|
@@ -40,8 +40,8 @@ class Texture {
|
|
public var startingMip : Int = 0;
|
|
public var startingMip : Int = 0;
|
|
public var lodBias : Float = 0.;
|
|
public var lodBias : Float = 0.;
|
|
public var mipLevels(get, never) : Int;
|
|
public var mipLevels(get, never) : Int;
|
|
- public var depthBias : Float = 0.;
|
|
|
|
- public var slopeScaledBias : Float = 0.;
|
|
|
|
|
|
+ public var depthBias(default, set) : Float = 0.;
|
|
|
|
+ public var slopeScaledBias(default, set) : Float = 0.;
|
|
public var depthClamp : Bool = false;
|
|
public var depthClamp : Bool = false;
|
|
var customMipLevels : Int;
|
|
var customMipLevels : Int;
|
|
|
|
|
|
@@ -201,6 +201,22 @@ class Texture {
|
|
name = n;
|
|
name = n;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ public function set_depthBias(v : Float) {
|
|
|
|
+ if ( v != depthBias ) {
|
|
|
|
+ depthBias = v;
|
|
|
|
+ h3d.Engine.getCurrent().onTextureBiasChanged(this);
|
|
|
|
+ }
|
|
|
|
+ return depthBias;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ public function set_slopeScaledBias(v : Float) {
|
|
|
|
+ if ( v != slopeScaledBias ) {
|
|
|
|
+ slopeScaledBias = v;
|
|
|
|
+ h3d.Engine.getCurrent().onTextureBiasChanged(this);
|
|
|
|
+ }
|
|
|
|
+ return slopeScaledBias;
|
|
|
|
+ }
|
|
|
|
+
|
|
function set_mipMap(m:MipMap) {
|
|
function set_mipMap(m:MipMap) {
|
|
bits = (bits & ~(3 << 0)) | (Type.enumIndex(m) << 0);
|
|
bits = (bits & ~(3 << 0)) | (Type.enumIndex(m) << 0);
|
|
return mipMap = m;
|
|
return mipMap = m;
|
|
@@ -331,7 +347,7 @@ class Texture {
|
|
flags.set(WasCleared);
|
|
flags.set(WasCleared);
|
|
checkMipMapGen(mipLevel, layer);
|
|
checkMipMapGen(mipLevel, layer);
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
public function dispose() {
|
|
public function dispose() {
|
|
if( t != null )
|
|
if( t != null )
|
|
mem.deleteTexture(this);
|
|
mem.deleteTexture(this);
|