Bläddra i källkod

set WasCleared flag on uploadBitmap() and uploadPixels()

bstouls 9 år sedan
förälder
incheckning
15388747dc
1 ändrade filer med 2 tillägg och 0 borttagningar
  1. 2 0
      h3d/mat/Texture.hx

+ 2 - 0
h3d/mat/Texture.hx

@@ -163,11 +163,13 @@ class Texture {
 	public function uploadBitmap( bmp : hxd.BitmapData, mipLevel = 0, side = 0 ) {
 		alloc();
 		mem.driver.uploadTextureBitmap(this, bmp, mipLevel, side);
+		flags.set(WasCleared);
 	}
 
 	public function uploadPixels( pixels : hxd.Pixels, mipLevel = 0, side = 0 ) {
 		alloc();
 		mem.driver.uploadTexturePixels(this, pixels, mipLevel, side);
+		flags.set(WasCleared);
 	}
 
 	public function dispose() {