diff options
author | MaZderMind <git@mazdermind.de> | 2015-12-03 00:44:22 +0100 |
---|---|---|
committer | MaZderMind <git@mazdermind.de> | 2015-12-03 00:44:22 +0100 |
commit | 331f1dc3fc5ee57c4714a0f5d78160e8aec9cbff (patch) | |
tree | 924ca1f2e67a7c9971f355631f75590506afe76d /voctogui/lib/videodisplay.py | |
parent | cfae754c4a5d20431a42ed8d3864eec51de3c490 (diff) |
[voctogui] implement warning-overlay in gtk instead of rendering it into the video
Diffstat (limited to 'voctogui/lib/videodisplay.py')
-rw-r--r-- | voctogui/lib/videodisplay.py | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/voctogui/lib/videodisplay.py b/voctogui/lib/videodisplay.py index 4195d70..bec6789 100644 --- a/voctogui/lib/videodisplay.py +++ b/voctogui/lib/videodisplay.py @@ -6,11 +6,10 @@ from lib.config import Config class VideoDisplay(object): """ Displays a Voctomix-Video-Stream into a GtkWidget """ - def __init__(self, drawing_area, port, play_audio=False, draw_callback=None, level_callback=None): + def __init__(self, drawing_area, port, play_audio=False, level_callback=None): self.log = logging.getLogger('VideoDisplay[%s]' % drawing_area.get_name()) self.drawing_area = drawing_area - self.draw_callback = draw_callback self.level_callback = level_callback caps = Config.get('mix', 'videocaps') @@ -49,14 +48,6 @@ class VideoDisplay(object): queue ! """ - # If an overlay is required, add an cairooverlay-Element into the Video-Path - if self.draw_callback: - pipeline += """ - videoconvert ! - cairooverlay name=overlay ! - videoconvert ! - """ - # Video Display if Config.getboolean('x11', 'xv'): pipeline += """ @@ -118,9 +109,6 @@ class VideoDisplay(object): if self.level_callback: bus.connect("message::element", self.on_level) - if self.draw_callback: - self.pipeline.get_by_name('overlay').connect('draw', self.on_draw) - self.log.debug('Launching Display-Pipeline') self.pipeline.set_state(Gst.State.PLAYING) @@ -146,6 +134,3 @@ class VideoDisplay(object): peaks = msg.get_structure().get_value('peak') rms = msg.get_structure().get_value('rms') self.level_callback(peaks, rms) - - def on_draw(self, cairooverlay, cr, timestamp, duration): - self.draw_callback(cr, timestamp, duration) |