Browse Source

DracoLoader: Normalise color attributes by default (#26036)

* normalise color attributes by default

* set normalised if not float32
George 2 years ago
parent
commit
0d9af1426c
1 changed files with 2 additions and 0 deletions
  1. 2 0
      examples/jsm/loaders/DRACOLoader.js

+ 2 - 0
examples/jsm/loaders/DRACOLoader.js

@@ -209,6 +209,8 @@ class DRACOLoader extends Loader {
 
 				this._assignVertexColorSpace( attribute, result.vertexColorSpace );
 
+				attribute.normalized = ( array instanceof Float32Array ) === false;
+
 			}
 
 			geometry.setAttribute( name, attribute );