Hey Delta,
You’re right with regards to the auto clearing. I re-added autoClear = false and preserveFrameBuffer = true and spector.js is reporting no clearing taking place. It looks like the frame buffer is actually persisting correctly. However the canvas on the page appears blank when we don’t scene.render(). It’s as if the frame buffer isn’t being copied to the canvas on the page if scene.render() is not called. I’m not 100% sure how that works at the base level though so purely speculation.
I’ve included a screenshot of the issue in safari, on the right you’ll see frame buffer canvas 4 is correctly rendered not blank. But whenever we skip scene.render() in the loop function the canvas displayed to the user goes blank. This wasn’t the case when I was using the standard flow for rendering, passing the canvas directly to engine. Should I manually be copying the frame buffer to my view canvas when not calling scene.render()?
I’d certainly be happy to contribute to this stuff moving forward, it’s quite important to us right now and this is a library we use extensively. In the meantime I’m still trying to get a code demo running for some reason I always get the following error
Failed to execute 'drawImage' on 'CanvasRenderingContext2D': The image argument is a canvas element with a width or height of 0.
Even after checking both the view canvas and working canvas are non zero dimensions before calling render()… I’ll post here the second I get it running…
As for the low resolution, I’ll wait to get a code demo running. But it appears the frame buffer is rendering at 360 x 306, which is the size of the view canvas exactly. But on my S8 I would expect the frame buffer to be 360 * 3 x 306 * 3 as the S8 has a device pixel ratio of 3, is it correct for me to think this? Again I’ll try and demonstrate this in a sandbox.