message: demo: Add Basis support to GLTFLoader
  This change probably doesn't make sense to upstream, but without it it's
  impossible to use embedded Basis images in glTF content for testing.
  Eventually KHR_image_ktx2 will replace this.
diff: @@ -14,6 +14,7 @@ THREE.GLTFLoader = ( function () {
  this.dracoLoader = null;
  this.ddsLoader = null;
  + this.basisLoader = null;
  this.meshoptDecoder = null;
  }
  @@ -111,6 +112,13 @@ THREE.GLTFLoader = ( function () {
  },
  + setBasisLoader: function ( basisLoader ) {
  +
  + this.basisLoader = basisLoader;
  + return this;
  +
  + },
  +
  setMeshoptDecoder: function ( decoder ) {
  this.meshoptDecoder = decoder;
  @@ -222,7 +230,8 @@ THREE.GLTFLoader = ( function () {
  path: path || this.resourcePath || '',
  crossOrigin: this.crossOrigin,
  - manager: this.manager
  + manager: this.manager,
  + basisLoader: this.basisLoader,
  } );
  @@ -1970,11 +1979,29 @@ THREE.GLTFLoader = ( function () {
  var loader = options.manager.getHandler( sourceURI );
  + if ( ! loader && textureExtensions[ EXTENSIONS.MSFT_TEXTURE_DDS ] ) {
  +
  + loader = parser.extensions[ EXTENSIONS.MSFT_TEXTURE_DDS ].ddsLoader
  +
  + }
  +
  + if ( ! loader && options.basisLoader ) {
  +
  + if ( source.uri !== undefined && source.uri.toLowerCase().endsWith(".basis") ) {
  +
  + loader = options.basisLoader;
  +
  + } else if ( source.bufferView !== undefined && source.mimeType == "image/basis" ) {
  +
  + loader = options.basisLoader;
  +
  + }
  +
  + }
  +
  if ( ! loader ) {
  - loader = textureExtensions[ EXTENSIONS.MSFT_TEXTURE_DDS ]
  - ? parser.extensions[ EXTENSIONS.MSFT_TEXTURE_DDS ].ddsLoader
  - : textureLoader;
  + loader = textureLoader;
  }
  