Browse Source

added mikktspace hl.Format definition

ncannasse 7 years ago
parent
commit
48c3250ec7
1 changed files with 26 additions and 1 deletions
  1. 26 1
      std/hl/Format.hx

+ 26 - 1
std/hl/Format.hx

@@ -74,4 +74,29 @@ class Format {
 	public static function digest( out : hl.Bytes, src : hl.Bytes, srcLen : Int, algorithm : Int ) {
 	public static function digest( out : hl.Bytes, src : hl.Bytes, srcLen : Int, algorithm : Int ) {
 	}
 	}
 
 
-}
+}
+
+#if !hl_disable_mikkt
+class Mikktspace {
+	public var buffer : hl.BytesAccess<Single>;
+	public var stride : Int;
+	public var xPos : Int;
+	public var normalPos : Int;
+	public var uvPos : Int;
+	public var tangents : hl.BytesAccess<Single>;
+	public var tangentStride : Int;
+	public var tangentPos : Int;
+	public var indexes : hl.BytesAccess<Int>;
+	public var indices : Int;
+	public function new() {
+	}
+
+	public function compute( threshold = 180. ) {
+		if( !_compute(this,threshold) ) throw "assert";
+	}
+
+	@:hlNative("fmt","compute_mikkt_tangents") static function _compute( m : Dynamic, threshold : Float ) : Bool {
+		return false;
+	}
+}
+#end