IMediaPlayerFactory

Syntax

class IMediaPlayerFactory

Remarks

Interface for media player factories.

Media player factories are used to create instances of media player implementations. Most media players will be implemented inside plug-ins, which will register their factories on startup. The Media module will use the CanPlayUrl() method on this interface to determine which media player to instantiate for a given media source.

Destructors

Name Description

Public function Virtual

~IMediaPlayerFactory()

Virtual destructor.

Functions

Name Description

Public function Const

bool

 

CanPlayUrl

(
    const FString & Url,
    const IMediaOptions * Options
)

Whether the player can play the specified source URL.

Public function Const

bool

 

CanPlayUrl

(
    const FString & Url,
    const IMediaOptions * Options,
    TArray < FText >* OutWarnings,
    TArray < FText >* OutErrors
)

Whether the player can play the specified source URL.

Public function

TSharedPtr < ...

 

CreatePlayer

(
    IMediaEventSink & EventSink
)

Creates a media player.

Public function Const

FText

 

GetDisplayName()

Get the human readable name of the player.

Public function Const

FName

 

GetPlayerName()

Get the unique name of the media player.

Public function Const

const TArray ...

 

GetSupportedPlatforms()

Get the names of platforms that the media player supports.

Public function Const

bool

 

SupportsFeature

(
    EMediaFeature Feature
)

Check whether the media player supports the specified feature.

Public function Const

bool

 

SupportsPlatform

(
    const FString & PlatformName
)

Whether the player works on the given platform.

See Also

References

Module

Media

Header

Runtime/Media/Public/IMediaPlayerFactory.h