tags:

views:

1101

answers:

3

Just found out that the video output of the iPad is not a system level functionality, but that it needs to be explicitly build in into each app. Is there somebody who has any experience with this, who could point me to sample code? Secondary question would be: why wouldn't Apple make this a system feature. Is it a hardware issue, that I should be aware of when building this into my app?

+1  A: 

External Display Support

An iPad can be connected to an external display through a set of supported cables. When connected, the associated screen can be used by the application to display content. Information about the screen, including its supported resolutions, is accessible through the interfaces of the UIKit framework. You also use that framework to associate your application’s windows with one screen or another.

  • The UIScreen class provides support for retrieving screen objects for all available screens (including the device’s main screen). Each screen object contains information about the properties of the screen itself, including the dimensions that correctly take into account the size and pixel aspect ratio of the screen.

  • The UIScreenMode class provides information about one particular size and pixel aspect ratio setting of a screen.

  • Windows (represented by the UIWindow class) can now be assigned to a specific screen.

jamone
Looks like you copy-pasted this from somewhere; if so, please post the originating URL.
Ricket
A: 

Sorry, I don't seem to have the necessary standing to comment on other posts. So, here's a bit of code that might be useful to explore new External Display Support:

    NSUInteger numScreens = [[UIScreen screens] count];
DLog(@"[[UIScreen screens] count] = %d", numScreens);
NSUInteger j = 0;
for (UIScreen *screen in [UIScreen screens])
    {
    DLog(@" screen %d", j++);
    NSArray *modes = [screen availableModes];
    for (int i = 0; i < [modes count]; ++i)
        {
        UIScreenMode *mode = [modes objectAtIndex:i];
        DLog(@"  modes[%d] : size = (%f, %f) ; aspect ration = %f", i, mode.size.width, mode.size.height, mode.pixelAspectRatio);
        }
    }

Note that you still need some sort of video cable. I have tested this with Apple's Component AV Cable. Although ungainly, this is nice for debugging because it has USB and 30-pin connector, so you can be connected to iPhone/iPad and run your app in debugger.

The problem is that you will still need to do some work to mirror parts of your display to external screen, while keeping controls on iPhone/iPad. You might want to look at this link text for inspiration.

westsider
Also you can use WiFi for debugging. You have to load the app on the iPad via USB but then can unhook the USB and use WiFi. I know it can be done, but how... I've never done it.
jamone
A: 

hello, how i can disable the video output of iphone/ ipad 3.2 /4.0 sdk?

i don't want my video display on tv

luca