tags:

views:

56

answers:

2

Hi there,

I am due to do a demo in a week of an app which i have been working on for a company - until now, i have been using code taken from this useful tutorial here

The problem is that this no longer seems to be working - causing a SIGABRT inside of the following (see initWithVideoView):

- (void) startTVOut;
{
 // you need to have a main window already open when you call start
 if (!tvoutWindow) {
  deviceWindow = [self keyWindow];

  MPVideoView *vidView = [[MPVideoView alloc] initWithFrame: CGRectZero]; 
  **tvoutWindow = [[MPTVOutWindow alloc] initWithVideoView:vidView];**
  [tvoutWindow makeKeyAndVisible];
  tvoutWindow.userInteractionEnabled = NO;

  mirrorView = [[UIImageView alloc] initWithFrame: [[UIScreen mainScreen] bounds]];

  [self reformatTVOutOrientation];

  mirrorView.center = vidView.center;
  [vidView addSubview: mirrorView];

  [deviceWindow makeKeyAndVisible];

  [NSThread detachNewThreadSelector:@selector(updateLoop) toTarget:self withObject:nil];
 }
}

Can anyone help at all??? This was all working fine, but seems to have stopped working recently - none of my code has changed, so assuming Apple have removed that API (yes, i know it was a private API in the first place, so im not moaning!) Just need to know if there is an alternative way of displaying the contents of my iPhone screen in my app...

Many thanks in advance!

A: 

Have you found a solution to this? It definitely seems that Apple has changed this private API. Hopefully there is a replacement that can be used on pre-iPad devices. On iPad and iPhone 4 you can just use the VGA cable using public APIs.

Bryce
A: 

I am having this same issue too! Hopefully the code will be updated.

Blake