Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webcodecs: Temporal SVC encode #28063

Merged
merged 1 commit into from Mar 16, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 5 additions & 2 deletions webcodecs/video-encoder.any.js
Expand Up @@ -60,7 +60,10 @@ promise_test(t => {
promise_test(async t => {
let output_chunks = [];
let codecInit = getDefaultCodecInit(t);
codecInit.output = chunk => output_chunks.push(chunk);
codecInit.output = (chunk, metadata) => {
assert_not_equals(metadata, null);
output_chunks.push(chunk);
}

let encoder = new VideoEncoder(codecInit);

Expand Down Expand Up @@ -102,7 +105,7 @@ promise_test(async t => {
let bitmap = await generateBitmap(320, 200);
let encoder = null;
let reset_completed = false;
codecInit.output = chunk => {
codecInit.output = (chunk, metadata) => {
if (chunk.timestamp % 2 == 0) {
// pre-reset frames have even timestamp
callbacks_before_reset++;
Expand Down