Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Webgl2

Name: Anonymous 2017-06-30 4:58

It looks a bit clunky, but i guess that's par for running code on the gpu

Anyone here tamed this beast?

Name: Anonymous 2017-07-04 4:43

<script>

var canvas;

var gl = null;

canvas = document.getElementById('glCanvas');

gl = canvas.getContext('webgl2');

if(gl) alert(gl.getParameter(gl.VERSION));

if(gl) doGL();

alert("Fin");


function doGL(){

gl.clearColor(0.0, 0.0, 0.0, 1.0);
// Enable depth testing
gl.enable(gl.DEPTH_TEST);
// Near things obscure far things
gl.depthFunc(gl.LEQUAL);
// Clear the color as well as the depth buffer.
gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);

}
</script>

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List