Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

show_picture not working in IOS 5 #21

Open
zanderl opened this issue Aug 3, 2011 · 2 comments
Open

show_picture not working in IOS 5 #21

zanderl opened this issue Aug 3, 2011 · 2 comments

Comments

@zanderl
Copy link

zanderl commented Aug 3, 2011

First of all - awesome tool!

I have no experience with previous versions of Airplay, but my IOS 5 client had some strange behavior with pictures. Photos would show, but would erratically display the prior photo, or the next one in the sequence, and sometimes would get stuck. It turns out that there is some new logic with caching directives:

  1. At first you'll get 3 calls - I'll paste in the headers which will help explain:

{'X-Apple-Session-Id': 'b108f96e-bdcd-4935-8fb2-3103be84853a', 'Content-Length': '159460', 'X-Apple-Assetkey': '857DDE75-1986-4D44-A9A1-2935903CE1FF', 'User-Agent': 'MediaControl/1.0'}
{'X-Apple-Session-Id': 'b108f96e-bdcd-4935-8fb2-3103be84853a', 'Content-Length': '196144', 'User-Agent': 'MediaControl/1.0', 'X-Apple-Assetaction': 'cacheOnly', 'X-Apple-Assetkey': '2065D39A-8DFD-4C41-B0A1-CEF928B7D56E'}
{'X-Apple-Session-Id': 'b108f96e-bdcd-4935-8fb2-3103be84853a', 'Content-Length': '101450', 'User-Agent': 'MediaControl/1.0', 'X-Apple-Assetaction': 'cacheOnly', 'X-Apple-Assetkey': 'DECAC583-F80A-4A38-B926-57ED78266E6F'}

You can see that the first is "this" photo, and the other two are the prior and next pictures in the album which are sent as a pre-cache (cacheOnly). In the current airplay, all three of these are loaded in a non-deterministic and non-thread-safe order which explains the erratic behavior.

  1. Subsequent calls may look like:

    {'X-Apple-Session-Id': 'b108f96e-bdcd-4935-8fb2-3103be84853a', 'Content-Length': '0', 'X-Apple-Assetkey': '2065D39A-8DFD-4C41-B0A1-CEF928B7D56E', 'User-Agent': 'MediaControl/1.0', 'X-Apple-Assetaction': 'displayCached', 'X-Apple-Transition': 'Dissolve'}
    {'X-Apple-Session-Id': 'b108f96e-bdcd-4935-8fb2-3103be84853a', 'Content-Length': '182319', 'X-Apple-Assetkey': 'F1F713A7-A8FC-4707-900D-0E1056E0E323', 'User-Agent': 'MediaControl/1.0', 'X-Apple-Assetaction': 'cacheOnly', 'X-Apple-Transition': 'Dissolve'}

Note two things:
a. The content-length of the first one is 0, and it's X-Apple-Assetaction is 'displayCached' - with the reference to the AssetKey and Session from the first exchange.
b. The second entry is caching the next picture with an actual payload, and, again, cacheOnly.

I have a patch which solves this by separating the caching from the showing, caching in a "session" directory, and generally trying to clean up after itself when the session ends. I have no way of testing on a non-IOS 5 Beta4 client, nor do I know how this will behave on any other target beyond XBMC (though it looks like Boxee/Plex don't implement pictures anyhow)

@pascalw
Copy link
Owner

pascalw commented Aug 6, 2011

Hi. Airplayer might indeed not be iOS 5 compatible right now. However, I'm not going to spend time on investigating iOS 5 related issues until iOS 5 matures.

@pascalw
Copy link
Owner

pascalw commented Oct 15, 2011

Are you still experiencing this issue? For me streaming pictures from the camera roll works just fine on iOS 5.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants