Explorar o código

Canvas2D: potential breaking change!

Sprite2D no longer force the texture wrapU/V to CLAMP_ADDRESSMODE
nockawa %!s(int64=8) %!d(string=hai) anos
pai
achega
4ede4171ec
Modificáronse 1 ficheiros con 3 adicións e 2 borrados
  1. 3 2
      canvas2D/src/Engine/babylon.sprite2d.ts

+ 3 - 2
canvas2D/src/Engine/babylon.sprite2d.ts

@@ -355,8 +355,9 @@
             super(settings);
 
             this.texture = texture;
-            this.texture.wrapU = Texture.CLAMP_ADDRESSMODE;
-            this.texture.wrapV = Texture.CLAMP_ADDRESSMODE;
+            // This is removed to let the user the possibility to setup the addressing mode he wants
+            //this.texture.wrapU = Texture.CLAMP_ADDRESSMODE;
+            //this.texture.wrapV = Texture.CLAMP_ADDRESSMODE;
             this._useSize = false;
             this._spriteSize = (settings.spriteSize!=null) ? settings.spriteSize.clone() : null;
             this._spriteLocation = (settings.spriteLocation!=null) ? settings.spriteLocation.clone() : new Vector2(0, 0);