let canvas = document.createElement("canvas");
canvas.width = 150;
canvas.height = 150;
let ctx = canvas.getContext('webgl2');
let shader = ctx.createShader(35633);
ctx.shaderSource(shader,'\n        attribute vec4 aPosition;\n        attribute vec4 aColor;\n        uniform vec4 anOffset;\n        varying vec4 vColor;\n        void main(void) {\n          gl_Position = aPosition + anOffset;\n          vColor = aColor;\n        }\n      ');
ctx.compileShader(shader);
let shaderParam1 = ctx.getShaderParameter(shader, 35713);
let shader2 = ctx.createShader(35632);
ctx.shaderSource(shader2,'\n        precision mediump float;\n        varying vec4 vColor;\n        void main(void) {\n          gl_FragColor = vColor;\n        }\n      ');
ctx.compileShader(shader2);
let shaderParam2 =  ctx.getShaderParameter(shader2, 35713);
let program = ctx.createProgram();
ctx.attachShader(program, shader);
ctx.attachShader(program, shader2);
ctx.linkProgram(program);
let programParam1 = ctx.getProgramParameter(program, 35714);
let buffer1 = ctx.createBuffer();
ctx.bindBuffer(34962, buffer1);
let Float32Array1 = new Float32Array(6);
ctx.bufferData(34962, Float32Array1, 35044);
let buffer2 = ctx.createBuffer();
ctx.bindBuffer(34962, buffer2);
let Float32Array2 = new Float32Array(12);
ctx.bufferData(34962, Float32Array2, 35044);
let attribLocationAPosition = ctx.getAttribLocation(program, 'aPosition');
let attribLocationAColor = ctx.getAttribLocation(program, 'aColor');
ctx.bindBuffer(34962, buffer1);
ctx.vertexAttribPointer(0, 2, 5126, false, 0, 0);
ctx.enableVertexAttribArray(0);
ctx.bindBuffer(34962, buffer2);
ctx.vertexAttribPointer(1, 4, 5126, false, 0, 0);
ctx.enableVertexAttribArray(1);
ctx.useProgram(program);
let webglUniformLocation = ctx.getUniformLocation(program, 'anOffset');
ctx.uniform4fv(webglUniformLocation, [0.2, 0, 0, 0])
ctx.drawArrays(5,0,3)
let unint8Array = new Uint8Array(90000);
ctx.readPixels(50, 0, 100, 128, 6408, 5121, unint8Array);
console.log(unint8Array+'')






