From a39e45747b0ab3f62db85544e60021a99b77c50e Mon Sep 17 00:00:00 2001 From: Gregg Tavares Date: Mon, 4 Dec 2023 11:33:33 -0800 Subject: [PATCH] fix clear --- examples/js/index/index.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/examples/js/index/index.js b/examples/js/index/index.js index 33787cf..89d4374 100644 --- a/examples/js/index/index.js +++ b/examples/js/index/index.js @@ -13,6 +13,9 @@ function render(time) { time *= 0.001; twgl.resizeCanvasToDisplaySize(canvas); + gl.disable(gl.SCISSOR_TEST); + gl.clearColor(0, 0, 0, 0); + gl.clear(gl.COLOR_BUFFER_BIT); canvas.style.transform = `translateX(${window.scrollX}px) translateY(${window.scrollY}px)`;