aboutsummaryrefslogtreecommitdiff
path: root/model
diff options
context:
space:
mode:
authorMaZderMind2015-04-05 19:05:33 +0200
committerMaZderMind2015-04-05 19:05:33 +0200
commitc28560754e2e4f7bb79f32c97edbe36dbaed6d54 (patch)
tree30d999029ad2cad0bfd430f7501aba756d42a168 /model
parent02fb25f64021afde4f48699b54168b6816d8cb1e (diff)
Streams-JSON v1
Diffstat (limited to 'model')
-rw-r--r--model/Stream.php66
1 files changed, 62 insertions, 4 deletions
diff --git a/model/Stream.php b/model/Stream.php
index 402dfff..0d96a02 100644
--- a/model/Stream.php
+++ b/model/Stream.php
@@ -108,10 +108,30 @@ class Stream
case 'hls':
return 'http://cdn.c3voc.de/hls/'.rawurlencode($this->getRoom()->getStream()).'_'.rawurlencode($this->getLanguage()).'_'.rawurlencode($this->getSelection()).'.m3u8';
+ }
- default:
- return null;
+ return null;
+ }
+ public function getVideoTech($proto)
+ {
+ switch($proto)
+ {
+ case 'webm':
+ if($this->getSelection() == 'hd')
+ return '1920x1080, VP8+Vorbis in WebM, 2.8 MBit/s';
+
+ else if($this->getSelection() == 'sd')
+ return '1024x576, VP8+Vorbis in WebM, 800 kBit/s';
+
+ case 'hls':
+ if($this->getSelection() == 'hd')
+ return '1920x1080, h264+AAC im MPEG-TS-Container via HTTP, 3 MBit/s';
+
+ else if($this->getSelection() == 'sd')
+ return '1024x576, h264+AAC im MPEG-TS-Container via HTTP, 800 kBit/s';
}
+
+ return null;
}
public static function getVideoProtos()
{
@@ -125,6 +145,19 @@ class Stream
{
return $this->getVideoUrl($proto);
}
+ public function getSlidesTech($proto)
+ {
+ switch($proto)
+ {
+ case 'webm':
+ return '1024x576, VP8+Vorbis in WebM, XXX kBit/s';
+
+ case 'hls':
+ return '1024x576, h264+AAC im MPEG-TS-Container via HTTP, XXX kBit/s';
+ }
+
+ return null;
+ }
public static function getSlidesProtos()
{
return Stream::getVideoProtos();
@@ -140,10 +173,22 @@ class Stream
case 'opus':
return 'http://cdn.c3voc.de/'.rawurlencode($this->getRoom()->getStream()).'_'.rawurlencode($this->getLanguage()).'.opus';
+ }
- default:
- return null;
+ return null;
+ }
+ public function getAudioTech($proto)
+ {
+ switch($proto)
+ {
+ case 'mp3':
+ return 'MP3-Audio, 96 kBit/s';
+
+ case 'opus':
+ return 'Opus-Audio, 64 kBit/s';
}
+
+ return null;
}
public static function getAudioProtos()
{
@@ -167,6 +212,19 @@ class Stream
return null;
}
}
+ public function getMusicTech($proto)
+ {
+ switch($proto)
+ {
+ case 'mp3':
+ return 'MP3-Audio, 192 kBit/s';
+
+ case 'opus':
+ return 'Opus-Audio, 96 kBit/s';
+ }
+
+ return null;
+ }
public static function getMusicProtos()
{
return array(