在 iPad 上的本机应用程序和 Web 视图中播放视频
我有一个可以播放视频的 iPad 原生应用程序。该应用程序还使用网络视图来显示某些内容,我也想在网络视图中播放视频。
是否可以同时在本机和网络视图中播放视频?我读过,只有一个视频可以同时本地播放,但是如果一个视频是本地视频而另一个视频在网络视图中,这是否适用?
如果视频正在本机播放并且加载了包含视频的 Web 视图,则在 Web 视图中启动视频播放是否会自动停止本机视频,或者是否需要从 Web 视图到本机代码进行通信来停止视频,以及反之亦然?
感谢您抽出时间。
I have a native iPad app that plays video. The app also uses a webview for some content and I would like to play a video in the webview as well.
Is it possible to play video natively as well as in a webview at the same time? I've read that only one video can play natively at the same time but does this apply if one video is native and the other is in a webview?
If a video is playing natively and a webview is loaded that includes a video, would initiating playback of the video in the webview automatically stop the native video or does there need to be communication from the webview to the native code to stop the video, and vice versa?
Thanks for your time.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我想说这是不可能的,根据我的经验,当在网络视图中播放视频时,视频能够全屏显示,并且当发生这种情况时,它使用与播放视频本机使用的相同视频播放器/控件。我看不出两个视频如何能够同时使用此播放器/控件。
您还会遇到内存问题,至少在第一台 iPad 上是这样。
I would say it isn't possible, in my experience when playing video in a webview the video is able to go fullscreen and when this happens it uses the same video player/controls that playing a video natively uses. I can't see how two videos would be able to use this player/controls at the same time.
You will also encounter memory issues, at least on the first iPad.