[webkit-reviews] review granted: [Bug 190085] [MSE] Use tolerance when growing the coded frame group : [Attachment 352979] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Oct 30 13:19:20 PDT 2018
Jer Noble <jer.noble at apple.com> has granted Alicia Boya GarcĂa
<aboya at igalia.com>'s request for review:
Bug 190085: [MSE] Use tolerance when growing the coded frame group
https://bugs.webkit.org/show_bug.cgi?id=190085
Attachment 352979: Patch
https://bugs.webkit.org/attachment.cgi?id=352979&action=review
--- Comment #18 from Jer Noble <jer.noble at apple.com> ---
Comment on attachment 352979
--> https://bugs.webkit.org/attachment.cgi?id=352979
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=352979&action=review
r=me with nit.
> LayoutTests/media/media-source/media-source-append-acb-tolerance.html:39
> + function makeAWebMLikeSample(presentationTimeMilliseconds,
durationMicroseconds, trackID, flags, generation) {
> + // The original makeASample() function uses millisecond precision
for all the fields, but for this test we need
> + // to test what happens with overlaps smaller than that.
> +
> + var byteLength = 30;
> + var buffer = new ArrayBuffer(byteLength);
> + var array = new Uint8Array(buffer);
> + array.set(stringToArray('smpl'));
> +
> + var view = new DataView(buffer);
> + view.setUint32(4, byteLength, true);
> +
> + var timeScale = 1e6;
> + view.setInt32(8, timeScale, true);
> + view.setInt32(12, presentationTimeMilliseconds * 1000, true);
> + view.setInt32(16, presentationTimeMilliseconds * 1000, true);
> + view.setInt32(20, durationMicroseconds, true);
> + view.setInt32(24, trackID, true);
> + view.setUint8(28, flags);
> + view.setUint8(29, generation);
> +
> + return buffer
> + }
mock-media-source.js's makeASample() now takes a timeScale for the last
parameter (after generation), so you can likely remove this method...
> LayoutTests/media/media-source/media-source-append-acb-tolerance.html:54
> + const ptsMilliseconds = Math.round(1000 * (start + numFrame /
fps));
> + const durationMicroseconds = 33333;
> + samples.push(makeAWebMLikeSample(ptsMilliseconds,
durationMicroseconds, 1, numFrame === 0 ? SAMPLE_FLAG.SYNC :
SAMPLE_FLAG.NONE));
...And update this section to use makeASample().
More information about the webkit-reviews
mailing list