VideoView在ViewFlipper是透明的,当视频正在播放 [英] VideoView in ViewFlipper is transparent when video is playing

查看:1011
本文介绍了VideoView在ViewFlipper是透明的,当视频正在播放的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有在一个ViewFlipper设置了两个意见一个活动。其中一个观点是一个GLSurfaceView和其他一些小部件的布局,对方只是有一个TextView和VideoView的布局。当我点击了GLSurfaceView东西时,ViewFlipper互换让视频可以播放。在这个截图中,可以看到纯GLSurfaceView呈现在左边的地图。右边是什么样子的ViewFlipper已翻转后的视频开始播放。

I've got an Activity with two views set up in a ViewFlipper. One of the views is a layout with a GLSurfaceView and a few other widgets, the other just has a layout with a TextView and a VideoView. When I click on something in the GLSurfaceView, the ViewFlipper swaps so the video can play. In this screenshot, you can see the plain GLSurfaceView rendering a map on the left. On the right is what it looks like after the ViewFlipper has flipped and the video starts playing.

空透明区域,其中GLSurfaceView示出了通过是该视频被认为是。我可以听到它打通过扬声器和时间表正在向前推进,所以我知道它的演奏。

The empty transparent area where the GLSurfaceView shows through is where the video is supposed to be. I can hear it playing through the speaker and the timeline is moving forward, so I know it's playing.

我可以张贴code,如果你需要它,但有参与,以便它可以得到相当复杂了很多。

I can post code if you need it, but there's a lot involved so it could get rather complicated.

任何想法,这是怎么回事呢?

Any ideas as to what's going on here?

推荐答案

您不能有两个 SurfaceViews 在重叠的活动,我怀疑,其中包括情况下,像 ViewFlipper 在技术上,他们不会因能见度变化重叠。

You cannot have two SurfaceViews in an activity that overlap, and I suspect that includes cases like ViewFlipper where technically they would not overlap due to visibility changes.

这篇关于VideoView在ViewFlipper是透明的,当视频正在播放的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆