Parameters for Transcoded Streaming Parameters are identifier=value pairs separated by an ampersand (&) character. They can be appended to an URL as query (beginning with a question mark) or entered in the expert mode input line of the streaming configuration page in the web interface. Example: http://127.0.0.1:8089/tv.html?preset=1&ffpeset=fast&delay=3000&chid=0 Identifier: chid Meaning: ID of the channel that shall be played Applicable to: all Possible values: zero-based channel number or channel ID Default: N/A Remarks: Channel IDs can be obtained from the DVBViewer channel list editor by right-clicking a channel -> Copy ID to Clipboard, or by requesting /api/getchannelsxml.html from the Recording Service. In contrast to channel numbers channel IDs do not depend on the channel order in the list. Identifier: recid Meaning: ID of the recording that shall be played Applicable to: all Possible values: one-based number resp. index of the recording in the recording database. Default: N/A Remarks: A list of the available recordings and their IDs can bei obtained from the Recording Service as XML by requesting /api/recordings.html Identifier: streamid Meaning: Identifies a stream (besides client IP and user agent) Applicable to: all Possible values: any (unique) character string Default: empty character string Remarks: By default the Recording Service does not allow more than one transcoded stream per client IP and user agent. If a client application tries to obtain two streams at the same time, the first one is stopped. This limitation can be circumvented by requesting streams with different stream ID. Identifier: preset Meaning: selects a preset from the file ffmpegpefs.ini (WebM, Flash, TS) or iphoneprefs.ini (HLS) Applicable to: all Possible values: zero based preset index (0 is the first preset in the INI file) or preset name (the name in square brackets from the INI file) Default: If no preset or an invalid preset is specified for video output, the Recording Service uses the first matching preset with a horizontal resolution <= 640 Remarks: Presets define different quality / bitrate levels for encoding. If a video preset is specified for radio / audio file playback the Recording Service automatically switches to an "audio only" preset. When using an "audio only" preset for TV or video, only audio will be played. Identifier: ffpreset Meaning: selects the encoder speed Applicable to: all Possible values: ultrafast, superfast, veryfast, faster, fast, medium, slow, slower, veryslow, placebo Default: veryfast Remarks: Faster encoding decreases the server CPU load and the video quality. A low encoding speed or too many trancoded streams may overstrain the server CPU and prevent other tasks from being executed. Identifier: vcodec Meaning: video codec for FFmpeg output. Applicable to: WebM Possible values: vp8 or vp9. Default: vp8 (specified in the default presets) Remarks: VP9 is the more advanced codec, but tends to consume a lor of CPU power. At the same speed level it shows no significant advantage over VP8. Identifier: acodec Meaning: audio codec for FFmpeg output Applicable to: all Possible values: vorbis or opus for WebM, mp3 or aac for TS, HLS, Flash. Default: vorbis / mp3 (specified in the default presets) Remarks: Opus as more advanced codec may provide a better WebM audio quality. The built-in FFmpeg AAC Encoder shows no significant advantage compared to MP3. Identifier: subs Meaning: display a DVB subtitle stream Applicable to: all Possible values: >= 0 Default: no subtitles (parameter not present) Remarks: 0 selects the first available DVB subtitle stream, 1 the second etc. Please note that specifying a non-existing subtitle stream may let FFmpeg stop and prevent playback altogether. The Recording Service works against this issue by adding a dummy subtitle stream to the FFmpeg input, so that playback will work with subs=0 even if there is no subtitle stream. subs=1 will prevent playback in this case, however. Identifier: seg Meaning: Number of pre-buffered segments Applicable to: HLS Possible values: >= 2 Default: 3 Remarks: Specifies how many stream segments the client can read ahead. Increasing the value decreases drop-outs, but also delays playback start. Identifier: segdur Meaning: Length of pre-buffered segments in seconds Applicable to: HLS TV/Radio Possible values: >= 1 Default: 2 Remarks: Increasing the value decreases drop-outs, but also delays playback start. seg=3&segdur=2 yields a delay of 3 x 2 = 6 seconds for buffering in the Recording Service. Identifier: delay Meaning: buffering delay in milliseconds Applicable to: WebM, Flash, TS Possible values: >= 0 Default: 2000 for WebM, otherwise 0 (specified in the default presets) Remarks: The buffered period of time before data delivery begins allows the client to read ahead. Increasing the value decreases drop-outs, but also delays playback start. Identifier: maxwidth Meaning: maximum horizontal output video resolution in pixel Applicable to: all Possible values: >= 320 Default: given by the selected preset Remarks: See keepres parameter for more information Identifier: maxheight Meaning: maximum vertical output video resolution in pixel Applicable to: all Possible values: >= 320 Default: given by the selected preset Remarks: See keepres parameter for more information Identifier: keepres Meaning: keep the horizontal or vertical video resolution Applicable to: all Possible values: h, v or hv Default: h Remarks: h: Keeps the horizontal resolution of the source video, if not limited by maxwidth, and calculates the vertical output resolution according to the source aspect ratio so that pixels are square (non-anamorphic output). maxheight is ignored. v: Keeps the vertical resolution of the source video, if not limited by maxheight, and calculates the horizontal output resolution according to the source aspect ratio so that pixels are square (non-anamorphic output). maxwidth is ignored. hv: Keeps the horizontal and vertical resolution of the source video, if not limited by maxwidth and maxheight. The output may be anamorphic with non-square pixels, requiring the client ability to scale the video to the correct aspect ratio. Example: A 720x576 anamorphic video input (SD TV) with an aspect ratio of 16:9 yields a 720x404 output with h, 1024x576 with v and 720x576 with hv, provided the output resolution is not limited to a lower value by maxwidth or maxheight.