// Create context const createGL = require('gl') const width = 64 const height = 64 const gl = createGL(width, height, { preserveDrawingBuffer: true }) //Clear screen to red gl.clearColor(1, 0, 0, 1) gl.clear(gl.COLOR_BUFFER_BIT) //Write output as a PPM formatted image const pixels = new Uint8Array(width * height * 4) gl.readPixels(0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, pixels) process.st

