Questions tagged [airplay]

Airplay is a streaming technology made by Apple to stream media to multiple devices wirelessly or to the Airplay SDK that offers deployment to many platforms.

Airplay?

Airplay is a Streaming Technology made by Apple Inc to stream media to multiple devices wirelessly or to the Airplay SDK that offers deployment to many platforms including iOS, macOS, tvOS, watchOS, Windows, Linux, Android, Symbian, and more recently, through the Airplay Arcade, all major consoles and handheld devices.


Apple added Airplay in Safari

In 2015 Apple added Airplay for HTML5 Video *default player, And a API for JavaScript Presentation mode, for those who wanna use their own video player.

This can be done by using the following code:

// Safari 9+
if (window.WebKitPlaybackTargetAvailabilityEvent) {
    video.addEventListener('webkitplaybacktargetavailabilitychanged', function(event) {
        switch (event.availability) {
            case "available":
                airPlay.style.display = 'block';
                break;
            default:
                airPlay.style.display = 'none';
        }
        airPlay.addEventListener('click', function() {
            video.webkitShowPlaybackTargetPicker();
        });
    });
}

NOTE: Airplay can be use for both Audio and Video.


In 2016 They added Picture In Picture to the default HTML5 Player, its also use Javascript Presentation mode API.

453 questions
5
votes
0 answers

How to play an encrypted stream via AirPlay?

I would like to play an encrypted stream (available as an in-app purchase) via AirPlay. Here's a sample .m3u8…
5
votes
1 answer

AirPrint: Set default printer in UIPrintInteractionController

I need a way to force the selected Printer to the UIPrintInteractionController when it's presented, using an already known printerId. NOTE: To make tests I'm using Printopia installed on my "MacBook Pro" that shares the "Printer" I've made this…
Lubbo
  • 1,030
  • 1
  • 10
  • 18
5
votes
2 answers

How to support airplay in the background in iOS6

My app should stream video's to an AppleTV via Airplay, even when the app is in the background. Under iOS5 it worked perfectly. In iOS6 it does not. Xcode gives me a deprecated warning on this line of…
murze
  • 4,015
  • 8
  • 43
  • 70
5
votes
1 answer

Difference between IwGx, Iw2D and s3e

What is the main difference between IwGx, Iw2D and s3e api in marmalade?
0xC0DED00D
  • 19,522
  • 20
  • 117
  • 184
4
votes
1 answer

Airplay Mirroring + External UIScreen = fullscreen UIWebView video playback?

I'm currently playing around with some app ideas using AirPlay mirroring and a second UIScreen (a la Real Racing) on my Apple TV2 along with HTML5 video content (x-webkit-airplay="deny") within a UIWebView (allowsInlineMediaPlayback=YES,…
gdog
  • 88
  • 2
  • 7
4
votes
0 answers

Tap area of AirPlay button in MPVolumeView

I have a MPVolumeView with AirPlay button. When I tap the AirPlay button in the center of the icon it does not respond. It seems like the tap isn't recognized. When I tap the icon on the right side of the icon the popover is displayed correctly.…
osigge
  • 218
  • 4
  • 13
4
votes
3 answers

AirPlay Mirroring iPhone to Mac OS / using UIWebView + AirPlay

I need to live-demo a Mobile Safari browser app (iOS 5, iPhone 4S) on my Macbook and was wondering the best way to do this? One way I thought might be possible would be using AirPlay Mirroring, but there doesn't seem to be any Mac OS apps capable of…
JamieNewman
  • 917
  • 1
  • 12
  • 20
4
votes
0 answers

H264 stream produced by Apple M1 CPU don't play on many devices, any workaround?

We've detected that the h264 streaming produced by Apple M1 hardware encoder apparently is not following the standard of H264 and some hardware decoders aren't able to play an stream produced with M1. By our tests, it plays without any issues on M1…
forlayo
  • 1,371
  • 2
  • 13
  • 23
4
votes
1 answer

AVPlayerViewController plays audio through airplay when allowsExternalPlayback is false

I have a main video that plays through AVPlayerViewController that should be played through Airplay to e.g. the AppleTV. This is how I set up the view controller: let player = AVPlayer(url: url) let controller =…
Tomáš Kohout
  • 755
  • 6
  • 15
4
votes
2 answers

Crash AVFoundation in +[AVOutputContext(FigRoutingContext) currentRoutingContextFactory]

We have crash in AVFoundation. AVFoundation +[AVOutputContext(FigRoutingContext) currentRoutingContextFactory] EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x0000000a3c27beb8 Crashed: Thread 0 libobjc.A.dylib 0x183b8c910 objc_msgSend + 16 1 …
4
votes
1 answer

Airplay background streaming like Spotify / Amazon Music

Is it possible to do Airplay audio streaming like Spotify or Amazon Music. When i setup an Airplay stream with Audio from my App the screen (on the Apple-TV) turns black and shows only the progressbar. Is it possible to show the small hint in the…
ANE
  • 243
  • 1
  • 10
4
votes
0 answers

MPVolumeview volumeseider disappears when Airplay connected

I have a video application in which I am using Airplay to stream the video. I am using the below code. let airView: MPVolumeView = MPVolumeView() airView.showsRouteButton = true airView.showsVolumeSlider = true airView.sizeToFit() …
Saty
  • 2,563
  • 3
  • 37
  • 88
4
votes
0 answers

How to implement airplay in an iOS app for streaming video on Apple TV

I am working on an iOS app with video streaming. My requirement is that I want to stream video content on Apple TV using Airplay, also streaming should continue even if my phone gets locked / app enters background state. Thanks in advance.
4
votes
0 answers

Airplay button not showing up in AVPlayerViewController

I'm trying to get the Airplay button to appear in the native AVPlayer controls, using the AVPlayerViewController. I started a new project and am using the following block of sample code in viewDidAppear: override func viewDidAppear(animated: Bool)…
Four
  • 406
  • 4
  • 13
4
votes
0 answers

How do I detect the presence of an Airplay AUDIO-ONLY device on the network?

I'm unable to find code online (yes, googled aplenty) that details how to discover devices that support the audio only version of Airplay. There doesn't seem to be anything on Apple's developer site either - I spent an hour scouring Google and…
Vexir
  • 615
  • 5
  • 16