aboutsummaryrefslogtreecommitdiff
path: root/voctocore/lib
diff options
context:
space:
mode:
Diffstat (limited to 'voctocore/lib')
-rw-r--r--voctocore/lib/avpreviewoutput.py16
1 files changed, 13 insertions, 3 deletions
diff --git a/voctocore/lib/avpreviewoutput.py b/voctocore/lib/avpreviewoutput.py
index 05f1ceb..2be4a52 100644
--- a/voctocore/lib/avpreviewoutput.py
+++ b/voctocore/lib/avpreviewoutput.py
@@ -124,12 +124,22 @@ class AVPreviewOutput(TCPMultiConnection):
def construct_native_video_pipeline(self, target_caps):
do_deinterlace = Config.getboolean('previews', 'deinterlace')
- return '''
+ if do_deinterlace:
+ pipeline = '''
+ deinterlace mode={imode} !
+ videorate !
+ '''
+ else:
+ pipeline = ''
+
+
+ pipeline += '''
videoscale !
{target_caps} !
- deinterlace mode={imode} !
jpegenc quality=90
- '''.format(
+ '''
+
+ return pipeline.format(
imode='interlaced' if do_deinterlace else 'disabled',
target_caps=target_caps,
)