From f4aeb1940c336d03252657677f3f812fce5f9463 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Tue, 16 Oct 2012 17:34:40 +0200 Subject: small fix for audio only stream --- src/audio.json | 46 ++++++++++++++++++++++++++++++++++++++++++++++ src/flufigut.py | 13 +++++++------ 2 files changed, 53 insertions(+), 6 deletions(-) create mode 100644 src/audio.json (limited to 'src') diff --git a/src/audio.json b/src/audio.json new file mode 100644 index 0000000..1d6e15c --- /dev/null +++ b/src/audio.json @@ -0,0 +1,46 @@ +{ + "globals":{ + "version": "0.10.0", + "name": "audio-only", + "description": "Audio only test", + "domain": "spreadspace.org", + "rrd-dir": "/var/lib/flumotion/rrd", + "manager": { + "machine": "calypso", + "host": "89.106.215.48", + "port": 7531, + "transport": "ssl" + }, + "formats": { + "ogg": { "muxer": "ogg", "audio": "vorbis" } + }, + "profiles": { + "high": { "audio": 160 }, + "medium": { "audio": 128 }, + "low": { "audio": 96 } + }, + "machines": { + "calypso": [ "input", "encoder-vorbis-160", "encoder-vorbis-128", "encoder-vorbis-96", + "muxer-ogg-high", "muxer-ogg-medium", "muxer-ogg-low", "streamer-local1" ] + } + }, + "input": { + "source": "decklink", + "samplerate": 48000, + "device": 0, + "connection": 0, + "audio-input": 0, + "mode": 16 + }, + "transcode": { + "ogg": [ "high", "medium", "low" ] + }, + "stream": { + "streamer-local": { + "formats": [ "ogg" ], + "type": "http", "count": 1, "port": 8000, + "max-con": 5, "burst-on-connect": 5, + "hostname": "audio" + } + } +} diff --git a/src/flufigut.py b/src/flufigut.py index b1e04af..1c0e538 100755 --- a/src/flufigut.py +++ b/src/flufigut.py @@ -105,12 +105,13 @@ for format in transcode.keys(): if input['samplerate'] != samplerate: samplerates.append(samplerate) for profile in transcode[format]: - resolution = globals['profiles'][profile]['video'] - if resolution not in resolutions: - if input['resolution'] != resolution: - if globals['resolutions'][resolution]['rate'] != globals['resolutions'][input['resolution']]['rate']: - raise SystemExit("ERROR: video rate conversion is not yet supported!!!") - resolutions.append(resolution) + if 'video' in globals['profiles'][profile]: + resolution = globals['profiles'][profile]['video'] + if resolution not in resolutions: + if input['resolution'] != resolution: + if globals['resolutions'][resolution]['rate'] != globals['resolutions'][input['resolution']]['rate']: + raise SystemExit("ERROR: video rate conversion is not yet supported!!!") + resolutions.append(resolution) for resolution in resolutions: if 'resize' not in worker: -- cgit v1.2.3