aboutsummaryrefslogtreecommitdiff
path: root/js/lib/geom/geom-obj.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/lib/geom/geom-obj.js')
-rwxr-xr-xjs/lib/geom/geom-obj.js11
1 files changed, 10 insertions, 1 deletions
diff --git a/js/lib/geom/geom-obj.js b/js/lib/geom/geom-obj.js
index 4cb21a25..6b73463f 100755
--- a/js/lib/geom/geom-obj.js
+++ b/js/lib/geom/geom-obj.js
@@ -180,7 +180,7 @@ exports.GeomObj = Object.create(Object.prototype, {
180 /////////////////////////////////////////////////////////////////////// 180 ///////////////////////////////////////////////////////////////////////
181 // Methods 181 // Methods
182 /////////////////////////////////////////////////////////////////////// 182 ///////////////////////////////////////////////////////////////////////
183 setMaterialColor: { 183 setMaterialColor: {
184 value: function(c, type) { 184 value: function(c, type) {
185 var i = 0, 185 var i = 0,
186 nMats = 0; 186 nMats = 0;
@@ -285,6 +285,8 @@ exports.GeomObj = Object.create(Object.prototype, {
285 this.setStrokeColor(this._strokeColor); 285 this.setStrokeColor(this._strokeColor);
286 } 286 }
287 287
288 this._strokeMaterial = strokeMaterial;
289
288 return strokeMaterial; 290 return strokeMaterial;
289 } 291 }
290 }, 292 },
@@ -309,12 +311,16 @@ exports.GeomObj = Object.create(Object.prototype, {
309 this.setFillColor(this._fillColor); 311 this.setFillColor(this._fillColor);
310 } 312 }
311 313
314 this._fillMaterial = fillMaterial;
315
312 return fillMaterial; 316 return fillMaterial;
313 } 317 }
314 }, 318 },
315 319
316 exportMaterialsJSON: { 320 exportMaterialsJSON: {
317 value: function() { 321 value: function() {
322 MaterialsModel = require("js/models/materials-model").MaterialsModel;
323
318 var jObj; 324 var jObj;
319 if (this._materialArray && this._materialNodeArray && this.getWorld().isWebGL()) { 325 if (this._materialArray && this._materialNodeArray && this.getWorld().isWebGL()) {
320 var nMats = this._materialArray.length; 326 var nMats = this._materialArray.length;
@@ -345,6 +351,8 @@ exports.GeomObj = Object.create(Object.prototype, {
345 351
346 importMaterialsJSON: { 352 importMaterialsJSON: {
347 value: function(jObj) { 353 value: function(jObj) {
354 MaterialsModel = require("js/models/materials-model").MaterialsModel;
355
348 this._materialArray = []; 356 this._materialArray = [];
349 this._materialTypeArray = []; 357 this._materialTypeArray = [];
350 358
@@ -370,6 +378,7 @@ exports.GeomObj = Object.create(Object.prototype, {
370 case "tunnel": 378 case "tunnel":
371 case "reliefTunnel": 379 case "reliefTunnel":
372 case "squareTunnel": 380 case "squareTunnel":
381 case "flag":
373 case "twist": 382 case "twist":
374 case "fly": 383 case "fly":
375 case "julia": 384 case "julia":