);

const srcData = new Uint8Array([ 1, 2, 3, 4, 5, 6, 7, 8 ]);
const noData = new Uint8Array(8);

const srcBuffer = gl.createBuffer();
gl.bindBuffer(gl.COPY_READ_BUFFER, srcBuffer);
gl.bufferData(gl.COPY_READ_BUFFER, srcData, gl.STATIC_DRAW);

const badBuffer = gl.createBuffer();
gl.bindBuffer(gl.ARRAY_BUFFER, badBuffer);
gl.bufferData(gl.ARRAY_BUFFER, 8, gl.STATIC_DRAW);

let readbackBuffer;
function deleteReadbackBuffer() {
    gl.deleteBuffer(readbackBuffer);
}
function recreateReadbackBuffer() {
    re