unreal.MediaStream¶
- class unreal.MediaStream(outer: Object | None = None, name: Name | str = 'None')¶
Bases:
ObjectMedia Stream. Provides an agnostic interface between controllers and players.
C++ Source:
Plugin: MediaStream
Module: MediaStream
File: MediaStream.h
Editor Properties: (see get_editor_property/set_editor_property)
on_source_changed(OnSourceChanged): [Read-Write]player_object(Object): [Read-Only] The player instance is automatically created based on the type of source. Where possible, the player is re-used when opening new media.source(MediaStreamSource): [Read-Write]
- get_player() MediaStreamPlayer¶
- Returns:
Gets the active Media Stream Player.
- Return type:
- get_source() MediaStreamSource¶
- Returns:
The current Media Stream Source. Does not guaranteed that it is valid.
- Return type:
- has_valid_source() bool¶
- Returns:
True if the media source scheme is not empty. Does not guarantee the source is correct, only valid.
- Return type:
- property on_source_changed: OnSourceChanged¶
[Read-Write]
- Type:
(OnSourceChanged)
- property player_object: Object¶
[Read-Only] The player instance is automatically created based on the type of source. Where possible, the player is re-used when opening new media.
- Type:
(Object)
- resolve_source() MediaStreamSource¶
- Returns:
The source at the end of the chain of proxy players, or the local one if it is local. If the chain is interrupted, the last link in the chain’s source will be returned.
- Return type:
- set_source(source) bool¶
Sets a new Media Stream Source and inits the Player. It should be ready to use if this returns true.
- Parameters:
source (MediaStreamSource) – The new source.
- Returns:
True if the source was successfully applied.
- Return type:
- property source: MediaStreamSource¶
[Read-Write]
- Type: