@@ -278,7 +278,7 @@ enum RTCEncodedVideoFrameType {
278
278
};
279
279
</pre>
280
280
<table dfn-for="RTCEncodedVideoFrameType" class="simple">
281
- <caption> Enumeration description</caption>
281
+ <caption> Enumeration description</caption>
282
282
<thead>
283
283
<tr>
284
284
<th> Enum value</th><th> Description</th>
@@ -371,7 +371,7 @@ dictionary RTCEncodedVideoFrameMetadata {
371
371
<dd>
372
372
<p>
373
373
The media presentation timestamp (PTS) in microseconds of raw frame, matching the
374
- {{VideoFrame/timestamp}} for raw frames which correspond to this frame.
374
+ {{VideoFrame/timestamp}} for raw frames which correspond to this frame.
375
375
</p>
376
376
</dd>
377
377
</dl>
@@ -433,6 +433,27 @@ interface RTCEncodedVideoFrame {
433
433
</dd>
434
434
</dl>
435
435
436
+ ### Serialization ### {#RTCEncodedVideoFrame-serialization}
437
+
438
+ {{RTCEncodedVideoFrame}} objects are serializable objects [[HTML]] .
439
+ Their serialization steps, given |value|, |serialized|, and |forStorage|, are:
440
+
441
+ 1. If |forStorage| is true, then throw a "DataCloneError" DOMException.
442
+ 1. Set |serialized|.`[[metadata]] ` to an internal representation of |value|'s metadata.
443
+ 1. Set |serialized|.`[[data]] ` to |value|.`[[data]] `
444
+
445
+ Their deserialization steps, given |serialized|, |value| and |realm|, are:
446
+
447
+ 1. Set |value|'s metadata to the platform object representation of |serialized|.`[[metadata]] `
448
+ 1. Set |value|.`[[data]] ` to |serialized|.`[[data]] `.
449
+
450
+ <p class="note">
451
+ The internal form of a serialized RTCEncodedVideoFrame is not observable;
452
+ it is defined chiefly so that it can be used with frame cloning in the
453
+ [$writeEncodedData$] algortihm and in the StructuredClone operation.
454
+ An implementation is therefore free to choose whatever method works best.
455
+ </p>
456
+
436
457
## <dfn dictionary>RTCEncodedAudioFrameMetadata</dfn> dictionary ## {#RTCEncodedAudioFrameMetadata}
437
458
<pre class="idl">
438
459
dictionary RTCEncodedAudioFrameMetadata {
@@ -529,6 +550,20 @@ interface RTCEncodedAudioFrame {
529
550
</dl>
530
551
531
552
553
+ ### Serialization ### {#RTCEncodedAudioFrame-serialization}
554
+
555
+ {{RTCEncodedAudioFrame}} objects are serializable objects [[HTML]] .
556
+ Their serialization steps, given |value|, |serialized|, and |forStorage|, are:
557
+
558
+ 1. If |forStorage| is true, then throw a "DataCloneError" DOMException.
559
+ 1. Set |serialized|.`[[metadata]] ` to an internal representation of |value|'s metadata.
560
+ 1. Set |serialized|.`[[data]] ` to |value|.`[[data]] `
561
+
562
+ Their deserialization steps, given |serialized|, |value| and |realm|, are:
563
+
564
+ 1. Set |value|'s metadata to the platform object representation of |serialized|.`[[metadata]] `
565
+ 1. Set |value|.`[[data]] ` to |serialized|.`[[data]] `.
566
+
532
567
// New interfaces to expose JavaScript-based transforms.
533
568
##Interfaces
534
569
<pre class="idl">
0 commit comments