├── .gitignore
├── LICENSE
├── README.md
├── about.html
├── build
├── glam-nodeps.js
├── glam-nodeps.min.js
├── glam.js
└── glam.min.js
├── css
├── fonts.css
└── project-pages.css
├── demos
├── bubblepop.html
├── glamcity.html
├── glamcubeanimated.html
└── glamsceneanimatedeffects.html
├── docs
├── css
│ └── fonts.css
├── fonts
│ └── PT_Sans
│ │ └── v5
│ │ ├── 0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff
│ │ ├── 7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff
│ │ ├── PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff
│ │ └── lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff
├── glamcopy.html
├── images
│ ├── bubblepopcb.png
│ ├── figure-coordinatesystem.png
│ └── figure-perspectiveprojection.png
├── index.html
├── list.js
├── manual
│ ├── concepts.html
│ ├── introduction.html
│ └── tutorials
│ │ └── adding-cardboardvr.html
├── page.css
├── page.js
├── prettify
│ ├── prettify.css
│ ├── prettify.js
│ ├── readme.txt
│ └── threejs.css
└── reference
│ ├── cssreference.html
│ ├── elementsreference.html
│ └── eventsreference.html
├── examples
├── 2d
│ └── glam2Dgeometry.html
├── animation
│ ├── glamcubeanimated.html
│ ├── glamcubeanimatedtags.html
│ ├── glamsceneanimated.html
│ └── glamsceneanimatedtags.html
├── backgrounds
│ ├── glamskybox.html
│ └── glamskysphere.html
├── basic
│ ├── glamcube.html
│ └── glamcubestyle.html
├── effects
│ ├── glamcityeffects.html
│ ├── glamcubeeffects.html
│ └── glamsceneanimatedeffects.html
├── hierarchy
│ ├── glamscene.html
│ └── glamsceneanimated.html
├── imports
│ └── glamimport.html
├── interaction
│ └── glamcubeinteractive.html
├── materials
│ ├── glambumpmap.html
│ ├── glamearth.html
│ ├── glamenvmap.html
│ ├── glammultitexture.html
│ └── glamspecularmap.html
├── shaders
│ ├── glamshaderfresnel.html
│ ├── glamshadertoon.html
│ └── glamsun.html
├── visuals
│ ├── glamlines.html
│ ├── glammesh.html
│ ├── glamparticles.html
│ └── glamtext.html
└── vr
│ ├── bubblepopcb.html
│ ├── bubblepopcbtest.html
│ ├── glamcityvr.html
│ ├── glamshaderfresnelvr.html
│ └── glamskyspherevr.html
├── fonts
├── LICENSE
├── PT_Sans
│ └── v5
│ │ ├── 0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff
│ │ ├── 7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff
│ │ ├── PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff
│ │ └── lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff
├── droid
│ ├── NOTICE
│ ├── README.txt
│ ├── droid_sans_bold.typeface.js
│ ├── droid_sans_mono_regular.typeface.js
│ ├── droid_sans_regular.typeface.js
│ ├── droid_serif_bold.typeface.js
│ └── droid_serif_regular.typeface.js
├── gentilis_bold.typeface.js
├── gentilis_regular.typeface.js
├── helvetiker_bold.typeface.js
├── helvetiker_regular.typeface.js
├── optimer_bold.typeface.js
└── optimer_regular.typeface.js
├── images
├── Park2
│ ├── negx.jpg
│ ├── negy.jpg
│ ├── negz.jpg
│ ├── posx.jpg
│ ├── posy.jpg
│ ├── posz.jpg
│ └── readme.txt
├── Park2_1024
│ ├── negx.jpg
│ ├── negx.png
│ ├── negy.jpg
│ ├── negy.png
│ ├── negz.jpg
│ ├── negz.png
│ ├── posx.jpg
│ ├── posx.png
│ ├── posy.jpg
│ ├── posy.png
│ ├── posz.jpg
│ ├── posz.png
│ └── readme.txt
├── Star02.png
├── ash_uvgrid01-bw.jpg
├── ash_uvgrid01.jpg
├── bkg.png
├── blacktocat.png
├── bowieorangeglam.png
├── bubbles.png
├── cloud.png
├── earth_atmos_2048.jpg
├── earth_normal_2048.jpg
├── envmap
│ ├── 2-NEGATIVE_X.jpg
│ ├── 2-NEGATIVE_Y.jpg
│ ├── 2-NEGATIVE_Z.jpg
│ ├── 2-POSITIVE_X.jpg
│ ├── 2-POSITIVE_Y.jpg
│ └── 2-POSITIVE_Z.jpg
├── firefly.png
├── flowers.jpg
├── lavatile.jpg
├── moon_1024.jpg
├── parisi1.jpg
├── sky35
│ ├── backcity.jpg
│ ├── backcity.png
│ ├── botcity.jpg
│ ├── botcity.png
│ ├── citysky.rwx
│ ├── frontcity.jpg
│ ├── frontcity.png
│ ├── leftcity.jpg
│ ├── leftcity.png
│ ├── rightcity.jpg
│ ├── rightcity.png
│ ├── topcity.jpg
│ └── topcity.png
├── slidebg.png
├── smokeparticle.png
├── snowflake.png
├── spherepano
│ ├── Panorama-wx8jmd.jpg
│ ├── Panorama-wx8jmd.png
│ ├── belmorepark1right.jpg
│ ├── belmorepark1right.png
│ ├── car.jpg
│ ├── car.png
│ ├── car2.jpg
│ ├── car2.png
│ ├── car3.jpg
│ ├── car3.png
│ ├── mellon_square.jpg
│ ├── mellon_square.png
│ ├── pan0.jpg
│ ├── pan0.png
│ ├── pan1.jpg
│ ├── pan1.png
│ ├── pan2.jpg
│ ├── pan2.png
│ ├── pan3.jpg
│ ├── pan3.png
│ ├── pan4.jpg
│ ├── pan4.png
│ ├── pan5.jpg
│ ├── pan5.png
│ ├── pan6.jpg
│ ├── pan6.png
│ ├── pan7.jpg
│ ├── pan7.png
│ ├── pan8.jpg
│ ├── pan8.png
│ ├── pan9.jpg
│ ├── pan9.png
│ ├── room.jpg
│ ├── room.png
│ ├── room2.jpg
│ ├── room2.png
│ ├── room3.jpg
│ ├── room3.png
│ ├── room4.jpg
│ ├── room4.png
│ ├── room5.jpg
│ └── room5.png
└── stockvault-sun-flowers114982.jpg
├── img
├── bg.jpg
├── demo
│ ├── bubblepop.jpg
│ ├── bubblepopcb.png
│ ├── glam2Dgeometry.jpg
│ ├── glambumpmap.jpg
│ ├── glamcity.jpg
│ ├── glamcityvr.jpg
│ ├── glamcube.jpg
│ ├── glamcubeanimated.jpg
│ ├── glamcubebowie.jpg
│ ├── glamcubeeffects.jpg
│ ├── glamcubeinteractive.jpg
│ ├── glamearth.jpg
│ ├── glamlights.jpg
│ ├── glamlines.jpg
│ ├── glammesh.jpg
│ ├── glamparticles.jpg
│ ├── glamscene.jpg
│ ├── glamsceneanimated.jpg
│ ├── glamsceneanimatedeffects.jpg
│ ├── glamscenecss.jpg
│ ├── glamshaderfresnel.jpg
│ ├── glamshaderfresnelvr.jpg
│ ├── glamshadertoon.jpg
│ ├── glamskybox.jpg
│ ├── glamskysphere.jpg
│ ├── glamskyspherevr.jpg
│ ├── glamsolarsystem.jpg
│ ├── glamspecularmap.jpg
│ ├── glamsun.jpg
│ ├── glamtext.jpg
│ └── threejscubelit.jpg
├── fundedwithkickstarter.png
├── pattern1.svg
├── pattern2.svg
├── pattern3.svg
├── pattern4.svg
├── pattern5.svg
└── pattern6.svg
├── index.html
├── javascripts
└── main.js
├── libs
├── requestAnimationFrame
│ └── RequestAnimationFrame.js
├── three.js.r68
│ ├── ParticleEngine
│ │ ├── Pool.js
│ │ ├── ShaderParticleEmitter.js
│ │ ├── ShaderParticleGroup.js
│ │ └── ShaderParticles.min.js
│ ├── controls
│ │ └── VRControls.js
│ ├── loaders
│ │ ├── ColladaLoader.js
│ │ └── gltf
│ │ │ ├── glTF-parser.js
│ │ │ ├── glTFAnimation.js
│ │ │ ├── glTFLoader.js
│ │ │ └── glTFLoaderUtils.js
│ ├── postprocessing
│ │ ├── BloomPass.js
│ │ ├── BokehPass.js
│ │ ├── DotScreenPass.js
│ │ ├── EffectComposer.js
│ │ ├── FilmPass.js
│ │ ├── GlitchPass.js
│ │ ├── MaskPass.js
│ │ ├── RenderPass.js
│ │ ├── SavePass.js
│ │ ├── ShaderPass.js
│ │ └── TexturePass.js
│ ├── renderers
│ │ ├── StereoEffect.js
│ │ └── VREffect.js
│ ├── shaders
│ │ ├── BasicShader.js
│ │ ├── BleachBypassShader.js
│ │ ├── BlendShader.js
│ │ ├── BokehShader.js
│ │ ├── BokehShader2.js
│ │ ├── BrightnessContrastShader.js
│ │ ├── ColorCorrectionShader.js
│ │ ├── ColorifyShader.js
│ │ ├── ConvolutionShader.js
│ │ ├── CopyShader.js
│ │ ├── DOFMipMapShader.js
│ │ ├── DigitalGlitch.js
│ │ ├── DotScreenRGBShader.js
│ │ ├── DotScreenShader.js
│ │ ├── EdgeShader.js
│ │ ├── EdgeShader2.js
│ │ ├── FXAAShader.js
│ │ ├── FilmShader.js
│ │ ├── FocusShader.js
│ │ ├── FresnelShader.js
│ │ ├── HorizontalBlurShader.js
│ │ ├── HorizontalTiltShiftShader.js
│ │ ├── HueSaturationShader.js
│ │ ├── KaleidoShader.js
│ │ ├── LuminosityShader.js
│ │ ├── MirrorShader.js
│ │ ├── NormalMapShader.js
│ │ ├── OceanShaders.js
│ │ ├── RGBShiftShader.js
│ │ ├── SSAOShader.js
│ │ ├── SepiaShader.js
│ │ ├── TechnicolorShader.js
│ │ ├── TriangleBlurShader.js
│ │ ├── UnpackDepthRGBAShader.js
│ │ ├── VerticalBlurShader.js
│ │ ├── VerticalTiltShiftShader.js
│ │ └── VignetteShader.js
│ ├── stats.min.js
│ ├── three.js
│ └── three.min.js
└── tween.js
│ └── tween.min.js
├── models
└── futurgo_city
│ ├── futurgo_city.dae
│ └── images
│ ├── .mayaSwatches
│ ├── ACUnit_A.bmp.swatch
│ ├── Ad_Sqr11.bmp.swatch
│ ├── Apart_B.bmp.swatch
│ ├── Apart_C.bmp.swatch
│ ├── Apart_D.bmp.swatch
│ ├── Apart_E.bmp.swatch
│ ├── Apart_F.bmp.swatch
│ ├── BrickES4.bmp.swatch
│ ├── Brick_K4.bmp.swatch
│ ├── Brick_K6.bmp.swatch
│ ├── ConcWal1.bmp.swatch
│ ├── Conc_K3.bmp.swatch
│ ├── Corug_K1.bmp.swatch
│ ├── DoorDb_B.bmp.swatch
│ ├── Door_A.bmp.swatch
│ ├── Door_B.bmp.swatch
│ ├── GrasES_K.bmp.swatch
│ ├── MetalES1.bmp.swatch
│ ├── MetalES2.bmp.swatch
│ ├── MetalES4.bmp.swatch
│ ├── Pave_02.bmp.swatch
│ ├── Pave_05.bmp.swatch
│ ├── Pine_A.bmp.swatch
│ ├── Pine_A_png.png.swatch
│ ├── Pine_Aa.bmp.swatch
│ ├── Road_01.bmp.swatch
│ ├── Road_03.bmp.swatch
│ ├── Road_J04.bmp.swatch
│ ├── Road_J08.bmp.swatch
│ ├── Road_Z01.bmp.swatch
│ ├── Roof2.bmp.swatch
│ ├── Roof_F_A.bmp.swatch
│ ├── Roof_F_B.bmp.swatch
│ ├── Roof_F_C.bmp.swatch
│ ├── Roof_F_D.bmp.swatch
│ ├── SS_Lo_02.bmp.swatch
│ ├── SS_Lo_04.bmp.swatch
│ ├── SS_Lo_07.bmp.swatch
│ ├── SS_Lo_09.bmp.swatch
│ ├── SS_Lo_10.bmp.swatch
│ ├── SS_Lo_11.bmp.swatch
│ ├── SS_Lo_12.bmp.swatch
│ ├── SS_Lo_13.bmp.swatch
│ ├── Sign_VL2.bmp.swatch
│ ├── TREE_B.bmp.swatch
│ ├── TREE_B_png.png.swatch
│ ├── TREE_C.bmp.swatch
│ ├── TREE_C_png.png.swatch
│ ├── TREE_G.bmp.swatch
│ ├── TREE_G_png.png.swatch
│ ├── Tree_Ba.bmp.swatch
│ ├── Tree_Ca.bmp.swatch
│ ├── TrfcLitA.bmp.swatch
│ ├── Vent_K2.bmp.swatch
│ ├── WalRuinB.bmp.swatch
│ ├── WallRuf1.bmp.swatch
│ ├── WallRuf2.bmp.swatch
│ ├── Windx4_A.bmp.swatch
│ ├── Windx4_B.bmp.swatch
│ ├── Windx4_H.bmp.swatch
│ ├── Windx4_N.bmp.swatch
│ ├── Windx4_Q.bmp.swatch
│ ├── Windx4_R.bmp.swatch
│ └── WoodES-B.bmp.swatch
│ ├── ACUnit_A.bmp
│ ├── Ad_Sqr11.bmp
│ ├── Apart_A.bmp
│ ├── Apart_B.bmp
│ ├── Apart_C.bmp
│ ├── Apart_D.bmp
│ ├── Apart_E.bmp
│ ├── Apart_F.bmp
│ ├── BrickES4.bmp
│ ├── Brick_K4.bmp
│ ├── Brick_K6.bmp
│ ├── ConcWal1.bmp
│ ├── Conc_K3.bmp
│ ├── Corug_K1.bmp
│ ├── DoorDb_B.bmp
│ ├── Door_A.bmp
│ ├── Door_B.bmp
│ ├── GrasES_K.bmp
│ ├── MetalES1.bmp
│ ├── MetalES2.bmp
│ ├── MetalES4.bmp
│ ├── Pave_02.bmp
│ ├── Pave_05.bmp
│ ├── Pine_A_png.png
│ ├── Road_01.bmp
│ ├── Road_03.bmp
│ ├── Road_J04.bmp
│ ├── Road_J08.bmp
│ ├── Road_Z01.bmp
│ ├── Roof2.bmp
│ ├── Roof_F_A.bmp
│ ├── Roof_F_B.bmp
│ ├── Roof_F_C.bmp
│ ├── Roof_F_D.bmp
│ ├── SS_Lo_02.bmp
│ ├── SS_Lo_04.bmp
│ ├── SS_Lo_07.bmp
│ ├── SS_Lo_09.bmp
│ ├── SS_Lo_10.bmp
│ ├── SS_Lo_11.bmp
│ ├── SS_Lo_12.bmp
│ ├── SS_Lo_13.bmp
│ ├── Sign_VL2.bmp
│ ├── TREE_B_png.png
│ ├── TREE_C_png.png
│ ├── TREE_G_png.png
│ ├── TrfcLitA.bmp
│ ├── Vent_K2.bmp
│ ├── WalRuinB.bmp
│ ├── WallRuf1.bmp
│ ├── WallRuf2.bmp
│ ├── Windx4_A.bmp
│ ├── Windx4_B.bmp
│ ├── Windx4_H.bmp
│ ├── Windx4_N.bmp
│ ├── Windx4_Q.bmp
│ ├── Windx4_R.bmp
│ └── WoodES-B.bmp
├── params.json
├── server
├── shaders
├── colorify.fs
├── colorify.vs
├── fresnel.fs
├── fresnel.vs
├── mirror.fs
├── mirror.vs
├── sun.fs
├── sun.vs
├── toon1.fs
└── toon1.vs
├── sounds
├── 235264__godowan__bubble1.wav
└── 235264__godowan__bubble1_trimmed.wav
├── src
├── animations
│ ├── animationService.js
│ ├── interpolator.js
│ ├── keyFrameAnimator.js
│ ├── transition.js
│ └── tweenService.js
├── behaviors
│ ├── behavior.js
│ ├── bounceBehavior.js
│ ├── fadeBehavior.js
│ ├── highlightBehavior.js
│ ├── moveBehavior.js
│ ├── rotateBehavior.js
│ └── scaleBehavior.js
├── cameras
│ ├── camera.js
│ ├── cameraManager.js
│ └── perspectiveCamera.js
├── config
│ ├── modules.js
│ └── nodeps.js
├── controllers
│ ├── DeviceOrientationControls-cb.js
│ ├── DeviceOrientationControls.js
│ ├── deviceOrientationController.js
│ ├── firstPersonController.js
│ ├── firstPersonControls.js
│ ├── modelController.js
│ ├── oculusRiftControls.js
│ ├── orbitControls.js
│ ├── pointerLockController.js
│ ├── pointerLockControls.js
│ └── riftController.js
├── core
│ ├── application.js
│ ├── component.js
│ ├── glam.js
│ ├── object.js
│ ├── service.js
│ └── services.js
├── dom
│ ├── CSSParser.js
│ ├── animation.js
│ ├── arc.js
│ ├── background.js
│ ├── box.js
│ ├── camera.js
│ ├── circle.js
│ ├── classList.js
│ ├── cone.js
│ ├── controller.js
│ ├── cylinder.js
│ ├── document.js
│ ├── dom.js
│ ├── effect.js
│ ├── group.js
│ ├── import.js
│ ├── input.js
│ ├── light.js
│ ├── line.js
│ ├── material.js
│ ├── mesh.js
│ ├── node.js
│ ├── parser.js
│ ├── particles.js
│ ├── rect.js
│ ├── renderer.js
│ ├── sphere.js
│ ├── style.js
│ ├── text.js
│ ├── transform.js
│ ├── transition.js
│ ├── types.js
│ ├── viewer.js
│ └── visual.js
├── events
│ ├── eventDispatcher.js
│ └── eventService.js
├── graphics
│ ├── graphics.js
│ └── graphicsThreeJS.js
├── helpers
│ └── helpers.js
├── input
│ ├── cylinderDragger.js
│ ├── gamepad.js
│ ├── input.js
│ ├── keyboard.js
│ ├── mouse.js
│ ├── pickManager.js
│ ├── picker.js
│ ├── planeDragger.js
│ ├── surfaceDragger.js
│ └── viewpicker.js
├── lights
│ ├── ambientLight.js
│ ├── directionalLight.js
│ ├── light.js
│ ├── pointLight.js
│ └── spotLight.js
├── loaders
│ └── loader.js
├── objects
│ ├── hud.js
│ ├── skybox.js
│ └── skysphere.js
├── particles
│ ├── particleEmitter.js
│ └── particleSystem.js
├── postprocessing
│ ├── composer.js
│ └── effect.js
├── prefabs
│ └── prefabs.js
├── scene
│ ├── decoration.js
│ ├── sceneComponent.js
│ ├── sceneUtils.js
│ ├── sceneVisual.js
│ ├── transform.js
│ └── visual.js
├── scripts
│ └── script.js
├── system
│ └── system.js
├── time
│ ├── time.js
│ └── timer.js
└── viewer
│ └── viewer.js
├── tests
└── glameventbubble.html
└── utils
├── compile-all.sh
├── compile-debug.sh
├── compile-min.sh
└── compiler.jar
/.gitignore:
--------------------------------------------------------------------------------
1 |
2 | .DS_Store
3 |
4 | .DS_Store
5 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | The MIT License
2 |
3 | Copyright (c) 2014 Tony Parisi and glam authors. All rights reserved.
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in
13 | all copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21 | THE SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | glam
2 | ====
3 |
4 | glam (**GL** **A** nd **M** arkup) is a declarative language for creating 3D web content.
5 |
6 |
7 | For background and motivation, documentation and other info, please visit the [GLAM Project Page](http://www.glamjs.org/)
8 |
9 |
--------------------------------------------------------------------------------
/about.html:
--------------------------------------------------------------------------------
1 |
2 |
About GLAM
3 |
4 | GLAM (GL And Markup) is a declarative language for 3D web content.
5 |
6 | GLAM combines the power of WebGL with a set of easy-to-use markup tags and style properties. With GLAM, 3D authoring is like any other web authoring. To make 3D, you create elements, set their attributes, add event listeners, and define styles. Just like DOM used to make! Content is easy to animate: keyframes and tweens can be defined in a compact set of markup tags, or as standard CSS3 animations or transitions. GLAM is also fully extensible: to add custom behavior, write JavaScript event handlers. If you want fancy shading written in GLSL, simply specify your vertex and fragment shaders as properties of the object's style. GLAM renders with WebGL, using Three.js, and adds behaviors, interaction and lots of easy-to-use features on top. But most importantly, GLAM defines a markup language and set of stylesheet extensions that make 3D programming a snap.
7 |
8 | GLAM was created by Tony Parisi, the guy who made the Virtual Reality Markup Language (VRML), 20 years before anybody knew they needed it. Since then, Tony's learned a few more things about graphics, web browsers have grown up, and the world has caught up with the vision. GLAM is still quite young. We're adding features and demos at a rapid clip, and we are also looking closely at related technologies such as Web Components as they come of age. We'd love your feedback and contributions!
9 |
--------------------------------------------------------------------------------
/css/fonts.css:
--------------------------------------------------------------------------------
1 | @CHARSET "UTF-8";
2 | @font-face {
3 | font-family: 'PT Sans';
4 | font-style: normal;
5 | font-weight: 400;
6 | src: local('PT Sans'), local('PTSans-Regular'), url(../fonts/PT_Sans/v5/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff) format('woff');
7 | }
8 | @font-face {
9 | font-family: 'PT Sans';
10 | font-style: normal;
11 | font-weight: 700;
12 | src: local('PT Sans Bold'), local('PTSans-Bold'), url(../fonts/PT_Sans/v5/0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff) format('woff');
13 | }
14 | @font-face {
15 | font-family: 'PT Sans';
16 | font-style: italic;
17 | font-weight: 400;
18 | src: local('PT Sans Italic'), local('PTSans-Italic'), url(../fonts/PT_Sans/v5/PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff) format('woff');
19 | }
20 | @font-face {
21 | font-family: 'PT Sans';
22 | font-style: italic;
23 | font-weight: 700;
24 | src: local('PT Sans Bold Italic'), local('PTSans-BoldItalic'), url(../fonts/PT_Sans/v5/lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff) format('woff');
25 | }
--------------------------------------------------------------------------------
/demos/glamcubeanimated.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - animated cube
7 |
8 |
37 |
38 |
39 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
--------------------------------------------------------------------------------
/docs/css/fonts.css:
--------------------------------------------------------------------------------
1 | @CHARSET "UTF-8";
2 | @font-face {
3 | font-family: 'PT Sans';
4 | font-style: normal;
5 | font-weight: 400;
6 | src: local('PT Sans'), local('PTSans-Regular'), url(../fonts/PT_Sans/v5/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff) format('woff');
7 | }
8 | @font-face {
9 | font-family: 'PT Sans';
10 | font-style: normal;
11 | font-weight: 700;
12 | src: local('PT Sans Bold'), local('PTSans-Bold'), url(../fonts/PT_Sans/v5/0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff) format('woff');
13 | }
14 | @font-face {
15 | font-family: 'PT Sans';
16 | font-style: italic;
17 | font-weight: 400;
18 | src: local('PT Sans Italic'), local('PTSans-Italic'), url(../fonts/PT_Sans/v5/PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff) format('woff');
19 | }
20 | @font-face {
21 | font-family: 'PT Sans';
22 | font-style: italic;
23 | font-weight: 700;
24 | src: local('PT Sans Bold Italic'), local('PTSans-BoldItalic'), url(../fonts/PT_Sans/v5/lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff) format('woff');
25 | }
--------------------------------------------------------------------------------
/docs/fonts/PT_Sans/v5/0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/fonts/PT_Sans/v5/0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff
--------------------------------------------------------------------------------
/docs/fonts/PT_Sans/v5/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/fonts/PT_Sans/v5/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff
--------------------------------------------------------------------------------
/docs/fonts/PT_Sans/v5/PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/fonts/PT_Sans/v5/PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff
--------------------------------------------------------------------------------
/docs/fonts/PT_Sans/v5/lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/fonts/PT_Sans/v5/lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff
--------------------------------------------------------------------------------
/docs/images/bubblepopcb.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/images/bubblepopcb.png
--------------------------------------------------------------------------------
/docs/images/figure-coordinatesystem.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/images/figure-coordinatesystem.png
--------------------------------------------------------------------------------
/docs/images/figure-perspectiveprojection.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/docs/images/figure-perspectiveprojection.png
--------------------------------------------------------------------------------
/docs/prettify/prettify.css:
--------------------------------------------------------------------------------
1 | .pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
--------------------------------------------------------------------------------
/docs/prettify/readme.txt:
--------------------------------------------------------------------------------
1 | Prettify syntax highlighter:
2 | http://code.google.com/p/google-code-prettify/
3 |
4 | Code license - Apache License 2.0
5 | http://www.apache.org/licenses/LICENSE-2.0
--------------------------------------------------------------------------------
/docs/prettify/threejs.css:
--------------------------------------------------------------------------------
1 | pre .str, code .str { color: #8000ff; } /* string */
2 | pre .kwd, code .kwd { color: #30b030; } /* keyword */
3 | pre .com, code .com { color: #999999; } /* comment */
4 | pre .typ, code .typ { color: #2194ce; } /* type */
5 | pre .lit, code .lit { color: #ff0080; } /* literal */
6 | pre .pun, code .pun { color: #888888; } /* punctuation */
7 | pre .pln, code .pln { color: #444444; } /* plaintext */
8 | pre .dec, code .dec { color: #22c0c4; } /* decimal */
9 |
10 |
11 |
12 | pre.prettyprint, code.prettyprint {
13 | background-color: #f9f9f9;
14 | font-family: 'inconsolata';
15 | }
16 |
--------------------------------------------------------------------------------
/docs/reference/eventsreference.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | Events Reference
12 |
13 |
14 | MouseEvent3D
15 |
16 | blah
17 |
18 |
19 |
20 | TouchEvent3D
21 | blah
22 |
23 |
24 |
25 | Touch3D
26 | blah
27 |
28 |
29 |
30 | ViewEvent3D
31 | blah
32 |
33 |
34 |
35 |
36 |
37 |
--------------------------------------------------------------------------------
/examples/2d/glam2Dgeometry.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - 2D shapes
7 |
8 |
42 |
43 |
44 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
--------------------------------------------------------------------------------
/examples/animation/glamcubeanimated.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - animated cube
7 |
8 |
37 |
38 |
39 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
--------------------------------------------------------------------------------
/examples/animation/glamcubeanimatedtags.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - animated cube
7 |
8 |
20 |
21 |
22 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
--------------------------------------------------------------------------------
/examples/backgrounds/glamskybox.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - Scene with skybox background and environment map
7 |
8 |
36 |
37 |
38 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
--------------------------------------------------------------------------------
/examples/basic/glamcube.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - eight line cube
7 |
8 |
21 |
22 |
23 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/examples/basic/glamcubestyle.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - eight line cube
7 |
8 |
15 |
16 |
17 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/examples/effects/glamcubeeffects.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - cube with effects
7 |
8 |
37 |
38 |
39 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
--------------------------------------------------------------------------------
/examples/hierarchy/glamscene.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - shapes, materials, groups and hierarchy
7 |
8 |
49 |
50 |
51 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
--------------------------------------------------------------------------------
/examples/materials/glambumpmap.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - bump mapping
7 |
8 |
39 |
40 |
41 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
--------------------------------------------------------------------------------
/examples/materials/glamearth.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - normal mapping
7 |
8 |
42 |
43 |
44 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/examples/materials/glamenvmap.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - bump mapping
7 |
8 |
45 |
46 |
47 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
--------------------------------------------------------------------------------
/examples/materials/glamspecularmap.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - specular mapping
7 |
8 |
41 |
42 |
43 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
--------------------------------------------------------------------------------
/examples/shaders/glamshadertoon.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - toon shading
7 |
8 |
40 |
41 |
42 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/examples/visuals/glamlines.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | glam - line tests
7 |
8 |
30 |
31 |
32 |
35 |
36 |
37 |
38 |
39 |
40 | -.5 -.5 0 .5 -.5 0 .5 .5 0 -.5 .5 0 -.5 -.5 0
41 | 1 0 0 0 1 0 0 1 1 0 0 1 1 0 0
42 |
43 |
44 |
45 |
46 | -.5 -.5 0 .5 -.5 0 .5 .5 0 -.5 .5 0 -.5 -.5 0
47 |
48 |
49 |
50 |
51 | -.5 -.5 0 .5 -.5 0 .5 .5 0 -.5 .5 0 -.5 -.5 0
52 |
53 |
54 |
55 |
56 | -.5 -.5 0 .5 -.5 0 .5 .5 0 -.5 .5 0 -.5 -.5 0
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/fonts/LICENSE:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/fonts/LICENSE
--------------------------------------------------------------------------------
/fonts/PT_Sans/v5/0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/fonts/PT_Sans/v5/0XxGQsSc1g4rdRdjJKZrNL3hpw3pgy2gAi-Ip7WPMi0.woff
--------------------------------------------------------------------------------
/fonts/PT_Sans/v5/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/fonts/PT_Sans/v5/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff
--------------------------------------------------------------------------------
/fonts/PT_Sans/v5/PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/fonts/PT_Sans/v5/PIPMHY90P7jtyjpXuZ2cLLO3LdcAZYWl9Si6vvxL-qU.woff
--------------------------------------------------------------------------------
/fonts/PT_Sans/v5/lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/fonts/PT_Sans/v5/lILlYDvubYemzYzN7GbLkKRDOzjiPcYnFooOUGCOsRk.woff
--------------------------------------------------------------------------------
/fonts/droid/README.txt:
--------------------------------------------------------------------------------
1 | Copyright (C) 2008 The Android Open Source Project
2 |
3 | Licensed under the Apache License, Version 2.0 (the "License");
4 | you may not use this file except in compliance with the License.
5 | You may obtain a copy of the License at
6 |
7 | http://www.apache.org/licenses/LICENSE-2.0
8 |
9 | Unless required by applicable law or agreed to in writing, software
10 | distributed under the License is distributed on an "AS IS" BASIS,
11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 | See the License for the specific language governing permissions and
13 | limitations under the License.
14 |
15 | ##########
16 |
17 | This directory contains the fonts for the platform. They are licensed
18 | under the Apache 2 license.
19 |
--------------------------------------------------------------------------------
/images/Park2/negx.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2/negx.jpg
--------------------------------------------------------------------------------
/images/Park2/negy.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2/negy.jpg
--------------------------------------------------------------------------------
/images/Park2/negz.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2/negz.jpg
--------------------------------------------------------------------------------
/images/Park2/posx.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2/posx.jpg
--------------------------------------------------------------------------------
/images/Park2/posy.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2/posy.jpg
--------------------------------------------------------------------------------
/images/Park2/posz.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2/posz.jpg
--------------------------------------------------------------------------------
/images/Park2/readme.txt:
--------------------------------------------------------------------------------
1 | Author
2 | ======
3 |
4 | This is the work of Emil Persson, aka Humus.
5 | http://www.humus.name
6 | humus@comhem.se
7 |
8 |
9 |
10 | Legal stuff
11 | ===========
12 |
13 | This work is free and may be used by anyone for any purpose
14 | and may be distributed freely to anyone using any distribution
15 | media or distribution method as long as this file is included.
16 | Distribution without this file is allowed if it's distributed
17 | with free non-commercial software; however, fair credit of the
18 | original author is expected.
19 | Any commercial distribution of this software requires the written
20 | approval of Emil Persson.
21 |
--------------------------------------------------------------------------------
/images/Park2_1024/negx.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/negx.jpg
--------------------------------------------------------------------------------
/images/Park2_1024/negx.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/negx.png
--------------------------------------------------------------------------------
/images/Park2_1024/negy.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/negy.jpg
--------------------------------------------------------------------------------
/images/Park2_1024/negy.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/negy.png
--------------------------------------------------------------------------------
/images/Park2_1024/negz.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/negz.jpg
--------------------------------------------------------------------------------
/images/Park2_1024/negz.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/negz.png
--------------------------------------------------------------------------------
/images/Park2_1024/posx.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/posx.jpg
--------------------------------------------------------------------------------
/images/Park2_1024/posx.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/posx.png
--------------------------------------------------------------------------------
/images/Park2_1024/posy.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/posy.jpg
--------------------------------------------------------------------------------
/images/Park2_1024/posy.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/posy.png
--------------------------------------------------------------------------------
/images/Park2_1024/posz.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/posz.jpg
--------------------------------------------------------------------------------
/images/Park2_1024/posz.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Park2_1024/posz.png
--------------------------------------------------------------------------------
/images/Park2_1024/readme.txt:
--------------------------------------------------------------------------------
1 | Author
2 | ======
3 |
4 | This is the work of Emil Persson, aka Humus.
5 | http://www.humus.name
6 | humus@comhem.se
7 |
8 |
9 |
10 | Legal stuff
11 | ===========
12 |
13 | This work is free and may be used by anyone for any purpose
14 | and may be distributed freely to anyone using any distribution
15 | media or distribution method as long as this file is included.
16 | Distribution without this file is allowed if it's distributed
17 | with free non-commercial software; however, fair credit of the
18 | original author is expected.
19 | Any commercial distribution of this software requires the written
20 | approval of Emil Persson.
21 |
--------------------------------------------------------------------------------
/images/Star02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/Star02.png
--------------------------------------------------------------------------------
/images/ash_uvgrid01-bw.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/ash_uvgrid01-bw.jpg
--------------------------------------------------------------------------------
/images/ash_uvgrid01.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/ash_uvgrid01.jpg
--------------------------------------------------------------------------------
/images/bkg.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/bkg.png
--------------------------------------------------------------------------------
/images/blacktocat.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/blacktocat.png
--------------------------------------------------------------------------------
/images/bowieorangeglam.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/bowieorangeglam.png
--------------------------------------------------------------------------------
/images/bubbles.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/bubbles.png
--------------------------------------------------------------------------------
/images/cloud.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/cloud.png
--------------------------------------------------------------------------------
/images/earth_atmos_2048.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/earth_atmos_2048.jpg
--------------------------------------------------------------------------------
/images/earth_normal_2048.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/earth_normal_2048.jpg
--------------------------------------------------------------------------------
/images/envmap/2-NEGATIVE_X.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/envmap/2-NEGATIVE_X.jpg
--------------------------------------------------------------------------------
/images/envmap/2-NEGATIVE_Y.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/envmap/2-NEGATIVE_Y.jpg
--------------------------------------------------------------------------------
/images/envmap/2-NEGATIVE_Z.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/envmap/2-NEGATIVE_Z.jpg
--------------------------------------------------------------------------------
/images/envmap/2-POSITIVE_X.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/envmap/2-POSITIVE_X.jpg
--------------------------------------------------------------------------------
/images/envmap/2-POSITIVE_Y.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/envmap/2-POSITIVE_Y.jpg
--------------------------------------------------------------------------------
/images/envmap/2-POSITIVE_Z.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/envmap/2-POSITIVE_Z.jpg
--------------------------------------------------------------------------------
/images/firefly.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/firefly.png
--------------------------------------------------------------------------------
/images/flowers.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/flowers.jpg
--------------------------------------------------------------------------------
/images/lavatile.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/lavatile.jpg
--------------------------------------------------------------------------------
/images/moon_1024.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/moon_1024.jpg
--------------------------------------------------------------------------------
/images/parisi1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/parisi1.jpg
--------------------------------------------------------------------------------
/images/sky35/backcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/backcity.jpg
--------------------------------------------------------------------------------
/images/sky35/backcity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/backcity.png
--------------------------------------------------------------------------------
/images/sky35/botcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/botcity.jpg
--------------------------------------------------------------------------------
/images/sky35/botcity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/botcity.png
--------------------------------------------------------------------------------
/images/sky35/citysky.rwx:
--------------------------------------------------------------------------------
1 |
2 | ModelBegin
3 | ProtoBegin cube_0_0
4 | TextureModes Lit Foreshorten
5 | Color 1 1 1
6 | Transform 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 1
7 | Opacity 1
8 | #! Textureaddressmode clamp
9 |
10 | Vertex 1 -1 1 UV 0 0 #! Prelight 1 1 1
11 | Vertex -1 -1 1 UV 1 0 #! Prelight 1 1 1
12 | Vertex -1 -1 -1 UV 1 1 #! Prelight 1 1 1
13 | Vertex 1 -1 -1 UV 0 1 #! Prelight 1 1 1
14 | Texture backcity
15 | Quad 4 3 2 1
16 |
17 | Vertex 1 1 1 UV 1 0 #! Prelight 1 1 1
18 | Vertex -1 1 1 UV 0 0 #! Prelight 1 1 1
19 | Vertex -1 1 -1 UV 0 1 #! Prelight 1 1 1
20 | Vertex 1 1 -1 UV 1 1 #! Prelight 1 1 1
21 | Texture frontcity
22 | Quad 7 8 5 6
23 |
24 | Vertex -1 1 1 UV 1 0 #! Prelight 1 1 1
25 | Vertex -1 -1 1 UV 0 0 #! Prelight 1 1 1
26 | Vertex -1 -1 -1 UV 0 1 #! Prelight 1 1 1
27 | Vertex -1 1 -1 UV 1 1 #! Prelight 1 1 1
28 | Texture rightcity
29 | Quad 9 10 11 12
30 |
31 | Vertex 1 1 1 UV 0 0 #! Prelight 1 1 1
32 | Vertex 1 -1 1 UV 1 0 #! Prelight 1 1 1
33 | Vertex 1 -1 -1 UV 1 1 #! Prelight 1 1 1
34 | Vertex 1 1 -1 UV 0 1 #! Prelight 1 1 1
35 | Texture leftcity
36 | Quad 16 15 14 13
37 |
38 | Vertex 1 1 -1 UV 1 0 #! Prelight 1 1 1
39 | Vertex -1 1 -1 UV 0 0 #! Prelight 1 1 1
40 | Vertex -1 -1 -1 UV 0 1 #! Prelight 1 1 1
41 | Vertex 1 -1 -1 UV 1 1 #! Prelight 1 1 1
42 | Texture botcity
43 | Quad 19 20 17 18
44 | rotate 0 0 1 180
45 | Vertex 1 1 1 UV 0 0 #! Prelight 1 1 1
46 | Vertex -1 1 1 UV 1 0 #! Prelight 1 1 1
47 | Vertex -1 -1 1 UV 1 1 #! Prelight 1 1 1
48 | Vertex 1 -1 1 UV 0 1 #! Prelight 1 1 1
49 | Texture topcity
50 | Quad 24 23 22 21
51 | ProtoEnd # cube_0_0
52 |
53 | ClumpBegin
54 | Rotate 1 0 0 -90
55 | Scale .1 .1 .1
56 | ProtoInstance cube_0_0
57 | ClumpEnd
58 | ModelEnd
--------------------------------------------------------------------------------
/images/sky35/frontcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/frontcity.jpg
--------------------------------------------------------------------------------
/images/sky35/frontcity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/frontcity.png
--------------------------------------------------------------------------------
/images/sky35/leftcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/leftcity.jpg
--------------------------------------------------------------------------------
/images/sky35/leftcity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/leftcity.png
--------------------------------------------------------------------------------
/images/sky35/rightcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/rightcity.jpg
--------------------------------------------------------------------------------
/images/sky35/rightcity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/rightcity.png
--------------------------------------------------------------------------------
/images/sky35/topcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/topcity.jpg
--------------------------------------------------------------------------------
/images/sky35/topcity.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/sky35/topcity.png
--------------------------------------------------------------------------------
/images/slidebg.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/slidebg.png
--------------------------------------------------------------------------------
/images/smokeparticle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/smokeparticle.png
--------------------------------------------------------------------------------
/images/snowflake.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/snowflake.png
--------------------------------------------------------------------------------
/images/spherepano/Panorama-wx8jmd.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/Panorama-wx8jmd.jpg
--------------------------------------------------------------------------------
/images/spherepano/Panorama-wx8jmd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/Panorama-wx8jmd.png
--------------------------------------------------------------------------------
/images/spherepano/belmorepark1right.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/belmorepark1right.jpg
--------------------------------------------------------------------------------
/images/spherepano/belmorepark1right.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/belmorepark1right.png
--------------------------------------------------------------------------------
/images/spherepano/car.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/car.jpg
--------------------------------------------------------------------------------
/images/spherepano/car.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/car.png
--------------------------------------------------------------------------------
/images/spherepano/car2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/car2.jpg
--------------------------------------------------------------------------------
/images/spherepano/car2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/car2.png
--------------------------------------------------------------------------------
/images/spherepano/car3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/car3.jpg
--------------------------------------------------------------------------------
/images/spherepano/car3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/car3.png
--------------------------------------------------------------------------------
/images/spherepano/mellon_square.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/mellon_square.jpg
--------------------------------------------------------------------------------
/images/spherepano/mellon_square.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/mellon_square.png
--------------------------------------------------------------------------------
/images/spherepano/pan0.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan0.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan0.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan0.png
--------------------------------------------------------------------------------
/images/spherepano/pan1.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan1.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan1.png
--------------------------------------------------------------------------------
/images/spherepano/pan2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan2.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan2.png
--------------------------------------------------------------------------------
/images/spherepano/pan3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan3.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan3.png
--------------------------------------------------------------------------------
/images/spherepano/pan4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan4.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan4.png
--------------------------------------------------------------------------------
/images/spherepano/pan5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan5.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan5.png
--------------------------------------------------------------------------------
/images/spherepano/pan6.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan6.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan6.png
--------------------------------------------------------------------------------
/images/spherepano/pan7.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan7.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan7.png
--------------------------------------------------------------------------------
/images/spherepano/pan8.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan8.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan8.png
--------------------------------------------------------------------------------
/images/spherepano/pan9.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan9.jpg
--------------------------------------------------------------------------------
/images/spherepano/pan9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/pan9.png
--------------------------------------------------------------------------------
/images/spherepano/room.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room.jpg
--------------------------------------------------------------------------------
/images/spherepano/room.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room.png
--------------------------------------------------------------------------------
/images/spherepano/room2.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room2.jpg
--------------------------------------------------------------------------------
/images/spherepano/room2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room2.png
--------------------------------------------------------------------------------
/images/spherepano/room3.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room3.jpg
--------------------------------------------------------------------------------
/images/spherepano/room3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room3.png
--------------------------------------------------------------------------------
/images/spherepano/room4.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room4.jpg
--------------------------------------------------------------------------------
/images/spherepano/room4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room4.png
--------------------------------------------------------------------------------
/images/spherepano/room5.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room5.jpg
--------------------------------------------------------------------------------
/images/spherepano/room5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/spherepano/room5.png
--------------------------------------------------------------------------------
/images/stockvault-sun-flowers114982.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/images/stockvault-sun-flowers114982.jpg
--------------------------------------------------------------------------------
/img/bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/bg.jpg
--------------------------------------------------------------------------------
/img/demo/bubblepop.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/bubblepop.jpg
--------------------------------------------------------------------------------
/img/demo/bubblepopcb.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/bubblepopcb.png
--------------------------------------------------------------------------------
/img/demo/glam2Dgeometry.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glam2Dgeometry.jpg
--------------------------------------------------------------------------------
/img/demo/glambumpmap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glambumpmap.jpg
--------------------------------------------------------------------------------
/img/demo/glamcity.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcity.jpg
--------------------------------------------------------------------------------
/img/demo/glamcityvr.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcityvr.jpg
--------------------------------------------------------------------------------
/img/demo/glamcube.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcube.jpg
--------------------------------------------------------------------------------
/img/demo/glamcubeanimated.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcubeanimated.jpg
--------------------------------------------------------------------------------
/img/demo/glamcubebowie.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcubebowie.jpg
--------------------------------------------------------------------------------
/img/demo/glamcubeeffects.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcubeeffects.jpg
--------------------------------------------------------------------------------
/img/demo/glamcubeinteractive.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamcubeinteractive.jpg
--------------------------------------------------------------------------------
/img/demo/glamearth.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamearth.jpg
--------------------------------------------------------------------------------
/img/demo/glamlights.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamlights.jpg
--------------------------------------------------------------------------------
/img/demo/glamlines.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamlines.jpg
--------------------------------------------------------------------------------
/img/demo/glammesh.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glammesh.jpg
--------------------------------------------------------------------------------
/img/demo/glamparticles.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamparticles.jpg
--------------------------------------------------------------------------------
/img/demo/glamscene.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamscene.jpg
--------------------------------------------------------------------------------
/img/demo/glamsceneanimated.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamsceneanimated.jpg
--------------------------------------------------------------------------------
/img/demo/glamsceneanimatedeffects.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamsceneanimatedeffects.jpg
--------------------------------------------------------------------------------
/img/demo/glamscenecss.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamscenecss.jpg
--------------------------------------------------------------------------------
/img/demo/glamshaderfresnel.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamshaderfresnel.jpg
--------------------------------------------------------------------------------
/img/demo/glamshaderfresnelvr.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamshaderfresnelvr.jpg
--------------------------------------------------------------------------------
/img/demo/glamshadertoon.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamshadertoon.jpg
--------------------------------------------------------------------------------
/img/demo/glamskybox.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamskybox.jpg
--------------------------------------------------------------------------------
/img/demo/glamskysphere.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamskysphere.jpg
--------------------------------------------------------------------------------
/img/demo/glamskyspherevr.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamskyspherevr.jpg
--------------------------------------------------------------------------------
/img/demo/glamsolarsystem.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamsolarsystem.jpg
--------------------------------------------------------------------------------
/img/demo/glamspecularmap.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamspecularmap.jpg
--------------------------------------------------------------------------------
/img/demo/glamsun.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamsun.jpg
--------------------------------------------------------------------------------
/img/demo/glamtext.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/glamtext.jpg
--------------------------------------------------------------------------------
/img/demo/threejscubelit.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/demo/threejscubelit.jpg
--------------------------------------------------------------------------------
/img/fundedwithkickstarter.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/img/fundedwithkickstarter.png
--------------------------------------------------------------------------------
/javascripts/main.js:
--------------------------------------------------------------------------------
1 | console.log('This would be the main JS file.');
2 |
--------------------------------------------------------------------------------
/libs/requestAnimationFrame/RequestAnimationFrame.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Provides requestAnimationFrame in a cross browser way.
3 | * http://paulirish.com/2011/requestanimationframe-for-smart-animating/
4 | */
5 |
6 | if ( !window.requestAnimationFrame ) {
7 |
8 | window.requestAnimationFrame = ( function() {
9 |
10 | return window.webkitRequestAnimationFrame ||
11 | window.mozRequestAnimationFrame ||
12 | window.oRequestAnimationFrame ||
13 | window.msRequestAnimationFrame ||
14 | function( /* function FrameRequestCallback */ callback, /* DOMElement Element */ element ) {
15 |
16 | window.setTimeout( callback, 1000 / 60 );
17 |
18 | };
19 |
20 | } )();
21 |
22 | }
23 |
--------------------------------------------------------------------------------
/libs/three.js.r68/ParticleEngine/Pool.js:
--------------------------------------------------------------------------------
1 | function Pool( numItems, object, creationArgument ) {
2 | var store = [];
3 |
4 | this.get = function() {
5 | if(store.length) {
6 | return store.pop();
7 | }
8 | else {
9 | return new object( creationArgument );
10 | }
11 | };
12 |
13 | this.release = function( o ) {
14 | this.reset( o );
15 | store.unshift( o );
16 | };
17 |
18 | this.reset = function() {};
19 |
20 | this.getLength = function() {
21 | return store.length;
22 | };
23 |
24 | this.getStore = function() {
25 | return store;
26 | };
27 |
28 | for( var i = 0, o; i < numItems; ++i ) {
29 | o = new object( creationArgument );
30 | store.push( o );
31 | }
32 | }
--------------------------------------------------------------------------------
/libs/three.js.r68/controls/VRControls.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author dmarcos / https://github.com/dmarcos
3 | */
4 |
5 | THREE.VRControls = function ( camera, done ) {
6 |
7 | this._camera = camera;
8 |
9 | this._init = function () {
10 | var self = this;
11 | if ( !navigator.mozGetVRDevices && !navigator.getVRDevices ) {
12 | if ( done ) {
13 | done("Your browser is not VR Ready");
14 | }
15 | return;
16 | }
17 | if ( navigator.getVRDevices ) {
18 | navigator.getVRDevices().then( gotVRDevices );
19 | } else {
20 | navigator.mozGetVRDevices( gotVRDevices );
21 | }
22 | function gotVRDevices( devices ) {
23 | var vrInput;
24 | var error;
25 | for ( var i = 0; i < devices.length; ++i ) {
26 | if ( devices[i] instanceof PositionSensorVRDevice ) {
27 | vrInput = devices[i]
28 | self._vrInput = vrInput;
29 | break; // We keep the first we encounter
30 | }
31 | }
32 | if ( done ) {
33 | if ( !vrInput ) {
34 | error = 'HMD not available';
35 | }
36 | done( error );
37 | }
38 | }
39 | };
40 |
41 | this._init();
42 |
43 | this.update = function() {
44 | var camera = this._camera;
45 | var quat;
46 | var vrState = this.getVRState();
47 | if ( !vrState ) {
48 | return;
49 | }
50 | // Applies head rotation from sensors data.
51 | if ( camera ) {
52 | camera.quaternion.fromArray( vrState.hmd.rotation );
53 | }
54 | };
55 |
56 | this.getVRState = function() {
57 | var vrInput = this._vrInput;
58 | var orientation;
59 | var vrState;
60 | if ( !vrInput ) {
61 | return null;
62 | }
63 | orientation = vrInput.getState().orientation;
64 | vrState = {
65 | hmd : {
66 | rotation : [
67 | orientation.x,
68 | orientation.y,
69 | orientation.z,
70 | orientation.w
71 | ]
72 | }
73 | };
74 | return vrState;
75 | };
76 |
77 | };
--------------------------------------------------------------------------------
/libs/three.js.r68/postprocessing/DotScreenPass.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | */
4 |
5 | THREE.DotScreenPass = function ( center, angle, scale ) {
6 |
7 | if ( THREE.DotScreenShader === undefined )
8 | console.error( "THREE.DotScreenPass relies on THREE.DotScreenShader" );
9 |
10 | var shader = THREE.DotScreenShader;
11 |
12 | this.uniforms = THREE.UniformsUtils.clone( shader.uniforms );
13 |
14 | if ( center !== undefined ) this.uniforms[ "center" ].value.copy( center );
15 | if ( angle !== undefined ) this.uniforms[ "angle"].value = angle;
16 | if ( scale !== undefined ) this.uniforms[ "scale"].value = scale;
17 |
18 | this.material = new THREE.ShaderMaterial( {
19 |
20 | uniforms: this.uniforms,
21 | vertexShader: shader.vertexShader,
22 | fragmentShader: shader.fragmentShader
23 |
24 | } );
25 |
26 | this.enabled = true;
27 | this.renderToScreen = false;
28 | this.needsSwap = true;
29 |
30 |
31 | this.camera = new THREE.OrthographicCamera( -1, 1, 1, -1, 0, 1 );
32 | this.scene = new THREE.Scene();
33 |
34 | this.quad = new THREE.Mesh( new THREE.PlaneGeometry( 2, 2 ), null );
35 | this.scene.add( this.quad );
36 |
37 | };
38 |
39 | THREE.DotScreenPass.prototype = {
40 |
41 | render: function ( renderer, writeBuffer, readBuffer, delta ) {
42 |
43 | this.uniforms[ "tDiffuse" ].value = readBuffer;
44 | this.uniforms[ "tSize" ].value.set( readBuffer.width, readBuffer.height );
45 |
46 | this.quad.material = this.material;
47 |
48 | if ( this.renderToScreen ) {
49 |
50 | renderer.render( this.scene, this.camera );
51 |
52 | } else {
53 |
54 | renderer.render( this.scene, this.camera, writeBuffer, false );
55 |
56 | }
57 |
58 | }
59 |
60 | };
61 |
--------------------------------------------------------------------------------
/libs/three.js.r68/postprocessing/FilmPass.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | */
4 |
5 | THREE.FilmPass = function ( noiseIntensity, scanlinesIntensity, scanlinesCount, grayscale ) {
6 |
7 | if ( THREE.FilmShader === undefined )
8 | console.error( "THREE.FilmPass relies on THREE.FilmShader" );
9 |
10 | var shader = THREE.FilmShader;
11 |
12 | this.uniforms = THREE.UniformsUtils.clone( shader.uniforms );
13 |
14 | this.material = new THREE.ShaderMaterial( {
15 |
16 | uniforms: this.uniforms,
17 | vertexShader: shader.vertexShader,
18 | fragmentShader: shader.fragmentShader
19 |
20 | } );
21 |
22 | if ( grayscale !== undefined ) this.uniforms.grayscale.value = grayscale;
23 | if ( noiseIntensity !== undefined ) this.uniforms.nIntensity.value = noiseIntensity;
24 | if ( scanlinesIntensity !== undefined ) this.uniforms.sIntensity.value = scanlinesIntensity;
25 | if ( scanlinesCount !== undefined ) this.uniforms.sCount.value = scanlinesCount;
26 |
27 | this.enabled = true;
28 | this.renderToScreen = false;
29 | this.needsSwap = true;
30 |
31 |
32 | this.camera = new THREE.OrthographicCamera( -1, 1, 1, -1, 0, 1 );
33 | this.scene = new THREE.Scene();
34 |
35 | this.quad = new THREE.Mesh( new THREE.PlaneGeometry( 2, 2 ), null );
36 | this.scene.add( this.quad );
37 |
38 | };
39 |
40 | THREE.FilmPass.prototype = {
41 |
42 | render: function ( renderer, writeBuffer, readBuffer, delta ) {
43 |
44 | this.uniforms[ "tDiffuse" ].value = readBuffer;
45 | this.uniforms[ "time" ].value += delta;
46 |
47 | this.quad.material = this.material;
48 |
49 | if ( this.renderToScreen ) {
50 |
51 | renderer.render( this.scene, this.camera );
52 |
53 | } else {
54 |
55 | renderer.render( this.scene, this.camera, writeBuffer, false );
56 |
57 | }
58 |
59 | }
60 |
61 | };
62 |
--------------------------------------------------------------------------------
/libs/three.js.r68/postprocessing/RenderPass.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | */
4 |
5 | THREE.RenderPass = function ( scene, camera, overrideMaterial, clearColor, clearAlpha ) {
6 |
7 | this.scene = scene;
8 | this.camera = camera;
9 |
10 | this.overrideMaterial = overrideMaterial;
11 |
12 | this.clearColor = clearColor;
13 | this.clearAlpha = ( clearAlpha !== undefined ) ? clearAlpha : 1;
14 |
15 | this.oldClearColor = new THREE.Color();
16 | this.oldClearAlpha = 1;
17 |
18 | this.enabled = true;
19 | this.clear = true;
20 | this.needsSwap = false;
21 |
22 | };
23 |
24 | THREE.RenderPass.prototype = {
25 |
26 | render: function ( renderer, writeBuffer, readBuffer, delta ) {
27 |
28 | this.scene.overrideMaterial = this.overrideMaterial;
29 |
30 | if ( this.clearColor ) {
31 |
32 | this.oldClearColor.copy( renderer.getClearColor() );
33 | this.oldClearAlpha = renderer.getClearAlpha();
34 |
35 | renderer.setClearColor( this.clearColor, this.clearAlpha );
36 |
37 | }
38 |
39 | renderer.render( this.scene, this.camera, readBuffer, this.clear );
40 |
41 | if ( this.clearColor ) {
42 |
43 | renderer.setClearColor( this.oldClearColor, this.oldClearAlpha );
44 |
45 | }
46 |
47 | this.scene.overrideMaterial = null;
48 |
49 | }
50 |
51 | };
52 |
--------------------------------------------------------------------------------
/libs/three.js.r68/postprocessing/SavePass.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | */
4 |
5 | THREE.SavePass = function ( renderTarget ) {
6 |
7 | if ( THREE.CopyShader === undefined )
8 | console.error( "THREE.SavePass relies on THREE.CopyShader" );
9 |
10 | var shader = THREE.CopyShader;
11 |
12 | this.textureID = "tDiffuse";
13 |
14 | this.uniforms = THREE.UniformsUtils.clone( shader.uniforms );
15 |
16 | this.material = new THREE.ShaderMaterial( {
17 |
18 | uniforms: this.uniforms,
19 | vertexShader: shader.vertexShader,
20 | fragmentShader: shader.fragmentShader
21 |
22 | } );
23 |
24 | this.renderTarget = renderTarget;
25 |
26 | if ( this.renderTarget === undefined ) {
27 |
28 | this.renderTargetParameters = { minFilter: THREE.LinearFilter, magFilter: THREE.LinearFilter, format: THREE.RGBFormat, stencilBuffer: false };
29 | this.renderTarget = new THREE.WebGLRenderTarget( window.innerWidth, window.innerHeight, this.renderTargetParameters );
30 |
31 | }
32 |
33 | this.enabled = true;
34 | this.needsSwap = false;
35 | this.clear = false;
36 |
37 |
38 | this.camera = new THREE.OrthographicCamera( -1, 1, 1, -1, 0, 1 );
39 | this.scene = new THREE.Scene();
40 |
41 | this.quad = new THREE.Mesh( new THREE.PlaneGeometry( 2, 2 ), null );
42 | this.scene.add( this.quad );
43 |
44 | };
45 |
46 | THREE.SavePass.prototype = {
47 |
48 | render: function ( renderer, writeBuffer, readBuffer, delta ) {
49 |
50 | if ( this.uniforms[ this.textureID ] ) {
51 |
52 | this.uniforms[ this.textureID ].value = readBuffer;
53 |
54 | }
55 |
56 | this.quad.material = this.material;
57 |
58 | renderer.render( this.scene, this.camera, this.renderTarget, this.clear );
59 |
60 | }
61 |
62 | };
63 |
--------------------------------------------------------------------------------
/libs/three.js.r68/postprocessing/ShaderPass.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | */
4 |
5 | THREE.ShaderPass = function ( shader, textureID ) {
6 |
7 | this.textureID = ( textureID !== undefined ) ? textureID : "tDiffuse";
8 |
9 | this.uniforms = THREE.UniformsUtils.clone( shader.uniforms );
10 |
11 | this.material = new THREE.ShaderMaterial( {
12 |
13 | uniforms: this.uniforms,
14 | vertexShader: shader.vertexShader,
15 | fragmentShader: shader.fragmentShader
16 |
17 | } );
18 |
19 | this.renderToScreen = false;
20 |
21 | this.enabled = true;
22 | this.needsSwap = true;
23 | this.clear = false;
24 |
25 |
26 | this.camera = new THREE.OrthographicCamera( -1, 1, 1, -1, 0, 1 );
27 | this.scene = new THREE.Scene();
28 |
29 | this.quad = new THREE.Mesh( new THREE.PlaneGeometry( 2, 2 ), null );
30 | this.scene.add( this.quad );
31 |
32 | };
33 |
34 | THREE.ShaderPass.prototype = {
35 |
36 | render: function ( renderer, writeBuffer, readBuffer, delta ) {
37 |
38 | if ( this.uniforms[ this.textureID ] ) {
39 |
40 | this.uniforms[ this.textureID ].value = readBuffer;
41 |
42 | }
43 |
44 | this.quad.material = this.material;
45 |
46 | if ( this.renderToScreen ) {
47 |
48 | renderer.render( this.scene, this.camera );
49 |
50 | } else {
51 |
52 | renderer.render( this.scene, this.camera, writeBuffer, this.clear );
53 |
54 | }
55 |
56 | }
57 |
58 | };
59 |
--------------------------------------------------------------------------------
/libs/three.js.r68/postprocessing/TexturePass.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | */
4 |
5 | THREE.TexturePass = function ( texture, opacity ) {
6 |
7 | if ( THREE.CopyShader === undefined )
8 | console.error( "THREE.TexturePass relies on THREE.CopyShader" );
9 |
10 | var shader = THREE.CopyShader;
11 |
12 | this.uniforms = THREE.UniformsUtils.clone( shader.uniforms );
13 |
14 | this.uniforms[ "opacity" ].value = ( opacity !== undefined ) ? opacity : 1.0;
15 | this.uniforms[ "tDiffuse" ].value = texture;
16 |
17 | this.material = new THREE.ShaderMaterial( {
18 |
19 | uniforms: this.uniforms,
20 | vertexShader: shader.vertexShader,
21 | fragmentShader: shader.fragmentShader
22 |
23 | } );
24 |
25 | this.enabled = true;
26 | this.needsSwap = false;
27 |
28 |
29 | this.camera = new THREE.OrthographicCamera( -1, 1, 1, -1, 0, 1 );
30 | this.scene = new THREE.Scene();
31 |
32 | this.quad = new THREE.Mesh( new THREE.PlaneGeometry( 2, 2 ), null );
33 | this.scene.add( this.quad );
34 |
35 | };
36 |
37 | THREE.TexturePass.prototype = {
38 |
39 | render: function ( renderer, writeBuffer, readBuffer, delta ) {
40 |
41 | this.quad.material = this.material;
42 |
43 | renderer.render( this.scene, this.camera, readBuffer );
44 |
45 | }
46 |
47 | };
48 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/BasicShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author mrdoob / http://www.mrdoob.com
3 | *
4 | * Simple test shader
5 | */
6 |
7 | THREE.BasicShader = {
8 |
9 | uniforms: {},
10 |
11 | vertexShader: [
12 |
13 | "void main() {",
14 |
15 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
16 |
17 | "}"
18 |
19 | ].join("\n"),
20 |
21 | fragmentShader: [
22 |
23 | "void main() {",
24 |
25 | "gl_FragColor = vec4( 1.0, 0.0, 0.0, 0.5 );",
26 |
27 | "}"
28 |
29 | ].join("\n")
30 |
31 | };
32 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/BleachBypassShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Bleach bypass shader [http://en.wikipedia.org/wiki/Bleach_bypass]
5 | * - based on Nvidia example
6 | * http://developer.download.nvidia.com/shaderlibrary/webpages/shader_library.html#post_bleach_bypass
7 | */
8 |
9 | THREE.BleachBypassShader = {
10 |
11 | uniforms: {
12 |
13 | "tDiffuse": { type: "t", value: null },
14 | "opacity": { type: "f", value: 1.0 }
15 |
16 | },
17 |
18 | vertexShader: [
19 |
20 | "varying vec2 vUv;",
21 |
22 | "void main() {",
23 |
24 | "vUv = uv;",
25 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
26 |
27 | "}"
28 |
29 | ].join("\n"),
30 |
31 | fragmentShader: [
32 |
33 | "uniform float opacity;",
34 |
35 | "uniform sampler2D tDiffuse;",
36 |
37 | "varying vec2 vUv;",
38 |
39 | "void main() {",
40 |
41 | "vec4 base = texture2D( tDiffuse, vUv );",
42 |
43 | "vec3 lumCoeff = vec3( 0.25, 0.65, 0.1 );",
44 | "float lum = dot( lumCoeff, base.rgb );",
45 | "vec3 blend = vec3( lum );",
46 |
47 | "float L = min( 1.0, max( 0.0, 10.0 * ( lum - 0.45 ) ) );",
48 |
49 | "vec3 result1 = 2.0 * base.rgb * blend;",
50 | "vec3 result2 = 1.0 - 2.0 * ( 1.0 - blend ) * ( 1.0 - base.rgb );",
51 |
52 | "vec3 newColor = mix( result1, result2, L );",
53 |
54 | "float A2 = opacity * base.a;",
55 | "vec3 mixRGB = A2 * newColor.rgb;",
56 | "mixRGB += ( ( 1.0 - A2 ) * base.rgb );",
57 |
58 | "gl_FragColor = vec4( mixRGB, base.a );",
59 |
60 | "}"
61 |
62 | ].join("\n")
63 |
64 | };
65 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/BlendShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Blend two textures
5 | */
6 |
7 | THREE.BlendShader = {
8 |
9 | uniforms: {
10 |
11 | "tDiffuse1": { type: "t", value: null },
12 | "tDiffuse2": { type: "t", value: null },
13 | "mixRatio": { type: "f", value: 0.5 },
14 | "opacity": { type: "f", value: 1.0 }
15 |
16 | },
17 |
18 | vertexShader: [
19 |
20 | "varying vec2 vUv;",
21 |
22 | "void main() {",
23 |
24 | "vUv = uv;",
25 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
26 |
27 | "}"
28 |
29 | ].join("\n"),
30 |
31 | fragmentShader: [
32 |
33 | "uniform float opacity;",
34 | "uniform float mixRatio;",
35 |
36 | "uniform sampler2D tDiffuse1;",
37 | "uniform sampler2D tDiffuse2;",
38 |
39 | "varying vec2 vUv;",
40 |
41 | "void main() {",
42 |
43 | "vec4 texel1 = texture2D( tDiffuse1, vUv );",
44 | "vec4 texel2 = texture2D( tDiffuse2, vUv );",
45 | "gl_FragColor = opacity * mix( texel1, texel2, mixRatio );",
46 |
47 | "}"
48 |
49 | ].join("\n")
50 |
51 | };
52 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/BrightnessContrastShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author tapio / http://tapio.github.com/
3 | *
4 | * Brightness and contrast adjustment
5 | * https://github.com/evanw/glfx.js
6 | * brightness: -1 to 1 (-1 is solid black, 0 is no change, and 1 is solid white)
7 | * contrast: -1 to 1 (-1 is solid gray, 0 is no change, and 1 is maximum contrast)
8 | */
9 |
10 | THREE.BrightnessContrastShader = {
11 |
12 | uniforms: {
13 |
14 | "tDiffuse": { type: "t", value: null },
15 | "brightness": { type: "f", value: 0 },
16 | "contrast": { type: "f", value: 0 }
17 |
18 | },
19 |
20 | vertexShader: [
21 |
22 | "varying vec2 vUv;",
23 |
24 | "void main() {",
25 |
26 | "vUv = uv;",
27 |
28 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
29 |
30 | "}"
31 |
32 | ].join("\n"),
33 |
34 | fragmentShader: [
35 |
36 | "uniform sampler2D tDiffuse;",
37 | "uniform float brightness;",
38 | "uniform float contrast;",
39 |
40 | "varying vec2 vUv;",
41 |
42 | "void main() {",
43 |
44 | "gl_FragColor = texture2D( tDiffuse, vUv );",
45 |
46 | "gl_FragColor.rgb += brightness;",
47 |
48 | "if (contrast > 0.0) {",
49 | "gl_FragColor.rgb = (gl_FragColor.rgb - 0.5) / (1.0 - contrast) + 0.5;",
50 | "} else {",
51 | "gl_FragColor.rgb = (gl_FragColor.rgb - 0.5) * (1.0 + contrast) + 0.5;",
52 | "}",
53 |
54 | "}"
55 |
56 | ].join("\n")
57 |
58 | };
59 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/ColorCorrectionShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Color correction
5 | */
6 |
7 | THREE.ColorCorrectionShader = {
8 |
9 | uniforms: {
10 |
11 | "tDiffuse": { type: "t", value: null },
12 | "powRGB": { type: "v3", value: new THREE.Vector3( 2, 2, 2 ) },
13 | "mulRGB": { type: "v3", value: new THREE.Vector3( 1, 1, 1 ) }
14 |
15 | },
16 |
17 | vertexShader: [
18 |
19 | "varying vec2 vUv;",
20 |
21 | "void main() {",
22 |
23 | "vUv = uv;",
24 |
25 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
26 |
27 | "}"
28 |
29 | ].join("\n"),
30 |
31 | fragmentShader: [
32 |
33 | "uniform sampler2D tDiffuse;",
34 | "uniform vec3 powRGB;",
35 | "uniform vec3 mulRGB;",
36 |
37 | "varying vec2 vUv;",
38 |
39 | "void main() {",
40 |
41 | "gl_FragColor = texture2D( tDiffuse, vUv );",
42 | "gl_FragColor.rgb = mulRGB * pow( gl_FragColor.rgb, powRGB );",
43 |
44 | "}"
45 |
46 | ].join("\n")
47 |
48 | };
49 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/ColorifyShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Colorify shader
5 | */
6 |
7 | THREE.ColorifyShader = {
8 |
9 | uniforms: {
10 |
11 | "tDiffuse": { type: "t", value: null },
12 | "color": { type: "c", value: new THREE.Color( 0xffffff ) }
13 |
14 | },
15 |
16 | vertexShader: [
17 |
18 | "varying vec2 vUv;",
19 |
20 | "void main() {",
21 |
22 | "vUv = uv;",
23 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
24 |
25 | "}"
26 |
27 | ].join("\n"),
28 |
29 | fragmentShader: [
30 |
31 | "uniform vec3 color;",
32 | "uniform sampler2D tDiffuse;",
33 |
34 | "varying vec2 vUv;",
35 |
36 | "void main() {",
37 |
38 | "vec4 texel = texture2D( tDiffuse, vUv );",
39 |
40 | "vec3 luma = vec3( 0.299, 0.587, 0.114 );",
41 | "float v = dot( texel.xyz, luma );",
42 |
43 | "gl_FragColor = vec4( v * color, texel.w );",
44 |
45 | "}"
46 |
47 | ].join("\n")
48 |
49 | };
50 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/CopyShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Full-screen textured quad shader
5 | */
6 |
7 | THREE.CopyShader = {
8 |
9 | uniforms: {
10 |
11 | "tDiffuse": { type: "t", value: null },
12 | "opacity": { type: "f", value: 1.0 }
13 |
14 | },
15 |
16 | vertexShader: [
17 |
18 | "varying vec2 vUv;",
19 |
20 | "void main() {",
21 |
22 | "vUv = uv;",
23 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
24 |
25 | "}"
26 |
27 | ].join("\n"),
28 |
29 | fragmentShader: [
30 |
31 | "uniform float opacity;",
32 |
33 | "uniform sampler2D tDiffuse;",
34 |
35 | "varying vec2 vUv;",
36 |
37 | "void main() {",
38 |
39 | "vec4 texel = texture2D( tDiffuse, vUv );",
40 | "gl_FragColor = opacity * texel;",
41 |
42 | "}"
43 |
44 | ].join("\n")
45 |
46 | };
47 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/DOFMipMapShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Depth-of-field shader using mipmaps
5 | * - from Matt Handley @applmak
6 | * - requires power-of-2 sized render target with enabled mipmaps
7 | */
8 |
9 | THREE.DOFMipMapShader = {
10 |
11 | uniforms: {
12 |
13 | "tColor": { type: "t", value: null },
14 | "tDepth": { type: "t", value: null },
15 | "focus": { type: "f", value: 1.0 },
16 | "maxblur": { type: "f", value: 1.0 }
17 |
18 | },
19 |
20 | vertexShader: [
21 |
22 | "varying vec2 vUv;",
23 |
24 | "void main() {",
25 |
26 | "vUv = uv;",
27 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
28 |
29 | "}"
30 |
31 | ].join("\n"),
32 |
33 | fragmentShader: [
34 |
35 | "uniform float focus;",
36 | "uniform float maxblur;",
37 |
38 | "uniform sampler2D tColor;",
39 | "uniform sampler2D tDepth;",
40 |
41 | "varying vec2 vUv;",
42 |
43 | "void main() {",
44 |
45 | "vec4 depth = texture2D( tDepth, vUv );",
46 |
47 | "float factor = depth.x - focus;",
48 |
49 | "vec4 col = texture2D( tColor, vUv, 2.0 * maxblur * abs( focus - depth.x ) );",
50 |
51 | "gl_FragColor = col;",
52 | "gl_FragColor.a = 1.0;",
53 |
54 | "}"
55 |
56 | ].join("\n")
57 |
58 | };
59 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/DotScreenRGBShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Dot screen shader
5 | * based on glfx.js sepia shader
6 | * https://github.com/evanw/glfx.js
7 | */
8 |
9 | THREE.DotScreenRGBShader = {
10 |
11 | uniforms: {
12 |
13 | "tDiffuse": { type: "t", value: null },
14 | "tSize": { type: "v2", value: new THREE.Vector2( 256, 256 ) },
15 | "center": { type: "v2", value: new THREE.Vector2( 0.5, 0.5 ) },
16 | "angle": { type: "f", value: 1.57 },
17 | "scale": { type: "f", value: 1.0 }
18 |
19 | },
20 |
21 | vertexShader: [
22 |
23 | "varying vec2 vUv;",
24 |
25 | "void main() {",
26 |
27 | "vUv = uv;",
28 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
29 |
30 | "}"
31 |
32 | ].join("\n"),
33 |
34 | fragmentShader: [
35 |
36 | "uniform vec2 center;",
37 | "uniform float angle;",
38 | "uniform float scale;",
39 | "uniform vec2 tSize;",
40 |
41 | "uniform sampler2D tDiffuse;",
42 |
43 | "varying vec2 vUv;",
44 |
45 | "float pattern() {",
46 |
47 | "float s = sin( angle ), c = cos( angle );",
48 |
49 | "vec2 tex = vUv * tSize - center;",
50 | "vec2 point = vec2( c * tex.x - s * tex.y, s * tex.x + c * tex.y ) * scale;",
51 |
52 | "return ( sin( point.x ) * sin( point.y ) ) * 4.0;",
53 |
54 | "}",
55 |
56 | "void main() {",
57 |
58 | "vec4 color = texture2D( tDiffuse, vUv );",
59 |
60 | "float r = color.r * 10.0 - 5.0 + pattern();",
61 | "float g = color.g * 10.0 - 5.0 + pattern();",
62 | "float b = color.b * 10.0 - 5.0 + pattern();",
63 |
64 | "gl_FragColor = vec4( r, g, b, color.a );",
65 |
66 | "}"
67 |
68 | ].join("\n")
69 |
70 | };
71 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/DotScreenShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Dot screen shader
5 | * based on glfx.js sepia shader
6 | * https://github.com/evanw/glfx.js
7 | */
8 |
9 | THREE.DotScreenShader = {
10 |
11 | uniforms: {
12 |
13 | "tDiffuse": { type: "t", value: null },
14 | "tSize": { type: "v2", value: new THREE.Vector2( 256, 256 ) },
15 | "center": { type: "v2", value: new THREE.Vector2( 0.5, 0.5 ) },
16 | "angle": { type: "f", value: 1.57 },
17 | "scale": { type: "f", value: 1.0 }
18 |
19 | },
20 |
21 | vertexShader: [
22 |
23 | "varying vec2 vUv;",
24 |
25 | "void main() {",
26 |
27 | "vUv = uv;",
28 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
29 |
30 | "}"
31 |
32 | ].join("\n"),
33 |
34 | fragmentShader: [
35 |
36 | "uniform vec2 center;",
37 | "uniform float angle;",
38 | "uniform float scale;",
39 | "uniform vec2 tSize;",
40 |
41 | "uniform sampler2D tDiffuse;",
42 |
43 | "varying vec2 vUv;",
44 |
45 | "float pattern() {",
46 |
47 | "float s = sin( angle ), c = cos( angle );",
48 |
49 | "vec2 tex = vUv * tSize - center;",
50 | "vec2 point = vec2( c * tex.x - s * tex.y, s * tex.x + c * tex.y ) * scale;",
51 |
52 | "return ( sin( point.x ) * sin( point.y ) ) * 4.0;",
53 |
54 | "}",
55 |
56 | "void main() {",
57 |
58 | "vec4 color = texture2D( tDiffuse, vUv );",
59 |
60 | "float average = ( color.r + color.g + color.b ) / 3.0;",
61 |
62 | "gl_FragColor = vec4( vec3( average * 10.0 - 5.0 + pattern() ), color.a );",
63 |
64 | "}"
65 |
66 | ].join("\n")
67 |
68 | };
69 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/KaleidoShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author felixturner / http://airtight.cc/
3 | *
4 | * Kaleidoscope Shader
5 | * Radial reflection around center point
6 | * Ported from: http://pixelshaders.com/editor/
7 | * by Toby Schachman / http://tobyschachman.com/
8 | *
9 | * sides: number of reflections
10 | * angle: initial angle in radians
11 | */
12 |
13 | THREE.KaleidoShader = {
14 |
15 | uniforms: {
16 |
17 | "tDiffuse": { type: "t", value: null },
18 | "sides": { type: "f", value: 6.0 },
19 | "angle": { type: "f", value: 0.0 }
20 |
21 | },
22 |
23 | vertexShader: [
24 |
25 | "varying vec2 vUv;",
26 |
27 | "void main() {",
28 |
29 | "vUv = uv;",
30 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
31 |
32 | "}"
33 |
34 | ].join("\n"),
35 |
36 | fragmentShader: [
37 |
38 | "uniform sampler2D tDiffuse;",
39 | "uniform float sides;",
40 | "uniform float angle;",
41 |
42 | "varying vec2 vUv;",
43 |
44 | "void main() {",
45 |
46 | "vec2 p = vUv - 0.5;",
47 | "float r = length(p);",
48 | "float a = atan(p.y, p.x) + angle;",
49 | "float tau = 2. * 3.1416 ;",
50 | "a = mod(a, tau/sides);",
51 | "a = abs(a - tau/sides/2.) ;",
52 | "p = r * vec2(cos(a), sin(a));",
53 | "vec4 color = texture2D(tDiffuse, p + 0.5);",
54 | "gl_FragColor = color;",
55 |
56 | "}"
57 |
58 | ].join("\n")
59 |
60 | };
61 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/LuminosityShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Luminosity
5 | * http://en.wikipedia.org/wiki/Luminosity
6 | */
7 |
8 | THREE.LuminosityShader = {
9 |
10 | uniforms: {
11 |
12 | "tDiffuse": { type: "t", value: null }
13 |
14 | },
15 |
16 | vertexShader: [
17 |
18 | "varying vec2 vUv;",
19 |
20 | "void main() {",
21 |
22 | "vUv = uv;",
23 |
24 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
25 |
26 | "}"
27 |
28 | ].join("\n"),
29 |
30 | fragmentShader: [
31 |
32 | "uniform sampler2D tDiffuse;",
33 |
34 | "varying vec2 vUv;",
35 |
36 | "void main() {",
37 |
38 | "vec4 texel = texture2D( tDiffuse, vUv );",
39 |
40 | "vec3 luma = vec3( 0.299, 0.587, 0.114 );",
41 |
42 | "float v = dot( texel.xyz, luma );",
43 |
44 | "gl_FragColor = vec4( v, v, v, texel.w );",
45 |
46 | "}"
47 |
48 | ].join("\n")
49 |
50 | };
51 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/MirrorShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author felixturner / http://airtight.cc/
3 | *
4 | * Mirror Shader
5 | * Copies half the input to the other half
6 | *
7 | * side: side of input to mirror (0 = left, 1 = right, 2 = top, 3 = bottom)
8 | */
9 |
10 | THREE.MirrorShader = {
11 |
12 | uniforms: {
13 |
14 | "tDiffuse": { type: "t", value: null },
15 | "side": { type: "i", value: 1 }
16 |
17 | },
18 |
19 | vertexShader: [
20 |
21 | "varying vec2 vUv;",
22 |
23 | "void main() {",
24 |
25 | "vUv = uv;",
26 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
27 |
28 | "}"
29 |
30 | ].join("\n"),
31 |
32 | fragmentShader: [
33 |
34 | "uniform sampler2D tDiffuse;",
35 | "uniform int side;",
36 |
37 | "varying vec2 vUv;",
38 |
39 | "void main() {",
40 |
41 | "vec2 p = vUv;",
42 | "if (side == 0){",
43 | "if (p.x > 0.5) p.x = 1.0 - p.x;",
44 | "}else if (side == 1){",
45 | "if (p.x < 0.5) p.x = 1.0 - p.x;",
46 | "}else if (side == 2){",
47 | "if (p.y < 0.5) p.y = 1.0 - p.y;",
48 | "}else if (side == 3){",
49 | "if (p.y > 0.5) p.y = 1.0 - p.y;",
50 | "} ",
51 | "vec4 color = texture2D(tDiffuse, p);",
52 | "gl_FragColor = color;",
53 |
54 | "}"
55 |
56 | ].join("\n")
57 |
58 | };
59 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/NormalMapShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Normal map shader
5 | * - compute normals from heightmap
6 | */
7 |
8 | THREE.NormalMapShader = {
9 |
10 | uniforms: {
11 |
12 | "heightMap": { type: "t", value: null },
13 | "resolution": { type: "v2", value: new THREE.Vector2( 512, 512 ) },
14 | "scale": { type: "v2", value: new THREE.Vector2( 1, 1 ) },
15 | "height": { type: "f", value: 0.05 }
16 |
17 | },
18 |
19 | vertexShader: [
20 |
21 | "varying vec2 vUv;",
22 |
23 | "void main() {",
24 |
25 | "vUv = uv;",
26 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
27 |
28 | "}"
29 |
30 | ].join("\n"),
31 |
32 | fragmentShader: [
33 |
34 | "uniform float height;",
35 | "uniform vec2 resolution;",
36 | "uniform sampler2D heightMap;",
37 |
38 | "varying vec2 vUv;",
39 |
40 | "void main() {",
41 |
42 | "float val = texture2D( heightMap, vUv ).x;",
43 |
44 | "float valU = texture2D( heightMap, vUv + vec2( 1.0 / resolution.x, 0.0 ) ).x;",
45 | "float valV = texture2D( heightMap, vUv + vec2( 0.0, 1.0 / resolution.y ) ).x;",
46 |
47 | "gl_FragColor = vec4( ( 0.5 * normalize( vec3( val - valU, val - valV, height ) ) + 0.5 ), 1.0 );",
48 |
49 | "}"
50 |
51 | ].join("\n")
52 |
53 | };
54 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/RGBShiftShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author felixturner / http://airtight.cc/
3 | *
4 | * RGB Shift Shader
5 | * Shifts red and blue channels from center in opposite directions
6 | * Ported from http://kriss.cx/tom/2009/05/rgb-shift/
7 | * by Tom Butterworth / http://kriss.cx/tom/
8 | *
9 | * amount: shift distance (1 is width of input)
10 | * angle: shift angle in radians
11 | */
12 |
13 | THREE.RGBShiftShader = {
14 |
15 | uniforms: {
16 |
17 | "tDiffuse": { type: "t", value: null },
18 | "amount": { type: "f", value: 0.005 },
19 | "angle": { type: "f", value: 0.0 }
20 |
21 | },
22 |
23 | vertexShader: [
24 |
25 | "varying vec2 vUv;",
26 |
27 | "void main() {",
28 |
29 | "vUv = uv;",
30 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
31 |
32 | "}"
33 |
34 | ].join("\n"),
35 |
36 | fragmentShader: [
37 |
38 | "uniform sampler2D tDiffuse;",
39 | "uniform float amount;",
40 | "uniform float angle;",
41 |
42 | "varying vec2 vUv;",
43 |
44 | "void main() {",
45 |
46 | "vec2 offset = amount * vec2( cos(angle), sin(angle));",
47 | "vec4 cr = texture2D(tDiffuse, vUv + offset);",
48 | "vec4 cga = texture2D(tDiffuse, vUv);",
49 | "vec4 cb = texture2D(tDiffuse, vUv - offset);",
50 | "gl_FragColor = vec4(cr.r, cga.g, cb.b, cga.a);",
51 |
52 | "}"
53 |
54 | ].join("\n")
55 |
56 | };
57 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/SepiaShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Sepia tone shader
5 | * based on glfx.js sepia shader
6 | * https://github.com/evanw/glfx.js
7 | */
8 |
9 | THREE.SepiaShader = {
10 |
11 | uniforms: {
12 |
13 | "tDiffuse": { type: "t", value: null },
14 | "amount": { type: "f", value: 1.0 }
15 |
16 | },
17 |
18 | vertexShader: [
19 |
20 | "varying vec2 vUv;",
21 |
22 | "void main() {",
23 |
24 | "vUv = uv;",
25 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
26 |
27 | "}"
28 |
29 | ].join("\n"),
30 |
31 | fragmentShader: [
32 |
33 | "uniform float amount;",
34 |
35 | "uniform sampler2D tDiffuse;",
36 |
37 | "varying vec2 vUv;",
38 |
39 | "void main() {",
40 |
41 | "vec4 color = texture2D( tDiffuse, vUv );",
42 | "vec3 c = color.rgb;",
43 |
44 | "color.r = dot( c, vec3( 1.0 - 0.607 * amount, 0.769 * amount, 0.189 * amount ) );",
45 | "color.g = dot( c, vec3( 0.349 * amount, 1.0 - 0.314 * amount, 0.168 * amount ) );",
46 | "color.b = dot( c, vec3( 0.272 * amount, 0.534 * amount, 1.0 - 0.869 * amount ) );",
47 |
48 | "gl_FragColor = vec4( min( vec3( 1.0 ), color.rgb ), color.a );",
49 |
50 | "}"
51 |
52 | ].join("\n")
53 |
54 | };
55 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/TechnicolorShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author flimshaw / http://charliehoey.com
3 | *
4 | * Technicolor Shader
5 | * Simulates the look of the two-strip technicolor process popular in early 20th century films.
6 | * More historical info here: http://www.widescreenmuseum.com/oldcolor/technicolor1.htm
7 | * Demo here: http://charliehoey.com/technicolor_shader/shader_test.html
8 | */
9 |
10 | THREE.TechnicolorShader = {
11 |
12 | uniforms: {
13 |
14 | "tDiffuse": { type: "t", value: null },
15 |
16 | },
17 |
18 | vertexShader: [
19 |
20 | "varying vec2 vUv;",
21 |
22 | "void main() {",
23 |
24 | "vUv = uv;",
25 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
26 |
27 | "}"
28 |
29 | ].join("\n"),
30 |
31 | fragmentShader: [
32 |
33 | "uniform sampler2D tDiffuse;",
34 | "varying vec2 vUv;",
35 |
36 | "void main() {",
37 |
38 | "vec4 tex = texture2D( tDiffuse, vec2( vUv.x, vUv.y ) );",
39 | "vec4 newTex = vec4(tex.r, (tex.g + tex.b) * .5, (tex.g + tex.b) * .5, 1.0);",
40 |
41 | "gl_FragColor = newTex;",
42 |
43 | "}"
44 |
45 | ].join("\n")
46 |
47 | };
48 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/UnpackDepthRGBAShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Unpack RGBA depth shader
5 | * - show RGBA encoded depth as monochrome color
6 | */
7 |
8 | THREE.UnpackDepthRGBAShader = {
9 |
10 | uniforms: {
11 |
12 | "tDiffuse": { type: "t", value: null },
13 | "opacity": { type: "f", value: 1.0 }
14 |
15 | },
16 |
17 | vertexShader: [
18 |
19 | "varying vec2 vUv;",
20 |
21 | "void main() {",
22 |
23 | "vUv = uv;",
24 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
25 |
26 | "}"
27 |
28 | ].join("\n"),
29 |
30 | fragmentShader: [
31 |
32 | "uniform float opacity;",
33 |
34 | "uniform sampler2D tDiffuse;",
35 |
36 | "varying vec2 vUv;",
37 |
38 | // RGBA depth
39 |
40 | "float unpackDepth( const in vec4 rgba_depth ) {",
41 |
42 | "const vec4 bit_shift = vec4( 1.0 / ( 256.0 * 256.0 * 256.0 ), 1.0 / ( 256.0 * 256.0 ), 1.0 / 256.0, 1.0 );",
43 | "float depth = dot( rgba_depth, bit_shift );",
44 | "return depth;",
45 |
46 | "}",
47 |
48 | "void main() {",
49 |
50 | "float depth = 1.0 - unpackDepth( texture2D( tDiffuse, vUv ) );",
51 | "gl_FragColor = opacity * vec4( vec3( depth ), 1.0 );",
52 |
53 | "}"
54 |
55 | ].join("\n")
56 |
57 | };
58 |
--------------------------------------------------------------------------------
/libs/three.js.r68/shaders/VignetteShader.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Vignette shader
5 | * based on PaintEffect postprocess from ro.me
6 | * http://code.google.com/p/3-dreams-of-black/source/browse/deploy/js/effects/PaintEffect.js
7 | */
8 |
9 | THREE.VignetteShader = {
10 |
11 | uniforms: {
12 |
13 | "tDiffuse": { type: "t", value: null },
14 | "offset": { type: "f", value: 1.0 },
15 | "darkness": { type: "f", value: 1.0 }
16 |
17 | },
18 |
19 | vertexShader: [
20 |
21 | "varying vec2 vUv;",
22 |
23 | "void main() {",
24 |
25 | "vUv = uv;",
26 | "gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );",
27 |
28 | "}"
29 |
30 | ].join("\n"),
31 |
32 | fragmentShader: [
33 |
34 | "uniform float offset;",
35 | "uniform float darkness;",
36 |
37 | "uniform sampler2D tDiffuse;",
38 |
39 | "varying vec2 vUv;",
40 |
41 | "void main() {",
42 |
43 | // Eskil's vignette
44 |
45 | "vec4 texel = texture2D( tDiffuse, vUv );",
46 | "vec2 uv = ( vUv - vec2( 0.5 ) ) * vec2( offset );",
47 | "gl_FragColor = vec4( mix( texel.rgb, vec3( 1.0 - darkness ), dot( uv, uv ) ), texel.a );",
48 |
49 | /*
50 | // alternative version from glfx.js
51 | // this one makes more "dusty" look (as opposed to "burned")
52 |
53 | "vec4 color = texture2D( tDiffuse, vUv );",
54 | "float dist = distance( vUv, vec2( 0.5 ) );",
55 | "color.rgb *= smoothstep( 0.8, offset * 0.799, dist *( darkness + offset ) );",
56 | "gl_FragColor = color;",
57 | */
58 |
59 | "}"
60 |
61 | ].join("\n")
62 |
63 | };
64 |
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/ACUnit_A.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/ACUnit_A.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Ad_Sqr11.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Ad_Sqr11.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Apart_B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Apart_B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Apart_C.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Apart_C.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Apart_D.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Apart_D.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Apart_E.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Apart_E.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Apart_F.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Apart_F.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/BrickES4.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/BrickES4.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Brick_K4.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Brick_K4.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Brick_K6.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Brick_K6.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/ConcWal1.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/ConcWal1.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Conc_K3.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Conc_K3.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Corug_K1.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Corug_K1.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/DoorDb_B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/DoorDb_B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Door_A.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Door_A.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Door_B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Door_B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/GrasES_K.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/GrasES_K.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/MetalES1.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/MetalES1.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/MetalES2.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/MetalES2.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/MetalES4.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/MetalES4.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Pave_02.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Pave_02.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Pave_05.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Pave_05.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Pine_A.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Pine_A.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Pine_A_png.png.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Pine_A_png.png.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Pine_Aa.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Pine_Aa.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Road_01.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Road_01.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Road_03.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Road_03.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Road_J04.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Road_J04.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Road_J08.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Road_J08.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Road_Z01.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Road_Z01.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Roof2.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Roof2.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Roof_F_A.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Roof_F_A.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Roof_F_B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Roof_F_B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Roof_F_C.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Roof_F_C.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Roof_F_D.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Roof_F_D.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_02.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_02.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_04.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_04.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_07.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_07.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_09.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_09.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_10.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_10.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_11.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_11.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_12.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_12.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/SS_Lo_13.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/SS_Lo_13.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Sign_VL2.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Sign_VL2.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TREE_B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TREE_B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TREE_B_png.png.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TREE_B_png.png.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TREE_C.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TREE_C.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TREE_C_png.png.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TREE_C_png.png.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TREE_G.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TREE_G.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TREE_G_png.png.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TREE_G_png.png.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Tree_Ba.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Tree_Ba.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Tree_Ca.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Tree_Ca.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/TrfcLitA.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/TrfcLitA.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Vent_K2.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Vent_K2.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/WalRuinB.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/WalRuinB.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/WallRuf1.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/WallRuf1.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/WallRuf2.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/WallRuf2.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Windx4_A.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Windx4_A.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Windx4_B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Windx4_B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Windx4_H.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Windx4_H.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Windx4_N.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Windx4_N.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Windx4_Q.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Windx4_Q.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/Windx4_R.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/Windx4_R.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/.mayaSwatches/WoodES-B.bmp.swatch:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/.mayaSwatches/WoodES-B.bmp.swatch
--------------------------------------------------------------------------------
/models/futurgo_city/images/ACUnit_A.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/ACUnit_A.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Ad_Sqr11.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Ad_Sqr11.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Apart_A.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Apart_A.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Apart_B.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Apart_B.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Apart_C.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Apart_C.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Apart_D.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Apart_D.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Apart_E.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Apart_E.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Apart_F.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Apart_F.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/BrickES4.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/BrickES4.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Brick_K4.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Brick_K4.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Brick_K6.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Brick_K6.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/ConcWal1.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/ConcWal1.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Conc_K3.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Conc_K3.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Corug_K1.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Corug_K1.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/DoorDb_B.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/DoorDb_B.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Door_A.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Door_A.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Door_B.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Door_B.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/GrasES_K.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/GrasES_K.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/MetalES1.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/MetalES1.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/MetalES2.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/MetalES2.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/MetalES4.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/MetalES4.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Pave_02.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Pave_02.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Pave_05.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Pave_05.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Pine_A_png.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Pine_A_png.png
--------------------------------------------------------------------------------
/models/futurgo_city/images/Road_01.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Road_01.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Road_03.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Road_03.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Road_J04.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Road_J04.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Road_J08.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Road_J08.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Road_Z01.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Road_Z01.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Roof2.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Roof2.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Roof_F_A.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Roof_F_A.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Roof_F_B.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Roof_F_B.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Roof_F_C.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Roof_F_C.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Roof_F_D.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Roof_F_D.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_02.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_02.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_04.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_04.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_07.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_07.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_09.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_09.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_10.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_10.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_11.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_11.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_12.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_12.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/SS_Lo_13.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/SS_Lo_13.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Sign_VL2.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Sign_VL2.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/TREE_B_png.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/TREE_B_png.png
--------------------------------------------------------------------------------
/models/futurgo_city/images/TREE_C_png.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/TREE_C_png.png
--------------------------------------------------------------------------------
/models/futurgo_city/images/TREE_G_png.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/TREE_G_png.png
--------------------------------------------------------------------------------
/models/futurgo_city/images/TrfcLitA.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/TrfcLitA.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Vent_K2.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Vent_K2.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/WalRuinB.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/WalRuinB.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/WallRuf1.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/WallRuf1.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/WallRuf2.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/WallRuf2.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Windx4_A.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Windx4_A.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Windx4_B.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Windx4_B.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Windx4_N.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Windx4_N.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Windx4_Q.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Windx4_Q.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/Windx4_R.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/Windx4_R.bmp
--------------------------------------------------------------------------------
/models/futurgo_city/images/WoodES-B.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/models/futurgo_city/images/WoodES-B.bmp
--------------------------------------------------------------------------------
/server:
--------------------------------------------------------------------------------
1 | server:
2 | python -m SimpleHTTPServer
3 |
4 |
--------------------------------------------------------------------------------
/shaders/colorify.fs:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Colorify shader
5 | */
6 |
7 |
8 |
9 | uniform vec3 color;
10 | uniform sampler2D tDiffuse;
11 |
12 | varying vec2 vUv;,
13 |
14 | void main() {,
15 |
16 | vec4 texel = texture2D( tDiffuse, vUv );
17 |
18 | vec3 luma = vec3( 0.299, 0.587, 0.114 );
19 | float v = dot( texel.xyz, luma );
20 |
21 | gl_FragColor = vec4( v * color, texel.w );
22 |
23 | }
24 |
25 |
--------------------------------------------------------------------------------
/shaders/colorify.vs:
--------------------------------------------------------------------------------
1 | /**
2 | * @author alteredq / http://alteredqualia.com/
3 | *
4 | * Colorify shader
5 | */
6 |
7 |
8 |
9 | varying vec2 vUv;
10 |
11 | void main() {
12 |
13 | vUv = uv;
14 | gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );
15 |
16 | }
17 |
18 |
--------------------------------------------------------------------------------
/shaders/fresnel.fs:
--------------------------------------------------------------------------------
1 | uniform samplerCube tCube;
2 |
3 | varying vec3 vReflect;
4 | varying vec3 vRefract[3];
5 | varying float vReflectionFactor;
6 |
7 | void main() {
8 |
9 | vec4 reflectedColor = textureCube( tCube, vec3( -vReflect.x, vReflect.yz ) );
10 | vec4 refractedColor = vec4( 1.0 );
11 |
12 | refractedColor.r = textureCube( tCube, vec3( -vRefract[0].x, vRefract[0].yz ) ).r;
13 | refractedColor.g = textureCube( tCube, vec3( -vRefract[1].x, vRefract[1].yz ) ).g;
14 | refractedColor.b = textureCube( tCube, vec3( -vRefract[2].x, vRefract[2].yz ) ).b;
15 |
16 | gl_FragColor = mix( refractedColor, reflectedColor, clamp( vReflectionFactor, 0.0, 1.0 ) );
17 |
18 | }
19 |
--------------------------------------------------------------------------------
/shaders/fresnel.vs:
--------------------------------------------------------------------------------
1 | uniform float mRefractionRatio;
2 | uniform float mFresnelBias;
3 | uniform float mFresnelScale;
4 | uniform float mFresnelPower;
5 |
6 | varying vec3 vReflect;
7 | varying vec3 vRefract[3];
8 | varying float vReflectionFactor;
9 |
10 | void main() {
11 |
12 | vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );
13 | vec4 worldPosition = modelMatrix * vec4( position, 1.0 );
14 |
15 | vec3 worldNormal = normalize( mat3( modelMatrix[0].xyz, modelMatrix[1].xyz, modelMatrix[2].xyz ) * normal );
16 |
17 | vec3 I = worldPosition.xyz - cameraPosition;
18 |
19 | vReflect = reflect( I, worldNormal );
20 | vRefract[0] = refract( normalize( I ), worldNormal, mRefractionRatio );
21 | vRefract[1] = refract( normalize( I ), worldNormal, mRefractionRatio * 0.99 );
22 | vRefract[2] = refract( normalize( I ), worldNormal, mRefractionRatio * 0.98 );
23 | vReflectionFactor = mFresnelBias + mFresnelScale * pow( 1.0 + dot( normalize( I ), worldNormal ), mFresnelPower );
24 |
25 | gl_Position = projectionMatrix * mvPosition;
26 |
27 | }
28 |
--------------------------------------------------------------------------------
/shaders/mirror.fs:
--------------------------------------------------------------------------------
1 | /**
2 | * @author felixturner / http://airtight.cc/
3 | *
4 | * Mirror Shader
5 | * Copies half the input to the other half
6 | *
7 | * side: side of input to mirror (0 = left, 1 = right, 2 = top, 3 = bottom)
8 | */
9 |
10 |
11 | uniform sampler2D tDiffuse;
12 | uniform int side;
13 |
14 | varying vec2 vUv;
15 |
16 | void main() {
17 |
18 | vec2 p = vUv;
19 | if (side == 0){
20 | if (p.x > 0.5) p.x = 1.0 - p.x;
21 | }else if (side == 1){
22 | if (p.x < 0.5) p.x = 1.0 - p.x;
23 | }else if (side == 2){
24 | if (p.y < 0.5) p.y = 1.0 - p.y;
25 | }else if (side == 3){
26 | if (p.y > 0.5) p.y = 1.0 - p.y;
27 | }
28 | vec4 color = texture2D(tDiffuse, p);
29 | gl_FragColor = color;
30 |
31 | }
--------------------------------------------------------------------------------
/shaders/mirror.vs:
--------------------------------------------------------------------------------
1 | /**
2 | * @author felixturner / http://airtight.cc/
3 | *
4 | * Mirror Shader
5 | * Copies half the input to the other half
6 | *
7 | * side: side of input to mirror (0 = left, 1 = right, 2 = top, 3 = bottom)
8 | */
9 |
10 |
11 |
12 | varying vec2 vUv;
13 |
14 | void main() {
15 |
16 | vUv = uv;
17 | gl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );
18 |
19 | }
20 |
21 |
--------------------------------------------------------------------------------
/shaders/sun.fs:
--------------------------------------------------------------------------------
1 | uniform float time;
2 |
3 | uniform sampler2D texture1;
4 | uniform sampler2D texture2;
5 |
6 | varying vec2 texCoord;
7 |
8 | void main( void ) {
9 |
10 | vec4 noise = texture2D( texture1, texCoord );
11 |
12 | vec2 T1 = texCoord + vec2( 1.5, -1.5 ) * time * 0.01;
13 | vec2 T2 = texCoord + vec2( -0.5, 2.0 ) * time * 0.01;
14 |
15 | T1.x -= noise.r * 2.0;
16 | T1.y += noise.g * 4.0;
17 | T2.x += noise.g * 0.2;
18 | T2.y += noise.b * 0.2;
19 |
20 | float p = texture2D( texture1, T1 * 2.0 ).a + 0.25;
21 |
22 | vec4 color = texture2D( texture2, T2 );
23 | vec4 temp = color * 2.0 * ( vec4( p, p, p, p ) ) + ( color * color );
24 | gl_FragColor = temp;
25 | }
26 |
--------------------------------------------------------------------------------
/shaders/sun.vs:
--------------------------------------------------------------------------------
1 | varying vec2 texCoord;
2 |
3 | void main()
4 | {
5 | texCoord = uv;
6 | vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );
7 | gl_Position = projectionMatrix * mvPosition;
8 | }
9 |
--------------------------------------------------------------------------------
/shaders/toon1.fs:
--------------------------------------------------------------------------------
1 | varying vec3 vNormal;
2 | varying vec3 vRefract;
3 |
4 | vec3 uDirLightPos = vec3(1.0, 0.0, 1.0);
5 |
6 | uniform vec3 uDirLightColor;
7 | uniform vec3 uAmbientLightColor;
8 | uniform vec3 uBaseColor;
9 |
10 |
11 | void main() {
12 |
13 | float directionalLightWeighting = max( dot( normalize( vNormal ), uDirLightPos ), 0.0);
14 | vec3 lightWeighting = uAmbientLightColor + uDirLightColor * directionalLightWeighting;
15 |
16 | float intensity = smoothstep( - 0.5, 1.0, pow( length(lightWeighting), 20.0 ) );
17 | intensity += length(lightWeighting) * 0.2;
18 |
19 | float cameraWeighting = dot( normalize( vNormal ), vRefract );
20 | intensity += pow( 1.0 - length( cameraWeighting ), 6.0 );
21 | intensity = intensity * 0.2 + 0.3;
22 |
23 | if ( intensity < 0.50 ) {
24 |
25 | gl_FragColor = vec4( 2.0 * intensity * uBaseColor, 1.0 );
26 |
27 | } else {
28 |
29 | gl_FragColor = vec4( 1.0 - 2.0 * ( 1.0 - intensity ) * ( 1.0 - uBaseColor ), 1.0 );
30 |
31 | }
32 | }
33 |
34 |
35 |
--------------------------------------------------------------------------------
/shaders/toon1.vs:
--------------------------------------------------------------------------------
1 | // uDirLightPos: { type: v3, value: new THREE.Vector3() },
2 | // uDirLightColor: { type: c, value: new THREE.Color( 0xeeeeee ) },
3 |
4 | // uAmbientLightColor: { type: c, value: new THREE.Color( 0x050505 ) },
5 |
6 |
7 | varying vec3 vNormal;
8 | varying vec3 vRefract;
9 |
10 | uniform vec3 uDirLightColor;
11 | uniform vec3 uAmbientLightColor;
12 | uniform vec3 uBaseColor;
13 |
14 | void main() {
15 |
16 | vec4 worldPosition = modelMatrix * vec4( position, 1.0 );
17 | vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );
18 | vec3 worldNormal = normalize ( mat3( modelMatrix[0].xyz, modelMatrix[1].xyz, modelMatrix[2].xyz ) * normal );
19 |
20 | vNormal = normalize( normalMatrix * normal );
21 |
22 | vec3 I = worldPosition.xyz - cameraPosition;
23 | vRefract = refract( normalize( I ), worldNormal, 1.02 );
24 |
25 | gl_Position = projectionMatrix * mvPosition;
26 | }
27 |
28 |
--------------------------------------------------------------------------------
/sounds/235264__godowan__bubble1.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/sounds/235264__godowan__bubble1.wav
--------------------------------------------------------------------------------
/sounds/235264__godowan__bubble1_trimmed.wav:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/sounds/235264__godowan__bubble1_trimmed.wav
--------------------------------------------------------------------------------
/src/animations/animationService.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.require('glam.Service');
5 | goog.provide('glam.AnimationService');
6 |
7 | /**
8 | * The AnimationService.
9 | *
10 | * @extends {glam.Service}
11 | */
12 | glam.AnimationService = function() {};
13 |
14 | goog.inherits(glam.AnimationService, glam.Service);
15 |
16 | //---------------------------------------------------------------------
17 | // Initialization/Termination
18 | //---------------------------------------------------------------------
19 |
20 | /**
21 | * Initializes the events system.
22 | */
23 | glam.AnimationService.prototype.initialize = function(param) {};
24 |
25 | /**
26 | * Terminates the events world.
27 | */
28 | glam.AnimationService.prototype.terminate = function() {};
29 |
30 |
31 | /**
32 | * Updates the AnimationService.
33 | */
34 | glam.AnimationService.prototype.update = function()
35 | {
36 | if (window.TWEEN)
37 | THREE.glTFAnimator.update();
38 | }
39 |
--------------------------------------------------------------------------------
/src/animations/tweenService.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.require('glam.Service');
5 | goog.provide('glam.TweenService');
6 |
7 | /**
8 | * The TweenService.
9 | *
10 | * @extends {glam.Service}
11 | */
12 | glam.TweenService = function() {};
13 |
14 | goog.inherits(glam.TweenService, glam.Service);
15 |
16 | //---------------------------------------------------------------------
17 | // Initialization/Termination
18 | //---------------------------------------------------------------------
19 |
20 | /**
21 | * Initializes the events system.
22 | */
23 | glam.TweenService.prototype.initialize = function(param) {};
24 |
25 | /**
26 | * Terminates the events world.
27 | */
28 | glam.TweenService.prototype.terminate = function() {};
29 |
30 |
31 | /**
32 | * Updates the TweenService.
33 | */
34 | glam.TweenService.prototype.update = function()
35 | {
36 | if (window.TWEEN)
37 | TWEEN.update();
38 | }
--------------------------------------------------------------------------------
/src/behaviors/behavior.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Behavior component - base class for time-based behaviors
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.Behavior');
8 | goog.require('glam.Component');
9 |
10 | glam.Behavior = function(param) {
11 | param = param || {};
12 | this.startTime = 0;
13 | this.running = false;
14 | this.loop = (param.loop !== undefined) ? param.loop : false;
15 | this.autoStart = (param.autoStart !== undefined) ? param.autoStart : false;
16 | glam.Component.call(this, param);
17 | }
18 |
19 | goog.inherits(glam.Behavior, glam.Component);
20 |
21 | glam.Behavior.prototype._componentCategory = "behaviors";
22 |
23 | glam.Behavior.prototype.realize = function()
24 | {
25 | glam.Component.prototype.realize.call(this);
26 |
27 | if (this.autoStart)
28 | this.start();
29 | }
30 |
31 | glam.Behavior.prototype.start = function()
32 | {
33 | this.startTime = glam.Time.instance.currentTime;
34 | this.running = true;
35 | }
36 |
37 | glam.Behavior.prototype.stop = function()
38 | {
39 | this.startTime = 0;
40 | this.running = false;
41 | }
42 |
43 | glam.Behavior.prototype.toggle = function()
44 | {
45 | if (this.running)
46 | this.stop();
47 | else
48 | this.start();
49 | }
50 |
51 | glam.Behavior.prototype.update = function()
52 | {
53 | if (this.running)
54 | {
55 | // N.B.: soon, add logic to subtract suspend times
56 | var now = glam.Time.instance.currentTime;
57 | var elapsedTime = (now - this.startTime) / 1000;
58 |
59 | this.evaluate(elapsedTime);
60 | }
61 | }
62 |
63 | glam.Behavior.prototype.evaluate = function(t)
64 | {
65 | if (glam.Behavior.WARN_ON_ABSTRACT)
66 | glam.System.warn("Abstract Behavior.evaluate called");
67 | }
68 |
69 | glam.Behavior.WARN_ON_ABSTRACT = true;
70 |
--------------------------------------------------------------------------------
/src/behaviors/highlightBehavior.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview HighlightBehavior - simple angular rotation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.HighlightBehavior');
8 | goog.require('glam.Behavior');
9 |
10 | glam.HighlightBehavior = function(param) {
11 | param = param || {};
12 | this.highlightColor = (param.highlightColor !== undefined) ? param.highlightColor : 0xffffff;
13 | this.savedColors = [];
14 | glam.Behavior.call(this, param);
15 | }
16 |
17 | goog.inherits(glam.HighlightBehavior, glam.Behavior);
18 |
19 | glam.HighlightBehavior.prototype.start = function()
20 | {
21 | glam.Behavior.prototype.start.call(this);
22 |
23 | if (this._realized && this._object.visuals) {
24 | var visuals = this._object.visuals;
25 | var i, len = visuals.length;
26 | for (i = 0; i < len; i++) {
27 | this.savedColors.push(visuals[i].material.color.getHex());
28 | visuals[i].material.color.setHex(this.highlightColor);
29 | }
30 | }
31 | }
32 |
33 | glam.HighlightBehavior.prototype.evaluate = function(t)
34 | {
35 | }
36 |
37 | glam.HighlightBehavior.prototype.stop = function()
38 | {
39 | glam.Behavior.prototype.stop.call(this);
40 |
41 | if (this._realized && this._object.visuals)
42 | {
43 | var visuals = this._object.visuals;
44 | var i, len = visuals.length;
45 | for (i = 0; i < len; i++) {
46 | visuals[i].material.color.setHex(this.savedColors[i]);
47 | }
48 | }
49 |
50 | }
51 |
52 | // Alias a few functions - syntactic sugar
53 | glam.HighlightBehavior.prototype.on = glam.HighlightBehavior.prototype.start;
54 | glam.HighlightBehavior.prototype.off = glam.HighlightBehavior.prototype.stop;
55 |
--------------------------------------------------------------------------------
/src/behaviors/moveBehavior.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview MoveBehavior - simple angular rotation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.MoveBehavior');
8 | goog.require('glam.Behavior');
9 |
10 | glam.MoveBehavior = function(param) {
11 | param = param || {};
12 | this.duration = (param.duration !== undefined) ? param.duration : 1;
13 | this.moveVector = (param.moveVector !== undefined) ? param.moveVector : new THREE.Vector3(0, 1, 0);
14 | this.tween = null;
15 | glam.Behavior.call(this, param);
16 | }
17 |
18 | goog.inherits(glam.MoveBehavior, glam.Behavior);
19 |
20 | glam.MoveBehavior.prototype.start = function()
21 | {
22 | if (this.running)
23 | return;
24 |
25 | this.movePosition = new THREE.Vector3;
26 | this.moveEndPosition = this.moveVector.clone();
27 | this.prevMovePosition = new THREE.Vector3;
28 | this.moveDelta = new THREE.Vector3;
29 | this.tween = new TWEEN.Tween(this.movePosition).to(this.moveEndPosition, this.duration * 1000)
30 | .easing(TWEEN.Easing.Quadratic.InOut)
31 | .repeat(0)
32 | .start();
33 |
34 | glam.Behavior.prototype.start.call(this);
35 | }
36 |
37 | glam.MoveBehavior.prototype.evaluate = function(t)
38 | {
39 | if (t >= this.duration)
40 | {
41 | this.stop();
42 | if (this.loop) {
43 | this.start();
44 | }
45 | else {
46 | this.dispatchEvent("complete");
47 | }
48 | }
49 |
50 | this.moveDelta.copy(this.movePosition).sub(this.prevMovePosition);
51 | this.prevMovePosition.copy(this.movePosition);
52 | this._object.transform.position.add(this.moveDelta);
53 | }
54 |
55 |
56 | glam.MoveBehavior.prototype.stop = function()
57 | {
58 | if (this.tween)
59 | this.tween.stop();
60 |
61 | glam.Behavior.prototype.stop.call(this);
62 | }
--------------------------------------------------------------------------------
/src/behaviors/rotateBehavior.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview RotateBehavior - simple angular rotation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.RotateBehavior');
8 | goog.require('glam.Behavior');
9 |
10 | glam.RotateBehavior = function(param) {
11 | param = param || {};
12 | this.duration = (param.duration !== undefined) ? param.duration : 1;
13 | this.velocity = (param.velocity !== undefined) ? param.velocity : (Math.PI / 2 / this.duration);
14 | this.startAngle = 0;
15 | this.angle = 0;
16 | glam.Behavior.call(this, param);
17 | }
18 |
19 | goog.inherits(glam.RotateBehavior, glam.Behavior);
20 |
21 | glam.RotateBehavior.prototype.start = function()
22 | {
23 | this.angle = 0;
24 | this._object.transform.rotation.y = this._object.transform.rotation.y % (Math.PI * 2);
25 | this.startAngle = this._object.transform.rotation.y;
26 |
27 | glam.Behavior.prototype.start.call(this);
28 | }
29 |
30 | glam.RotateBehavior.prototype.evaluate = function(t)
31 | {
32 | var twopi = Math.PI * 2;
33 | this.angle = this.velocity * t;
34 | if (this.angle >= twopi)
35 | {
36 | if (this.once)
37 | this.angle = twopi;
38 | else
39 | this.angle = this.angle % twopi;
40 | }
41 |
42 | this._object.transform.rotation.y = this.startAngle + this.angle;
43 |
44 | if (this.once && this.angle >= twopi)
45 | {
46 | this.stop();
47 | }
48 | }
--------------------------------------------------------------------------------
/src/behaviors/scaleBehavior.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview ScaleBehavior - simple scale up/down over time
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.ScaleBehavior');
8 | goog.require('glam.Behavior');
9 |
10 | glam.ScaleBehavior = function(param) {
11 | param = param || {};
12 | this.duration = (param.duration !== undefined) ? param.duration : 1;
13 | this.startScale = (param.startScale !== undefined) ? param.startScale.clone() :
14 | new THREE.Vector3(1, 1, 1);
15 | this.endScale = (param.endScale !== undefined) ? param.endScale.clone() :
16 | new THREE.Vector3(2, 2, 2);
17 | this.tween = null;
18 | glam.Behavior.call(this, param);
19 | }
20 |
21 | goog.inherits(glam.ScaleBehavior, glam.Behavior);
22 |
23 | glam.ScaleBehavior.prototype.start = function()
24 | {
25 | if (this.running)
26 | return;
27 |
28 | this.scale = this.startScale.clone();
29 | this.originalScale = this._object.transform.scale.clone();
30 | this.tween = new TWEEN.Tween(this.scale).to(this.endScale, this.duration * 1000)
31 | .easing(TWEEN.Easing.Quadratic.InOut)
32 | .repeat(0)
33 | .start();
34 |
35 | glam.Behavior.prototype.start.call(this);
36 | }
37 |
38 | glam.ScaleBehavior.prototype.evaluate = function(t)
39 | {
40 | if (t >= this.duration)
41 | {
42 | this.stop();
43 | if (this.loop) {
44 | this.start();
45 | }
46 | else {
47 | this.dispatchEvent("complete");
48 | }
49 | }
50 |
51 | var sx = this.originalScale.x * this.scale.x;
52 | var sy = this.originalScale.y * this.scale.y;
53 | var sz = this.originalScale.z * this.scale.z;
54 |
55 | this._object.transform.scale.set(sx, sy, sz);
56 | }
57 |
58 |
59 | glam.ScaleBehavior.prototype.stop = function()
60 | {
61 | if (this.tween)
62 | this.tween.stop();
63 |
64 | glam.Behavior.prototype.stop.call(this);
65 | }
--------------------------------------------------------------------------------
/src/cameras/camera.js:
--------------------------------------------------------------------------------
1 | goog.provide('glam.Camera');
2 | goog.require('glam.SceneComponent');
3 |
4 | glam.Camera = function(param)
5 | {
6 | param = param || {};
7 |
8 | glam.SceneComponent.call(this, param);
9 |
10 | // Accessors
11 | Object.defineProperties(this, {
12 | active: {
13 | get: function() {
14 | return this._active;
15 | },
16 | set: function(v) {
17 | this._active = v;
18 | // N.B.: trying this out for now... TP
19 | if (/*this._realized && */ this._active)
20 | {
21 | glam.CameraManager.setActiveCamera(this);
22 | }
23 | }
24 | },
25 |
26 | });
27 |
28 | this._active = param.active || false;
29 | var position = param.position || glam.Camera.DEFAULT_POSITION;
30 | //this.position.copy(position);
31 | }
32 |
33 | goog.inherits(glam.Camera, glam.SceneComponent);
34 |
35 | glam.Camera.prototype._componentProperty = "camera";
36 | glam.Camera.prototype._componentPropertyType = "Camera";
37 |
38 | glam.Camera.prototype.realize = function()
39 | {
40 | glam.SceneComponent.prototype.realize.call(this);
41 |
42 | this.addToScene();
43 |
44 | glam.CameraManager.addCamera(this);
45 |
46 | if (this._active && !glam.CameraManager.activeCamera)
47 | {
48 | glam.CameraManager.setActiveCamera(this);
49 | }
50 | }
51 |
52 | glam.Camera.prototype.lookAt = function(v)
53 | {
54 | this.object.lookAt(v);
55 | }
56 |
57 | glam.Camera.DEFAULT_POSITION = new THREE.Vector3(0, 0, 0);
58 | glam.Camera.DEFAULT_NEAR = 1;
59 | glam.Camera.DEFAULT_FAR = 10000;
60 |
--------------------------------------------------------------------------------
/src/cameras/cameraManager.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Camera Manager - singleton to manage cameras, active, resize etc.
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.CameraManager');
8 |
9 | glam.CameraManager.addCamera = function(camera)
10 | {
11 | glam.CameraManager.cameraList.push(camera);
12 | }
13 |
14 | glam.CameraManager.removeCamera = function(camera)
15 | {
16 | var i = glam.CameraManager.cameraList.indexOf(camera);
17 |
18 | if (i != -1)
19 | {
20 | glam.CameraManager.cameraList.splice(i, 1);
21 | }
22 | }
23 |
24 | glam.CameraManager.setActiveCamera = function(camera)
25 | {
26 | if (glam.CameraManager.activeCamera && glam.CameraManager.activeCamera != camera)
27 | glam.CameraManager.activeCamera.active = false;
28 |
29 | glam.CameraManager.activeCamera = camera;
30 | glam.Graphics.instance.setCamera(camera.object);
31 | }
32 |
33 |
34 | glam.CameraManager.handleWindowResize = function(width, height)
35 | {
36 | var cameras = glam.CameraManager.cameraList;
37 |
38 | if (cameras.length == 0)
39 | return false;
40 |
41 | var i, len = cameras.length;
42 | for (i = 0; i < len; i++)
43 | {
44 | var camera = cameras[i];
45 | camera.aspect = width / height;
46 | }
47 |
48 | return true;
49 | }
50 |
51 |
52 | glam.CameraManager.cameraList = [];
53 | glam.CameraManager.activeCamera = null;
--------------------------------------------------------------------------------
/src/config/nodeps.js:
--------------------------------------------------------------------------------
1 | var CLOSURE_NO_DEPS = true;
2 |
--------------------------------------------------------------------------------
/src/core/component.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Component is the base class for defining capabilities used within an Object
3 | *
4 | * @author Tony Parisi
5 | */
6 | goog.provide('glam.Component');
7 | goog.require('glam.EventDispatcher');
8 |
9 | /**
10 | * Creates a new Component.
11 | * @constructor
12 | */
13 | glam.Component = function(param) {
14 | glam.EventDispatcher.call(this);
15 |
16 | param = param || {};
17 |
18 | /**
19 | * @type {glam.Object}
20 | * @private
21 | */
22 | this._object = null;
23 |
24 | /**
25 | * @type {Boolean}
26 | * @private
27 | */
28 | this._realized = false;
29 | }
30 |
31 | goog.inherits(glam.Component, glam.EventDispatcher);
32 |
33 | /**
34 | * Gets the Object the Component is associated with.
35 | * @returns {glam.Object} The Object the Component is associated with.
36 | */
37 | glam.Component.prototype.getObject = function() {
38 | return this._object;
39 | }
40 |
41 | /**
42 | * Sets the Object the Component is associated with.
43 | * @param {glam.Object} object
44 | */
45 | glam.Component.prototype.setObject = function(object) {
46 | this._object = object;
47 | }
48 |
49 | glam.Component.prototype.realize = function() {
50 | this._realized = true;
51 | }
52 |
53 | glam.Component.prototype.update = function() {
54 | }
55 |
--------------------------------------------------------------------------------
/src/core/glam.js:
--------------------------------------------------------------------------------
1 | goog.provide('glam');
2 |
3 | glam.loadUrl = function(url, element, options) {
4 |
5 | options = options || {};
6 | options.container = element;
7 | var viewer = new glam.Viewer(options);
8 | var loader = new glam.Loader;
9 | loader.addEventListener("loaded", function(data) { onLoadComplete(data, loadStartTime); });
10 | loader.addEventListener("progress", function(progress) { onLoadProgress(progress); });
11 | var loadStartTime = Date.now();
12 | loader.loadScene(url);
13 | viewer.run();
14 |
15 | function onLoadComplete(data, loadStartTime) {
16 | var loadTime = (Date.now() - loadStartTime) / 1000;
17 | glam.System.log("glam.loadUrl, scene loaded in ", loadTime, " seconds.");
18 | viewer.replaceScene(data);
19 | if (viewer.cameras.length > 1) {
20 | viewer.useCamera(1);
21 | }
22 |
23 | if (options.headlight) {
24 | viewer.setHeadlightOn(true);
25 | }
26 | }
27 |
28 | function onLoadProgress(progress) {
29 | var percentProgress = progress.loaded / progress.total * 100;
30 | glam.System.log("glam.loadUrl, ", percentProgress, " % loaded.");
31 | }
32 |
33 | return { viewer : viewer };
34 | }
35 |
36 | glam.ready = function() {
37 | glam.DOM.ready();
38 | }
39 |
40 |
41 | glam.setFullScreen = function(enable) {
42 | return glam.Graphics.instance.setFullScreen(enable);
43 | }
--------------------------------------------------------------------------------
/src/core/service.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @author Tony Parisi
3 | */
4 | goog.provide('glam.Service');
5 |
6 | /**
7 | * Interface for a Service.
8 | *
9 | * Allows multiple different backends for the same type of service.
10 | * @interface
11 | */
12 | glam.Service = function() {};
13 |
14 | //---------------------------------------------------------------------
15 | // Initialization/Termination
16 | //---------------------------------------------------------------------
17 |
18 | /**
19 | * Initializes the Service - Abstract.
20 | */
21 | glam.Service.prototype.initialize = function(param) {};
22 |
23 | /**
24 | * Terminates the Service - Abstract.
25 | */
26 | glam.Service.prototype.terminate = function() {};
27 |
28 |
29 | /**
30 | * Updates the Service - Abstract.
31 | */
32 | glam.Service.prototype.update = function() {};
--------------------------------------------------------------------------------
/src/core/services.js:
--------------------------------------------------------------------------------
1 |
2 | /**
3 | * @fileoverview Service locator for various game services.
4 | */
5 | goog.provide('glam.Services');
6 | goog.require('glam.Time');
7 | goog.require('glam.Input');
8 | goog.require('glam.TweenService');
9 | goog.require('glam.EventService');
10 | goog.require('glam.GraphicsThreeJS');
11 |
12 | glam.Services = {};
13 |
14 | glam.Services._serviceMap =
15 | {
16 | "time" : { object : glam.Time },
17 | "input" : { object : glam.Input },
18 | "tween" : { object : glam.TweenService },
19 | "events" : { object : glam.EventService },
20 | "graphics" : { object : glam.GraphicsThreeJS },
21 | };
22 |
23 | glam.Services.create = function(serviceName)
24 | {
25 | var serviceType = glam.Services._serviceMap[serviceName];
26 | if (serviceType)
27 | {
28 | var prop = serviceType.property;
29 |
30 | if (glam.Services[serviceName])
31 | {
32 | throw new Error('Cannot create two ' + serviceName + ' service instances');
33 | }
34 | else
35 | {
36 | if (serviceType.object)
37 | {
38 | var service = new serviceType.object;
39 | glam.Services[serviceName] = service;
40 |
41 | return service;
42 | }
43 | else
44 | {
45 | throw new Error('No object type supplied for creating service ' + serviceName + '; cannot create');
46 | }
47 | }
48 | }
49 | else
50 | {
51 | throw new Error('Unknown service: ' + serviceName + '; cannot create');
52 | }
53 | }
54 |
55 | glam.Services.registerService = function(serviceName, object)
56 | {
57 | if (glam.Services._serviceMap[serviceName])
58 | {
59 | throw new Error('Service ' + serviceName + 'already registered; cannot register twice');
60 | }
61 | else
62 | {
63 | var serviceType = { object: object };
64 | glam.Services._serviceMap[serviceName] = serviceType;
65 | }
66 | }
--------------------------------------------------------------------------------
/src/dom/box.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview cube primitive parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.BoxElement');
8 |
9 | glam.BoxElement.DEFAULT_WIDTH = 2;
10 | glam.BoxElement.DEFAULT_HEIGHT = 2;
11 | glam.BoxElement.DEFAULT_DEPTH = 2;
12 |
13 | glam.BoxElement.create = function(docelt, style) {
14 | return glam.VisualElement.create(docelt, style, glam.BoxElement);
15 | }
16 |
17 | glam.BoxElement.getAttributes = function(docelt, style, param) {
18 |
19 | var width = docelt.getAttribute('width') || glam.BoxElement.DEFAULT_WIDTH;
20 | var height = docelt.getAttribute('height') || glam.BoxElement.DEFAULT_HEIGHT;
21 | var depth = docelt.getAttribute('depth') || glam.BoxElement.DEFAULT_DEPTH;
22 |
23 | if (style) {
24 | if (style.width)
25 | width = style.width
26 | if (style.height)
27 | height = style.height;
28 | if (style.depth)
29 | depth = style.depth;
30 | }
31 |
32 | width = parseFloat(width);
33 | height = parseFloat(height);
34 | depth = parseFloat(depth);
35 |
36 | param.width = width;
37 | param.height = height;
38 | param.depth = depth;
39 | }
40 |
41 | glam.BoxElement.createVisual = function(docelt, material, param) {
42 |
43 | var visual = new glam.Visual(
44 | { geometry: new THREE.BoxGeometry(param.width, param.height, param.depth),
45 | material: material
46 | });
47 |
48 | return visual;
49 | }
50 |
--------------------------------------------------------------------------------
/src/dom/camera.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview camera parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.CameraElement');
8 |
9 | glam.CameraElement.DEFAULT_FOV = 45;
10 | glam.CameraElement.DEFAULT_NEAR = 1;
11 | glam.CameraElement.DEFAULT_FAR = 10000;
12 |
13 | glam.CameraElement.create = function(docelt, style, app) {
14 |
15 | var fov = docelt.getAttribute('fov') || glam.CameraElement.DEFAULT_FOV;
16 | var near = docelt.getAttribute('near') || glam.CameraElement.DEFAULT_NEAR;
17 | var far = docelt.getAttribute('far') || glam.CameraElement.DEFAULT_FAR;
18 | var aspect = docelt.getAttribute('aspect');
19 |
20 | if (style) {
21 | if (style.fov)
22 | fov = style.fov;
23 | if (style.near)
24 | near = style.near;
25 | if (style.far)
26 | far = style.far;
27 | if (style.aspect)
28 | aspect = style.aspect;
29 | }
30 |
31 | fov = parseFloat(fov);
32 | near = parseFloat(near);
33 | far = parseFloat(far);
34 |
35 | var param = {
36 | fov : fov,
37 | near : near,
38 | far : far,
39 | };
40 |
41 | if (aspect) {
42 | aspect = parseFloat(aspect);
43 | param.aspect = aspect;
44 | }
45 |
46 | var camera = new glam.Object;
47 | var cam = new glam.PerspectiveCamera(param);
48 | camera.addComponent(cam);
49 |
50 | app.addCamera(cam, docelt.id);
51 |
52 | return camera;
53 | }
54 |
--------------------------------------------------------------------------------
/src/dom/circle.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview 2D circle parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.CircleElement');
8 |
9 | glam.CircleElement.DEFAULT_RADIUS = 2;
10 | glam.CircleElement.DEFAULT_RADIUS_SEGMENTS = 32;
11 |
12 | glam.CircleElement.create = function(docelt, style) {
13 | return glam.VisualElement.create(docelt, style, glam.CircleElement);
14 | }
15 |
16 | glam.CircleElement.getAttributes = function(docelt, style, param) {
17 |
18 | var radius = docelt.getAttribute('radius') || glam.CircleElement.DEFAULT_RADIUS;
19 | var radiusSegments = docelt.getAttribute('radiusSegments') || glam.CircleElement.DEFAULT_RADIUS_SEGMENTS;
20 |
21 | if (style) {
22 | if (style.radius)
23 | radius = style.radius;
24 | if (style.radiusSegments)
25 | radiusSegments = style.radiusSegments;
26 | }
27 |
28 | radius = parseFloat(radius);
29 | radiusSegments = parseInt(radiusSegments);
30 |
31 | param.radius = radius;
32 | param.radiusSegments = radiusSegments;
33 | }
34 |
35 | glam.CircleElement.createVisual = function(docelt, material, param) {
36 |
37 | var visual = new glam.Visual(
38 | { geometry: new THREE.CircleGeometry(param.radius, param.radiusSegments),
39 | material: material
40 | });
41 |
42 | return visual;
43 | }
44 |
--------------------------------------------------------------------------------
/src/dom/classList.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview class list - emulate DOM classList property for glam
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.DOMClassList');
8 |
9 | glam.DOMClassList = function(docelt) {
10 | this.docelt = docelt;
11 | Array.call(this);
12 | }
13 |
14 | glam.DOMClassList.prototype = new Array;
15 |
16 | glam.DOMClassList.prototype.item = function(i) {
17 | return this[i];
18 | }
19 |
20 | glam.DOMClassList.prototype.add = function(item) {
21 | return this.push(item);
22 | }
23 |
24 | glam.DOMClassList.prototype.remove = function(item) {
25 | var i = this.indexOf(item);
26 | if (i != -1) {
27 | this.splice(i, 1)
28 | }
29 | }
30 |
31 |
--------------------------------------------------------------------------------
/src/dom/cone.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview cone primitive parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.ConeElement');
8 |
9 | glam.ConeElement.DEFAULT_RADIUS = 2;
10 | glam.ConeElement.DEFAULT_HEIGHT = 2;
11 |
12 | glam.ConeElement.create = function(docelt, style) {
13 | return glam.VisualElement.create(docelt, style, glam.ConeElement);
14 | }
15 |
16 | glam.ConeElement.getAttributes = function(docelt, style, param) {
17 |
18 | var radius = docelt.getAttribute('radius') || glam.ConeElement.DEFAULT_RADIUS;
19 | var height = docelt.getAttribute('height') || glam.ConeElement.DEFAULT_HEIGHT;
20 |
21 | if (style) {
22 | if (style.radius)
23 | radius = style.radius;
24 | if (style.height)
25 | height = style.height;
26 | }
27 |
28 | radius = parseFloat(radius);
29 | height = parseFloat(height);
30 |
31 | param.radius = radius;
32 | param.height = height;
33 | }
34 |
35 | glam.ConeElement.createVisual = function(docelt, material, param) {
36 |
37 | var visual = new glam.Visual(
38 | { geometry: new THREE.CylinderGeometry(0, param.radius, param.height, 32),
39 | material: material
40 | });
41 |
42 | return visual;
43 | }
44 |
--------------------------------------------------------------------------------
/src/dom/cylinder.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview cylinder parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.CylinderElement');
8 |
9 | glam.CylinderElement.DEFAULT_RADIUS = 2;
10 | glam.CylinderElement.DEFAULT_HEIGHT = 2;
11 |
12 | glam.CylinderElement.create = function(docelt, style) {
13 | return glam.VisualElement.create(docelt, style, glam.CylinderElement);
14 | }
15 |
16 | glam.CylinderElement.getAttributes = function(docelt, style, param) {
17 |
18 | var radius = docelt.getAttribute('radius') || glam.CylinderElement.DEFAULT_RADIUS;
19 | var height = docelt.getAttribute('height') || glam.CylinderElement.DEFAULT_HEIGHT;
20 |
21 | if (style) {
22 | if (style.radius)
23 | radius = style.radius;
24 | if (style.height)
25 | height = style.height;
26 | }
27 |
28 | radius = parseFloat(radius);
29 | height = parseFloat(height);
30 | param.radius = radius;
31 | param.height = height;
32 | }
33 |
34 | glam.CylinderElement.createVisual = function(docelt, material, param) {
35 |
36 | var visual = new glam.Visual(
37 | { geometry: new THREE.CylinderGeometry(param.radius, param.radius, param.height, 32),
38 | material: material
39 | });
40 |
41 | return visual;
42 | }
43 |
--------------------------------------------------------------------------------
/src/dom/document.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview glam document class
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.DOMDocument');
8 |
9 | glam.DOMDocument = {
10 |
11 | scenes : {},
12 |
13 | styles : [],
14 |
15 | animations : {},
16 |
17 | addScene : function(script, scene)
18 | {
19 | glam.DOMDocument.scenes[script.id] = { parentElement : script.parentElement, scene : scene };
20 | },
21 |
22 | addStyle : function(declaration)
23 | {
24 | glam.DOMDocument.styles.push(declaration);
25 | },
26 |
27 | addAnimation : function(id, animation)
28 | {
29 | glam.DOMDocument.animations[id] = animation;
30 | },
31 |
32 | parseDocument : function()
33 | {
34 | var dp = new DOMParser;
35 |
36 | var i, len;
37 |
38 | var scripts = document.getElementsByTagName("script");
39 | var len = scripts.length;
40 | for (i = 0; i < len; i++)
41 | {
42 | if (scripts[i].type == "text/glam")
43 | {
44 | var scene = dp.parseFromString(scripts[i].textContent, "text/xml");
45 | glam.DOMDocument.addScene(scripts[i], scene);
46 | }
47 | }
48 |
49 | var styles = document.head.getElementsByTagName("style");
50 | var len = styles.length;
51 | for (i = 0; i < len; i++)
52 | {
53 | {
54 | glam.CSSParser.parsecss(styles[i].childNodes[0].data,
55 | function(css) {
56 | glam.DOMDocument.addStyle(css);
57 | }
58 | );
59 | }
60 | }
61 | },
62 | };
63 |
--------------------------------------------------------------------------------
/src/dom/dom.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview glam namespace and globals
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 |
8 | goog.provide('glam.DOM');
9 |
10 | glam.DOM = {
11 |
12 | documents : {},
13 |
14 | documentIndex : 0,
15 |
16 | styles : {},
17 |
18 | viewers : {},
19 |
20 | animations : {},
21 |
22 | };
23 |
24 | glam.DOM.isReady = false;
25 | glam.DOM.ready = function() {
26 | if (glam.DOM.isReady)
27 | return;
28 |
29 | glam.DOMParser.parseDocument();
30 | glam.DOM.createViewers();
31 |
32 | glam.DOM.isReady = true;
33 | }
34 |
35 | glam.DOM.createViewers = function() {
36 | for (var docname in glam.DOM.documents) {
37 | var doc = glam.DOM.documents[docname];
38 | var viewer = new glam.DOMViewer(doc);
39 | glam.DOM.viewers[docname] = viewer;
40 | viewer.go();
41 | }
42 | }
43 |
44 |
45 | glam.DOM.addStyle = function(selector, style)
46 | {
47 | glam.DOM.styles[selector] = style;
48 | }
49 |
50 | glam.DOM.getStyle = function(selector)
51 | {
52 | return glam.DOM.styles[selector];
53 | }
54 |
55 | glam.DOM.addAnimation = function(id, animation)
56 | {
57 | glam.DOM.animations[id] = animation;
58 | }
59 |
60 | glam.DOM.getAnimation = function(id) {
61 | return glam.DOM.animations[id];
62 | }
63 |
64 | window.addEventListener('load',
65 | function() {
66 | glam.DOM.ready();
67 | },
68 | false);
69 |
70 |
--------------------------------------------------------------------------------
/src/dom/group.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview grouping element parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.GroupElement');
8 |
9 | glam.GroupElement.create = function(docelt, style) {
10 |
11 | // Create the group
12 | var group = new glam.Object;
13 |
14 | return group;
15 | }
16 |
--------------------------------------------------------------------------------
/src/dom/import.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview model import parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 |
8 | goog.provide('glam.ImportElement');
9 |
10 | glam.ImportElement.create = function(docelt, style) {
11 | var src = docelt.getAttribute('src');
12 |
13 | // Create the cube
14 | var obj = new glam.Object;
15 |
16 | if (src) {
17 | var loader = new glam.Loader;
18 |
19 | var loadCallback = function(data) {
20 | glam.ImportElement.onLoadComplete(obj, data, src);
21 | loader.removeEventListener("loaded", loadCallback);
22 | }
23 |
24 | loader.addEventListener("loaded", loadCallback);
25 | loader.loadScene(src);
26 | }
27 |
28 | return obj;
29 | }
30 |
31 | glam.ImportElement.onLoadComplete = function(obj, data, url) {
32 |
33 | obj.addChild(data.scene);
34 | }
35 |
--------------------------------------------------------------------------------
/src/dom/input.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview mouse input implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.DOMInput');
8 |
9 | glam.DOMInput = {};
10 |
11 | glam.DOMInput.add = function(docelt, obj) {
12 |
13 | function addListener(picker, evt) {
14 | picker.addEventListener(evt, function(event){
15 | var domEvent = new CustomEvent(
16 | evt,
17 | {
18 | detail: {
19 | },
20 | bubbles: true,
21 | cancelable: true
22 | }
23 | );
24 | for (var propName in event) {
25 | if (domEvent[propName] === undefined) {
26 | domEvent[propName] = event[propName];
27 | }
28 | else {
29 | ; // console.log("Skipping prop", propName);
30 | }
31 | }
32 | var res = docelt.dispatchEvent(domEvent);
33 |
34 | });
35 | }
36 |
37 | var picker = new glam.Picker;
38 |
39 | var events = ["click", "mouseover", "mouseout", "mousedown", "mouseup", "mousemove",
40 | "touchstart", "touchend"];
41 | for (var index in events) {
42 | var evt = events[index];
43 | addListener(picker, evt);
44 | }
45 |
46 | obj.addComponent(picker);
47 |
48 | var viewpicker = new glam.ViewPicker;
49 | obj.addComponent(viewpicker);
50 | addListener(viewpicker, "viewover")
51 | addListener(viewpicker, "viewout");
52 | }
53 |
--------------------------------------------------------------------------------
/src/dom/line.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview line primitive parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.LineElement');
8 |
9 | glam.LineElement.create = function(docelt, style) {
10 |
11 | var material = glam.DOMMaterial.create(style, null, "line");
12 |
13 | var geometry = new THREE.Geometry;
14 |
15 | glam.LineElement.parse(docelt, geometry, material);
16 |
17 | var line = new THREE.Line(geometry, material);
18 |
19 | var obj = new glam.Object;
20 | var visual = new glam.Visual(
21 | {
22 | object : line,
23 | });
24 | obj.addComponent(visual);
25 |
26 | // Is this the API?
27 | docelt.geometry = geometry;
28 | docelt.material = material;
29 |
30 | return obj;
31 | }
32 |
33 | glam.LineElement.parse = function(docelt, geometry, material) {
34 |
35 | var verts = docelt.getElementsByTagName('vertices');
36 | if (verts) {
37 | verts = verts[0];
38 | glam.DOMTypes.parseVector3Array(verts, geometry.vertices);
39 | }
40 |
41 | var vertexColors = [];
42 | var colors = docelt.getElementsByTagName('colors');
43 | if (colors) {
44 | colors = colors[0];
45 | if (colors) {
46 | glam.DOMTypes.parseColor3Array(colors, vertexColors);
47 |
48 | var i, len = vertexColors.length;
49 |
50 | for (i = 0; i < len; i++) {
51 | var c = vertexColors[i];
52 | geometry.colors.push(c.clone());
53 | }
54 |
55 | material.vertexColors = THREE.VertexColors;
56 | }
57 | }
58 |
59 |
60 | }
61 |
62 |
--------------------------------------------------------------------------------
/src/dom/node.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview base node class
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.DOMElement');
8 |
9 | glam.DOMElement.init = function(docelt) {
10 |
11 | docelt.glam = {
12 | };
13 |
14 | docelt.glam.setAttributeHandlers = [];
15 | docelt.glam.onSetAttribute = function(attr, val) {
16 | var i, len = docelt.glam.setAttributeHandlers.length;
17 | for (i = 0; i < len; i++) {
18 | var handler = docelt.glam.setAttributeHandlers[i];
19 | if (handler) {
20 | handler(attr, val);
21 | }
22 | }
23 | }
24 | }
25 |
26 | glam.DOMElement.getStyle = function(docelt) {
27 |
28 | var glamClassList = new glam.DOMClassList(docelt);
29 | docelt.glam.classList = glamClassList;
30 |
31 | var style = new glam.DOMStyle(docelt);
32 |
33 | if (docelt.id) {
34 | var styl = glam.DOM.getStyle("#" + docelt.id);
35 | style.addProperties(styl);
36 | }
37 |
38 | var klass = docelt.getAttribute('class');
39 | if (!klass)
40 | klass = docelt['class'];
41 |
42 | if (klass) {
43 |
44 | var klasses = klass.split(" ");
45 | for (var klassname in klasses) {
46 | var kls = klasses[klassname];
47 | if (kls) {
48 | var styl = glam.DOM.getStyle("." + kls);
49 | style.addProperties(styl);
50 |
51 | glamClassList.add(kls);
52 | }
53 | }
54 | }
55 |
56 | var styl = docelt.getAttribute("style");
57 | if (styl) {
58 | style.addPropertiesFromString(styl);
59 | }
60 |
61 | docelt.glam.style = style;
62 |
63 | return style;
64 | }
65 |
--------------------------------------------------------------------------------
/src/dom/rect.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview 2D rectangle parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 |
8 | goog.provide('glam.RectElement');
9 |
10 | glam.RectElement.DEFAULT_WIDTH = 2;
11 | glam.RectElement.DEFAULT_HEIGHT = 2;
12 | glam.RectElement.DEFAULT_WIDTH_SEGMENTS = 1;
13 | glam.RectElement.DEFAULT_HEIGHT_SEGMENTS = 1;
14 |
15 | glam.RectElement.create = function(docelt, style) {
16 | return glam.VisualElement.create(docelt, style, glam.RectElement);
17 | }
18 |
19 | glam.RectElement.getAttributes = function(docelt, style, param) {
20 |
21 | var width = docelt.getAttribute('width') || glam.RectElement.DEFAULT_WIDTH;
22 | var height = docelt.getAttribute('height') || glam.RectElement.DEFAULT_HEIGHT;
23 | var widthSegments = docelt.getAttribute('width') || glam.RectElement.DEFAULT_WIDTH_SEGMENTS;
24 | var heightSegments = docelt.getAttribute('height') || glam.RectElement.DEFAULT_HEIGHT_SEGMENTS;
25 |
26 | if (style) {
27 | if (style.width)
28 | width = style.width;
29 | if (style.height)
30 | height = style.height;
31 | if (style.widthSegments)
32 | widthSegments = style.widthSegments;
33 | if (style.heightSegments)
34 | heightSegments = style.heightSegments;
35 | }
36 |
37 | width = parseFloat(width);
38 | height = parseFloat(height);
39 | widthSegments = parseInt(widthSegments);
40 | heightSegments = parseInt(heightSegments);
41 |
42 | param.width = width;
43 | param.height = height;
44 | param.widthSegments = widthSegments;
45 | param.heightSegments = heightSegments;
46 | }
47 |
48 | glam.RectElement.createVisual = function(docelt, material, param) {
49 |
50 | var visual = new glam.Visual(
51 | { geometry: new THREE.PlaneGeometry(param.width, param.height, param.widthSegments, param.heightSegments),
52 | material: material
53 | });
54 |
55 | return visual;
56 | }
57 |
--------------------------------------------------------------------------------
/src/dom/renderer.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview renderer parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.DOMRenderer');
8 |
9 | glam.DOMRenderer = {
10 | };
11 |
--------------------------------------------------------------------------------
/src/dom/sphere.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview sphere primitive parser/implementation
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.SphereElement');
8 |
9 | glam.SphereElement.DEFAULT_RADIUS = 2;
10 | glam.SphereElement.DEFAULT_WIDTH_SEGMENTS = 32;
11 | glam.SphereElement.DEFAULT_HEIGHT_SEGMENTS = 32;
12 |
13 | glam.SphereElement.create = function(docelt, style) {
14 | return glam.VisualElement.create(docelt, style, glam.SphereElement);
15 | }
16 |
17 | glam.SphereElement.getAttributes = function(docelt, style, param) {
18 |
19 | var radius = docelt.getAttribute('radius') || glam.SphereElement.DEFAULT_RADIUS;
20 | var widthSegments = docelt.getAttribute('width-segments') || glam.SphereElement.DEFAULT_WIDTH_SEGMENTS;
21 | var heightSegments = docelt.getAttribute('height-segments') || glam.SphereElement.DEFAULT_HEIGHT_SEGMENTS;
22 |
23 | if (style) {
24 | if (style.radius)
25 | radius = style.radius;
26 | if (style.widthSegments || style["width-segments"])
27 | widthSegments = style.widthSegments || style["width-segments"];
28 | if (style.heightSegments || style["height-segments"])
29 | heightSegments = style.heightSegments || style["height-segments"];
30 | }
31 |
32 | radius = parseFloat(radius);
33 | widthSegments = parseInt(widthSegments);
34 | heightSegments = parseInt(heightSegments);
35 |
36 | param.radius = radius;
37 | param.widthSegments = widthSegments;
38 | param.heightSegments = heightSegments;
39 | }
40 |
41 | glam.SphereElement.createVisual = function(docelt, material, param) {
42 |
43 | var visual = new glam.Visual(
44 | { geometry: new THREE.SphereGeometry(param.radius, param.widthSegments, param.heightSegments),
45 | material: material
46 | });
47 |
48 | return visual;
49 | }
50 |
--------------------------------------------------------------------------------
/src/dom/transition.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview transition parser/implementation - still WIP
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.TransitionElement');
8 | goog.require('glam.AnimationElement');
9 |
10 | glam.TransitionElement.DEFAULT_DURATION = glam.AnimationElement.DEFAULT_DURATION;
11 | glam.TransitionElement.DEFAULT_TIMING_FUNCTION = glam.AnimationElement.DEFAULT_TIMING_FUNCTION;
12 |
13 | // transition:transform 2s, background-color 5s linear 2s;
14 |
15 | glam.TransitionElement.parse = function(docelt, style, obj) {
16 |
17 | var transition = style.transition || "";
18 |
19 | var transitions = {
20 | };
21 |
22 | var comps = transition.split(",");
23 | var i, len = comps.length;
24 | for (i = 0; i < len; i++) {
25 | var comp = comps[i];
26 | if (comp) {
27 | var params = comp.split(" ");
28 | if (params[0] == "")
29 | params.shift();
30 | var propname = params[0];
31 | var duration = params[1];
32 | var timingFunction = params[2] || glam.TransitionElement.DEFAULT_TIMING_FUNCTION;
33 | var delay = params[3] || "";
34 |
35 | duration = glam.AnimationElement.parseTime(duration);
36 | timingFunction = glam.AnimationElement.parseTimingFunction(timingFunction);
37 | delay = glam.AnimationElement.parseTime(delay);
38 |
39 | transitions[propname] = {
40 | duration : duration,
41 | timingFunction : timingFunction,
42 | delay : delay
43 | };
44 | }
45 | }
46 |
47 | }
48 |
--------------------------------------------------------------------------------
/src/dom/visual.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview visual base type - used by all thing seen on screen
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.VisualElement');
8 |
9 | glam.VisualElement.create = function(docelt, style, cls) {
10 |
11 | var param = {
12 | };
13 |
14 | cls.getAttributes(docelt, style, param);
15 |
16 | var obj = new glam.Object;
17 |
18 | var material = glam.DOMMaterial.create(style, function(material) {
19 | glam.VisualElement.createVisual(obj, cls, docelt, material, param);
20 | });
21 |
22 | if (material) {
23 | glam.VisualElement.createVisual(obj, cls, docelt, material, param);
24 | }
25 |
26 | return obj;
27 | }
28 |
29 | glam.VisualElement.createVisual = function(obj, cls, docelt, material, param) {
30 | var visual = cls.createVisual(docelt, material, param);
31 | if (visual) {
32 | obj.addComponent(visual);
33 | glam.VisualElement.addProperties(docelt, obj);
34 | }
35 | }
36 |
37 | glam.VisualElement.addProperties = function(docelt, obj) {
38 |
39 | var visuals = obj.getComponents(glam.Visual);
40 | var visual = visuals[0];
41 |
42 | if (visual) {
43 | // Is this the API?
44 | docelt.geometry = visual.geometry;
45 | docelt.material = visual.material;
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/events/eventService.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.require('glam.Service');
5 | goog.provide('glam.EventService');
6 |
7 | /**
8 | * The EventService.
9 | *
10 | * @extends {glam.Service}
11 | */
12 | glam.EventService = function() {};
13 |
14 | goog.inherits(glam.EventService, glam.Service);
15 |
16 | //---------------------------------------------------------------------
17 | // Initialization/Termination
18 | //---------------------------------------------------------------------
19 |
20 | /**
21 | * Initializes the events system.
22 | */
23 | glam.EventService.prototype.initialize = function(param) {};
24 |
25 | /**
26 | * Terminates the events world.
27 | */
28 | glam.EventService.prototype.terminate = function() {};
29 |
30 |
31 | /**
32 | * Updates the EventService.
33 | */
34 | glam.EventService.prototype.update = function()
35 | {
36 | do
37 | {
38 | glam.EventService.eventsPending = false;
39 | glam.Application.instance.updateObjects();
40 | }
41 | while (glam.EventService.eventsPending);
42 | }
--------------------------------------------------------------------------------
/src/graphics/graphics.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Main interface to the graphics and rendering subsystem
3 | *
4 | * @author Tony Parisi
5 | */
6 | goog.provide('glam.Graphics');
7 |
8 | glam.Graphics = function()
9 | {
10 | // Freak out if somebody tries to make 2
11 | if (glam.Graphics.instance)
12 | {
13 | throw new Error('Graphics singleton already exists')
14 | }
15 |
16 | glam.Graphics.instance = this;
17 | }
18 |
19 | glam.Graphics.instance = null;
20 |
--------------------------------------------------------------------------------
/src/input/input.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.provide('glam.Input');
5 | goog.require('glam.Service');
6 | goog.require('glam.Mouse');
7 | goog.require('glam.Keyboard');
8 |
9 | glam.Input = function()
10 | {
11 | // N.B.: freak out if somebody tries to make 2
12 | // throw (...)
13 |
14 | this.mouse = new glam.Mouse();
15 | this.keyboard = new glam.Keyboard();
16 | this.gamepad = new glam.Gamepad();
17 | glam.Input.instance = this;
18 | }
19 |
20 | goog.inherits(glam.Input, glam.Service);
21 |
22 | glam.Input.prototype.update = function() {
23 | if (this.gamepad && this.gamepad.update)
24 | this.gamepad.update();
25 | }
26 |
27 | glam.Input.instance = null;
--------------------------------------------------------------------------------
/src/input/keyboard.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.provide('glam.Keyboard');
5 |
6 | glam.Keyboard = function()
7 | {
8 | // N.B.: freak out if somebody tries to make 2
9 | // throw (...)
10 |
11 | glam.Keyboard.instance = this;
12 | }
13 |
14 | glam.Keyboard.prototype.onKeyDown = function(event)
15 | {
16 | }
17 |
18 | glam.Keyboard.prototype.onKeyUp = function(event)
19 | {
20 | }
21 |
22 | glam.Keyboard.prototype.onKeyPress = function(event)
23 | {
24 | }
25 |
26 | glam.Keyboard.instance = null;
27 |
28 | /* key codes
29 | 37: left
30 | 38: up
31 | 39: right
32 | 40: down
33 | */
34 | glam.Keyboard.KEY_LEFT = 37;
35 | glam.Keyboard.KEY_UP = 38;
36 | glam.Keyboard.KEY_RIGHT = 39;
37 | glam.Keyboard.KEY_DOWN = 40;
38 |
--------------------------------------------------------------------------------
/src/input/mouse.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.provide('glam.Mouse');
5 |
6 | glam.Mouse = function()
7 | {
8 | // N.B.: freak out if somebody tries to make 2
9 | // throw (...)
10 |
11 | this.state =
12 | { x : glam.Mouse.NO_POSITION, y: glam.Mouse.NO_POSITION,
13 |
14 | buttons : { left : false, middle : false, right : false },
15 | scroll : 0,
16 | };
17 |
18 | glam.Mouse.instance = this;
19 | };
20 |
21 | glam.Mouse.prototype.onMouseMove = function(event)
22 | {
23 | this.state.x = event.elementX;
24 | this.state.y = event.elementY;
25 | }
26 |
27 | glam.Mouse.prototype.onMouseDown = function(event)
28 | {
29 | this.state.x = event.elementX;
30 | this.state.y = event.elementY;
31 | this.state.buttons.left = true;
32 | }
33 |
34 | glam.Mouse.prototype.onMouseUp = function(event)
35 | {
36 | this.state.x = event.elementX;
37 | this.state.y = event.elementY;
38 | this.state.buttons.left = false;
39 | }
40 |
41 | glam.Mouse.prototype.onMouseClick = function(event)
42 | {
43 | this.state.x = event.elementX;
44 | this.state.y = event.elementY;
45 | this.state.buttons.left = false;
46 | }
47 |
48 | glam.Mouse.prototype.onMouseDoubleClick = function(event)
49 | {
50 | this.state.x = event.elementX;
51 | this.state.y = event.elementY;
52 | this.state.buttons.left = false;
53 | }
54 |
55 | glam.Mouse.prototype.onMouseScroll = function(event, delta)
56 | {
57 | this.state.scroll = 0; // PUNT!
58 | }
59 |
60 |
61 | glam.Mouse.prototype.getState = function()
62 | {
63 | return this.state;
64 | }
65 |
66 | glam.Mouse.instance = null;
67 | glam.Mouse.NO_POSITION = Number.MIN_VALUE;
68 |
--------------------------------------------------------------------------------
/src/lights/ambientLight.js:
--------------------------------------------------------------------------------
1 | goog.provide('glam.AmbientLight');
2 | goog.require('glam.Light');
3 |
4 | glam.AmbientLight = function(param)
5 | {
6 | param = param || {};
7 |
8 | glam.Light.call(this, param);
9 |
10 | if (param.object) {
11 | this.object = param.object;
12 | }
13 | else {
14 | this.object = new THREE.AmbientLight(param.color);
15 | }
16 | }
17 |
18 | goog.inherits(glam.AmbientLight, glam.Light);
19 |
20 | glam.AmbientLight.prototype.realize = function()
21 | {
22 | glam.Light.prototype.realize.call(this);
23 | }
24 |
--------------------------------------------------------------------------------
/src/lights/light.js:
--------------------------------------------------------------------------------
1 | goog.provide('glam.Light');
2 | goog.require('glam.SceneComponent');
3 |
4 | glam.Light = function(param)
5 | {
6 | param = param || {};
7 | glam.SceneComponent.call(this, param);
8 |
9 | // Create accessors for all properties... just pass-throughs to Three.js
10 | Object.defineProperties(this, {
11 | color: {
12 | get: function() {
13 | return this.object.color;
14 | }
15 | },
16 | intensity: {
17 | get: function() {
18 | return this.object.intensity;
19 | },
20 | set: function(v) {
21 | this.object.intensity = v;
22 | }
23 | },
24 |
25 | });
26 |
27 | }
28 |
29 | goog.inherits(glam.Light, glam.SceneComponent);
30 |
31 | glam.Light.prototype._componentProperty = "light";
32 | glam.Light.prototype._componentPropertyType = "Light";
33 |
34 | glam.Light.prototype.realize = function()
35 | {
36 | glam.SceneComponent.prototype.realize.call(this);
37 | }
38 |
39 | glam.Light.DEFAULT_COLOR = 0xFFFFFF;
40 | glam.Light.DEFAULT_INTENSITY = 1;
41 | glam.Light.DEFAULT_RANGE = 10000;
--------------------------------------------------------------------------------
/src/lights/pointLight.js:
--------------------------------------------------------------------------------
1 | goog.provide('glam.PointLight');
2 | goog.require('glam.Light');
3 |
4 | glam.PointLight = function(param)
5 | {
6 | param = param || {};
7 |
8 | glam.Light.call(this, param);
9 |
10 | this.positionVec = new THREE.Vector3;
11 |
12 | if (param.object) {
13 | this.object = param.object;
14 | }
15 | else {
16 | var distance = ( param.distance !== undefined ) ? param.distance : glam.PointLight.DEFAULT_DISTANCE;
17 | this.object = new THREE.PointLight(param.color, param.intensity, distance);
18 | }
19 |
20 | // Create accessors for all properties... just pass-throughs to Three.js
21 | Object.defineProperties(this, {
22 | distance: {
23 | get: function() {
24 | return this.object.distance;
25 | },
26 | set: function(v) {
27 | this.object.distance = v;
28 | }
29 | },
30 |
31 | });
32 |
33 | }
34 |
35 | goog.inherits(glam.PointLight, glam.Light);
36 |
37 | glam.PointLight.prototype.realize = function()
38 | {
39 | glam.Light.prototype.realize.call(this);
40 | }
41 |
42 | glam.PointLight.prototype.update = function()
43 | {
44 | if (this.object)
45 | {
46 | this.positionVec.set(0, 0, 0);
47 | var worldmat = this.object.parent.matrixWorld;
48 | this.positionVec.applyMatrix4(worldmat);
49 | this.position.copy(this.positionVec);
50 | }
51 |
52 | // Update the rest
53 | glam.Light.prototype.update.call(this);
54 | }
55 |
56 | glam.PointLight.DEFAULT_DISTANCE = 0;
57 |
--------------------------------------------------------------------------------
/src/objects/hud.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Object collects a group of Components that define an object and its behaviors
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 |
8 | goog.require('glam.Prefabs');
9 |
10 | glam.Prefabs.HUD = function(param) {
11 |
12 | param = param || {};
13 |
14 | var hud = new glam.Object();
15 |
16 | var hudScript = new glam.HUDScript(param);
17 | hud.addComponent(hudScript);
18 |
19 | return hud;
20 | }
21 |
22 | goog.provide('glam.HUDScript');
23 | goog.require('glam.Script');
24 |
25 | glam.HUDScript = function(param) {
26 |
27 | glam.Script.call(this, param);
28 |
29 | this.zDistance = (param.zDistance !== undefined) ? param.zDistance : glam.HUDScript.DEFAULT_Z_DISTANCE;
30 | this.position = new THREE.Vector3(0, 0, -this.zDistance);
31 | this.savedPosition = this.position.clone();
32 | this.scale = new THREE.Vector3;
33 | this.quaternion = new THREE.Quaternion;
34 | }
35 |
36 | goog.inherits(glam.HUDScript, glam.Script);
37 |
38 | glam.HUDScript.prototype.realize = function() {
39 | }
40 |
41 | glam.HUDScript.EPSILON = 0.001;
42 |
43 | glam.HUDScript.prototype.update = function() {
44 |
45 | var cam = glam.Graphics.instance.camera;
46 |
47 | cam.updateMatrixWorld();
48 |
49 | cam.matrixWorld.decompose(this.position, this.quaternion, this.scale);
50 |
51 | this._object.transform.quaternion.copy(this.quaternion);
52 | this._object.transform.position.copy(this.position);
53 | this._object.transform.translateZ(-this.zDistance);
54 |
55 | if (this.savedPosition.distanceTo(this.position) > glam.HUDScript.EPSILON) {
56 | console.log("Position changed:", this.position)
57 | }
58 |
59 | this.savedPosition.copy(this.position);
60 | }
61 |
62 | glam.HUDScript.DEFAULT_Z_DISTANCE = 1;
63 |
64 |
--------------------------------------------------------------------------------
/src/postprocessing/effect.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Effect - GLAM postprocessing effect, wraps Three.js
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.Effect');
8 | goog.require('glam.EventDispatcher');
9 |
10 | /**
11 | * @constructor
12 | */
13 |
14 | glam.Effect = function(shader)
15 | {
16 | glam.EventDispatcher.call(this);
17 |
18 | this.isShaderEffect = false;
19 |
20 | if (shader.render && typeof(shader.render) == "function") {
21 | this.pass = shader;
22 | }
23 | else {
24 | this.pass = new THREE.ShaderPass(shader);
25 | this.isShaderEffect = true;
26 | }
27 | }
28 |
29 | goog.inherits(glam.Effect, glam.EventDispatcher);
30 |
31 | glam.Effect.prototype.update = function() {
32 |
33 | // hook for later - maybe we do
34 | // subclass with specific knowledge about shader uniforms
35 | }
36 |
37 |
--------------------------------------------------------------------------------
/src/prefabs/prefabs.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Contains prefab assemblies for core GLAM package
3 | * @author Tony Parisi
4 | */
5 | goog.provide('glam.Prefabs');
--------------------------------------------------------------------------------
/src/scene/decoration.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Base class for visual decoration - like glam.Visual but not pickable.
3 | * @author Tony Parisi
4 | */
5 | goog.provide('glam.Decoration');
6 | goog.require('glam.Visual');
7 |
8 | /**
9 | * @constructor
10 | */
11 | glam.Decoration = function(param)
12 | {
13 | param = param || {};
14 |
15 | glam.Visual.call(this, param);
16 |
17 | }
18 |
19 | goog.inherits(glam.Decoration, glam.Visual);
20 |
21 | glam.Decoration.prototype._componentCategory = "decorations";
22 |
23 | glam.Decoration.prototype.realize = function()
24 | {
25 | glam.Visual.prototype.realize.call(this);
26 | this.object.ignorePick = true;
27 | }
--------------------------------------------------------------------------------
/src/scene/sceneVisual.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview A visual containing a model in Collada format
3 | * @author Tony Parisi
4 | */
5 | goog.provide('glam.SceneVisual');
6 | goog.require('glam.Visual');
7 |
8 | glam.SceneVisual = function(param)
9 | {
10 | param = param || {};
11 |
12 | glam.Visual.call(this, param);
13 |
14 | this.object = param.scene;
15 | }
16 |
17 | goog.inherits(glam.SceneVisual, glam.Visual);
18 |
19 | glam.SceneVisual.prototype.realize = function()
20 | {
21 | glam.Visual.prototype.realize.call(this);
22 |
23 | this.addToScene();
24 | }
25 |
--------------------------------------------------------------------------------
/src/scene/transform.js:
--------------------------------------------------------------------------------
1 | /**
2 | *
3 | */
4 | goog.provide('glam.Transform');
5 | goog.require('glam.SceneComponent');
6 |
7 | glam.Transform = function(param) {
8 | param = param || {};
9 | glam.SceneComponent.call(this, param);
10 |
11 | if (param.object) {
12 | this.object = param.object;
13 | }
14 | else {
15 | this.object = new THREE.Object3D();
16 | }
17 | }
18 |
19 | goog.inherits(glam.Transform, glam.SceneComponent);
20 |
21 | glam.Transform.prototype._componentProperty = "transform";
22 | glam.Transform.prototype._componentPropertyType = "Transform";
23 |
24 | glam.Transform.prototype.addToScene = function() {
25 | var scene = this.layer ? this.layer.scene : glam.Graphics.instance.scene;
26 | if (this._object)
27 | {
28 | var parent = (this._object._parent && this._object._parent.transform) ? this._object._parent.transform.object : scene;
29 | if (parent)
30 | {
31 | parent.add(this.object);
32 | this.object.data = this; // backpointer for picking and such
33 | }
34 | else
35 | {
36 | // N.B.: throw something?
37 | }
38 | }
39 | else
40 | {
41 | // N.B.: throw something?
42 | }
43 | }
44 |
45 | glam.Transform.prototype.removeFromScene = function() {
46 | var scene = this.layer ? this.layer.scene : glam.Graphics.instance.scene;
47 | if (this._object)
48 | {
49 | var parent = (this._object._parent && this._object._parent.transform) ? this._object._parent.transform.object : scene;
50 | if (parent)
51 | {
52 | this.object.data = null;
53 | parent.remove(this.object);
54 | }
55 | else
56 | {
57 | // N.B.: throw something?
58 | }
59 | }
60 | else
61 | {
62 | // N.B.: throw something?
63 | }
64 | }
65 |
--------------------------------------------------------------------------------
/src/scene/visual.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Base class for visual elements.
3 | * @author Tony Parisi
4 | */
5 | goog.provide('glam.Visual');
6 | goog.require('glam.SceneComponent');
7 |
8 | /**
9 | * @constructor
10 | */
11 | glam.Visual = function(param)
12 | {
13 | param = param || {};
14 |
15 | glam.SceneComponent.call(this, param);
16 |
17 | if (param.object) {
18 | this.object = param.object;
19 | this.geometry = this.object.geometry;
20 | this.material = this.object.material;
21 | }
22 | else {
23 | this.geometry = param.geometry;
24 | this.material = param.material;
25 | }
26 | }
27 |
28 | goog.inherits(glam.Visual, glam.SceneComponent);
29 |
30 | // We're going to let this slide until we figure out the glTF mulit-material mesh
31 | //glam.Visual.prototype._componentProperty = "visual";
32 | //glam.Visual.prototype._componentPropertyType = "Visual";
33 | glam.Visual.prototype._componentCategory = "visuals";
34 |
35 | glam.Visual.prototype.realize = function()
36 | {
37 | glam.SceneComponent.prototype.realize.call(this);
38 |
39 | if (!this.object && this.geometry && this.material) {
40 | this.object = new THREE.Mesh(this.geometry, this.material);
41 | this.object.ignorePick = false;
42 | this.addToScene();
43 | }
44 | }
45 |
46 |
--------------------------------------------------------------------------------
/src/scripts/script.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Behavior component - base class for time-based behaviors
3 | *
4 | * @author Tony Parisi
5 | */
6 |
7 | goog.provide('glam.Script');
8 | goog.require('glam.Component');
9 |
10 | glam.Script = function(param) {
11 | param = param || {};
12 | glam.Component.call(this, param);
13 | }
14 |
15 | goog.inherits(glam.Script, glam.Component);
16 |
17 | glam.Script.prototype._componentCategory = "scripts";
18 |
19 | glam.Script.prototype.realize = function()
20 | {
21 | glam.Component.prototype.realize.call(this);
22 | }
23 |
24 | glam.Script.prototype.update = function()
25 | {
26 | if (glam.Script.WARN_ON_ABSTRACT)
27 | glam.System.warn("Abstract Script.evaluate called");
28 | }
29 |
30 | glam.Script.WARN_ON_ABSTRACT = true;
31 |
--------------------------------------------------------------------------------
/src/system/system.js:
--------------------------------------------------------------------------------
1 | goog.provide("glam.System");
2 |
3 | glam.System = {
4 | log : function() {
5 | var args = ["[glam] "].concat([].slice.call(arguments));
6 | console.log.apply(console, args);
7 | },
8 | warn : function() {
9 | var args = ["[glam] "].concat([].slice.call(arguments));
10 | console.warn.apply(console, args);
11 | },
12 | error : function() {
13 | var args = ["[glam] "].concat([].slice.call(arguments));
14 | console.error.apply(console, args);
15 | },
16 | ajax : function(param) {
17 |
18 | var type = param.type,
19 | url = param.url,
20 | dataType = param.dataType,
21 | success = param.success,
22 | error = param.error;
23 |
24 | var xhr = new XMLHttpRequest();
25 | xhr.open(type, url, true);
26 | xhr.responseType = dataType;
27 |
28 | xhr.addEventListener( 'load', function ( event ) {
29 | success(xhr.response);
30 | }, false );
31 | xhr.addEventListener( 'error', function ( event ) {
32 | error(xhr.status);
33 | }, false );
34 | xhr.send(null);
35 | },
36 | };
--------------------------------------------------------------------------------
/src/time/time.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Main interface to the graphics and rendering subsystem
3 | *
4 | * @author Tony Parisi
5 | */
6 | goog.provide('glam.Time');
7 |
8 | glam.Time = function()
9 | {
10 | // Freak out if somebody tries to make 2
11 | if (glam.Time.instance)
12 | {
13 | throw new Error('Graphics singleton already exists')
14 | }
15 | }
16 |
17 |
18 | glam.Time.prototype.initialize = function(param)
19 | {
20 | this.currentTime = Date.now();
21 |
22 | glam.Time.instance = this;
23 | }
24 |
25 | glam.Time.prototype.update = function()
26 | {
27 | this.currentTime = Date.now();
28 | }
29 |
30 | glam.Time.instance = null;
31 |
32 |
--------------------------------------------------------------------------------
/src/time/timer.js:
--------------------------------------------------------------------------------
1 | /**
2 | * @fileoverview Timer - component that generates time events
3 | *
4 | * @author Tony Parisi
5 | */
6 | goog.provide('glam.Timer');
7 | goog.require('glam.Component');
8 |
9 | glam.Timer = function(param)
10 | {
11 | glam.Component.call(this);
12 | param = param || {};
13 |
14 | this.currentTime = glam.Time.instance.currentTime;
15 | this.running = false;
16 | this.duration = param.duration ? param.duration : 0;
17 | this.loop = (param.loop !== undefined) ? param.loop : false;
18 | this.lastFraction = 0;
19 | }
20 |
21 | goog.inherits(glam.Timer, glam.Component);
22 |
23 | glam.Timer.prototype.update = function()
24 | {
25 | if (!this.running)
26 | return;
27 |
28 | var now = glam.Time.instance.currentTime;
29 | var deltat = now - this.currentTime;
30 |
31 | if (deltat)
32 | {
33 | this.dispatchEvent("time", now);
34 | }
35 |
36 | if (this.duration)
37 | {
38 | var mod = now % this.duration;
39 | var fract = mod / this.duration;
40 |
41 | this.dispatchEvent("fraction", fract);
42 |
43 | if (fract < this.lastFraction)
44 | {
45 | this.dispatchEvent("cycleTime");
46 |
47 | if (!this.loop)
48 | {
49 | this.stop();
50 | }
51 | }
52 |
53 | this.lastFraction = fract;
54 | }
55 |
56 | this.currentTime = now;
57 |
58 | }
59 |
60 | glam.Timer.prototype.start = function()
61 | {
62 | this.running = true;
63 | this.currentTime = glam.Time.instance.currentTime;
64 | }
65 |
66 | glam.Timer.prototype.stop = function()
67 | {
68 | this.running = false;
69 | }
70 |
71 |
--------------------------------------------------------------------------------
/utils/compile-all.sh:
--------------------------------------------------------------------------------
1 | Echo "Compiling debug..."
2 | ./compile-debug.sh
3 | Echo "Compiling min..."
4 | ./compile-min.sh
5 |
--------------------------------------------------------------------------------
/utils/compiler.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/tparisi/glam/1ab0b5fa4fe009d76d8361e9a77d16c76c83d2ba/utils/compiler.jar
--------------------------------------------------------------------------------