Chrome 128 WebGL issue breaks project. "... The provided float value is non-finite."

Chrome 128 was released 6 days ago and it can break a PlayCanvas project.

playcanvas-1.71.6.js:12516 Uncaught TypeError: Failed to execute 'uniform4fv' on 'WebGL2RenderingContext': The provided float value is non-finite.
    at WebglGraphicsDevice._this.commitFunction.<computed> (playcanvas-1.71.6.js:12516:9)
    at WebglGraphicsDevice.draw (playcanvas-1.71.6.js:13437:44)
    at QuadRender.render (playcanvas-1.71.6.js:18764:11)
    at RenderPassQuad.execute (playcanvas-1.71.6.js:18789:14)
    at RenderPassQuad.render (playcanvas-1.71.6.js:14372:11)
    at drawQuadWithShader (playcanvas-1.71.6.js:18811:14)
    at Object.reprojectTexture (playcanvas-1.71.6.js:25360:5)
	... 

The project code before the engine code executing there:


// Reproject a cubemap into a texture
DynamicCubemap.prototype.reprojectCubemap = function (cubemap) {
    // Original
    pc.reprojectTexture(cubemap, this.cubemapTextures[0]);

    // Generate prefiltered data
    var sizes = [256, 128, 64, 32, 16, 8, 4];
    var specPower = [undefined, undefined, 512, 128, 32, 8, 2];

    // Prefilter cubemap into textures with different size+specular
    for (let k = 1; k < sizes.length; k++) {
        pc.reprojectTexture(this.cubemapTextures[0], this.cubemapTextures[k], {
            specularPower: specPower[k],
            numSamples: 1024,
        });
    }
};

That stack trace is from engine 1.71.6. I confirmed the same exception is thrown when using 1.73.4 or 2.0.0.

Chromium issue ticket: Chromium

Is this a Chrome issue? Is a patch in PlayCanvas engine needed? Thoughts on a project-level fix?

Thanks, I believed this was fixed a while back by reprojectTexture options#seamPixels divides by 0 · Issue #4889 · playcanvas/engine · GitHub but perhaps there is still some issue @slimbuck could investigate and fix.

@3dTim - would you have a repro project you could share with us?

The Chromium is in the meantime urgently reverting their change and are back-porting it to v128 as well: Chromium

1 Like
1 Like

Thank you both. The patch seems to work.

No, I don’t have a public repro project, unfortunately.