unreal.MediaSource

class unreal.MediaSource(outer=None, name='None')

Bases: unreal.Object

Abstract base class for media sources.

Media sources describe the location and/or settings of media objects that can be played in a media player, such as a video file on disk, a video stream on the internet, or a web cam attached to or built into the target device. The location is encoded as a media URL string, whose URI scheme and optional file extension will be used to locate a suitable media player.

C++ Source:

  • Module: MediaAssets

  • File: MediaSource.h

get_url()str

Get the media source’s URL string (must be implemented in child classes). see: GetProxies

Returns

The media URL.

Return type

str

set_media_option_bool(key, value)None

Set a boolean parameter to pass to the player.

Parameters
set_media_option_float(key, value)None

Set a float parameter to pass to the player.

Parameters
set_media_option_int64(key, value)None

Set an integer64 parameter to pass to the player.

Parameters
  • key (Name) –

  • value (int64) –

set_media_option_string(key, value)None

Set a string parameter to pass to the player.

Parameters
validate()bool

Validate the media source settings (must be implemented in child classes).

Returns

true if validation passed, false otherwise.

Return type

bool