Skip to content

Commit

Permalink
Increase tolerance to 8 from 3. (KhronosGroup#3216)
Browse files Browse the repository at this point in the history
Found necessary on multiple platforms in http://crbug.com/1165751 .

Follow-up to KhronosGroup#3214 .
  • Loading branch information
kenrussell authored Feb 10, 2021
1 parent 08c57bd commit bfee2d2
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -149,12 +149,14 @@
// Buffers returned from setupQuad above, and ignored, are already bound.
wtu.drawUnitQuad(gl);

// Top and bottom halves should be equal. Go through one
// Top and bottom halves should be roughly equal. Go through one
// horizontal scanline in the middle.
const compareHeight = sz / 4;
let pixelValue = new Uint8Array(4);
let allEqual = true;
const tolerance = 3;
// Empirically found that tolerance between the top and bottom
// needs to be up to roughly 8 on some platforms.
const tolerance = 8;
let tempBuf = new Uint8Array(4);
// Step over some pixels to spew slightly fewer comparison messages.
for (let x = 0; x < sz; x += 4) {
Expand Down

0 comments on commit bfee2d2

Please sign in to comment.