aboutsummaryrefslogtreecommitdiff
path: root/js/helper-classes/RDGE/Materials/LinearGradientMaterial.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/helper-classes/RDGE/Materials/LinearGradientMaterial.js')
-rw-r--r--js/helper-classes/RDGE/Materials/LinearGradientMaterial.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/js/helper-classes/RDGE/Materials/LinearGradientMaterial.js b/js/helper-classes/RDGE/Materials/LinearGradientMaterial.js
index 357ce275..8b23d77e 100644
--- a/js/helper-classes/RDGE/Materials/LinearGradientMaterial.js
+++ b/js/helper-classes/RDGE/Materials/LinearGradientMaterial.js
@@ -98,6 +98,8 @@ function LinearGradientMaterial()
98 this._shader.default.u_cos_sin_angle.set([Math.cos(a), Math.sin(a)]); 98 this._shader.default.u_cos_sin_angle.set([Math.cos(a), Math.sin(a)]);
99 } 99 }
100 100
101 this.isAnimated = function() { return false; }
102
101 /////////////////////////////////////////////////////////////////////// 103 ///////////////////////////////////////////////////////////////////////
102 // Material Property Accessors 104 // Material Property Accessors
103 /////////////////////////////////////////////////////////////////////// 105 ///////////////////////////////////////////////////////////////////////
@@ -133,8 +135,10 @@ function LinearGradientMaterial()
133 // duplcate method requirde 135 // duplcate method requirde
134 this.dup = function() { return new LinearGradientMaterial(); } 136 this.dup = function() { return new LinearGradientMaterial(); }
135 137
136 this.init = function() 138 this.init = function( world )
137 { 139 {
140 this.setWorld( world );
141
138 // set up the shader 142 // set up the shader
139 this._shader = new jshader(); 143 this._shader = new jshader();
140 this._shader.def = linearGradientMaterialDef; 144 this._shader.def = linearGradientMaterialDef;
@@ -146,6 +150,8 @@ function LinearGradientMaterial()
146 150
147 // send the current values to the shader 151 // send the current values to the shader
148 this.updateShaderValues(); 152 this.updateShaderValues();
153
154 console.log( "**** LinearGradientMaterial initialized" );
149 } 155 }
150 156
151 this.updateShaderValues= function() 157 this.updateShaderValues= function()