ncannasse 8 năm trước cách đây
mục cha
commit
a068f7e1c2
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      tools/fbx/Viewer.hx

+ 2 - 0
tools/fbx/Viewer.hx

@@ -301,6 +301,7 @@ class Viewer extends hxd.App {
 					return;
 				}
 				t.resize(size.width, size.height);
+				t.wrap = t.flags.has(IsNPOT) ? Clamp : Repeat;
 				t.uploadPixels(new hxd.Pixels(size.width, size.height, pixels, BGRA));
 				reload.push(loadTexture.bind(textureName, mat, handleAlpha));
 			});
@@ -311,6 +312,7 @@ class Viewer extends hxd.App {
 			loader.contentLoaderInfo.addEventListener(flash.events.Event.COMPLETE, function(_) {
 				var bmp = flash.Lib.as(loader.content, flash.display.Bitmap).bitmapData;
 				t.resize(bmp.width, bmp.height);
+				t.wrap = t.flags.has(IsNPOT) ? Clamp : Repeat;
 				t.uploadBitmap(hxd.BitmapData.fromNative(bmp));
 				reload.push(loadTexture.bind(textureName, mat, handleAlpha));
 			});