A hidden API to enable AirPlay video support in third party apps has been found by Steven Troughton-Smith.
The search began with Erica Sadun…
When Apple announced its new iOS 4.2 feature set, Apple TV’s AirPlay video service really caught our attention. That’s why we were particularly disappointed when 4.2 debuted on Monday — only Apple’s own applications could ship video from iDevices to the 2nd generation Apple TV; third party applications were limited to audio transport only.
Erica succeeded in posting the demo video below; however, Steven Troughton-Smith managed to fine a one line solution.
“Yes, it still won’t be App Store safe, but it’s jailbreak friendly, works flawlessly, and suggests only a single item that Apple could move to a public API to open up this functionality to developers. What’s more, with a little screen scraping or off-screen layer manipulation and a clever use of AVFoundation, you can probably have games working out to Apple TV almost immediately.”
self.movieController = [[[MPMoviePlayerController alloc] initWithContentURL:[NSURL fileURLWithPath:CINDY_PATH]] autorelease];
movieController.view.frame = self.view.bounds;
Hopefully we will see this being used in applications very soon!