aboutsummaryrefslogtreecommitdiff
path: root/voctocore/lib
diff options
context:
space:
mode:
authorMaZderMind <git@mazdermind.de>2016-08-12 20:18:42 +0200
committerMaZderMind <git@mazdermind.de>2016-08-12 20:19:15 +0200
commit0195680851cce0bc796ce9bb7c471131baf7b913 (patch)
treef2935689985b682fd22858ad9819e335d02d6cf8 /voctocore/lib
parentd136eddbc773923fba9e6ce63cb8f8da84e2eddb (diff)
makes y-positions in side-by-side-equal mode separate configurable, fixes #71
Diffstat (limited to 'voctocore/lib')
-rw-r--r--voctocore/lib/videomix.py27
1 files changed, 20 insertions, 7 deletions
diff --git a/voctocore/lib/videomix.py b/voctocore/lib/videomix.py
index 2fa9200..aa2bedc 100644
--- a/voctocore/lib/videomix.py
+++ b/voctocore/lib/videomix.py
@@ -150,30 +150,43 @@ class VideoMix(object):
targetWidth = int((width - gutter) / 2)
targetHeight = int(targetWidth / width * height)
- try:
- y = Config.getint('side-by-side-equal', 'ypos')
- self.log.debug('Y-Pos configured to %u', y)
- except:
- y = (height - targetHeight) / 2
- self.log.debug('Y-Pos calculated to %u', y)
+ self.log.debug('Video-Size calculated to %ux%u', targetWidth, targetHeight)
xa = 0
xb = width - targetWidth
+ y = (height - targetHeight) / 2
+
+ try:
+ ya = Config.getint('side-by-side-equal', 'atop')
+ self.log.debug('A-Video Y-Pos configured to %u', ya)
+ except:
+ ya = y
+ self.log.debug('A-Video Y-Pos calculated to %u', ya)
+
+
+ try:
+ yb = Config.getint('side-by-side-equal', 'btop')
+ self.log.debug('B-Video Y-Pos configured to %u', yb)
+ except:
+ yb = y
+ self.log.debug('B-Video Y-Pos calculated to %u', yb)
+
for idx, name in enumerate(self.names):
pad = self.padState[idx]
pad.reset()
- pad.ypos = y
pad.width = targetWidth
pad.height = targetHeight
if idx == self.sourceA:
pad.xpos = xa
+ pad.ypos = ya
pad.zorder = 1
elif idx == self.sourceB:
pad.xpos = xb
+ pad.ypos = yb
pad.zorder = 2
else: