Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

为什么不能播放rtsp视频? #2

Closed
tzraeq opened this issue Jul 5, 2018 · 15 comments
Closed

为什么不能播放rtsp视频? #2

tzraeq opened this issue Jul 5, 2018 · 15 comments

Comments

@tzraeq
Copy link

tzraeq commented Jul 5, 2018

你好,vlc是可以支持rtsp和rtmp的,但是您的这个为什么不行呢?

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

求大神的即时通讯ID,我qq:36012713,希望能向你学习

@xuyuanzhou
Copy link
Owner

你的视频源地址是什么,在ios中是可以的"rtsp://184.72.239.149/vod/mp4://BigBuckBunny_175k.mov"

@xuyuanzhou
Copy link
Owner

你用1.0.6版本再尝试下

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

大神你好,我第一次没说清楚,我说的是直播视频,我用其他vlc播放器都是可以的,比如“rtmp://live.hkstv.hk.lxdns.com/live/hks”

@xuyuanzhou
Copy link
Owner

这个“rtmp://live.hkstv.hk.lxdns.com/live/hks”
在ios上也能播放

@xuyuanzhou
Copy link
Owner

1.你用的是哪个版本测试的
2.你测试的是android还是iOS
3.你的代码是怎样

@xuyuanzhou
Copy link
Owner

android经测试也是可以播放的

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

1.是npm上的版本
2.是android
3.代码的话,按照你给的VlCPlayerView,直接复制过来的。

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

我发现不论url设置什么,就算是mp4,都是不播放的,工程很简单,没有特殊的东西。

@xuyuanzhou
Copy link
Owner

你用最新版本1.0.6
这个版本修复了这个问题,url识别的问题,之前把 rtsp:之类开头的识别为本地资源导致的

@xuyuanzhou
Copy link
Owner

你把你设置url的代码发一下

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

大神,我换1.0.6试试。
url的代码的话,我是直接在render的return之前,设置了,this.state.url = "http://cdn.goluk.cn/video/t1_2.mp4";
然后player的属性,没动,就是url={this.state.url}

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

大神,我现在是任何url都不能播放,项目里没有特殊的地方。我用的是雷电模拟器,难道需要真机调试么?

@xuyuanzhou
Copy link
Owner

1.你现在的表现形式是怎样
2.点击一下画面,开启视屏播放

@tzraeq
Copy link
Author

tzraeq commented Jul 6, 2018

1.player部分是黑屏
2.player的部分点击没有任何反应
大神方便用微信或者qq交流么?这里发图好不方便。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants