WebCodecs Encoder: Allow Reset() to reject promises during Flush()'s callback
Categories
(Core :: Audio/Video: Web Codecs, defect, P1)
Tracking
()
Tracking | Status | |
---|---|---|
firefox127 | --- | fixed |
People
(Reporter: chunmin, Assigned: chunmin)
References
(Blocks 1 open bug)
Details
Attachments
(5 files)
In Bug 1839993, the issue of Reset() being unable to reject promises during Flush()'s callback in DecoderTemplate was resolved. Since most of the code in EncoderTemplate is copied from DecoderTemplate, it faces the same problem. This bug aims to address the same issue in EncoderTemplate.
Assignee | ||
Comment 1•10 months ago
|
||
The VP8 encoder, based on the libvpx API, is able to pass the
reset-during-flush WPT by change. However, tje H264 encoder, based on
the libx264 API, cannot. Therefore, adding the H264 encoder to the test
can expose the potential failures in the current EncoderTemplate code.
This addition enables us to assess whether subsequent patches
effectively resolve the issue.
Assignee | ||
Comment 2•10 months ago
|
||
Depends on D208188
Assignee | ||
Comment 3•10 months ago
|
||
Previously, Reset() lacked the ability to reject promises of the pending
flush requests during the output callback responsible for delivering the
result request. This limitation arose because once the promise was
transferred from the FlushMessage to the task delivering the flush's
result, there was no external access to that flush's promise outside of
the dispatched task.
This patch addresses this issue by implementing pending flush promises
as outlined in the WebCodecs spec, albeit with a slight modification,
allowing access to any stored pending promise as long as their
associated ID is provided. Conseqently, Reset() gains the capability to
reject all pending promises, while tasks with the corresponding IDs can
retrieve the promises to resolve or reject them based on their
requirements. The implementation aligns with its counterpart
implementation in DecoderTemplate [1].
[1] https://hg.mozilla.org/integration/autoland/rev/32b98903fcfb
Depends on D208189
Assignee | ||
Comment 4•10 months ago
|
||
Depends on D208190
Assignee | ||
Comment 5•10 months ago
|
||
Depends on D208192
Updated•10 months ago
|
Updated•10 months ago
|
Updated•10 months ago
|
Updated•10 months ago
|
Updated•10 months ago
|
Updated•10 months ago
|
https://hg.mozilla.org/mozilla-central/rev/7fa14088e1b4
https://hg.mozilla.org/mozilla-central/rev/05b8d9de3beb
https://hg.mozilla.org/mozilla-central/rev/eeac4e97050a
https://hg.mozilla.org/mozilla-central/rev/5cdecd63c396
https://hg.mozilla.org/mozilla-central/rev/e5d1ebdf2a34
Description
•