fixing a bug found by @CardinalPanda

This commit is contained in:
k4yt3x 2019-06-05 12:18:51 -04:00
parent 4cf83dc565
commit 0f4daa12d2
2 changed files with 8 additions and 4 deletions

View File

@ -4,7 +4,7 @@
Name: FFMPEG Class Name: FFMPEG Class
Author: K4YT3X Author: K4YT3X
Date Created: Feb 24, 2018 Date Created: Feb 24, 2018
Last Modified: May 4, 2019 Last Modified: June 5, 2019
Description: This class handles all FFMPEG related Description: This class handles all FFMPEG related
operations. operations.
@ -80,14 +80,16 @@ class Ffmpeg:
self.ffmpeg_binary self.ffmpeg_binary
] ]
execute.extend(self._read_configuration(phase='video_to_frames'))
execute.extend([ execute.extend([
'-i', '-i',
input_video, input_video,
f'{extracted_frames}\\extracted_%0d.{self.image_format}' f'{extracted_frames}\\extracted_%0d.{self.image_format}'
]) ])
execute.extend(self._read_configuration(phase='video_to_frames', section='output_options'))
execute.extend(self._read_configuration(phase='video_to_frames'))
self._execute(execute) self._execute(execute)
def convert_video(self, framerate, resolution, upscaled_frames): def convert_video(self, framerate, resolution, upscaled_frames):

View File

@ -42,7 +42,9 @@
"ffmpeg": { "ffmpeg": {
"ffmpeg_path": "C:\\Users\\K4YT3X\\AppData\\Local\\video2x\\ffmpeg-latest-win64-static\\bin", "ffmpeg_path": "C:\\Users\\K4YT3X\\AppData\\Local\\video2x\\ffmpeg-latest-win64-static\\bin",
"video_to_frames": { "video_to_frames": {
"-qscale:v": null, "output_options":{
"-qscale:v": null
},
"-hwaccel": "auto", "-hwaccel": "auto",
"-y": true "-y": true
}, },