4 Clear the canvas to green to test that we get pixels to the screen.
6 If this fails, something is seriously wrong.
11 <script type='text/javascript' src='webgl-utils.js'
></script>
12 <script type='text/javascript'
>
15 function setStatus(text
) {
16 var elem
= document
.getElementById('status');
17 elem
.innerHTML
= text
;
21 var canvas
= document
.getElementById('canvas');
23 var gl
= initGL(canvas
);
25 setStatus('WebGL context creation failed.');
29 gl
.clearColor(0.0, 1.0, 0.0, 1.0);
30 gl
.clear(gl
.COLOR_BUFFER_BIT
);
35 <body onload='runTest();'
>
36 <canvas id='canvas' width='
256' height='
256'
></canvas>
37 <div id='status'
></div>