Pick the first advertised MIME type compatible with the request list.
Runtime formats in preference order.
Caller formats in preference order (empty = any).
The normalized advertised type, undefined when none fits, or 'invalid' when a request item is malformed.
undefined
'invalid'
selectCaptureMimeType(['audio/webm;codecs=opus'], ['AUDIO/WEBM']) === 'audio/webm;codecs=opus'; Copy
selectCaptureMimeType(['audio/webm;codecs=opus'], ['AUDIO/WEBM']) === 'audio/webm;codecs=opus';
Pick the first advertised MIME type compatible with the request list.