# Transcoder Action & File formats

**URL:** <https://forums.plex.tv/t/transcoder-action-file-formats/90683>\
**Category:** Apps & Creations\
**Created:** [January 20, 2015, 1:02pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683 "2015-01-20T13:02:13Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 20, 2015, 1:02pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/1 "2015-01-20T13:02:13Z")

</div>

I know this is a well covered topic, but I'm at a loss. &nbsp;I'm trying to make sur emy files are in a format most suitable to DirectPlay on my ATV3. &nbsp;Most of my material is in MKV format which I know requires transcoding.

&nbsp;

I have used ffmpeg to convert my MKV files to MP4, retaining the H264 video. &nbsp;It's the audio format that has me baffled.

&nbsp;

Transcoder Action = DirectPlay - Video plays fine

AAC 5.1 play in Stereo &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;(PMS not transcoding - obviously)

AC3 5.1 plays in surround &nbsp; &nbsp; (PMS not transcoding - obviously)

&nbsp;

Transcoder Action = Auto - Video plays with some interruptions (slow CPU on PMS)

AAC 5.1 plays in surround &nbsp; &nbsp;(PMS transcoding both audio and video)

AC3 5.1 plays in surround &nbsp; &nbsp;(PMS transcoding video only)

&nbsp;

So now I'm confused. &nbsp;I thought AppleTV supported AAC so it wouldn't need transcoding. &nbsp;And why is the H264 video being transcoded when AppleTV supports H264 in an MP4 container?

&nbsp;

Can someone wiser than I am offer some guidance please?

---

<div class="post-metadata">

**Author:** ![BobSnot](https://avatars.discourse-cdn.com/v4/letter/b/94ad74/32.png) [@BobSnot](https://forums.plex.tv/u/BobSnot)\
**Post date:** [January 20, 2015, 1:05pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/2 "2015-01-20T13:05:31Z")

</div>

> I know this is a well covered topic, but I'm at a loss. &nbsp;I'm trying to make sur emy files are in a format most suitable to DirectPlay on my ATV3. &nbsp;Most of my material is in MKV format which I know requires transcoding.
> 
> I have used ffmpeg to convert my MKV files to MP4, retaining the H264 video. &nbsp;It's the audio format that has me baffled.
> 
> Transcoder Action = DirectPlay - Video plays fine
> 
> AAC 5.1 play in Stereo &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;(PMS not transcoding - obviously)
> 
> AC3 5.1 plays in surround &nbsp; &nbsp; (PMS not transcoding - obviously)
> 
> Transcoder Action = Auto - Video plays with some interruptions (slow CPU on PMS)
> 
> AAC 5.1 plays in surround &nbsp; &nbsp;(PMS transcoding both audio and video)
> 
> AC3 5.1 plays in surround &nbsp; &nbsp;(PMS transcoding video only)
> 
> So now I'm confused. &nbsp;I thought AppleTV supported AAC so it wouldn't need transcoding. &nbsp;And why is the H264 video being transcoded when AppleTV supports H264 in an MP4 container?
> 
> Can someone wiser than I am offer some guidance please?

1) are your .mp4 containers flagged as "web optimized aka optimized for streaming"?

2) are you sure the ATV supports 5.1 AAC, or only 2.0 AAC?

---

<div class="post-metadata">

**Author:** ![roidy](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/roidy/32/128627_2.png) [@roidy](https://forums.plex.tv/u/roidy)\
**Post date:** [January 20, 2015, 3:26pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/3 "2015-01-20T15:26:47Z")

</div>

AFAIK the aTV only support 2 channel AAC so if you feed it a 5.1 AAC track it will only play the Front Left and Right channels.  
  
A properly encoded aTV file should contain 2 audio tracks, the first being AAC 2.0 and the second being AC3 5.1, this is how all the iTunes store content is encoded.  
  
I use this set of python scripts:- [https://github.com/mdhiggins/sickbeard\_mp4\_automator/](https://github.com/mdhiggins/sickbeard_mp4_automator/) to remux all my mkv’s to an apple friendly format.  
  
Just download it set up the correct ffmpeg path locations and run:-  
&nbsp;

```
python manual.py -I inputfile.mkv
```
It will remux the mkv to an apple friendly format with both AAC 2.0 and AC3 5.1 audio tracks.  
  
It also does some other cool stuff like tagging the file with iTunes metadata from theTVdb and theMoviedb, which is great because if there is ever a time when Apple stops PlexConnect from working then all my media is ready to go straight back into iTunes 🙂  
  
It also allows you to add subtitle tracks to the remuxed file and will even pull them for you from the internet.

---

<div class="post-metadata">

**Author:** ![pecinko](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/pecinko/32/933_2.png) [@pecinko](https://forums.plex.tv/u/pecinko)\
**Post date:** [January 21, 2015, 11:02am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/4 "2015-01-21T11:02:04Z")

</div>

For those on mac OS X wanting simpler to use, GUI approach - Subler (video&audio) + SubsMarine (subtitles)

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 21, 2015, 6:28pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/5 "2015-01-21T18:28:03Z")

</div>

> AFAIK the aTV only support 2 channel AAC so if you feed it a 5.1 AAC track it will only play the Front Left and Right channels.  
>   
> A properly encoded aTV file should contain 2 audio tracks, the first being AAC 2.0 and the second being AC3 5.1, this is how all the iTunes store content is encoded.  
>   
> I use this set of python scripts:- [https://github.com/mdhiggins/sickbeard\_mp4\_automator/](https://github.com/mdhiggins/sickbeard_mp4_automator/) to remux all my mkv's to an apple friendly format.  
>   
> Just download it set up the correct ffmpeg path locations and run:-  
> &nbsp;
> 
> ```
> python manual.py -I inputfile.mkv
> ```
> It will remux the mkv to an apple friendly format with both AAC 2.0 and AC3 5.1 audio tracks.  
>   
> It also does some other cool stuff like tagging the file with iTunes metadata from theTVdb and theMoviedb, which is great because if there is ever a time when Apple stops PlexConnect from working then all my media is ready to go straight back into iTunes :)  
>   
> It also allows you to add subtitle tracks to the remuxed file and will even pull them for you from the internet.

Thanks for the link to the scripts, they are working perfectly for me on my Synology NAS. &nbsp;

I do have one question, however.

Which audio track do I choose to play on my ATV3? &nbsp;No matter whether I choose the AAC track or the AC3 track, my receiver (Yamaha RX-V1900) still seem to think it's getting a stereo signal. &nbsp;In thepast there was an audible click and the surround sound speaker icons lit up on the receiver, this no longer happens. &nbsp;Although I do get audio through all the speakers. &nbsp;I can only assume the receiver is getting a stereo signal and using its own DSP to "synthesise" surround sound rather than playing the original channels from the source media. &nbsp;Is that correct?

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 22, 2015, 6:56am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/6 "2015-01-22T06:56:07Z")

</div>

A little more information to try and highlight my point and assist troubleshooting. &nbsp;

ATV 3, with plex connect & transcoder action set to "DirectPlay" and DTS passthrough on the ATV enabled.

This file plays true surround sound on my receiver&nbsp;

```
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Blue Bloods - S03E18 - No Regrets.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf56.19.100
  Duration: 00:44:00.26, start: 0.000000, bitrate: 3332 kb/s
    Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709/unknown/unknown), 1280x720, 2942 kb/s, 23.98 fps, 23.98 tbr, 16k tbn, 47.95 tbc (default)
    Metadata:
      handler_name    : VideoHandler
    Stream #0:1(und): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
```

&nbsp;

&nbsp;

While this file (converted with the script roidy suggested) only plays stereo, no matter which audio track I pick

&nbsp;

```
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '../../Suits/Season 04/Suits - S04E01 - One-Two-Three Goâ¦.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
  [metadata removed]
  Duration: 00:43:01.95, start: 0.021333, bitrate: 3033 kb/s
    Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 2383 kb/s, 23.98 fps, 23.98 tbr, 16k tbn, 47.95 tbc (default)
    Metadata:
      handler_name    : VideoHandler
    Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 256 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
```

&nbsp;

---

<div class="post-metadata">

**Author:** ![wahlman.j](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wahlman.j/32/6441_2.png) [@wahlman.j](https://forums.plex.tv/u/wahlman.j)\
**Post date:** [January 22, 2015, 7:38am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/7 "2015-01-22T07:38:45Z")

</div>

Make sure your PMS settings are set to enable dd for ATV. On your Yamaha make sure your audio settings are set to auto detect audio source input. On your ATV make sure you have dd enabled in the native apple settings.app. The aTV3 currently only can output dd. I believe the aTV2 can output DTS if it’s jailbroken using xbmc.app using the plugin [Plexbmc](http://kodi.wiki/view/Add-on:PleXBMC). This assumes the content on PMS is dd or DTS.

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 22, 2015, 7:41am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/8 "2015-01-22T07:41:57Z")

</div>

Thanks for the info, I’ve enabled all of the setting you suggest and still the dual audio files play in stereo. What I don’t understand is that when the file has an AC3 5.1 track only it works but when there’s an AAC track present it doesn’t.

---

<div class="post-metadata">

**Author:** ![wahlman.j](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wahlman.j/32/6441_2.png) [@wahlman.j](https://forums.plex.tv/u/wahlman.j)\
**Post date:** [January 22, 2015, 7:52am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/9 "2015-01-22T07:52:52Z")

</div>

There should be a setting in your receiver to auto detect dd when it’s outputed. How is your aTV wired to the Yamaha? What aTV do you have 2 or 3?

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 22, 2015, 8:00am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/10 "2015-01-22T08:00:02Z")

</div>

There is, and that is enabled. &nbsp;It's an ATV3 and I've tried both HDMI and toslink-optical (both into the receiver). &nbsp;The current wiring is ATV3 --\> Yamaha --\> TV (with the "passthrough" on the Yamaha set to AMP only)

If I play a Netflix video it automatically triggers the dd on the receiver, the same if I force transcoding from the PMS or if I play a file with only an AC3 5.1 stream in it (as described in my post above). &nbsp;I'm baffled. &nbsp;Everything I've read seems to suggest that for the best compatibility I should have a stereo AAC stream as well as a dd AC3 5.1 stream in the file.

---

<div class="post-metadata">

**Author:** ![wahlman.j](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wahlman.j/32/6441_2.png) [@wahlman.j](https://forums.plex.tv/u/wahlman.j)\
**Post date:** [January 22, 2015, 8:02am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/11 "2015-01-22T08:02:44Z")

</div>

Well if the file in question is DTS I don’t think it would work due to the aTV3 only being able to output dd currently. You would need to rip it in a dd format for it to work I believe. I’m not sure if PlexConnect can downconvert (switch to dd) a DTS file to dd, I would assume not. The file would need to be a dd format to begin with I believe.

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 22, 2015, 8:27am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/12 "2015-01-22T08:27:42Z")

</div>

As you can see from the ffprobe output above, the file contains AC3 5.1 (which is DD as far as I understand) so I have not DTS streams to get in the way. &nbsp;And as I said earlier, a file with&nbsp; **only** an AC3 5.1 stream works fine, the issue seems to come in when I add the stereo AAC stream (as suggested for true ATV compatibility).

Could it have something to do with the PMS profile for Apple TV? &nbsp;I'm not sure how PMS profiles are implemented but mine looks like this:

```
<?xml version="1.0" encoding="utf-8"?>

  
    
      
      
    
    
      
      
    
    
    
  
  
    
    
    
  
  
    
      
        
        
        
        
      
    
    
      
        
      
    
    
      
        
        
        
      
    
 
```

---

<div class="post-metadata">

**Author:** ![wahlman.j](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wahlman.j/32/6441_2.png) [@wahlman.j](https://forums.plex.tv/u/wahlman.j)\
**Post date:** [January 22, 2015, 8:46am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/13 "2015-01-22T08:46:45Z")

</div>

Why not just make the file in question the same as the working format or do you have quite a few with the same issue?

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 22, 2015, 8:50am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/14 "2015-01-22T08:50:08Z")

</div>

That’s what I’m going to resort to, removing the AAC stream and leaving the AC3 stream, but it’s against everything I’ve read on this and other forums about the right format for AppleTV.

---

<div class="post-metadata">

**Author:** ![wahlman.j](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/wahlman.j/32/6441_2.png) [@wahlman.j](https://forums.plex.tv/u/wahlman.j)\
**Post date:** [January 22, 2015, 9:01am UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/15 "2015-01-22T09:01:03Z")

</div>

I wish I could help you further but maybe someone else with better knowledge on the subject can assist you further. Personally I would just go with the working format for now unless someone knows a better solution to your issue so you don’t need to change the format. Sounds like you have most of it figured out since some of them do play dd.

---

<div class="post-metadata">

**Author:** ![roidy](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/roidy/32/128627_2.png) [@roidy](https://forums.plex.tv/u/roidy)\
**Post date:** [January 22, 2015, 1:30pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/16 "2015-01-22T13:30:02Z")

</div>

> Could it have something to do with the PMS profile for Apple TV? &nbsp;I'm not sure how PMS profiles are implemented but mine looks like this:

  
No, because if you've remuxed these files to proper aTV formatted m4v files then PMS/PlexConnect will natively direct-play them and the aTV should natively decide which audio track to play based on weather or not you've got "Dolby Digital" turned on in the main aTV "Audio & Video" settings.  
  
Check and make sure in PlexConnect on the aTV that "Settings"-\>"Transcoder Action" is set to "Auto" or "DirectPlay"

---

<div class="post-metadata">

**Author:** ![beerygaz\_1](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@beerygaz\_1](https://forums.plex.tv/u/beerygaz_1)\
**Post date:** [January 22, 2015, 3:26pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/17 "2015-01-22T15:26:08Z")

</div>

Thanks for trying to help roidy. &nbsp;They are mp4 not m4v files, is that where I'm going wrong? &nbsp;I do have "Dolby Digital" turned on on the ATV itself as you suggest, and I have set "Transcoder Action" to "DirectPlay". &nbsp;If I set it to "Auto" then I can see my PMS fire up a transcoder thread, so something is definitely wrong.

---

<div class="post-metadata">

**Author:** ![BobSnot](https://avatars.discourse-cdn.com/v4/letter/b/94ad74/32.png) [@BobSnot](https://forums.plex.tv/u/BobSnot)\
**Post date:** [January 22, 2015, 3:28pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/18 "2015-01-22T15:28:43Z")

</div>

> Thanks for trying to help roidy. &nbsp;They are mp4 not m4v files, is that where I'm going wrong? &nbsp;I do have "Dolby Digital" turned on on the ATV itself as you suggest, and I have set "Transcoder Action" to "DirectPlay". &nbsp;If I set it to "Auto" then I can see my PMS fire up a transcoder thread, so something is definitely wrong.

mp4 and m4v are 99.9% the exact same thing. (m4v can cater for drm and a few optional things which you aren't actually using anyway) - if you are not using those optional things, they only difference is the file extension.

---

<div class="post-metadata">

**Author:** ![roidy](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/roidy/32/128627_2.png) [@roidy](https://forums.plex.tv/u/roidy)\
**Post date:** [January 22, 2015, 3:39pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/19 "2015-01-22T15:39:38Z")

</div>

> They are mp4 not m4v files, is that where I'm going wrong?

  
I suspect so... as Bob Snot said mp4 and m4v are 99.9% the same... however the m4v extension tells the aTV to passthru the AC3 audio, it also allow the file to contain chapter marker, but that's irrelevant. Try just renaming the file from .mp4 to .m4v

---

<div class="post-metadata">

**Author:** ![pecinko](https://sea1.discourse-cdn.com/plex/user_avatar/forums.plex.tv/pecinko/32/933_2.png) [@pecinko](https://forums.plex.tv/u/pecinko)\
**Post date:** [January 22, 2015, 5:00pm UTC](https://forums.plex.tv/t/transcoder-action-file-formats/90683/20 "2015-01-22T17:00:20Z")

</div>

> There is, and that is enabled. &nbsp;It's an ATV3 and I've tried both HDMI and toslink-optical (both into the receiver). &nbsp;The current wiring is ATV3 --\> Yamaha --\> TV (with the "passthrough" on the Yamaha set to AMP only)
> 
> If I play a Netflix video it automatically triggers the dd on the receiver, the same if I force transcoding from the PMS or if I play a file with only an AC3 5.1 stream in it (as described in my post above). &nbsp;I'm baffled. &nbsp;Everything I've read seems to suggest that for the best compatibility I should have a stereo AAC stream as well as a dd AC3 5.1 stream in the file.

Supported formats:

**Audio Formats**

- HE-AAC (V1), AAC (16 to 320 Kbps), protected AAC (from iTunes Store), MP3 (16 to 320 Kbps), MP3 VBR, Audible (formats 2, 3, and 4), Apple Lossless, AIFF, and WAV; Dolby Digital 5.1 surround sound pass-through

I read this as no AAC 5.1 (AAC Dolby Pro Logic II should work) only stereo.

[Next page](https://forums.plex.tv/t/transcoder-action-file-formats/90683.md?page=2)
