OnMediaPlayerStarted(mp)视频播放开始事件触发后的执行方法,OnMediaPlayerFinished(mp)视频播放开始事件触发后的执行方法 2. 全代码如下: using System.Collections; using System.Collections.Generic; using UnityEngine; using RenderHeads.Media.AVProVideo; public class AVPevent : MonoBehaviour { public MediaPlayer...
Unity AVPro video 开始播放,播放完成事件监听,voidStart(){StepOnePanel.MediaPlayer.Events.AddListener(OnMediaPlayerEvent);}privatevoidOnMediaPlayerEvent(MediaPlayerarg0,MediaPlayerEvent.EventTypearg1,ErrorCodearg2){switch(arg1){caseMediaPlayerE.
}voidSetMovie(stringmp4Str)//gamex + "/start/piantou.mp4"{ mediaplayer.OpenVideoFromFile(MediaPlayer.FileLocation.RelativeToStreamingAssetsFolder, Application.streamingAssetsPath+ mp4Str,true); mediaplayer.m_Loop=false; mediaplayer.Play(); }///<summary>///AVPro事件管理///</summary>///<param ...
Unity AVPro video 开始播放,播放完成事件监听,voidStart(){StepOnePanel.MediaPlayer.Events.AddListener(OnMediaPlayerEvent);}privatevoidOnMediaPlayerEvent(MediaPlayerarg0,MediaPlayerEvent.EventTypearg1,ErrorCodearg2){switch(arg1){caseMediaPlayerE.