import { vertex2d } from "https://deno.land/x/caviar@2.4.1/src/renderers/webgl/shader.ts";
type
`
attribute vec2 aVertexPosition;
attribute vec2 aTextureCoord;
uniform float uShaderUsage;
uniform vec4 uVertexColor;
uniform vec2 uTransformMatrix;
varying lowp float vShaderUsage;
varying lowp vec4 vColor;
varying highp vec2 vTextureCoord;
void main(void) {
gl_Position = vec4(aVertexPosition + uTransformMatrix, 1, 1);
if (uShaderUsage == 0.0) {
vColor = uVertexColor;
} else {
vTextureCoord = aTextureCoord;
}
vShaderUsage = uShaderUsage;
}
`