Browse Source

WebGLRenderer: Explicit checks for extensions.

Mr.doob 11 years ago
parent
commit
41ced7d595
1 changed files with 6 additions and 6 deletions
  1. 6 6
      src/renderers/WebGLRenderer.js

+ 6 - 6
src/renderers/WebGLRenderer.js

@@ -6469,34 +6469,34 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 
 		_glExtensionCompressedTextureS3TC = _gl.getExtension( 'WEBGL_compressed_texture_s3tc' ) || _gl.getExtension( 'MOZ_WEBGL_compressed_texture_s3tc' ) || _gl.getExtension( 'WEBKIT_WEBGL_compressed_texture_s3tc' );
 		_glExtensionCompressedTextureS3TC = _gl.getExtension( 'WEBGL_compressed_texture_s3tc' ) || _gl.getExtension( 'MOZ_WEBGL_compressed_texture_s3tc' ) || _gl.getExtension( 'WEBKIT_WEBGL_compressed_texture_s3tc' );
 
 
-		_glExtensionElementIndexUint = _gl.getExtension( 'OES_element_index_uint' )
+		_glExtensionElementIndexUint = _gl.getExtension( 'OES_element_index_uint' );
 		
 		
 		
 		
-		if ( ! _glExtensionTextureFloat ) {
+		if ( _glExtensionTextureFloat === null ) {
 
 
 			console.log( 'THREE.WebGLRenderer: Float textures not supported.' );
 			console.log( 'THREE.WebGLRenderer: Float textures not supported.' );
 
 
 		}
 		}
 
 
-		if ( ! _glExtensionStandardDerivatives ) {
+		if ( _glExtensionStandardDerivatives === null ) {
 
 
 			console.log( 'THREE.WebGLRenderer: Standard derivatives not supported.' );
 			console.log( 'THREE.WebGLRenderer: Standard derivatives not supported.' );
 
 
 		}
 		}
 
 
-		if ( ! _glExtensionTextureFilterAnisotropic ) {
+		if ( _glExtensionTextureFilterAnisotropic === null ) {
 
 
 			console.log( 'THREE.WebGLRenderer: Anisotropic texture filtering not supported.' );
 			console.log( 'THREE.WebGLRenderer: Anisotropic texture filtering not supported.' );
 
 
 		}
 		}
 
 
-		if ( ! _glExtensionCompressedTextureS3TC ) {
+		if ( _glExtensionCompressedTextureS3TC === null ) {
 
 
 			console.log( 'THREE.WebGLRenderer: S3TC compressed textures not supported.' );
 			console.log( 'THREE.WebGLRenderer: S3TC compressed textures not supported.' );
 
 
 		}
 		}
 
 
-		if ( ! _glExtensionElementIndexUint ) {
+		if ( _glExtensionElementIndexUint === null ) {
 
 
 			console.log( 'THREE.WebGLRenderer: elementindex as unsigned integer not supported.' );
 			console.log( 'THREE.WebGLRenderer: elementindex as unsigned integer not supported.' );