diff --git a/README.md b/README.md
index 6b68a97a..82546fc0 100644
--- a/README.md
+++ b/README.md
@@ -14,43 +14,49 @@ More? [#three.js on irc.freenode.net](http://webchat.freenode.net/?channels=thre
#### WebGL (Context 3D) ####
-[](http://mrdoob.github.com/three.js/examples/shader.html)
-[](http://mrdoob.github.com/three.js/examples/materials_normalmap2.html)
-[](http://mrdoob.github.com/three.js/examples/materials_grass.html)
-[](http://mrdoob.github.com/three.js/examples/materials_normalmap.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_terrain_gl.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_minecraft_ao.html)
-[](http://mrdoob.github.com/three.js/examples/materials_shaders_fresnel.html)
-[](http://mrdoob.github.com/three.js/examples/materials_cars.html)
-[](http://mrdoob.github.com/three.js/examples/materials_cubemap_refraction.html)
-[](http://mrdoob.github.com/three.js/examples/materials_cubemap_balls_reflection.html)
-[](http://mrdoob.github.com/three.js/examples/materials_cubemap_balls_refraction.html)
-[](http://mrdoob.github.com/three.js/examples/materials_cubemap_escher.html)
-[](http://mrdoob.github.com/three.js/examples/materials_cubemap.html)
-[](http://mrdoob.github.com/three.js/examples/materials_gl.html)
-[](http://mrdoob.github.com/three.js/examples/materials_shaders.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_large_mesh.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_video.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_postprocessing_dof.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_ribbons.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_geometry_colors.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_particles_billboards_colors.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_lines_colors.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_shader.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_normalmap2.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_grass.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_normalmap.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_geometry_terrain.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_geometry_minecraft_ao.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_shaders_fresnel.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_cars.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_cubemap_refraction.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_cubemap_balls_reflection.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_cubemap_balls_refraction.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_cubemap_escher.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_cubemap.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_materials_shaders.html)
+[](http://mrdoob.github.com/three.js/examples/webgl_geometry_large_mesh.html)
#### Canvas (Context 2D) ####
-[](http://mrdoob.github.com/three.js/examples/materials_reflection.html)
-[](http://mrdoob.github.com/three.js/examples/materials.html)
-[](http://mrdoob.github.com/three.js/examples/materials_depth.html)
-[](http://mrdoob.github.com/three.js/examples/materials_normal.html)
-[](http://mrdoob.github.com/three.js/examples/lights_pointlights.html)
-[](http://mrdoob.github.com/three.js/examples/interactive_cubes.html)
-[](http://mrdoob.github.com/three.js/examples/camera_orthographic.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_birds.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_earth.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_terrain.html)
-[](http://mrdoob.github.com/three.js/examples/materials_video.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_panorama.html)
-[](http://mrdoob.github.com/three.js/examples/geometry_cube.html)
-[](http://mrdoob.github.com/three.js/examples/particles_sprites.html)
-[](http://mrdoob.github.com/three.js/examples/particles_random.html)
-[](http://mrdoob.github.com/three.js/examples/particles_waves.html)
-[](http://mrdoob.github.com/three.js/examples/particles_floor.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_materials_reflection.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_materials.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_materials_depth.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_materials_normal.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_lights_pointlights.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_interactive_cubes.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_camera_orthographic.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_geometry_birds.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_geometry_earth.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_geometry_terrain.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_materials_video.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_geometry_panorama.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_geometry_cube.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_particles_sprites.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_particles_random.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_particles_waves.html)
+[](http://mrdoob.github.com/three.js/examples/canvas_particles_floor.html)
### Featured projects ###
@@ -73,16 +79,16 @@ More? [#three.js on irc.freenode.net](http://webchat.freenode.net/?channels=thre
Download the [minified library](http://mrdoob.github.com/three.js/build/Three.js) and include it in your html.
-
+
This code creates a camera, then creates a scene object, adds a bunch of random particles in it, creates a <canvas> renderer and adds its viewport in the document.body element.
-
-
+
diff --git a/examples/canvas_materials_normal.html b/examples/canvas_materials_normal.html
index 02fc53c0..c4c469eb 100644
--- a/examples/canvas_materials_normal.html
+++ b/examples/canvas_materials_normal.html
@@ -76,7 +76,6 @@
function animate() {
requestAnimationFrame( animate );
-
render();
}
diff --git a/examples/canvas_performance.html b/examples/canvas_performance.html
index 5160a08f..a5219528 100644
--- a/examples/canvas_performance.html
+++ b/examples/canvas_performance.html
@@ -63,7 +63,7 @@
-
+
diff --git a/examples/canvas_sandbox.html b/examples/canvas_sandbox.html
index f6de171f..8a534184 100644
--- a/examples/canvas_sandbox.html
+++ b/examples/canvas_sandbox.html
@@ -63,7 +63,7 @@
-
+
diff --git a/examples/misc_sound.html b/examples/misc_sound.html
index 03280d1f..7df1d13a 100644
--- a/examples/misc_sound.html
+++ b/examples/misc_sound.html
@@ -97,8 +97,8 @@
mesh1.position.set( -250, 30, 0 );
mesh1.scale.set( s, s, s );
- var sound1 = new THREE.Sound3D( [ "sounds/358232_j_s_song.mp3", "sounds/358232_j_s_song.ogg" ] , 275, 20, true );
- //var sound1 = new THREE.Sound3D( "sounds/358232_j_s_song.ogg", 275, 20, true );
+ var sound1 = new THREE.Sound( [ "sounds/358232_j_s_song.mp3", "sounds/358232_j_s_song.ogg" ] , 275, 20, true );
+ //var sound1 = new THREE.Sound( "sounds/358232_j_s_song.ogg", 275, 20, true );
sound1.play();
var dbg = new THREE.Mesh( cube, material_cube );
@@ -113,8 +113,8 @@
mesh2.position.set( 250, 30, 0 );
mesh2.scale.set( s, s, s );
- var sound2 = new THREE.Sound3D( [ "sounds/376737_Skullbeatz___Bad_Cat_Maste.mp3", "sounds/376737_Skullbeatz___Bad_Cat_Maste.ogg" ], 275, 20, true );
- //var sound2 = new THREE.Sound3D( "sounds/376737_Skullbeatz___Bad_Cat_Maste.ogg", 275, 20, true );
+ var sound2 = new THREE.Sound( [ "sounds/376737_Skullbeatz___Bad_Cat_Maste.mp3", "sounds/376737_Skullbeatz___Bad_Cat_Maste.ogg" ], 275, 20, true );
+ //var sound2 = new THREE.Sound( "sounds/376737_Skullbeatz___Bad_Cat_Maste.ogg", 275, 20, true );
sound2.play();
var dbg = new THREE.Mesh( cube, material_cube );
diff --git a/examples/misc_uqbiquity_test.html b/examples/misc_uqbiquity_test.html
index f9c67dae..e587bf01 100644
--- a/examples/misc_uqbiquity_test.html
+++ b/examples/misc_uqbiquity_test.html
@@ -64,7 +64,7 @@
-
+
diff --git a/examples/webgl_geometry_hierarchy.html b/examples/webgl_geometry_hierarchy.html
index 9b1c0105..078aa420 100644
--- a/examples/webgl_geometry_hierarchy.html
+++ b/examples/webgl_geometry_hierarchy.html
@@ -64,7 +64,7 @@
-
+
diff --git a/examples/webgl_geometry_hierarchy2.html b/examples/webgl_geometry_hierarchy2.html
index 2f8ac200..534ca62e 100644
--- a/examples/webgl_geometry_hierarchy2.html
+++ b/examples/webgl_geometry_hierarchy2.html
@@ -64,7 +64,7 @@
-
+
diff --git a/examples/webgl_performance.html b/examples/webgl_performance.html
index 2745f2c6..d0fdeac3 100644
--- a/examples/webgl_performance.html
+++ b/examples/webgl_performance.html
@@ -64,7 +64,7 @@
-
+
diff --git a/examples/webgl_sandbox.html b/examples/webgl_sandbox.html
index cce36d0c..9163e696 100644
--- a/examples/webgl_sandbox.html
+++ b/examples/webgl_sandbox.html
@@ -82,7 +82,7 @@
-
+
diff --git a/src/objects/Sound3D.js b/src/objects/Sound.js
similarity index 74%
rename from src/objects/Sound3D.js
rename to src/objects/Sound.js
index 25b188ca..e20a4a5c 100644
--- a/src/objects/Sound3D.js
+++ b/src/objects/Sound.js
@@ -2,7 +2,7 @@
* @author mikael emtinger / http://gomo.se/
*/
-THREE.Sound3D = function ( sources, radius, volume, loop ) {
+THREE.Sound = function ( sources, radius, volume, loop ) {
THREE.Object3D.call( this );
@@ -48,7 +48,7 @@ THREE.Sound3D = function ( sources, radius, volume, loop ) {
element = document.createElement( "source" );
element.src = this.sources[ s ];
- this.domElement.THREESound3D = this;
+ this.domElement.THREESound = this;
this.domElement.appendChild( element );
this.domElement.addEventListener( "canplay", this.onLoad, true );
this.domElement.load();
@@ -62,16 +62,16 @@ THREE.Sound3D = function ( sources, radius, volume, loop ) {
};
-THREE.Sound3D.prototype = new THREE.Object3D();
-THREE.Sound3D.prototype.constructor = THREE.Sound3D;
-THREE.Sound3D.prototype.supr = THREE.Object3D.prototype;
+THREE.Sound.prototype = new THREE.Object3D();
+THREE.Sound.prototype.constructor = THREE.Sound;
+THREE.Sound.prototype.supr = THREE.Object3D.prototype;
-THREE.Sound3D.prototype.onLoad = function () {
+THREE.Sound.prototype.onLoad = function () {
- var sound3D = this.THREESound3D;
+ var sound = this.THREESound;
- if ( sound3D.isLoaded ) {
+ if ( sound.isLoaded ) {
return;
@@ -79,25 +79,25 @@ THREE.Sound3D.prototype.onLoad = function () {
this.removeEventListener( "canplay", this.onLoad, true );
- sound3D.isLoaded = true;
- sound3D.duration = this.duration;
+ sound.isLoaded = true;
+ sound.duration = this.duration;
- if ( sound3D.isPlaying ) {
+ if ( sound.isPlaying ) {
- sound3D.play();
+ sound.play();
}
};
-THREE.Sound3D.prototype.addToDOM = function ( parent ) {
+THREE.Sound.prototype.addToDOM = function ( parent ) {
this.isAddedToDOM = true;
parent.appendChild( this.domElement );
};
-THREE.Sound3D.prototype.play = function ( startTime ) {
+THREE.Sound.prototype.play = function ( startTime ) {
this.isPlaying = true;
@@ -115,14 +115,14 @@ THREE.Sound3D.prototype.play = function ( startTime ) {
};
-THREE.Sound3D.prototype.pause = function () {
+THREE.Sound.prototype.pause = function () {
this.isPlaying = false;
this.domElement.pause();
};
-THREE.Sound3D.prototype.stop = function (){
+THREE.Sound.prototype.stop = function (){
this.isPlaying = false;
this.domElement.pause();
@@ -130,7 +130,7 @@ THREE.Sound3D.prototype.stop = function (){
};
-THREE.Sound3D.prototype.calculateVolumeAndPan = function ( cameraRelativePosition ) {
+THREE.Sound.prototype.calculateVolumeAndPan = function ( cameraRelativePosition ) {
var distance = cameraRelativePosition.length();
@@ -146,7 +146,7 @@ THREE.Sound3D.prototype.calculateVolumeAndPan = function ( cameraRelativePositio
};
-THREE.Sound3D.prototype.update = function ( parentMatrixWorld, forceUpdate, camera ) {
+THREE.Sound.prototype.update = function ( parentMatrixWorld, forceUpdate, camera ) {
// update local (rotation/scale is not used)
diff --git a/src/scenes/Scene.js b/src/scenes/Scene.js
index 2a66dbaf..415688d7 100644
--- a/src/scenes/Scene.js
+++ b/src/scenes/Scene.js
@@ -38,7 +38,7 @@ THREE.Scene.prototype.addChildRecurse = function( child ) {
}
- } else if ( child instanceof THREE.Sound3D ) {
+ } else if ( child instanceof THREE.Sound ) {
if ( this.sounds.indexOf( child ) === -1 ) {
@@ -84,7 +84,7 @@ THREE.Scene.prototype.removeChildRecurse = function( child ) {
}
- } else if ( child instanceof THREE.Sound3D ) {
+ } else if ( child instanceof THREE.Sound ) {
var i = this.sounds.indexOf( child );
diff --git a/utils/REVISION b/utils/REVISION
index f5c89552..bb95160c 100644
--- a/utils/REVISION
+++ b/utils/REVISION
@@ -1 +1 @@
-32
+33
diff --git a/utils/build.py b/utils/build.py
index 5c188b7d..64925270 100644
--- a/utils/build.py
+++ b/utils/build.py
@@ -59,7 +59,7 @@ COMMON_FILES = [
'objects/Bone.js',
'objects/SkinnedMesh.js',
'objects/Ribbon.js',
-'objects/Sound3D.js',
+'objects/Sound.js',
'scenes/Scene.js',
'scenes/Fog.js',
'scenes/FogExp2.js',