react-native-yz-vlcplayer icon indicating copy to clipboard operation
react-native-yz-vlcplayer copied to clipboard

VlcSimplePlayer 不能播放本地资源

Open thisSillyCow opened this issue 5 years ago • 2 comments

VlcSimplePlayer 我在播放本地资源的携带 file:// 或者不携带 都是不能播放 ;尝试以为是本地资源的问题 然后直接用手机自带的播放器是可以播放资源的; 源码: <VlcSimplePlayer ref={(video) => { this.player = video }} autoplay={true} //url={'file://' + this.state.currentUrl} url={this.state.currentUrl} initType={2} autoAspectRatio={true} isLive={true} autoplay={true} autoReloadLive={true} hwDecoderEnabled={1} hwDecoderForced={1} style={[styles.backgroundVideo,]} /> 打印本地的资源路径: /storage/emulated/0/HANJUTV/143/143-2/out.mp4 请帮我看一下哪里有问题 我看了之前几个关的 issue 都是可以播放本地资源的 我这边也没有修改源码

thisSillyCow avatar Aug 23 '19 06:08 thisSillyCow

Just remove file:// from url

ivan-kolesov avatar Aug 23 '19 09:08 ivan-kolesov

是的 我本地资源就是没有 file://的 /storage/emulated/0/HANJUTV/143/143-2/out.mp4 这个就是我使用的资源路径

thisSillyCow avatar Aug 23 '19 09:08 thisSillyCow