react-native实现视频直播功能

import { VLCPlayer, VlCPlayerView } from 'react-native-yz-vlcplayer';

 render() {
        return (
            
                 (this.vlcPlayer = ref)}
                    url={this.state.playerUrl}           //视频url
                    Orientation={Orientation}
                    //BackHandle={BackHandle}
                    ggUrl=""                      // 广告url
                    showGG={false}                 // 是否显示广告
                    showTitle={true}              // 是否显示标题
                    title=""                      // 标题
                    showBack={false}               // 是否显示返回按钮
                    paused={false}
                    onLeftPress={()=>{}}          // 返回按钮点击事件
                    onOpen={this.onOpen.bind(this)}
                    onPlaying={this.onPlaying.bind(this)}
                    onProgress={this.onProgress.bind(this)}
                    onPaused={this.onPaused.bind(this)}
                    onStopped={this.onStopped.bind(this)}
                    onIsPlaying={this.onIsPlaying.bind(this)}
                    onBuffering={this.onBuffering.bind(this)}
                    onEnded={this.onEnded.bind(this)}
                    onError={this.onError.bind(this)}
                    startFullScreen={() => {
                        this.setState({
                            isFull: true,
                        });
                    }}
                    closeFullScreen={() => {
                        this.setState({
                            isFull: false,
                        });
                    }}
                />
            
        );
    }

 

你可能感兴趣的:(react-native)