SEmbeddedVideo
| دالة | OnStateChange | – |
| دالة | Play | If URL is set, plays the video |
| دالة | Stop | Stops the playback |
| دالة | Pause | Pauses currently played video |
| دالة | Resume | If the video is currently paused, it will resume playback |
| دالة | SynchorizeUrl | Synchorize current video URL |
| دالة | ClearRenderTexture | Clears the Render Texture |
| خاصية | State | The state player is currently in. |
| خاصية | URL | Current URL set for this Player. |
| خاصية | AudioSource | Current AudioSource |
| خاصية | OutputTexture | – |
| خاصية | Texture | Texture which the player uses to display the video. |
| خاصية | Time | Current player time. |
| خاصية | Position | Current Video Frame Position |
| خاصية | UniqueName | – |
| خاصية | VideoLength | Get the length of the video |
| خاصية | Loop | Whether video is set to loop or not |
| خاصية | FrameCount | Returns the frame count of the video |
| خاصية | IsPlaying | Returns whether the video is playing or not |
| خاصية | GameObject | – |
الدوال
OnStateChange
المعاملات
| الاسم | النوع | القيمة الافتراضية |
|---|---|---|
| e | Closure | – |
القيم المرجعة
void
مثال
function stateChangeFunction(EmbeddedVideo, oldState, newState)
--what happens on state change
end
Space.Host.ExecutingObject.EmbeddedVideo.OnStageChange(stateChangeFunction)
--get embedded video component on your video player
video = Space.Scene.Find("VidepPlayer").EmbeddedVideo
function GetClosure()
return function (a,b,c)
log(a.URL..b..c)
end
end
video.OnStateChange(GetClosure())
video.Pause()
Play
If URL is set, plays the video
القيم المرجعة
void
مثال
Space.Host.ExecutingObject.EmbeddedVideo.Play()
Stop
Stops the playback
القيم المرجعة
void
مثال
Space.Host.ExecutingObject.EmbeddedVideo.Stop()
Pause
Pauses currently played video
القيم المرجعة
void
مثال
Space.Host.ExecutingObject.EmbeddedVideo.Pause()
Resume
If the video is currently paused, it will resume playback
القيم المرجعة
void
مثال
Space.Host.ExecutingObject.EmbeddedVideo.Resume()
SynchorizeUrl
Synchorize current video URL
القيم المرجعة
void
مثال
Space.Host.ExecutingObject.EmbeddedVideo.SynchorizeUrl()
ClearRenderTexture
Clears the Render Texture
القيم المرجعة
void
مثال
Space.Host.ExecutingObject.EmbeddedVideo.ClearRenderTexture()
الخصائص
Stateللقراءة فقط
The state player is currently in. You can track state changes through StateChangeEvent.
مثال
CurrentVideoState = Space.Host.ExecutingObject.EmbeddedVideo.State
URL
Current URL set for this Player.
مثال
CurrentURL = Space.Host.ExecutingObject.EmbeddedVideo.URL
AudioSource
Current AudioSource
مثال
CurrentAudioSource = Space.Host.ExecutingObject.EmbeddedVideo.AudioSource
OutputTextureللقراءة فقط
مثال
OutputTexture = Space.Host.ExecutingObject.EmbeddedVideo.OutputTexture
Textureللقراءة فقط
Texture which the player uses to display the video.
مثال
Texture = Space.Host.ExecutingObject.EmbeddedVideo.Texture
Time
Current player time. Can be set to move the 'playhead' to the specific position.
مثال
Time = Space.Host.ExecutingObject.EmbeddedVideo.Time
Positionللقراءة فقط
Current Video Frame Position
مثال
Position = Space.Host.ExecutingObject.EmbeddedVideo.Position
UniqueNameللقراءة فقط
مثال
UniqueName = Space.Host.ExecutingObject.EmbeddedVideo.UniqueName
VideoLengthللقراءة فقط
Get the length of the video
مثال
VideoLength = Space.Host.ExecutingObject.EmbeddedVideo.VideoLength
Loop
Whether video is set to loop or not
مثال
Space.Host.ExecutingObject.EmbeddedVideo.Loop = true
FrameCountللقراءة فقط
Returns the frame count of the video
مثال
FrameCount = Space.Host.ExecutingObject.EmbeddedVideo.FrameCount
IsPlayingللقراءة فقط
Returns whether the video is playing or not
مثال
IsPlaying = Space.Host.ExecutingObject.EmbeddedVideo.IsPlaying
GameObjectللقراءة فقط
مثال
theGameObject = Space.Host.ExecutingObject.EmbeddedVideo.GameObject



