Platforms to show: All Mac Windows Linux Cross-Platform
Back to AVPlayerMediaSelectionCriteriaMBS class.
AVPlayerMediaSelectionCriteriaMBS.Constructor(preferredLanguages() as string, preferredMediaCharacteristics() as string)
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | AVFoundation | MBS AVFoundation Plugin | 14.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
preferredLanguages: An array of strings containing language identifiers, in the preferred order. Can be nil.
preferredMediaCharacteristics: An array of strings indicating additional media characteristics, the preferred order. Can be nil.
Supported media characteristics are defined in AVMediaSelectionOption Constants and Media Characteristics.
Returns an initialized AVPlayerMediaSelectionCriteria instance.
When making selections, AVPlayer treats the preferredLanguages as the paramount criterion and the preference for preferredMediaCharacteristics as secondary.
The objects in the preferredLanguages array are indicated using BCP 47 language identifiers or ISO 639-2/T language codes.
If no option with any of the preferredLanguages is available, a selection is made according to the default enabling and disabling of media options as stored in the asset.
The preferredMediaCharacteristics are used when selecting media for the AVPlayer.
For example, desirable characteristics of legible media may include AVMediaCharacteristicTranscribesSpokenDialogForAccessibility and AVMediaCharacteristicDescribesMusicAndSoundForAccessibility.
Similarly, desirable characteristics of audible media may include AVMediaCharacteristicDescribesVideoForAccessibility.
If no option is found that possesses all of the desired characteristics, the option that best matches the desired characteristics will be selected.
Available in OS X v10.9 and later.
AVPlayerMediaSelectionCriteriaMBS.preferredLanguages as String()
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | AVFoundation | MBS AVFoundation Plugin | 14.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
Available in OS X v10.9 and later.
AVPlayerMediaSelectionCriteriaMBS.preferredMediaCharacteristics as String()
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
method | AVFoundation | MBS AVFoundation Plugin | 14.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
Available in OS X v10.9 and later.
The items on this page are in the following plugins: MBS AVFoundation Plugin.