View Full Version : External Display with App
Jul 12, 2011, 11:52 PM
What is needed to display an app on an external display using either VGA or HDMI adapter? Kind of like Keynote or Real Racing 2. The mirroring option on the iPad 2 isn't working for me since it doesn't take up much of the screen.
Jul 17, 2011, 05:28 AM
Check in documentation for class UIScreem, UIScreenMode and UIWindow.
In UIScreen is an array with all attached screens; index 0 is the main screen. External screen on index 1.
You can control the screen resolution with UIScreenMode.
Finally you need to create a new UIWindow and attach it to the external screen instance. Fill the content with UIKit or CALayers or other functions.
Debugging with the VGA cable is not possible as it can not pass through the debugger while connected. The new HDMI cable I think allow that, but not sure.
IOS Simulator can help with the first steps; you can simulate external monitors.
UPDATE: you can also register some notification to get informed when a screen got attached or detached.