#include <IMediaControls.h>
Interface for controlling media playback.
- See also
- IMediaCache, IMediaPlayer, IMediaSamples, IMediaTracks, IMediaView
◆ ~IMediaControls()
| virtual IMediaControls::~IMediaControls |
( |
| ) |
|
|
inlinevirtual |
◆ CanControl()
Whether the specified control is currently available.
- Returns
- true if the control is available, false otherwise.
◆ GetDuration()
Get the media's duration.
- Returns
- A time span representing the duration.
- See also
- GetTime
◆ GetPlaybackTimeRange()
◆ GetRate()
Get the nominal playback rate, i.e. 1.0 for real time.
- Returns
- Playback rate.
- See also
- Pause, Play, SetRate
◆ GetState()
Get the state of the media.
- Returns
- Media state.
- See also
- IsLooping
◆ GetStatus()
Get media player status flags.
- Returns
- Status flags.
◆ GetSupportedRates()
Get the supported playback rates.
- Parameters
-
| Thinning | The desired rate thinning mode. |
- Returns
- The ranges of supported rates.
- See also
- SetRate, SupportsRate
◆ GetTime()
Get the player's current playback time.
- Returns
- Playback time.
- See also
- Seek
◆ IsLooping()
Check whether playback is currently looping.
- Returns
- true if playback is looping, false otherwise.
- See also
- GetState, SetLooping
◆ Pause()
| bool IMediaControls::Pause |
( |
| ) |
|
|
inline |
Pause media playback.
This is the same as setting the playback rate to 0.0.
- Returns
- true if the media is being paused, false otherwise.
- See also
- Play, Stop
◆ Play()
| bool IMediaControls::Play |
( |
| ) |
|
|
inline |
Start media playback at the default rate of 1.0.
This is the same as setting the playback rate to 1.0.
- Returns
- true if playback is starting, false otherwise.
- See also
- Pause, Stop
◆ Seek() [1/3]
Same as Seek(), but with additional options. This default implementation just calls Seek() and ignores options.
◆ Seek() [2/3]
Change the media's playback time.
- Parameters
-
| Time | The playback time to set. |
- Returns
- true on success, false otherwise.
- See also
- GetTime
◆ Seek() [3/3]
Change the playback time of the media by a relative offset in the given direction.
- Parameters
-
| TimeOffset | The offset to apply to the time. |
| Direction | The direction to seek in. |
- Returns
- true on success, false otherwise.
- See also
- GetDuration, GetTime
◆ SetBlockingPlaybackHint()
| virtual void IMediaControls::SetBlockingPlaybackHint |
( |
bool |
bFacadeWillUseBlockingPlayback | ) |
|
|
inlinevirtual |
Hint for player indicating that blocked playback mode will be used / not used
- Parameters
-
| bFacadeWillUseBlockingPlayback | True if blocked playback will be used, false otherwiese |
- Note
- Implement as needed by the player.
◆ SetLooping()
Set whether playback should be looping.
- Parameters
-
| Looping | Enables or disables looping. |
- See also
- IsLooping
◆ SetPlaybackTimeRange()
◆ SetRate()
Set the current playback rate.
A playback rate of 1.0 will play the media normally at real-time. A rate of 0.0 corresponds to pausing playback. A negative rate, if supported, plays the media in reverse, and a rate larger than 1.0 fast forwards playback.
- Parameters
-
| Rate | The playback rate to set. |
- Returns
- true on success, false otherwise.
- See also
- GetRate, Pause, Play
The documentation for this class was generated from the following file: