aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--assets/shaders/plasma.frag.glsl4
-rwxr-xr-xjs/document/html-document.js137
-rwxr-xr-xjs/helper-classes/3D/math-utils.js5
-rw-r--r--js/helper-classes/RDGE/runtime/GLRuntime.js159
-rwxr-xr-xjs/helper-classes/backup-delete/GLCircle.js3
-rwxr-xr-xjs/helper-classes/backup-delete/GLGeomObj.js46
-rwxr-xr-xjs/helper-classes/backup-delete/GLRectangle.js2
-rwxr-xr-xjs/helper-classes/backup-delete/GLWorld.js71
-rwxr-xr-xjs/helper-classes/backup-delete/Materials/BumpMetalMaterial.js39
-rw-r--r--js/helper-classes/backup-delete/Materials/DeformMaterial.js2
-rwxr-xr-xjs/helper-classes/backup-delete/Materials/FlatMaterial.js34
-rw-r--r--js/helper-classes/backup-delete/Materials/FlyMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/JuliaMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/KeleidoscopeMaterial.js2
-rwxr-xr-xjs/helper-classes/backup-delete/Materials/LinearGradientMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/MandelMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/PlasmaMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/PulseMaterial.js5
-rw-r--r--js/helper-classes/backup-delete/Materials/RadialBlurMaterial.js2
-rwxr-xr-xjs/helper-classes/backup-delete/Materials/RadialGradientMaterial.js6
-rw-r--r--js/helper-classes/backup-delete/Materials/ReliefTunnelMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/SquareTunnelMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/StarMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/TaperMaterial.js4
-rw-r--r--js/helper-classes/backup-delete/Materials/TunnelMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/TwistMaterial.js2
-rw-r--r--js/helper-classes/backup-delete/Materials/TwistVertMaterial.js2
-rwxr-xr-xjs/helper-classes/backup-delete/Materials/UberMaterial.js73
-rw-r--r--js/helper-classes/backup-delete/Materials/WaterMaterial.js4
-rw-r--r--js/helper-classes/backup-delete/Materials/ZInvertMaterial.js2
-rwxr-xr-xjs/lib/NJUtils.js34
-rwxr-xr-xjs/lib/drawing/world.js90
-rwxr-xr-xjs/lib/geom/circle.js3
-rwxr-xr-xjs/lib/geom/geom-obj.js47
-rwxr-xr-xjs/lib/geom/rectangle.js4
-rwxr-xr-xjs/lib/rdge/materials/bump-metal-material.js4
-rw-r--r--js/lib/rdge/materials/deform-material.js2
-rwxr-xr-xjs/lib/rdge/materials/flat-material.js41
-rw-r--r--js/lib/rdge/materials/fly-material.js2
-rw-r--r--js/lib/rdge/materials/julia-material.js2
-rw-r--r--js/lib/rdge/materials/keleidoscope-material.js2
-rwxr-xr-xjs/lib/rdge/materials/linear-gradient-material.js2
-rw-r--r--js/lib/rdge/materials/mandel-material.js2
-rw-r--r--js/lib/rdge/materials/plasma-material.js37
-rw-r--r--js/lib/rdge/materials/pulse-material.js7
-rw-r--r--js/lib/rdge/materials/radial-blur-material.js5
-rwxr-xr-xjs/lib/rdge/materials/radial-gradient-material.js7
-rw-r--r--js/lib/rdge/materials/relief-tunnel-material.js2
-rw-r--r--js/lib/rdge/materials/square-tunnel-material.js2
-rw-r--r--js/lib/rdge/materials/star-material.js2
-rw-r--r--js/lib/rdge/materials/taper-material.js6
-rw-r--r--js/lib/rdge/materials/tunnel-material.js2
-rw-r--r--js/lib/rdge/materials/twist-material.js2
-rw-r--r--js/lib/rdge/materials/twist-vert-material.js6
-rwxr-xr-xjs/lib/rdge/materials/uber-material.js71
-rw-r--r--js/lib/rdge/materials/water-material.js2
-rw-r--r--js/lib/rdge/materials/z-invert-material.js2
-rw-r--r--js/lib/rdge/runtime/CanvasDataManager.js (renamed from js/helper-classes/RDGE/runtime/CanvasDataManager.js)43
-rw-r--r--js/lib/rdge/runtime/GLRuntime.js357
-rw-r--r--js/lib/rdge/runtime/RuntimeGeomObj.js633
-rw-r--r--js/lib/rdge/runtime/RuntimeMaterial.js351
-rw-r--r--js/panels/Timeline/Collapser.js26
-rw-r--r--js/panels/Timeline/Layer.reel/Layer.js138
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/TimelinePanel.html19
-rw-r--r--js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js124
-rw-r--r--js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js116
-rw-r--r--js/panels/Timeline/Tween.reel/Tween.js10
-rwxr-xr-xjs/preloader/Preloader.js2
68 files changed, 2317 insertions, 512 deletions
diff --git a/assets/shaders/plasma.frag.glsl b/assets/shaders/plasma.frag.glsl
index 2ab8f49c..248288a6 100644
--- a/assets/shaders/plasma.frag.glsl
+++ b/assets/shaders/plasma.frag.glsl
@@ -22,11 +22,9 @@ void main(void)
22{ 22{
23 float x = v_uv.x ; 23 float x = v_uv.x ;
24 float y = v_uv.y ; 24 float y = v_uv.y ;
25 float time = color.x; 25 float time = u_time;
26 float wave = (cos(time + y / 0.2 + cos(x / 0.3 + cos((y / 0.1))))); 26 float wave = (cos(time + y / 0.2 + cos(x / 0.3 + cos((y / 0.1)))));
27 float wave1 = (sin(abs(wave + y/0.6))); 27 float wave1 = (sin(abs(wave + y/0.6)));
28 float wave2 = (sin(abs(wave1 + y/0.8))); 28 float wave2 = (sin(abs(wave1 + y/0.8)));
29 float tmp = u_time * 0.1;
30 gl_FragColor = vec4( abs(vec3(wave2,wave1,wave)),1.0); 29 gl_FragColor = vec4( abs(vec3(wave2,wave1,wave)),1.0);
31 //gl_FragColor = color;
32} 30}
diff --git a/js/document/html-document.js b/js/document/html-document.js
index b9b68972..05c7d6c0 100755
--- a/js/document/html-document.js
+++ b/js/document/html-document.js
@@ -8,7 +8,9 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot
8// 8//
9var Montage = require("montage/core/core").Montage, 9var Montage = require("montage/core/core").Montage,
10 TextDocument = require("js/document/text-document").TextDocument, 10 TextDocument = require("js/document/text-document").TextDocument,
11 NJUtils = require("js/lib/NJUtils").NJUtils; 11 NJUtils = require("js/lib/NJUtils").NJUtils,
12 CanvasDataManager = require("js/lib/rdge/runtime/CanvasDataManager").CanvasDataManager,
13 GLWorld = require("js/lib/drawing/world").World;
12//////////////////////////////////////////////////////////////////////// 14////////////////////////////////////////////////////////////////////////
13// 15//
14exports.HTMLDocument = Montage.create(TextDocument, { 16exports.HTMLDocument = Montage.create(TextDocument, {
@@ -206,13 +208,113 @@ exports.HTMLDocument = Montage.create(TextDocument, {
206 var elt = this.documentRoot; 208 var elt = this.documentRoot;
207 if (elt) 209 if (elt)
208 { 210 {
209 console.log( "load canvas data: " , value ); 211// FOR JOSE: The following commented out lines are what the runtime
210 var cdm = new CanvasDataManager(); 212// version should execute.
211 cdm.loadGLData(elt, value); 213// var loadForRuntime = true;
214// if (loadForRuntime)
215// {
216// var cdm = new CanvasDataManager();
217// cdm.loadGLData(elt, value );
218// }
219// else
220 {
221 var nWorlds= value.length;
222 for (var i=0; i<nWorlds; i++)
223 {
224 var importStr = value[i];
225 var startIndex = importStr.indexOf( "id: " );
226 if (startIndex >= 0)
227 {
228 var endIndex = importStr.indexOf( "\n", startIndex );
229 if (endIndex > 0)
230 {
231 var id = importStr.substring( startIndex+4, endIndex );
232 if (id)
233 {
234 var canvas = this.findCanvasWithID( id, elt );
235 if (canvas)
236 {
237 if (!canvas.elementModel)
238 {
239 NJUtils.makeElementModel(canvas, "Canvas", "shape", true);
240 }
241
242 if (canvas.elementModel)
243 {
244 if (canvas.elementModel.shapeModel.GLWorld)
245 canvas.elementModel.shapeModel.GLWorld.clearTree();
246
247 var index = importStr.indexOf( "webGL: " );
248 var useWebGL = (index >= 0)
249 var world = new GLWorld( canvas, useWebGL );
250 world.import( importStr );
251
252 this.buildShapeModel( canvas.elementModel, world );
253 }
254 }
255 }
256 }
257 }
258 }
259 }
212 } 260 }
213 } 261 }
214 },