- getAudioTrack
long getAudioTrack()
- getBufferingMsec
long getBufferingMsec()
- getBus
String getBus()
- getStream
Ref!VideoStream getStream()
- getStreamName
String getStreamName()
Returns the video stream's name, or "<No Stream>" if no video stream is assigned.
- getStreamPosition
double getStreamPosition()
- getVideoTexture
Ref!Texture getVideoTexture()
Returns the current frame as a Texture.
- getVolume
double getVolume()
- getVolumeDb
double getVolumeDb()
- hasAutoplay
bool hasAutoplay()
- hasExpand
bool hasExpand()
- isPaused
bool isPaused()
- isPlaying
bool isPlaying()
Returns true if the video is playing.
Note: The video is still considered playing if paused during playback.
- opAssign
typeof(null) opAssign(typeof(null) n)
- opEquals
bool opEquals(VideoPlayer other)
- opEquals
bool opEquals(typeof(null) n)
- play
void play()
Starts the video playback from the beginning. If the video is paused, this will not unpause the video.
- setAudioTrack
void setAudioTrack(long track)
- setAutoplay
void setAutoplay(bool enabled)
- setBufferingMsec
void setBufferingMsec(long msec)
- setBus
void setBus(String bus)
- setExpand
void setExpand(bool enable)
- setPaused
void setPaused(bool paused)
- setStream
void setStream(VideoStream stream)
- setStreamPosition
void setStreamPosition(double position)
- setVolume
void setVolume(double volume)
- setVolumeDb
void setVolumeDb(double db)
- stop
void stop()
Stops the video playback and sets the stream position to 0.
Note: Although the stream position will be set to 0, the first frame of the video stream won't become the current frame.
- toHash
size_t toHash()
- audioTrack
long audioTrack [@property getter]
long audioTrack [@property setter]
The embedded audio track to play.
- autoplay
bool autoplay [@property getter]
bool autoplay [@property setter]
If true, playback starts when the scene loads.
- bufferingMsec
long bufferingMsec [@property getter]
long bufferingMsec [@property setter]
Amount of time in milliseconds to store in buffer while playing.
- bus
String bus [@property getter]
String bus [@property setter]
Audio bus to use for sound playback.
- expand
bool expand [@property getter]
bool expand [@property setter]
If true, the video scales to the control size. Otherwise, the control minimum size will be automatically adjusted to match the video stream's dimensions.
- paused
bool paused [@property getter]
bool paused [@property setter]
If true, the video is paused.
- stream
VideoStream stream [@property getter]
VideoStream stream [@property setter]
The assigned video stream. See description for supported formats.
- streamPosition
double streamPosition [@property getter]
double streamPosition [@property setter]
The current position of the stream, in seconds.
Note: Changing this value won't have any effect as seeking is not implemented yet, except in video formats implemented by a GDNative add-on.
- volume
double volume [@property getter]
double volume [@property setter]
Audio volume as a linear value.
- volumeDb
double volumeDb [@property getter]
double volumeDb [@property setter]
Control for playing video streams.
Control node for playing video streams using VideoStream resources. Supported video formats are url=https://www.webmproject.org/WebM/url (.webm, VideoStreamWebm), url=https://www.theora.org/Ogg Theora/url (.ogv, VideoStreamTheora), and any format exposed via a GDNative plugin using VideoStreamGDNative. Note: Due to a bug, VideoPlayer does not support localization remapping yet. Warning: On HTML5, video playback will perform poorly due to missing architecture-specific assembly optimizations, especially for VP8/VP9.