MediaCapabilitiesAPI
Types
audioConfiguration
type audioConfiguration = { mutable contentType: string, mutable channels?: string, mutable bitrate?: int, mutable samplerate?: int, mutable spatialRendering?: bool,}
Record fields
contentType
string
channels
option< string >
bitrate
option< int >
samplerate
option< int >
spatialRendering
option< bool >
colorGamut
type colorGamut = | @as("p3") P3 | @as("rec2020") Rec2020 | @as("srgb") Srgb
hdrMetadataType
type hdrMetadataType = | @as("smpteSt2086") SmpteSt2086 | @as("smpteSt2094-10") SmpteSt209410 | @as("smpteSt2094-40") SmpteSt209440
mediaCapabilities
type mediaCapabilities = {}
Module
There are methods and helpers defined in MediaCapabilities .
mediaCapabilitiesDecodingInfo
type mediaCapabilitiesDecodingInfo = { mutable supported: bool, mutable smooth: bool, mutable powerEfficient: bool, mutable configuration?: mediaDecodingConfiguration,}
Record fields
supported
bool
smooth
bool
powerEfficient
bool
configuration
option< mediaDecodingConfiguration >
mediaCapabilitiesEncodingInfo
type mediaCapabilitiesEncodingInfo = { mutable supported: bool, mutable smooth: bool, mutable powerEfficient: bool, mutable configuration?: mediaEncodingConfiguration,}
Record fields
supported
bool
smooth
bool
powerEfficient
bool
configuration
option< mediaEncodingConfiguration >
mediaCapabilitiesInfo
type mediaCapabilitiesInfo = { mutable supported: bool, mutable smooth: bool, mutable powerEfficient: bool,}
Record fields
supported
bool
smooth
bool
powerEfficient
bool
mediaConfiguration
type mediaConfiguration = { mutable video?: videoConfiguration, mutable audio?: audioConfiguration,}
Record fields
video
option< videoConfiguration >
audio
option< audioConfiguration >
mediaDecodingConfiguration
type mediaDecodingConfiguration = { mutable video?: videoConfiguration, mutable audio?: audioConfiguration, mutable type_: mediaDecodingType,}
Record fields
video
option< videoConfiguration >
audio
option< audioConfiguration >
type_
mediaDecodingType
type mediaDecodingType = | @as("file") File | @as("media-source") MediaSource | @as("webrtc") Webrtc
mediaEncodingConfiguration
type mediaEncodingConfiguration = { mutable video?: videoConfiguration, mutable audio?: audioConfiguration, mutable type_: mediaEncodingType,}
Record fields
video
option< videoConfiguration >
audio
option< audioConfiguration >
type_
mediaEncodingType
type mediaEncodingType = | @as("record") Record | @as("webrtc") Webrtc
transferFunction
type transferFunction = | @as("hlg") Hlg | @as("pq") Pq | @as("srgb") Srgb
videoConfiguration
type videoConfiguration = { mutable contentType: string, mutable width: int, mutable height: int, mutable bitrate: int, mutable framerate: float, mutable hasAlphaChannel?: bool, mutable hdrMetadataType?: hdrMetadataType, mutable colorGamut?: colorGamut, mutable transferFunction?: transferFunction, mutable scalabilityMode?: string,}
Record fields
contentType
string
width
int
height
int
bitrate
int
framerate
float
hasAlphaChannel
option< bool >
hdrMetadataType
option< hdrMetadataType >
colorGamut
option< colorGamut >
transferFunction
option< transferFunction >
scalabilityMode
option< string >