IMediaControls

Interface for controlling media playback.

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

IMediaControls

FMediaIOCorePlayerBase

References

Module

Media

Header

/Engine/Source/Runtime/Media/Public/IMediaControls.h

Include

#include "IMediaControls.h"

Syntax

class IMediaControls

Remarks

Interface for controlling media playback.

Destructors

Name Description

Public function Virtual

~IMediaControls()

Virtual destructor.

Functions

Name Description

Public function Const

bool

 

CanControl

(
    EMediaControl Control
)

Whether the specified control is currently available.

Public function Const

FTimespan

 

GetDuration()

Get the media's duration.

Public function Const

float

 

GetRate()

Get the nominal playback rate, i.e. 1.0 for real time.

Public function Const

EMediaState

 

GetState()

Get the state of the media.

Public function Const

EMediaStatus

 

GetStatus()

Get media player status flags.

Public function Const

TRangeSet< f...

 

GetSupportedRates

(
    EMediaRateThinning Thinning
)

Get the supported playback rates.

Public function Const

FTimespan

 

GetTime()

Get the player's current playback time.

Public function Const

bool

 

IsLooping()

Check whether playback is currently looping.

Public function

bool

 

Pause()

Pause media playback.

This is the same as setting the playback rate to 0.0.

Public function

bool

 

Play()

Start media playback at the default rate of 1.0.

Public function

bool

 

Seek

(
    const FTimespan& Time
)

Change the media's playback time.

Public function

bool

 

Seek

(
    const FTimespan& TimeOffset,
    EMediaSeekDirection Direction
)

Change the playback time of the media by a relative offset in the given direction.

Public function Virtual

void

 

SetBlockingPlaybackHint

(
    bool bFacadeWillUseBlockingPlayback
)

Hint for player indicating that blocked playback mode will be used / not used

Public function

bool

 

SetLooping

(
    bool Looping
)

Set whether playback should be looping.

Public function

bool

 

SetRate

(
    float Rate
)

Set the current playback rate.

See Also