|
4100 | 4100 | (with |init|, |frame|, |defaultVisibleRect|, |baseRotation|, |baseFlip|, |
4101 | 4101 | |defaultDisplayWidth| and |defaultDisplayHeight|) |
4102 | 4102 | :: 1. Let |visibleRect| be |defaultVisibleRect|. |
4103 | | - 2. If |init|.{{VideoFrameInit/visibleRect}} [=map/exists=], assign it to |
4104 | | - |visibleRect|. |
| 4103 | + 2. If |init|.{{VideoFrameInit/visibleRect}} [=map/exists=]: |
| 4104 | + 1. If any attribute of |init|.{{VideoFrameInit/visibleRect}} is negative or |
| 4105 | + not finite, throw a {{TypeError}}. |
| 4106 | + 2. Assign |init|.{{VideoFrameInit/visibleRect}} to |visibleRect|. |
4105 | 4107 | 3. Assign |visibleRect|'s {{DOMRect/x}}, {{DOMRect/y}}, {{DOMRect/width}}, |
4106 | 4108 | and {{DOMRect/height}}, to |frame|'s {{VideoFrame/[[visible left]]}}, |
4107 | 4109 | {{VideoFrame/[[visible top]]}}, {{VideoFrame/[[visible width]]}}, and |
|
4235 | 4237 | |overrideRect|, |codedWidth|, |codedHeight|, and |format|) |
4236 | 4238 | :: 1. Let |sourceRect| be |defaultRect| |
4237 | 4239 | 2. If |overrideRect| is not `undefined`: |
4238 | | - 1. If either of |overrideRect|.{{DOMRectInit/width}} or |
| 4240 | + 1. If any attribute of |overrideRect| is negative or not finite, return a {{TypeError}}. |
| 4241 | + 2. If either of |overrideRect|.{{DOMRectInit/width}} or |
4239 | 4242 | {{DOMRectInit/height}} is `0`, return a {{TypeError}}. |
4240 | | - 2. If the sum of |overrideRect|.{{DOMRectInit/x}} and |
| 4243 | + 3. If the sum of |overrideRect|.{{DOMRectInit/x}} and |
4241 | 4244 | |overrideRect|.{{DOMRectInit/width}} is greater than |
4242 | 4245 | |codedWidth|, return a {{TypeError}}. |
4243 | | - 3. If the sum of |overrideRect|.{{DOMRectInit/y}} and |
| 4246 | + 4. If the sum of |overrideRect|.{{DOMRectInit/y}} and |
4244 | 4247 | |overrideRect|.{{DOMRectInit/height}} is greater than |
4245 | 4248 | |codedHeight|, return a {{TypeError}}. |
4246 | | - 4. Assign |overrideRect| to |sourceRect|. |
| 4249 | + 5. Assign |overrideRect| to |sourceRect|. |
4247 | 4250 | 3. Let |validAlignment| be the result of running the |
4248 | 4251 | [=VideoFrame/Verify Rect Offset Alignment=] algorithm with |format| and |
4249 | 4252 | |sourceRect|. |
|
0 commit comments