aboutsummaryrefslogtreecommitdiff
path: root/js/models/materials-model.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/models/materials-model.js')
-rwxr-xr-xjs/models/materials-model.js14
1 files changed, 7 insertions, 7 deletions
diff --git a/js/models/materials-model.js b/js/models/materials-model.js
index 1fd52721..b8500234 100755
--- a/js/models/materials-model.js
+++ b/js/models/materials-model.js
@@ -110,7 +110,7 @@ exports.MaterialsModel = Montage.create(Component, {
110 return this._materials; 110 return this._materials;
111 } 111 }
112 }, 112 },
113 113
114 addMaterial: { 114 addMaterial: {
115 value: function (material) { 115 value: function (material) {
116 this._materials.push(material); 116 this._materials.push(material);
@@ -152,8 +152,8 @@ exports.MaterialsModel = Montage.create(Component, {
152 } 152 }
153 } 153 }
154 }, 154 },
155 155
156 getMaterialByShader: 156 getMaterialByShader:
157 { 157 {
158 value: function( shaderName ) 158 value: function( shaderName )
159 { 159 {
@@ -161,7 +161,7 @@ exports.MaterialsModel = Montage.create(Component, {
161 if (index >= 0) 161 if (index >= 0)
162 return this._materials[index]; 162 return this._materials[index];
163 } 163 }
164 }, 164 },
165 165
166 getIndexOfMaterialByShader: { 166 getIndexOfMaterialByShader: {
167 value: function (shaderName) { 167 value: function (shaderName) {
@@ -220,13 +220,13 @@ exports.MaterialsModel = Montage.create(Component, {
220 matArray.push( matObj ); 220 matArray.push( matObj );
221 } 221 }
222 222
223 var jObj = 223 var jObj =
224 { 224 {
225 'materialLibrary': 1.0, 225 'materialLibrary': 1.0,
226 'materials': matArray 226 'materials': matArray
227 }; 227 };
228 228
229 // prepend an identifiable string to aid parsing when the 229 // prepend an identifiable string to aid parsing when the
230 // material model is loaded. 230 // material model is loaded.
231 var jStr = "materialLibrary;" + JSON.stringify( jObj ); 231 var jStr = "materialLibrary;" + JSON.stringify( jObj );
232 232
@@ -285,7 +285,7 @@ exports.MaterialsModel = Montage.create(Component, {
285 // make sure we have some materials to import before doing anything 285 // make sure we have some materials to import before doing anything
286 var matArray = jObj.materials; 286 var matArray = jObj.materials;
287 if (!matArray) return; 287 if (!matArray) return;
288 288
289 // we replace allmaterials, so remove anything 289 // we replace allmaterials, so remove anything
290 // that is currently there. 290 // that is currently there.
291 this.clearAllMaterials(); 291 this.clearAllMaterials();