I want to apply screen mirroring through code.In iOS 11
and below we can achieve this task with MPVolumeView
class
In iOS11
and later iOS
The above class does not work for Screen Mirroring as it's only works for Audio mirroring (Airplay2).
I also try AVRoutePickerView
, but it is also working for audio mirroring only((Airplay2)).
In simple through code I want the same result with we can achieve with "Control Centre" "Screen Mirroring" button.check below video (1min 18secs in) for "Screen Mirroring" exact location.
https://www.youtube.com/watch?time_continue=80&v=wbWXNESUZ5w
Please check the attach image for exact location of screen mirroring button
Thanks