QVideoPlayerView

2025-04-10

inherits: QuickView

Render video content with ffmpeg, hardware accelerated.

Warning: this Node is a technology preview, and known to work on Linux + X11 + NVidia drivers. On Windows, it does not work (yet). MacOS is untested.

Public Types

enum PlaybackState { StoppedState, PlayingState, PausedState }
enum MediaStatus { NoMedia, LoadingMedia, LoadedMedia, StalledMedia, BufferingMedia, BufferedMedia, EndOfMedia, InvalidMedia }
enum MediaError { NoError, ResourceError, FormatError, NetworkError, AccessDeniedError }
enum MediaLoops { Infinite, Once }
enum MediaStretch { Stretch, PreserveAspectFit, PreserveAspectCrop }

Properties

  • int active_audio_track
    • get_active_audio_track()
    • set_active_audio_track(int active_audio_track)
  • int active_subtitle_track
    • get_active_subtitle_track()
    • set_active_subtitle_track(int active_subtitle_track)
  • int active_video_track
    • get_active_video_track()
    • set_active_video_track(int active_video_track)
  • Array audio_tracks
    • get_audio_tracks()
  • bool auto_play [default = true]
    • get_auto_play()
    • set_auto_play(bool auto_play)
  • float buffer_progress
    • get_buffer_progress()
  • String component [default = "Video...]
    • get_component_name()
    • set_component_name(String component)
  • bool controls_auto_hide [default = false]
    • get_controls_auto_hide()
    • set_controls_auto_hide(bool controls_auto_hide)
  • bool controls_enabled [default = true]
    • get_controls()
    • set_controls(bool controls_enabled)
  • int duration
    • get_duration()
  • QVideoPlayerView.MediaError error
    • get_error()
  • String error_string
    • get_error_string()
  • QVideoPlayerView.MediaStretch fill_mode [default = 1]
    • get_fill_mode()
    • set_fill_mode(QVideoPlayerView.MediaStretch fill_mode)
  • bool has_audio
    • get_has_audio()
  • bool has_video
    • get_has_video()
  • QVideoPlayerView.MediaLoops loops
    • get_loops()
    • set_loops(QVideoPlayerView.MediaLoops loops)
  • QVideoPlayerView.MediaStatus media_status
    • get_media_status()
  • Dictionary metadata
    • get_metadata()
  • String module [default = "Multi...]
    • get_module_name()
    • set_module_name(String module)
  • bool muted [default = false]
    • get_muted()
    • set_muted(bool muted)
  • float playback_rate
    • get_playback_rate()
    • set_playback_rate(float playback_rate)
  • QVideoPlayerView.PlaybackState playback_state
    • get_playback_state()
  • int position
    • get_position()
    • set_position(int position)
  • Vector2 resolution [default = Vector2(1920, 1080)]
    • get_resolution()
    • set_resolution(Vector2 resolution)
  • bool seekable
    • get_seekable()
  • String source [default = ""]
    • get_source()
    • set_source(String source)
  • Array subtitle_tracks
    • get_subtitle_tracks()
  • Array video_tracks
    • get_video_tracks()
  • float volume
    • get_volume()
    • set_volume(float volume)

Methods

String get_current_subtitle_name()
void pause()
void play()
void stop()

Signals

  • active_tracks_changed()
  • audio_buffer_output_changed()
  • audio_output_changed()
  • buffer_progress_changed(float progress)
  • duration_changed(int duration)
  • error_changed()
  • error_occurred(int code, String message)
  • has_audio_changed(bool has_audio)
  • has_video_changed(bool has_video)
  • loops_changed()
  • media_status_changed(int status)
  • metadata_changed()
  • muted_changed(bool muted)
  • playback_rate_changed(float rate)
  • playback_state_changed(int state)
  • playing_changed(bool playing)
  • position_changed(int position)
  • seekable_changed(bool seekable)
  • source_changed(String source)
  • tracks_changed()
  • video_output_changed()
  • volume_changed(float volume)