浏览代码

noMipMap options for texture init of photodome

Raanan Weber 4 年之前
父节点
当前提交
46c1fdbff5
共有 2 个文件被更改,包括 2 次插入1 次删除
  1. 1 1
      src/Helpers/photoDome.ts
  2. 1 0
      src/Helpers/textureDome.ts

+ 1 - 1
src/Helpers/photoDome.ts

@@ -55,7 +55,7 @@ export class PhotoDome extends TextureDome<Texture> {
     }
 
     protected _initTexture(urlsOrElement: string, scene: Scene, options: any): Texture {
-        return new Texture(urlsOrElement, scene, true, !this._useDirectMapping, undefined, undefined, (message, exception) => {
+        return new Texture(urlsOrElement, scene, options.noMipMap, !this._useDirectMapping, undefined, undefined, (message, exception) => {
             this.onLoadErrorObservable.notifyObservers(message || "Unknown error occured");
 
             if (this.onError) {

+ 1 - 0
src/Helpers/textureDome.ts

@@ -166,6 +166,7 @@ export abstract class TextureDome<T extends Texture> extends TransformNode {
             faceForward?: boolean;
             useDirectMapping?: boolean;
             halfDomeMode?: boolean;
+            noMipMap?: boolean;
         },
         scene: Scene,
         protected onError: Nullable<(message?: string, exception?: any) => void> = null