Ejemplo n.º 1
0
        public void GenerateStoryboard(string inputFileName, StoryBoardOptions options)
        {
            Guard.NotNullOrEmpty(inputFileName, nameof(inputFileName));
            Guard.NotNull(options, nameof(options));

            this.FFmpegEngine(new EngineParameters
            {
                InputFile         = new MediaFile(inputFileName),
                StoryBoardOptions = options,
                Task = FFmpegTask.Storyboard
            });
        }
        public Task Storyboard(string inputFile, StoryBoardOptions options)
        {
            Guard.NotNullOrEmpty(inputFile, nameof(inputFile));

            if (!File.Exists(inputFile))
            {
                throw new FileNotFoundException(inputFile);
            }

            if (!Directory.Exists(options.OutputDirectory))
            {
                Directory.CreateDirectory(options.OutputDirectory);
            }

            return(Task.Run(() => _engine.GenerateStoryboard(inputFile, options)));
        }