Răsfoiți Sursa

GLTFLoader: Fix regex for Safari detection. (#23305)

* Update GLTFLoader.js

* Update GLTFLoader.js
Diyou 3 ani în urmă
părinte
comite
6c89ee2634
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      examples/jsm/loaders/GLTFLoader.js

+ 1 - 1
examples/jsm/loaders/GLTFLoader.js

@@ -2251,7 +2251,7 @@ class GLTFParser {
 
 		// Use an ImageBitmapLoader if imageBitmaps are supported. Moves much of the
 		// expensive work of uploading a texture to the GPU off the main thread.
-		if ( typeof createImageBitmap !== 'undefined' && /Firefox|Safari/.test( navigator.userAgent ) === false ) {
+		if ( typeof createImageBitmap !== 'undefined' && /Firefox|^((?!chrome|android).)*safari/i.test( navigator.userAgent ) === false ) {
 
 			this.textureLoader = new ImageBitmapLoader( this.options.manager );