Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/maven/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
iphone、ipad VGA外部显示器-tvOutManager_Iphone_Objective C_Ipad_Vga_Television - Fatal编程技术网

iphone、ipad VGA外部显示器-tvOutManager

iphone、ipad VGA外部显示器-tvOutManager,iphone,objective-c,ipad,vga,television,Iphone,Objective C,Ipad,Vga,Television,我使用了所有的示例和源代码将应用程序内容显示到外部VGA显示器上。当在应用程序内部播放视频时,我在外部设备中看到下面的东西。任何建议。。。。我错过什么了吗。。但在设备中,它以良好的方式显示实际窗口 这段代码是在Robtrell的TVOutManager示例应用程序的mainviewController类中添加的。将设备连接到外部设备后。打开镜像视频时,我什么也看不到 大家好,我在回答我自己的问题 Robtrell的TVOutManager将不会通过简单地执行[[TVOutManager sha

我使用了所有的示例和源代码将应用程序内容显示到外部VGA显示器上。当在应用程序内部播放视频时,我在外部设备中看到下面的东西。任何建议。。。。我错过什么了吗。。但在设备中,它以良好的方式显示实际窗口


这段代码是在Robtrell的TVOutManager示例应用程序的mainviewController类中添加的。将设备连接到外部设备后。打开镜像视频时,我什么也看不到

大家好,我在回答我自己的问题

Robtrell的TVOutManager将不会通过简单地执行[[TVOutManager sharedinstance]StartVout]和[[TVOutManager sharedinstance]的topTVOut]来向外部设备播放任何视频

在这里,我们将player的实例添加到tvowwindow。 [TVOuthindow addSubview:玩家实例]

但这里的问题是视频并没有显示在设备中, 但您可以从设备控制外部窗口播放器


干杯。

我几乎懒洋洋的-P你需要问一些问题,让任何人回答。但画面很美@和蔼可亲的他确实问了一些问题——问题的格式不正确,所以问题最终变成了alt文本。我说得对吗,你的iPhone显示了视频,但你的电视显示了漂亮的图像?是的,你说得对。这就是我的问题所在…你的代码搞错了。你应该在电视上播放你想要的画面。。。去看电视。iPhone的视图应保持原样。只要交换一下就可以了。
   NSString *url = [[NSBundle mainBundle] pathForResource:@"Overview" ofType:@"mov"];

    player = [[MPMoviePlayerController alloc] initWithContentURL:[NSURL fileURLWithPath:url]];

    [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(movieFinishedCallback:)name:MPMoviePlayerPlaybackDidFinishNotification object:player];

        //---play partial screen---
    player.view.frame = CGRectMake(35, 450, 430, 300);
    [self.view addSubview:player.view];

    [player play];  

    - (void) movieFinishedCallback:(NSNotification*) aNotification {

    [[TVOutManager sharedInstance] startTVOut];
    player = [aNotification object];
    [[NSNotificationCenter defaultCenter] 
     removeObserver:self
     name:MPMoviePlayerPlaybackDidFinishNotification
     object:player];
    [player stop];

}