ZegoPlayerConfig class

Advanced player configuration.

Configure stream resource mode, CDN configuration and other advanced configurations.

Constructors

ZegoPlayerConfig(ZegoStreamResourceMode resourceMode, {ZegoCDNConfig? cdnConfig, String? roomID, ZegoVideoCodecID? videoCodecID, ZegoResourceType? sourceResourceType, int? codecTemplateID, ZegoStreamResourceSwitchMode? resourceSwitchMode, ZegoStreamResourceType? resourceWhenStopPublish, int? adaptiveSwitch, List<int>? adaptiveTemplateIDList, ZegoCustomPlayerResourceConfig? customResourceConfig})
ZegoPlayerConfig.defaultConfig()
Create a default advanced player config object

Properties

adaptiveSwitch ↔ int?
Whether to enable adaptive switching of streams, 1 means on, 0 means off. Valid only if resourceMode is ZegoStreamResourceModeOnlyL3. Please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
getter/setter pair
adaptiveTemplateIDList ↔ List<int>?
Stream adaptive transcoding template ID list. Valid only if resourceMode is ZegoStreamResourceModeOnlyL3. Please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
getter/setter pair
cdnConfig ZegoCDNConfig?
The CDN configuration for playing stream. If set, the stream is play according to the URL instead of the streamID. After that, the streamID is only used as the ID of SDK internal callback.
getter/setter pair
codecTemplateID ↔ int?
Preconfigured codec template ID, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
getter/setter pair
customResourceConfig ZegoCustomPlayerResourceConfig?
Play stream resource type configuration when resourceMode is ZegoStreamResourceModeCustom.
getter/setter pair
hashCode → int
The hash code for this object.
no setterinherited
resourceMode ZegoStreamResourceMode
Stream resource mode.
getter/setter pair
resourceSwitchMode ZegoStreamResourceSwitchMode?
Play resource switching strategy mode, the default is ZegoStreamResourceSwitchModeDefault
getter/setter pair
resourceWhenStopPublish ZegoStreamResourceType?
Play resource type when stop publish, the default is ZegoStreamResourceTypeDefault. This setting takes effect only if the user sets resourceMode to ZegoStreamResourceModeDefaut and resourceSwitchMode to ZegoStreamResourceSwitchModeDefault or ZegoStreamResourceSwitchModeSwitchToRTC.
getter/setter pair
roomID ↔ String?
The Room ID. It only needs to be filled in the multi-room mode, which indicates which room this stream needs to be bound to. This parameter is ignored in single room mode.
getter/setter pair
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sourceResourceType ZegoResourceType?
The resource type of the source stream, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
getter/setter pair
videoCodecID ZegoVideoCodecID?
The video encoding type of the stream, please contact ZEGO technical support if you need to use it, otherwise this parameter can be ignored.
getter/setter pair

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited