Skip to content

Commit

Permalink
Fixed class hierarchy for BinaryLoader and UTF8Loader.
Browse files Browse the repository at this point in the history
Also tried to clean whitespace for ColladaLoader. This thing is so massive.
  • Loading branch information
alteredq committed Sep 2, 2011
1 parent e459fc9 commit 22e8423
Show file tree
Hide file tree
Showing 8 changed files with 2,956 additions and 1,816 deletions.
678 changes: 339 additions & 339 deletions build/Three.js

Large diffs are not rendered by default.

166 changes: 83 additions & 83 deletions build/custom/ThreeExtras.js

Large diffs are not rendered by default.

856 changes: 426 additions & 430 deletions src/extras/loaders/BinaryLoader.js

Large diffs are not rendered by default.

2,714 changes: 1,932 additions & 782 deletions src/extras/loaders/ColladaLoader.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/extras/loaders/JSONLoader.js
Original file line number Diff line number Diff line change
Expand Up @@ -405,4 +405,4 @@ THREE.JSONLoader.prototype.createModel = function ( json, callback, texture_path

callback( geometry );

}
};
14 changes: 7 additions & 7 deletions src/extras/loaders/Loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,27 +55,27 @@ THREE.Loader.prototype = {

},

extractUrlbase: function( url ) {
extractUrlbase: function ( url ) {

var chunks = url.split( "/" );
chunks.pop();
return chunks.join( "/" );

},

init_materials: function( scope, materials, texture_path ) {
init_materials: function ( scope, materials, texture_path ) {

scope.materials = [];

for ( var i = 0; i < materials.length; ++i ) {
for ( var i = 0; i < materials.length; ++ i ) {

scope.materials[ i ] = [ THREE.Loader.prototype.createMaterial( materials[ i ], texture_path ) ];

}

},

hasNormals: function( scope ) {
hasNormals: function ( scope ) {

var m, i, il = scope.materials.length;

Expand Down Expand Up @@ -136,7 +136,7 @@ THREE.Loader.prototype = {

}

function create_texture( where, name, sourceFile, repeat, offset, wrap ) {
function create_texture ( where, name, sourceFile, repeat, offset, wrap ) {

var texture = document.createElement( 'canvas' );

Expand Down Expand Up @@ -174,7 +174,7 @@ THREE.Loader.prototype = {

}

function rgb2hex( rgb ) {
function rgb2hex ( rgb ) {

return ( rgb[ 0 ] * 255 << 16 ) + ( rgb[ 1 ] * 255 << 8 ) + rgb[ 2 ] * 255;

Expand Down Expand Up @@ -367,7 +367,7 @@ THREE.Loader.prototype = {
return material;

},

constructor : THREE.Loader

};
Loading

0 comments on commit 22e8423

Please sign in to comment.