Skip to content

Commit 52909d9

Browse files
committed
add mimeType to metadata
since the mapping from payload type to the codec mime type is nontrivial in environments like workers. Defined similar to webrtc-stats: https://w3c.github.io/webrtc-stats/#dom-rtccodecstats-mimetype
1 parent 7721c15 commit 52909d9

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

index.bs

+21-1
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,7 @@ dictionary RTCEncodedVideoFrameMetadata {
341341
sequence<unsigned long> contributingSources;
342342
long long timestamp; // microseconds
343343
unsigned long rtpTimestamp;
344+
DOMString mimeType;
344345
};
345346
</pre>
346347

@@ -381,7 +382,7 @@ dictionary RTCEncodedVideoFrameMetadata {
381382
<dd>
382383
<p>
383384
The media presentation timestamp (PTS) in microseconds of raw frame, matching the
384-
{{VideoFrame/timestamp}} for raw frames which correspond to this frame.
385+
{{VideoFrame/timestamp}} for raw frames which correspond to this frame.
385386
</p>
386387
</dd>
387388
<dt>
@@ -394,6 +395,15 @@ dictionary RTCEncodedVideoFrameMetadata {
394395
that reflects the sampling instant of the first octet in the RTP data packet.
395396
</p>
396397
</dd>
398+
<dt>
399+
<dfn dict-member>mimeType</dfn> <span class="idlMemberType">DOMString</span>
400+
</dt>
401+
<dd>
402+
<p>
403+
The codec MIME media type/subtype defined in the IANA media types registry
404+
[[!IANA-MEDIA-TYPES]], e.g. video/VP8.
405+
</p>
406+
</dd>
397407
</dl>
398408

399409

@@ -473,6 +483,7 @@ dictionary RTCEncodedAudioFrameMetadata {
473483
sequence&lt;unsigned long&gt; contributingSources;
474484
short sequenceNumber;
475485
unsigned long rtpTimestamp;
486+
DOMString mimeType;
476487
};
477488
</pre>
478489
### Members ### {#RTCEncodedAudioFrameMetadata-members}
@@ -525,6 +536,15 @@ dictionary RTCEncodedAudioFrameMetadata {
525536
that reflects the sampling instant of the first octet in the RTP data packet.
526537
</p>
527538
</dd>
539+
<dt>
540+
<dfn dict-member>mimeType</dfn> <span class="idlMemberType">DOMString</span>
541+
</dt>
542+
<dd>
543+
<p>
544+
The codec MIME media type/subtype defined in the IANA media types registry
545+
[[!IANA-MEDIA-TYPES]], e.g. audio/opus.
546+
</p>
547+
</dd>
528548
</dl>
529549

530550
## <dfn interface>RTCEncodedAudioFrame</dfn> interface ## {#RTCEncodedAudioFrame-interface}

0 commit comments

Comments
 (0)