<%doc> USAGE DOCUMENTATION :: PLEASE LEAVE THIS AT THE TOP OF THIS FILE For Mako templating syntax documentation please visit: http://docs.makotemplates.org/en/latest/ Filename: stream_data.html Version: 0.1 Variable names: data [list] data :: Usable parameters == Global keys == media_type Returns the type of session. Either 'episode' or 'movie'. title Returns the name of the episode or movie. user Returns the name of the user. transcode_video_dec Returns the video transcode decision. Either 'transcode', 'copy' or 'direct play'. transcode_video_codec Returns the name of the video codec for any transcode session. transcode_height Returns the value of the video height for any transcode session. transcode_width Returns the value of the video width for any transcode session. transcode_audio_dec Returns the audio transcode decision. Either 'transcode', 'copy' or 'direct play'. transcode_audio_codec Returns the name of the audio codec for any transcode session. transcode_audio_channels Returns the number of audio channels for any transcode session. transcode_container Returns the type of container for any transcode session. container Returns the type of container for the original media. height Returns the value of the video height for the original media. bitrate Returns the value of the video bitrate for the original media. width Returns the value of the video width for the original media. aspect_ratio Returns the value of the video aspect ratio for the original media. video_framerate Returns the value of the video framerate for the original media. video_codec Returns the name of the video codec for the original media. audio_codec Returns the name of the audio codec for the original media. audio_channels Returns the number of audio channels for the original media. == Only if 'media_type' is 'episode' == grandparent_title Returns the name of the TV Show. DOCUMENTATION :: END % if data is not None:

#### % if data['media_type'] == 'episode' or data['media_type'] == 'track': Stream Info: ${data['grandparent_title']} - ${data['title']} (${user}) % else: Stream Info: ${data['title']} (${user}) % endif

#### Stream Details

##### Media

- Container: ${data['transcode_container'] if data['transcode_container'] else data['container']}
% if data['media_type'] != 'track':
- Resolution: ${data['transcode_height'] if data['transcode_height'] else data['height']}p
% endif

% if data['media_type'] != 'track':

##### Video

- Stream: ${data['transcode_video_dec']}
% if data['transcode_video_dec'] != 'direct play':
- Width: ${data['transcode_width']}
- Height: ${data['transcode_height']}
- Codec: ${data['transcode_video_codec']}
% else:
- Width: ${data['width']}
- Height: ${data['height']}
- Codec: ${data['video_codec']}
% endif

% endif

##### Audio

- Stream: ${data['transcode_audio_dec']}
% if data['transcode_audio_dec'] != 'direct play':
- Codec: ${data['transcode_audio_codec']}
- Channels: ${data['transcode_audio_channels']}
% else:
- Codec: ${data['audio_codec']}
- Channels: ${data['audio_channels']}
% endif

#### Source Details

##### Media

- Container: ${data['container']}
% if data['media_type'] != 'track':
- Resolution: ${data['video_resolution'] + 'p' if data['video_resolution'] != 'sd' else data['video_resolution']}
% endif
- Bitrate: ${data['bitrate']} kbps

% if data['media_type'] != 'track':

##### Video

- Width: ${data['width']}
- Height: ${data['height']}
- Codec: ${data['video_codec']}
- Aspect Ratio: ${data['aspect_ratio']}
- Frame Rate: ${data['video_framerate']}

% endif

##### Audio

- Codec: ${data['audio_codec']}
- Channels: ${data['audio_channels']}

% endif