Support for Apple Spatial Audio

Running Plex on a Synology NAS. Had to get in to the shell via terminal to add the iOS.xml file. Got it in there and restarted, but after that I got ‘Couldn’t create the playback session for this item’ on any iOS device. Made sure the file was correct and that the syntax was correct. I didn’t have to create a profiles folder as there was already one there with at least 30 separate xml files. Not sure what to do at this point.

Fantastic! this worked for me, of course not for all content but at least working for some content.

I just try this solution and for me spacial audio is only working when switching in pip mode…

When you say ‘create a file’ do you mean just something like a text edit file and rename the extension to xml?

Yes, exactly that

You have to switch to the old player in Plex preferences.

1 Like

@AgentMax Thanks! This worked great for me, although there was already an iOS.xml profile – it seemed to be containing older info though.
On my OpenMediaVault server, the file was located in /usr/lib/plexmediaserver/Resources/Profiles
After I replaced the contents with yours and restarted the server, spatial started working.

1 Like

Is there any way to set up the profile to always force transcoding of audio formats Spatial Audio won’t accept to the formats it will for 5.1, 7.1, and Atmos content? I’m more concerned with compatibility than audio fidelity. I can’t hear the difference between DTS/TrueHD and their DD counterparts in my setup anyway.

Can we set up a similar profile for the Apple TV? I watch TV with my AirPods often and it would be exciting to get Spatial Audio working with both my iPhone and TV for all of my Plex content.

For me doesn’t work. Plex media server on Synology NAS and iPad Pro.
I’ve put the file in the new created folder Profiles here

/Plex/Library/Application Support/Plex Media Server

Tried the profile on several Synology NAS and it doesn’t work on all of them…

I’ve checked Plex dashboard during playback and on those on which it doesn’t work, the audio is transcoded instead of direct streamed (with the same content)…

Finally, I found out that a parameter needs to be enabled: transcoder > disable video stream transcoding

Now it works perfectly!

The above code worked for me. Now, is it possible to have Plex transcode all audio tracks for iOS devices only to AC3 to have spatial audio to work.

Figured it out… Changed the code, removed acc, and replaced with eac3 and replace all others and only left eac3 on video trans. Works like a charm!

2 Likes

@Saiks Do you mean DTS transcoded to EAC3 too?
Can you please share your XML file?

1 Like

@W_75 here you go… Its transcodes everything to eac3.

<?xml version="1.0" encoding="utf-8"?>
<Client name="iOS">
  <!-- Author: Plex Inc. -->
  <!-- This profile is used by A5 and higher devices (starting with iPhone 4S and iPad 3) -->
  <Settings>
    <Setting name="DirectPlayStreamSelection" value="true" />
    <Setting name="StreamUnselectedIncompatibleAudioStreams" value="true" />
  </Settings>
  <TranscodeTargets>
    <VideoProfile container="mp4" codec="h264" audioCodec="eac3" subtitleCodec="mov_text" context="static" />
	<VideoProfile protocol="hls" container="mp4" codec="h264" audioCodec="eac3" subtitleCodec="eia_608_embedded" context="streaming" />
	<VideoProfile protocol="hls" container="mp4" codec="hevc" audioCodec="eac3" subtitleCodec="eia_608_embedded" context="streaming" />
    <MusicProfile container="mp4" codec="aac" />
    <PhotoProfile container="jpeg" />
    <SubtitleProfile protocol="hls" container="webvtt" subtitleCodec="webvtt"/>
  </TranscodeTargets>
  <DirectPlayProfiles>
    <VideoProfile container="mp4" codec="h264" audioCodec="eac3" subtitleCodec="mov_text,tx3g,ttxt,text" />
    <VideoProfile container="mp4" codec="hevc" audioCodec="eac3" subtitleCodec="mov_text,tx3g,ttxt,text" />
    <VideoProfile container="mov" codec="h264" audioCodec="eac3" subtitleCodec="mov_text,tx3g,ttxt,text" />
    <!-- Allow Direct Play of HLS content  -->
	<VideoProfile protocol="hls" container="mpegts" codec="h264" audioCodec="eac3" />
	<VideoProfile protocol="hls" container="mp4" codec="h264" audioCodec="eac3" />
	<VideoProfile protocol="hls" container="mp4" codec="hevc" audioCodec="eac3" />
    <MusicProfile container="mp3" codec="mp3" />
    <MusicProfile container="mp4" codec="aac" />
    <MusicProfile container="mp4" codec="alac" />
	<MusicProfile container="flac" codec="flac" />
    <PhotoProfile container="jpeg,gif,bmp,png" />
  </DirectPlayProfiles>
  <CodecProfiles>
    <VideoCodec name="h264">
      <Limitations>
        <UpperBound name="video.width" value="3840" isRequired="true" />
        <UpperBound name="video.height" value="2160" isRequired="true" />
        <UpperBound name="video.bitDepth" value="8" />
        <NotMatch name="video.separateFields" value="1" />
      </Limitations>
    </VideoCodec>
    <VideoCodec name="hevc">
      <Limitations>
        <UpperBound name="video.width" value="3840" isRequired="true" />
        <UpperBound name="video.height" value="2160" isRequired="true" />
        <UpperBound name="video.bitDepth" value="10" />
        <NotMatch name="video.separateFields" value="1" />
        <UpperBound name="video.width" value="1920" onlyTranscodes="true" />
        <UpperBound name="video.height" value="1080" onlyTranscodes="true" />
        <UpperBound name="video.bitDepth" value="8" onlyTranscodes="true" />
      </Limitations>
    </VideoCodec>
    <VideoAudioCodec name="*">
      <Limitations>
        <UpperBound name="audio.channels" value="2" onlyTranscodes="true" />
      </Limitations>
    </VideoAudioCodec>
  </CodecProfiles>
</Client>
6 Likes

@Saiks Thanks
Tested on my Synology, it still transcodes DTS to AAC :confused:
image

Did you restart the server?

Yes, I did

It’s showing web - Safari. Use the Plex iOS app.

2 Likes

Thank you!
It’s working with the Plex app :pray:t3:
image

1 Like

for me unfortunately still doesn’t work
Screenshot 2020-10-12 at 20.42.58

it works only with the old media player enabled.
any special settings in the iPad app?
thanks