Skip to content

Instantly share code, notes, and snippets.

@jflo
Created February 9, 2015 23:38
Show Gist options
  • Save jflo/50b368ef6bbf916670fb to your computer and use it in GitHub Desktop.
Save jflo/50b368ef6bbf916670fb to your computer and use it in GitHub Desktop.
Plex profile for iOS-AppleTV which limits bitrate. Goes in the profiles directory.
<Client name="Apple TV (2nd generation)">
<TranscodeTargets>
<VideoProfile container="mp4" codec="h264" audioCodec="aac" context="all">
<!-- Inspired by Handbrake's profiles -->
<Setting name="VideoEncodeFlags" value="-x264opts bframes=3:cabac=1" />
</VideoProfile>
<VideoProfile protocol="hls" container="mpegts" codec="h264" audioCodec="aac,mp3" context="streaming">
<!-- Inspired by Handbrake's profiles -->
<Setting name="VideoEncodeFlags" value="-x264opts bframes=3:cabac=1" />
</VideoProfile>
<MusicProfile container="mp3" codec="mp3" />
<PhotoProfile container="jpeg" />
</TranscodeTargets>
<DirectPlayProfiles>
<VideoProfile container="mp4" codec="h264" audioCodec="aac" subtitleFormat="ttxt" />
<MusicProfile container="mp3" codec="mp3" />
<PhotoProfile container="jpeg" />
</DirectPlayProfiles>
<CodecProfiles>
<VideoCodec name="h264">
<Limitations>
<UpperBound name="video.width" value="1920" />
<UpperBound name="video.height" value="1080" />
<UpperBound name="video.bitrate" value="22000" isRequired="true" />
<UpperBound name="video.bitDepth" value="8" isRequired="false" />
<UpperBound name="video.refFrames" value="8" isRequired="false" />
</Limitations>
</VideoCodec>
<VideoAudioCodec name="aac">
<Limitations>
<UpperBound name="audio.channels" value="2" />
</Limitations>
</VideoAudioCodec>
<VideoAudioCodec name="mp3">
<Limitations>
<LowerBound name="audio.samplingRate" value="32000" />
<UpperBound name="audio.samplingRate" value="48000" />
<Match name="audio.samplingRate" regex="32000|44100|48000" />
</Limitations>
</VideoAudioCodec>
</CodecProfiles>
</Client>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment