summaryrefslogtreecommitdiff
path: root/voctocore
diff options
context:
space:
mode:
authorMaZderMind <github@mazdermind.de>2015-05-11 23:01:19 +0200
committerMaZderMind <github@mazdermind.de>2015-05-11 23:01:19 +0200
commit345b9eba28b3165f01ab681cf76bb624c0387aa3 (patch)
treea95deb4ac21a8d091d70a181199bab133e990980 /voctocore
parent14830e261e86e34ec249c73c6548119eba9d19da (diff)
remove obsolete audiomixer
Diffstat (limited to 'voctocore')
-rw-r--r--voctocore/lib/audiomix.py36
1 files changed, 0 insertions, 36 deletions
diff --git a/voctocore/lib/audiomix.py b/voctocore/lib/audiomix.py
deleted file mode 100644
index 326e7a5..0000000
--- a/voctocore/lib/audiomix.py
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/usr/bin/python3
-import time, logging
-from gi.repository import GLib, Gst
-
-from lib.config import Config
-
-class AudioMix(Gst.Bin):
- log = logging.getLogger('AudioMix')
- mixerpads = []
-
- def __init__(self):
- super().__init__()
-
- self.switch = Gst.ElementFactory.make('input-selector', 'switch')
-
- self.add(self.switch)
- self.switch.set_property('sync-streams', True)
- self.switch.set_property('sync-mode', 1) #GST_INPUT_SELECTOR_SYNC_MODE_CLOCK
- self.switch.set_property('cache-buffers', True)
-
- self.add_pad(
- Gst.GhostPad.new('src', self.switch.get_static_pad('src'))
- )
-
- def request_mixer_pad(self):
- mixerpad = self.switch.get_request_pad('sink_%u')
- self.mixerpads.append(mixerpad)
-
- self.log.info('requested mixerpad %u (named %s)', len(self.mixerpads) - 1, mixerpad.get_name())
- ghostpad = Gst.GhostPad.new(mixerpad.get_name(), mixerpad)
- self.add_pad(ghostpad)
- return ghostpad
-
- def set_active(self, target):
- self.log.info('switching to audiosource %u', target)
- self.switch.set_property('active-pad', self.mixerpads[target])