Skip to content

Commit cf2e061

Browse files
committed
Address review comments
1 parent 142c506 commit cf2e061

1 file changed

Lines changed: 11 additions & 13 deletions

File tree

index.src.html

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3748,8 +3748,8 @@
37483748

37493749
: <dfn method for=VideoFrame>copyTo(|destination|, |options|)</dfn>
37503750
:: Asynchronously copies the planes of this frame into |destination| according
3751-
to |options|. The format of the data is specified by {{VideoFrameCopyToOptions/format}},
3752-
if present, otherwise {{VideoFrame/format}}.
3751+
to |options|. The format of the data is |options|.{{VideoFrameCopyToOptions/format}},
3752+
if it [=map/exists=] or [=this=] {{VideoFrame}}'s {{VideoFrame/format}} otherwise.
37533753

37543754
NOTE: Promises that are returned by several calls to
37553755
{{VideoFrame/copyTo()}} are not guaranteed to resolve in the order they
@@ -3777,12 +3777,10 @@
37773777
and |options|.{{VideoFrameCopyToOptions/colorSpace}}.
37783778
4. Return the result of calling {{VideoFrame/copyTo()}} on |rgbFrame| with
37793779
|destination| and |newOptions|.
3780-
7. Otherwise, if |options|.{{VideoFrameCopyToOptions/format}} is not `undefined` or `null`
3781-
return a promise rejected with a {{NotSupportedError}} {{DOMException}}.
3782-
8. Let |p| be a new {{Promise}}.
3783-
9. Let |copyStepsQueue| be the result of starting a new [=parallel queue=].
3784-
10. Let |planeLayouts| be a new [=list=].
3785-
11. Enqueue the following steps to |copyStepsQueue|:
3780+
7. Let |p| be a new {{Promise}}.
3781+
8. Let |copyStepsQueue| be the result of starting a new [=parallel queue=].
3782+
9. Let |planeLayouts| be a new [=list=].
3783+
10. Enqueue the following steps to |copyStepsQueue|:
37863784
1. Let resource be the [=media resource=] referenced by
37873785
[[resource reference]].
37883786
2. Let |numPlanes| be the number of planes as defined by
@@ -3819,7 +3817,7 @@
38193817
10. Increment |planeIndex| by `1`.
38203818
11. Append |layout| to |planeLayouts|.
38213819
5. [=Queue a task=] to resolve |p| with |planeLayouts|.
3822-
12. Return |p|.
3820+
11. Return |p|.
38233821

38243822
: <dfn method for=VideoFrame>clone()</dfn>
38253823
:: Creates a new {{VideoFrame}} with a reference to the same
@@ -4064,7 +4062,7 @@
40644062
7. If |options|.{{VideoFrameCopyToOptions/layout}} [=map/exists=], assign
40654063
its value to |optLayout|.
40664064
8. Let |format| be `undefined`.
4067-
9. If |options|.{{VideoFrameCopyToOptions/format}} is `undefined`,
4065+
9. If |options|.{{VideoFrameCopyToOptions/format}} does not [=map/exist=],
40684066
assign {{VideoFrame/[[format]]}} to |format|.
40694067
10. Otherwise, if |options|.{{VideoFrameCopyToOptions/format}} is equal to
40704068
one of {{RGBA}}, {{RGBX}}, {{BGRA}}, {{BGRX}}, then assign
@@ -4324,14 +4322,14 @@
43244322
: <dfn dict-member for=VideoFrameCopyToOptions>format</dfn>
43254323
:: A {{VideoPixelFormat}} for the pixel data in the destination
43264324
{{BufferSource}}. Potential values are: {{RGBA}}, {{RGBX}}, {{BGRA}},
4327-
{{BGRX}}. If unspecified or `null`, the the destination
4328-
{{BufferSource}} will match {{VideoFrame/format}} .
4325+
{{BGRX}}. If it does not [=map/exist=], the the destination
4326+
{{BufferSource}} will be in the same format as {{VideoFrame/format}} .
43294327
: <dfn dict-member for=VideoFrameCopyToOptions>colorSpace</dfn>
43304328
:: A {{PredefinedColorSpace}} that <em class="rfc2119">MUST</em> be used as
43314329
a target color space for the pixel data in the destination
43324330
{{BufferSource}}, but only if {{VideoFrameCopyToOptions/format}} is one of
43334331
{{RGBA}}, {{RGBX}}, {{BGRA}}, {{BGRX}}, otherwise it is ignored.
4334-
If unspecified or `null`, {{srgb}} is used.
4332+
If it does not [=map/exist=], {{srgb}} is used.
43354333

43364334

43374335
DOMRects in VideoFrame {#videoframe-domrect}

0 commit comments

Comments
 (0)