|
485 | 485 | algorithm with |decoded outputs|. |
486 | 486 | 2. Remove |promise| from |
487 | 487 | {{AudioDecoder/[[pending flush promises]]}}. |
488 | | - 3. Resolve |promise|. |
| 488 | + 3. [=Resolve=] |promise|. |
489 | 489 | 2. Return `"processed"`. |
490 | 490 | </dd> |
491 | 491 |
|
|
534 | 534 | 1. Set {{AudioDecoderSupport/config}} to the result of running the |
535 | 535 | <a>Clone Configuration</a> algorithm with |config|. |
536 | 536 | 2. Set {{AudioDecoderSupport/supported}} to |supported|. |
537 | | - 2. Resolve |p| with |decoderSupport|. |
| 537 | + 2. [=Resolve=] |p| with |decoderSupport|. |
538 | 538 | 5. Return |p|. |
539 | 539 | </dd> |
540 | 540 | </dl> |
|
584 | 584 | 1. Set {{AudioDecoder/[[decodeQueueSize]]}} to zero. |
585 | 585 | 2. Run the [=AudioDecoder/Schedule Dequeue Event=] algorithm. |
586 | 586 | 6. For each |promise| in {{AudioDecoder/[[pending flush promises]]}}: |
587 | | - 1. Reject |promise| with |exception|. |
| 587 | + 1. [=Reject=] |promise| with |exception|. |
588 | 588 | 2. Remove |promise| from {{AudioDecoder/[[pending flush promises]]}}. |
589 | 589 | </dd> |
590 | 590 | <dt><dfn>Close AudioDecoder</dfn> (with |exception|)</dt> |
|
831 | 831 | algorithm with |decoded outputs|. |
832 | 832 | 2. Remove |promise| from |
833 | 833 | {{VideoDecoder/[[pending flush promises]]}}. |
834 | | - 3. Resolve |promise|. |
| 834 | + 3. [=Resolve=] |promise|. |
835 | 835 | 2. Return `"processed"`. |
836 | 836 | </dd> |
837 | 837 |
|
|
880 | 880 | 1. Set {{VideoDecoderSupport/config}} to the result of running the |
881 | 881 | <a>Clone Configuration</a> algorithm with |config|. |
882 | 882 | 2. Set {{VideoDecoderSupport/supported}} to |supported|. |
883 | | - 2. Resolve |p| with |decoderSupport|. |
| 883 | + 2. [=Resolve=] |p| with |decoderSupport|. |
884 | 884 | 5. Return |p|. |
885 | 885 | </dd> |
886 | 886 | </dl> |
|
943 | 943 | 1. Set {{VideoDecoder/[[decodeQueueSize]]}} to zero. |
944 | 944 | 2. Run the [=VideoDecoder/Schedule Dequeue Event=] algorithm. |
945 | 945 | 6. For each |promise| in {{VideoDecoder/[[pending flush promises]]}}: |
946 | | - 1. Reject |promise| with |exception|. |
| 946 | + 1. [=Reject=] |promise| with |exception|. |
947 | 947 | 2. Remove |promise| from {{VideoDecoder/[[pending flush promises]]}}. |
948 | 948 | </dd> |
949 | 949 | <dt><dfn>Close VideoDecoder</dfn> (with |exception|)</dt> |
|
1173 | 1173 | [=Output EncodedAudioChunks=] algorithm with |encoded outputs|. |
1174 | 1174 | 2. Remove |promise| from |
1175 | 1175 | {{AudioEncoder/[[pending flush promises]]}}. |
1176 | | - 3. Resolve |promise|. |
| 1176 | + 3. [=Resolve=] |promise|. |
1177 | 1177 | 2. Return `"processed"`. |
1178 | 1178 | </dd> |
1179 | 1179 |
|
|
1222 | 1222 | 1. Set {{AudioEncoderSupport/config}} to the result of running the |
1223 | 1223 | <a>Clone Configuration</a> algorithm with |config|. |
1224 | 1224 | 2. Set {{AudioEncoderSupport/supported}} to |supported|. |
1225 | | - 2. Resolve |p| with |encoderSupport|. |
| 1225 | + 2. [=Resolve=] |p| with |encoderSupport|. |
1226 | 1226 | 5. Return |p|. |
1227 | 1227 | </dd> |
1228 | 1228 | </dl> |
|
1302 | 1302 | 1. Set {{AudioEncoder/[[encodeQueueSize]]}} to zero. |
1303 | 1303 | 2. Run the [=AudioEncoder/Schedule Dequeue Event=] algorithm. |
1304 | 1304 | 8. For each |promise| in {{AudioEncoder/[[pending flush promises]]}}: |
1305 | | - 1. Reject |promise| with |exception|. |
| 1305 | + 1. [=Reject=] |promise| with |exception|. |
1306 | 1306 | 2. Remove |promise| from {{AudioEncoder/[[pending flush promises]]}}. |
1307 | 1307 | </dd> |
1308 | 1308 | <dt><dfn>Close AudioEncoder</dfn> (with |exception|)</dt> |
|
1559 | 1559 | [=Output EncodedVideoChunks=] algorithm with |encoded outputs|. |
1560 | 1560 | 2. Remove |promise| from |
1561 | 1561 | {{VideoEncoder/[[pending flush promises]]}}. |
1562 | | - 3. Resolve |promise|. |
| 1562 | + 3. [=Resolve=] |promise|. |
1563 | 1563 | 2. Return `"processed"`. |
1564 | 1564 | </dd> |
1565 | 1565 |
|
|
1608 | 1608 | 1. Set {{VideoEncoderSupport/config}} to the result of running the |
1609 | 1609 | <a>Clone Configuration</a> algorithm with |config|. |
1610 | 1610 | 2. Set {{VideoEncoderSupport/supported}} to |supported|. |
1611 | | - 2. Resolve |p| with |encoderSupport|. |
| 1611 | + 2. [=Resolve=] |p| with |encoderSupport|. |
1612 | 1612 | 5. Return |p|. |
1613 | 1613 | </dd> |
1614 | 1614 | </dl> |
|
1707 | 1707 | 1. Set {{VideoEncoder/[[encodeQueueSize]]}} to zero. |
1708 | 1708 | 2. Run the [=VideoEncoder/Schedule Dequeue Event=] algorithm. |
1709 | 1709 | 8. For each |promise| in {{VideoEncoder/[[pending flush promises]]}}: |
1710 | | - 1. Reject |promise| with |exception|. |
| 1710 | + 1. [=Reject=] |promise| with |exception|. |
1711 | 1711 | 2. Remove |promise| from {{VideoEncoder/[[pending flush promises]]}}. |
1712 | 1712 | </dd> |
1713 | 1713 | <dt><dfn>Close VideoEncoder</dfn> (with |exception|)</dt> |
|
3907 | 3907 | 4. Increment |row| by `1`. |
3908 | 3908 | 10. Increment |planeIndex| by `1`. |
3909 | 3909 | 11. Append |layout| to |planeLayouts|. |
3910 | | - 5. [=Queue a task=] to resolve |p| with |planeLayouts|. |
| 3910 | + 5. [=Queue a task=] to [=resolve=] |p| with |planeLayouts|. |
3911 | 3911 | 11. Return |p|. |
3912 | 3912 |
|
3913 | 3913 | : <dfn method for=VideoFrame>clone()</dfn> |
|
5475 | 5475 | 3. Otherwise: |
5476 | 5476 | 1. Assign a copy of `init.data` to {{ImageDecoder/[[encoded data]]}}. |
5477 | 5477 | 4. Assign `true` to {{ImageDecoder/[[complete]]}}. |
5478 | | - 5. Resolve {{ImageDecoder/[[completed promise]]}}. |
| 5478 | + 5. [=Resolve=] {{ImageDecoder/[[completed promise]]}}. |
5479 | 5479 | 6. Queue a control message to [=configure the image decoder=] with |
5480 | 5480 | |init|. |
5481 | 5481 | 7. Queue a control message to [=decode track metadata=]. |
|
5591 | 5591 | 3. Run the following steps [=in parallel=]: |
5592 | 5592 | 1. Let |isSupported| be the result of running the |
5593 | 5593 | [=Check Type Support=] algorithm with |type|. |
5594 | | - 2. [=Queue a task=] to resolve |p| with |isSupported|. |
| 5594 | + 2. [=Queue a task=] to [=resolve=] |p| with |isSupported|. |
5595 | 5595 | 4. Return |p|. |
5596 | 5596 |
|
5597 | 5597 | ### Algorithms ### {#imagedecoder-algorithms} |
|
5616 | 5616 |
|
5617 | 5617 | : [=read request/close steps=] |
5618 | 5618 | :: 1. Assign `true` to {{ImageDecoder/[[complete]]}} |
5619 | | - 2. Resolve {{ImageDecoder/[[completed promise]]}}. |
| 5619 | + 2. [=Resolve=] {{ImageDecoder/[[completed promise]]}}. |
5620 | 5620 |
|
5621 | 5621 | : [=read request/error steps=] |
5622 | 5622 | :: 1. [=Queue a task=] to run the [=ImageDecoder/Close ImageDecoder=] |
|
5678 | 5678 | {{ImageTrackList/[[track list]]}} internal slot. |
5679 | 5679 | 2. Assign |selectedTrackIndex| to {{ImageDecoder/tracks}} |
5680 | 5680 | {{ImageTrackList/[[selected index]]}}. |
5681 | | - 3. Resolve {{ImageTrackList/[[ready promise]]}}. |
| 5681 | + 3. [=Resolve=] {{ImageTrackList/[[ready promise]]}}. |
5682 | 5682 |
|
5683 | 5683 | : <dfn for=ImageDecoder>Get Default Selected Track Index</dfn> (with |
5684 | 5684 | |trackList|) |
|
5853 | 5853 | [=Create a VideoFrame=] algorithm with |output|, |timestamp|, |
5854 | 5854 | |duration|, |rotation|, and |flip|. |
5855 | 5855 | 19. Remove |promise| from {{ImageDecoder/[[pending decode promises]]}}. |
5856 | | - 20. Resolve |promise| with |decodeResult|. |
| 5856 | + 20. [=Resolve=] |promise| with |decodeResult|. |
5857 | 5857 |
|
5858 | 5858 | : <dfn for=ImageDecoder>Resolve Decode</dfn> (with |promise| and |result|) |
5859 | 5859 | :: 1. [=Queue a task=] to perform these steps: |
5860 | 5860 | 1. If {{ImageDecoder/[[closed]]}}, abort these steps. |
5861 | 5861 | 2. Assert that |promise| is an element of |
5862 | 5862 | {{ImageDecoder/[[pending decode promises]]}}. |
5863 | 5863 | 3. Remove |promise| from {{ImageDecoder/[[pending decode promises]]}}. |
5864 | | - 4. Resolve |promise| with |result|. |
| 5864 | + 4. [=Resolve=] |promise| with |result|. |
5865 | 5865 |
|
5866 | 5866 | : <dfn for=ImageDecoder>Reject Infeasible Decode</dfn> (with |promise|) |
5867 | 5867 | :: 1. Assert that {{ImageDecoder/complete}} is `true` or |
|
5874 | 5874 | 2. Assert that |promise| is an element of |
5875 | 5875 | {{ImageDecoder/[[pending decode promises]]}}. |
5876 | 5876 | 3. Remove |promise| from {{ImageDecoder/[[pending decode promises]]}}. |
5877 | | - 4. Reject |promise| with |exception|. |
| 5877 | + 4. [=Reject=] |promise| with |exception|. |
5878 | 5878 |
|
5879 | 5879 | : <dfn for=ImageDecoder>Fatally Reject Bad Data</dfn> |
5880 | 5880 | :: 1. [=Queue a task=] to perform these steps: |
|
5892 | 5892 | decoding operation. |
5893 | 5893 | 2. For each |decodePromise| in |
5894 | 5894 | {{ImageDecoder/[[pending decode promises]]}}: |
5895 | | - 1. Reject |decodePromise| with |exception|. |
| 5895 | + 1. [=Reject=] |decodePromise| with |exception|. |
5896 | 5896 | 2. Remove |decodePromise| from |
5897 | 5897 | {{ImageDecoder/[[pending decode promises]]}}. |
5898 | 5898 |
|
|
5901 | 5901 | 1. Assign `true` to {{ImageDecoder/[[closed]]}}. |
5902 | 5902 | 2. Clear {{ImageDecoder/[[codec implementation]]}} and release associated |
5903 | 5903 | [=system resources=]. |
5904 | | - 3. If {{ImageDecoder/[[ImageTrackList]]}} is empty, reject |
| 5904 | + 3. If {{ImageDecoder/[[ImageTrackList]]}} is empty, [=reject=] |
5905 | 5905 | {{ImageTrackList/[[ready promise]]}} with |exception|. Otherwise |
5906 | 5906 | perform these steps, |
5907 | 5907 | 1. Remove all entries from {{ImageDecoder/[[ImageTrackList]]}}. |
5908 | 5908 | 2. Assign `-1` to {{ImageDecoder/[[ImageTrackList]]}}'s |
5909 | 5909 | {{ImageTrackList/[[selected index]]}}. |
5910 | | - 4. If {{ImageDecoder/[[complete]]}} is false resolve |
| 5910 | + 4. If {{ImageDecoder/[[complete]]}} is false, [=reject=] |
5911 | 5911 | {{ImageDecoder/[[completed promise]]}} with |exception|. |
5912 | 5912 |
|
5913 | 5913 | ImageDecoderInit Interface {#imagedecoderinit-interface} |
|
0 commit comments