aboutsummaryrefslogtreecommitdiff
path: root/js/document
diff options
context:
space:
mode:
Diffstat (limited to 'js/document')
-rwxr-xr-xjs/document/html-document.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/js/document/html-document.js b/js/document/html-document.js
index 2d7192b7..8722e223 100755
--- a/js/document/html-document.js
+++ b/js/document/html-document.js
@@ -220,9 +220,14 @@ exports.HTMLDocument = Montage.create(TextDocument, {
220 if (canvas.elementModel.shapeModel.GLWorld) 220 if (canvas.elementModel.shapeModel.GLWorld)
221 canvas.elementModel.shapeModel.GLWorld.clearTree(); 221 canvas.elementModel.shapeModel.GLWorld.clearTree();
222 222
223 var world = new GLWorld( canvas ); 223 var index = importStr.indexOf( "webGL: " );
224 canvas.elementModel.shapeModel.GLWorld = world; 224 var useWebGL = (index >= 0)
225 var world = new GLWorld( canvas, useWebGL );
225 world.import( importStr ); 226 world.import( importStr );
227 canvas.elementModel.shapeModel.GLWorld = world;
228
229 ///////////////////////////
230 //something.buildShapeModel( world ); // to come from Nivesh
226 } 231 }
227 } 232 }
228 } 233 }