diff options
| author | Martin Kaistra | 2015-03-04 11:54:29 +0100 |
|---|---|---|
| committer | Martin Kaistra | 2015-03-04 11:54:29 +0100 |
| commit | f08b23f261ea7ab2376688dad6a51289c4f9d183 (patch) | |
| tree | 2c625ac5407907bf304c079a1f347ef2949a2d49 | |
| parent | 8928d0345bfd41c63b37b3f7ea2606f519aee769 (diff) | |
don't terminate ffmpeg too early, fixes problems with windows. also: use matroska container instead of mp4
| -rw-r--r-- | main.py | 2 | ||||
| -rw-r--r-- | video_thread.py | 8 |
2 files changed, 6 insertions, 4 deletions
@@ -91,7 +91,7 @@ class Main(QtCore.QObject): outputDir = self.settings.value("outputDir", expanduser("~")) fileName = QtGui.QFileDialog.getSaveFileName(self.window, - "Set Output Video File", outputDir, "Video Files (*.mp4)"); + "Set Output Video File", outputDir, "Video Files (*.mkv)"); if not fileName == "": self.settings.setValue("outputDir", os.path.dirname(fileName)) diff --git a/video_thread.py b/video_thread.py index 37dd59d..5a8120b 100644 --- a/video_thread.py +++ b/video_thread.py @@ -42,8 +42,10 @@ class Worker(QtCore.QObject): '-an', '-i', inputFile, '-acodec', "libmp3lame", # output audio codec - '-vcodec', "h264", - '-pix_fmt', "yuv422p", + '-vcodec', "libx264", + '-pix_fmt', "yuv444p", + '-preset', "medium", + '-f', "matroska", outputFile], stdin=sp.PIPE,stdout=sys.stdout, stderr=sys.stdout) @@ -83,7 +85,7 @@ class Worker(QtCore.QObject): if out_pipe.stderr is not None: print(out_pipe.stderr.read()) out_pipe.stderr.close() - out_pipe.terminate() + # out_pipe.terminate() # don't terminate ffmpeg too early out_pipe.wait() print("Video file created") self.progressBarUpdate.emit(100) |
