diff options
author | hwc487 | 2012-03-06 12:37:17 -0800 |
---|---|---|
committer | hwc487 | 2012-03-06 12:37:17 -0800 |
commit | e87069b43027b6b1707bb065a1f331b600b5db58 (patch) | |
tree | a897c648029016e2066292255fcb1da2f7e045bb /js/document | |
parent | 5e640e24c3b4658b8060cde837ae98dabd3ba5bf (diff) | |
download | ninja-e87069b43027b6b1707bb065a1f331b600b5db58.tar.gz |
Authortime import of 2d & 3d canvases
Diffstat (limited to 'js/document')
-rwxr-xr-x | js/document/html-document.js | 9 |
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 | } |