Changeset 19728 for issm/trunk-jpl/src/m/plot/plot_unit.js
- Timestamp:
- 11/17/15 00:41:57 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/plot/plot_unit.js
r19727 r19728 1 function plot_unit(x,y,z,elements,data,is2d,isplanet,datatype,options) {1 function plot_unit(x,y,z,elements,data,is2d,isplanet,datatype,options) { 2 2 //PLOT_UNIT - unit plot, display data 3 3 // … … 13 13 var canvas=document.getElementById(options.getfieldvalue('canvasid')); 14 14 15 // Initialize the GL context:15 // Initialize the GL context: 16 16 var gl=initWebGL(canvas); 17 17 … … 19 19 20 20 if (gl) { 21 // Set clear color to black, fully opaque 22 gl.clearColor(0.0, 0.0, 0.0, 1.0); 23 // Enable depth testing 24 gl.enable(gl.DEPTH_TEST); 25 // Near things obscure far things 26 gl.depthFunc(gl.LEQUAL); 27 // Clear the color as well as the depth buffer. 28 gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT); 21 loadShaders(gl); 22 var node=loadModel(gl,x,y,z,elements,data); 23 drawSceneGraphNode(gl,node); 29 24 } 30 25
Note:
See TracChangeset
for help on using the changeset viewer.