aboutsummaryrefslogtreecommitdiff
path: root/js/lib/rdge/materials/radial-gradient-material.js
diff options
context:
space:
mode:
authorJonathan Duran2012-03-14 08:59:17 -0700
committerJonathan Duran2012-03-14 08:59:17 -0700
commite065244ac75d1d0f25fd5c75cb58e714a13fe16b (patch)
tree6b49a85a45fdd41b81be5603fbbc2e0d197eb187 /js/lib/rdge/materials/radial-gradient-material.js
parente8f207dc50ad942ee8c1c1db6b146c0110ce3216 (diff)
downloadninja-e065244ac75d1d0f25fd5c75cb58e714a13fe16b.tar.gz
Squashed commit of the following:
merge master into timeline Signed-off-by: Jonathan Duran <jduran@motorola.com>
Diffstat (limited to 'js/lib/rdge/materials/radial-gradient-material.js')
-rwxr-xr-xjs/lib/rdge/materials/radial-gradient-material.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/js/lib/rdge/materials/radial-gradient-material.js b/js/lib/rdge/materials/radial-gradient-material.js
index 13be50f5..d19b44b7 100755
--- a/js/lib/rdge/materials/radial-gradient-material.js
+++ b/js/lib/rdge/materials/radial-gradient-material.js
@@ -193,14 +193,17 @@ var RadialGradientMaterial = function RadialGradientMaterial() {
193 return new RadialGradientMaterial(); 193 return new RadialGradientMaterial();
194 }; 194 };
195 195
196 this.init = function() { 196 this.init = function( world )
197 {
198 this.setWorld( world );
199
197 // set up the shader 200 // set up the shader
198 this._shader = new jshader(); 201 this._shader = new jshader();
199 this._shader.def = radialGradientMaterialDef; 202 this._shader.def = radialGradientMaterialDef;
200 this._shader.init(); 203 this._shader.init();
201 204
202 // set up the material node 205 // set up the material node
203 this._materialNode = createMaterialNode("radialGradientMaterial"); 206 this._materialNode = createMaterialNode("radialGradientMaterial" + "_" + world.generateUniqueNodeID());
204 this._materialNode.setShader(this._shader); 207 this._materialNode.setShader(this._shader);
205 208
206 // set the shader values in the shader 209 // set the shader values in the shader