android videoview 上的进度条
你好 我正在开发视频流应用程序,我需要在我的应用程序上制作一个进度条(不是进度对话框)我尝试实现它,我将它放在 xml 文件中并将其设置为 onprepared 方法上不可见,但问题是进度栏位于视频顶部,使视频尺寸变小 我需要让视频填充父级,进度条也像 YouTube 应用程序一样 我该怎么做?
另外我正在在线流媒体,所以当视频停止延迟时如何显示缓冲百分比
另一点是我希望当现在无法播放该视频的警报时进度条消失,但我不知道在哪里在代码中我应该消失进度条吗?此警报何时出现?
HI
i am developing video streaming application and i need to make a progress bar on my application (not a progress dialog) i tried implementing it i put it on the xml file and set it to invisible on the onprepared method but the problem is that the progress bar is placed on top of the video which makes the video size small
i need to make the video fill parent and the progress bar also like the youtube application
how can i do that ?
also i'm online streaming so how can i display the buffering percentage when the video is stopped for delay
another point is i want the progress bar to disappear when the alert of this video canot be played now ,, but i don't know where in the code i should disappear the progress bar ? when this alert appears ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我不确定 YouTube 的菜单是如何制作的,但您可以尝试 SlidingDrawer 并将您的
ProgressBar
嵌套在其中。I'm not sure how YouTube does their menu, but you could try a SlidingDrawer and nest your
ProgressBar
in that.看看这段代码,这可能对你有帮助。
该代码还包括必要的注释(如果需要)。
谢谢...
look at this code, this might help you.
This code also include necessary comments , where ever needed.
Thanks...