1
我已经在这条道路从下载服务器端的视频在localhost:播放视频从本地主机
/Users/adrian/Library/Application Support/iPhone Simulator/4.3.2/Applications/60584763-39F6-4124-805D-BEFDE453206D/Documents/videos/bar.mpeg
乃至视频在此路径存在。
但是,当我尝试播放它时,屏幕变黑,没有播放视频。
我做了这样的:
moviePlayer = [[CustomMoviePlayerViewController alloc] initWithPath:[NSString stringWithFormat:@"/Users/adrian/Library/Application Support/iPhone Simulator/4.3.2/Applications/60584763-39F6-4124-805D-BEFDE453206D/Documents/videos/bar.mpeg"]];
[moviePlayer readyPlayer];
[self presentModalViewController:moviePlayer animated:YES];
当我把资源文件夹都相同的视频作品perfect.So我认为这个问题是与path.But有什么问题呢?
,我怎么可以添加从外部文件夹到我的项目? – adrian
顺便说一句,上面的代码不是新的....我说这已经起作用了! – adrian
我不认为你可以用这种方式使用该文件,你必须将它添加到你的Xcode项目。 –