Sync Media Player
Used for playing synchronized media such as EPUB Media Overlays or TTS (Text-To-Speech).
Create a new player by calling ReadingSystemEngine.createSyncMediaPlayer with a SyncMediaTimeline.
The actual rendering of media such as audio or video are performed by SyncMediaObjectRenderers. These are currently not exposed in this API.
A SyncMediaPlayer can be attached to a ReaderView by assigning the player to ReaderView.syncMediaPlayer. When a SyncMediaPlayer is attached to a ReaderView, they are able to synchronize positions and enable features such as text highlighting (if the synchronized media format supports it).
Functions
Adds an instance of OnSyncMediaPlayerEventListener to the player. It will produce events with information about the playback state.
Attempts to synchronize the player with the ReaderView using the given method.
Removes an instance of OnSyncMediaPlayerEventListener from the player.
Seek to the approximate time from timeline start in milliseconds.
Seeks to the next segment in the timeline, if such segment exists.
Seeks to the previous segment in the timeline, if such segment exists.
Seeks to a position in the timeline.
Properties
Gets/sets the options related to how the SyncMediaPlayer automatically synchronizes with the ReaderView. Disable managed synchronization by setting SyncMediaManagedReaderViewSynchronizationOptions.enabled to false.
Gets/sets the synchronization wait behavior for the SyncMediaPlayer when it is attached to a ReaderView. See SyncMediaReaderViewSynchronizationWaitBehavior for a description on how each mode works.
Returns true if the player is waiting to become synchronized with the ReaderView.