iOS/Andriod devices forcing transcoding of HLS

Any reason why that would be?

 

It works on Chrome (via flash), PHT and Safari (via HTML video as I don't have flash installed system wide). When I try it on iOS or Android devices it always tries to transcode (and obviously fails).

 

Code:

CHANNEL_OBJECT              = VideoClipObject(
        key                     = Callback(
            CreateChannelEpisodeObject,
            TITLE               = TITLE,
            URL                 = URL,
            INCLUDE_CONTAINER   = True
        ),
        rating_key              = URL,
        title                   = TITLE,
        items                   = [
            MediaObject(
                video_resolution        = 576,
                width                   = 704,
                height                  = 576,
                audio_channels          = 2,
                parts                   =   [
                    PartObject(
                        key             = HTTPLiveStreamURL(
                            url         = URL
                        )
                    )
                ]
            )
        ]
    )

Logs:

Aug 13, 2014 12:57:34 [0x104df1000] DEBUG - Request: [10.0.0.15:56122] GET /video/premieradlive/:/function/CreateChannelEpisodeObject?function_args=Y2VyZWFsMQoxCmRpY3QKMwpzMTIwCmh0dHA6Ly8xNzMuMjU1LjEzNS42NDoxOTM1L25lbWVzaXMvcGxhZDEvcGxheWxpc3QubTN1OD91c2VybmFtZT1wYXBhbG96YXJvdSZwYXNzd29yZD0kUCRCaENqMEJiM1oyUk9VLlJrcGZvVlRyVzlmTmpDNVUuCnMzClVSTGIxczE3CklOQ0xVREVfQ09OVEFJTkVSczMKU1MxczUKVElUTEVyMAo_&X-Plex-Device=iPad&X-Plex-Client-Platform=iOS&X-Plex-Device-Name=LozPad&X-Plex-Language=en&X-Plex-Model=4%2C5&X-Plex-Platform=iOS&X-Plex-Client-Identifier=D6F345A6-3641-4DD5-8EEA-747DB8854DF5&X-Plex-Product=Plex%2FiOS&X-Plex-Platform-Version=7.1.2&X-Plex-Version=3.5.1 (4 live)
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * function_args => Y2VyZWFsMQoxCmRpY3QKMwpzMTIwCmh0dHA6Ly8xNzMuMjU1LjEzNS42NDoxOTM1L25lbWVzaXMvcGxhZDEvcGxheWxpc3QubTN1OD91c2VybmFtZT1wYXBhbG96YXJvdSZwYXNzd29yZD0kUCRCaENqMEJiM1oyUk9VLlJrcGZvVlRyVzlmTmpDNVUuCnMzClVSTGIxczE3CklOQ0xVREVfQ09OVEFJTkVSczMKU1MxczUKVElUTEVyMAo_
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Device => iPad
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Client-Platform => iOS
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Device-Name => LozPad
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Language => en
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Model => 4,5
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Platform => iOS
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Client-Identifier => D6F345A6-3641-4DD5-8EEA-747DB8854DF5
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Product => Plex/iOS
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Platform-Version => 7.1.2
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG -  * X-Plex-Version => 3.5.1
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG - Plug-in com.plexapp.plugins.premieradlive has been used 388 times.
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG - [com.plexapp.plugins.premieradlive] Sending command over HTTP (GET): /video/premieradlive/:/function/CreateChannelEpisodeObject?function_args=Y2VyZWFsMQoxCmRpY3QKMwpzMTIwCmh0dHA6Ly8xNzMuMjU1LjEzNS42NDoxOTM1L25lbWVzaXMvcGxhZDEvcGxheWxpc3QubTN1OD91c2VybmFtZT1wYXBhbG96YXJvdSZwYXNzd29yZD0kUCRCaENqMEJiM1oyUk9VLlJrcGZvVlRyVzlmTmpDNVUuCnMzClVSTGIxczE3CklOQ0xVREVfQ09OVEFJTkVSczMKU1MxczUKVElUTEVyMAo_
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG - HTTP requesting to: http://127.0.0.1:49694/video/premieradlive/:/function/CreateChannelEpisodeObject?function_args=Y2VyZWFsMQoxCmRpY3QKMwpzMTIwCmh0dHA6Ly8xNzMuMjU1LjEzNS42NDoxOTM1L25lbWVzaXMvcGxhZDEvcGxheWxpc3QubTN1OD91c2VybmFtZT1wYXBhbG96YXJvdSZwYXNzd29yZD0kUCRCaENqMEJiM1oyUk9VLlJrcGZvVlRyVzlmTmpDNVUuCnMzClVSTGIxczE3CklOQ0xVREVfQ09OVEFJTkVSczMKU1MxczUKVElUTEVyMAo_
Aug 13, 2014 12:57:34 [0x104df1000] DEBUG - [com.plexapp.plugins.premieradlive] HTTP reply status 200, with 1480 bytes of content.
Aug 13, 2014 12:57:36 [0x10be8a000] DEBUG - Request: [10.0.0.15:56125] GET /video/:/transcode/universal/start.m3u8?audioBoost=100&path=http%3A%2F%2F127.0.0.1%3A32400%2Fvideo%2Fpremieradlive%2F%3A%2Ffunction%2FCreateChannelEpisodeObject%3Ffunction_args

Can you grab the XML returned from PMS for the CreateChannelEpisodeObject() function? From the log above, you should be able to hit the following URL with a browser (or curl):

http://127.0.0.1:49694/video/premieradlive/:/function/CreateChannelEpisodeObject?function_args=Y2VyZWFsMQoxCmRpY3QKMwpzMTIwCmh0dHA6Ly8xNzMuMjU1LjEzNS42NDoxOTM1L25lbWVzaXMvcGxhZDEvcGxheWxpc3QubTN1OD91c2VybmFtZT1wYXBhbG96YXJvdSZwYXNzd29yZD0kUCRCaENqMEJiM1oyUk9VLlJrcGZvVlRyVzlmTmpDNVUuCnMzClVSTGIxczE3CklOQ0xVREVfQ09OVEFJTkVSczMKU1MxczUKVElUTEVyMAo_

That should show us whether all the necessary params are being set properly.

One possiblity is that it's not specifically the iOS/Android apps that are failing, just any player that is not on the same machine as the PMS. Have you tested with /web or PHT on a separate computer?

One possiblity is that it's not specifically the iOS/Android apps that are failing, just any player that is not on the same machine as the PMS. Have you tested with /web or PHT on a separate computer?

Didn't think of that (I know this site is quite strict on devices), so tried it and it does actually play.

The weird thing is, via Safari/Chrome on iOS the videos play. And they're exactly the same URLs.

Am just testing it as a URL service to see if that makes any sort of difference.

So... I set an arbitrary duration of 1 minute. 

And now the streams play on iOS/Android 4.3., but still not Apple TV or Andriod 4.4.4

**EDIT**

So it plays as per the above, for the set duration then stops. However, the transcoder is still kicking out errors for the duration of playback:

Aug 13, 2014 19:10:19 [0x104df1000] ERROR - [Transcoder] Failed to open bitstream filter h264_mp4toannexb for stream 0 with codec cop
Aug 13, 2014 19:10:19 [0x105b81000] ERROR - [Transcoder] : Invalid argument

I can obviously set an longer duration, say 60 hours, but it will be logging the above errors for the entire time.

Turns out it was related to the malformed data I posted about in https://forums.plex.tv/topic/117596-xml-parsing-issue/

The URL I was grabbing had a newline ( ) character on the end of it which was causing iOS/Apple TV to choke and triggering the transcoder. Removing that off the end has made it work on at least iOS/Apple TV, though android still has problems.

Is it the duration parameter that is still causing issues for Android?

I haven't checked recently as I'm refactoring code/trying to implement something else (and also all my actual devices are Apple ones, the android ones I have are just for testing). Will circle back once I have other things in place to check Android.

Cool.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.