|
@@ -341,9 +341,9 @@ class HlslOut {
|
|
}
|
|
}
|
|
add("))");
|
|
add("))");
|
|
case TCall({ e : TGlobal(g = (TextureSize)) }, args):
|
|
case TCall({ e : TGlobal(g = (TextureSize)) }, args):
|
|
- decl("float2 textureSize(Texture2D tex, int lod) { float w; float h; tex.GetDimensions(tex, (uint)lod, out w, out h); return float2(w, h); }");
|
|
|
|
- decl("float3 textureSize(Texture2DArray tex, int lod) { float w; float h; float els; tex.GetDimensions(tex, (uint)lod, out w, out h, out els); return float3(w, h, els); }");
|
|
|
|
- decl("float2 textureSize(TextureCube tex, int lod) { float w; float h; tex.GetDimensions(tex, (uint)lod, out w, out h); return float2(w, h); }");
|
|
|
|
|
|
+ decl("float2 textureSize(Texture2D tex, int lod) { float w; float h; float levels; tex.GetDimensions((uint)lod,w,h,levels); return float2(w, h); }");
|
|
|
|
+ decl("float3 textureSize(Texture2DArray tex, int lod) { float w; float h; float els; float levels; tex.GetDimensions((uint)lod,w,h,els,levels); return float3(w, h, els); }");
|
|
|
|
+ decl("float2 textureSize(TextureCube tex, int lod) { float w; float h; float levels; tex.GetDimensions((uint)lod,w,h,levels); return float2(w, h); }");
|
|
add("textureSize(");
|
|
add("textureSize(");
|
|
addValue(args[0], tabs);
|
|
addValue(args[0], tabs);
|
|
if (args.length != 1) {
|
|
if (args.length != 1) {
|