Defines a preferred video codec configuration for a Publisher's stream. More...
| Public Member Functions | |
| PreferredVideoCodecs (List< Codec > codecs) | |
| Creates a new manual codec preference configuration. More... |
| Static Public Member Functions | |
| static PreferredVideoCodecs | Automatic () |
| Enables automatic codec selection mode. More... |
| Properties | |
| List< Codec > | Codecs [get] |
| The list of codecs to prioritize (in order). | |
| bool | UseAutomatic [get] |
| Whether to use automatic codec selection (instead of manual ordering). |
Detailed Description
Defines a preferred video codec configuration for a Publisher's stream.
This class lets you specify an explicit codec priority order or opt into automatic codec selection. Use this to control which codecs are prioritized during negotiation, or let the SDK decide based on internal heuristics.
To use manual ordering:
new PreferredVideoCodecs(new List<PreferredVideoCodecs.Codec> { Codec.H264, Codec.VP8 })
To use automatic selection:
PreferredVideoCodecs.Automatic()
If null is passed instead, the SDK uses the default behavior defined by project settings.
Member Enumeration Documentation
Codec
Available video codec options.
| Enumerator | |
|---|---|
| VP8 | VP8 codec |
| H264 | H.264 codec |
| VP9 | VP9 codec |
Constructor & Destructor Documentation
PreferredVideoCodecs()
| OpenTok.PreferredVideoCodecs.PreferredVideoCodecs | ( | List< Codec > | codecs | ) |
Creates a new manual codec preference configuration.
Parameters : | | | | --- | --- | | codecs | A non-empty list of codecs in order of preference. |
Member Function Documentation
Automatic()
Enables automatic codec selection mode.
Returns : A PreferredVideoCodecs instance with automatic selection enabled.