FLCastPlayer
public protocol FLCastPlayer : AdPlayer
Cast Player, an equivalent to GCKRemoteMediaClient.
-
The currently played asset
Declaration
Swift
var castAsset: CastPlatformAsset? { get } -
loadMedia(castAsset:Default implementationmetadata: mediaTracks: selectedTracks: ) API to load media onto receiver
Default Implementation
API to load media onto receiver
Declaration
Swift
func loadMedia( castAsset: CastAsset, metadata: GCKMediaMetadata, mediaTracks: [GCKMediaTrack]?, selectedTracks: [MediaTrack]? )Parameters
castAssetThe asset that must be loaded and played
metadataThe metadata
mediaTracksThe Media tracks
selectedTracksAudio/subtitle track selections from the content player to apply once media is loaded on the receiver
-
loadMedia(castAsset:Default implementationmetadata: mediaTracks: selectedTracks: ) API to load media onto receiver
Default Implementation
API to load media onto receiver
Declaration
Swift
func loadMedia<T: Codable, U: Codable, V: Codable, W: Codable>( castAsset: CastAssetWithAnalytics<T, U, V, W>, metadata: GCKMediaMetadata, mediaTracks: [GCKMediaTrack]?, selectedTracks: [MediaTrack]? )Parameters
castAssetThe asset that must be loaded and played
metadataThe metadata
mediaTracksThe Media tracks
selectedTracksAudio/subtitle track selections from the content player to apply once media is loaded on the receiver
-
API to get current item in the queue
Declaration
Swift
func getCurrentItem() -> GCKMediaQueueItem?Return Value
Current item in the queue if available else nil
-
API to jump to next item in the queue.
Declaration
Swift
func jumpToNextItem() -
setActiveTrackIDs(_:Extension method) Sets the active tracks. The request will fail if there is no current media status.
Declaration
Swift
func setActiveTrackIDs(_ activeTrackIDs: [NSNumber]?) -> GCKRequest?Parameters
activeTrackIDsAn array of integers specifying the active tracks. May be empty or nil to disable any currently active tracks.
Return Value
The GCKRequest object for tracking this request. Nil if remote media client is not available.
-
setTextTrackStyle(_:Extension method) Sets the text track style. The request will fail if there is no current media status.
Declaration
Swift
func setTextTrackStyle(_ textTrackStyle: GCKMediaTextTrackStyle?) -> GCKRequest?Parameters
textTrackStyleThe text track style. The style will not be changed if this is nil.
Return Value
The GCKRequest object for tracking this request. Nil if remote media client is not available.