Radial Blur Default
(radial_blur:default
, 0x70d32e8dc05e70a0
)
This template is referenced 1 time by radial_blur.
Technique ambient
Render States
More info can be found on the Direct3D Docs
enum D3DRENDERSTATETYPE {
D3DRS_ZENABLE = 0,
D3DRS_ZFUNC = 4,
D3DRS_ZWRITEENABLE = 0,
D3DRS_ALPHABLENDENABLE = 0,
D3DRS_CULLMODE = 1,
D3DRS_COLORWRITEENABLE = 15,
D3DRS_COLORWRITEENABLE1 = 15,
D3DRS_COLORWRITEENABLE2 = 15,
D3DRS_STENCILENABLE = 0,
D3DRS_STENCILFUNC = 1,
D3DRS_STENCILFAIL = 1,
D3DRS_STENCILMASK = 0,
D3DRS_STENCILPASS = 1,
D3DRS_STENCILREF = 0,
D3DRS_STENCILWRITEMASK = 0,
D3DRS_STENCILZFAIL = 1,
D3DRS_DEPTHBIAS = 0,
D3DRS_SLOPESCALEDEPTHBIAS = 0,
D3DRS_FOGENABLE = 0,
D3DRS_SPECULARENABLE = 0,
D3DRS_ADAPTIVETESS_X = 0,
D3DRS_ADAPTIVETESS_Z = 0,
D3DRS_ADAPTIVETESS_W = 0,
D3DRS_SRGBWRITEENABLE = 0,
D3DRS_SEPARATEALPHABLENDENABLE = 0,
D3DRS_ALPHATESTENABLE = 0,
};
Sampler States
More info can be found on the Direct3D Docs
Sampler 0
enum D3DSAMPLERSTATETYPE {
D3DSAMP_MIPMAPLODBIAS = 827606343,
D3DSAMP_SRGBTEXTURE = 0,
D3DSAMP_ADDRESSU = 3,
D3DSAMP_ADDRESSV = 3,
D3DSAMP_MAGFILTER = 2,
D3DSAMP_MINFILTER = 2,
D3DSAMP_MIPFILTER = 2,
};
Shaders
Vertex Shader
column_major float4x4 camera_proj_matrix : register(vs_3_0, c8);
column_major float4x4 camera_view_matrix : register(vs_3_0, c4);
float3 ref_world_pos : register(vs_3_0, c15);
float3 render_target_texel_offset : register(vs_3_0, c12);
column_major float4x4 view_proj_matrix : register(vs_3_0, c0);
float3 vp_offset : register(vs_3_0, c13);
float3 vp_size : register(vs_3_0, c14);
struct VertexMain_Input
{
float4 position : POSITION;
float4 texcoord : TEXCOORD;
};
struct VertexMain_Output
{
float4 position : POSITION;
float2 texcoord : TEXCOORD;
float4 texcoord1 : TEXCOORD1;
};
VertexMain_Output VertexMain(VertexMain_Input i)
{
VertexMain_Output o;
float4 temp0, temp1, temp2;
// def c16, 1, 0, 2, -1
// def c17, 0.5, 0, 0, 0
// dcl_position v0
// dcl_texcoord v1
// dcl_position o0
// dcl_texcoord o1.xy
// dcl_texcoord1 o2
// dp4 o0.x, v0, c0
o.position.x = dot(i.position, (view_proj_matrix._m00_m10_m20_m30));
// dp4 o0.y, v0, c1
o.position.y = dot(i.position, (view_proj_matrix._m01_m11_m21_m31));
// dp4 o0.z, v0, c2
o.position.z = dot(i.position, (view_proj_matrix._m02_m12_m22_m32));
// dp4 o0.w, v0, c3
o.position.w = dot(i.position, (view_proj_matrix._m03_m13_m23_m33));
// mov r0.xyz, c16
temp0.xyz = float3(1, 0, 2);
// mad r1, c15.xyzx, r0.xxxy, r0.yyyx
temp1 = ref_world_pos.xyzx * temp0.xxxy + temp0.yyyx;
// dp4 r2.x, r1, c4
temp2.x = dot(temp1, (camera_view_matrix._m00_m10_m20_m30));
// dp4 r2.y, r1, c5
temp2.y = dot(temp1, (camera_view_matrix._m01_m11_m21_m31));
// dp4 r2.z, r1, c6
temp2.z = dot(temp1, (camera_view_matrix._m02_m12_m22_m32));
// dp4 r2.w, r1, c7
temp2.w = dot(temp1, (camera_view_matrix._m03_m13_m23_m33));
// dp4 o2.z, r2, c10
o.texcoord1.z = dot(temp2, (camera_proj_matrix._m02_m12_m22_m32));
// mov r0.xy, c14
temp0.xy = vp_size.xy;
// mad r0.xy, c13, r0.z, r0
temp0.xy = vp_offset.xy * temp0.zz + temp0.xy;
// add r0.xy, r0, c16.w
temp0.xy = temp0.xy + float2(-1, -1);
// dp4 r0.z, r2, c11
temp0.z = dot(temp2, (camera_proj_matrix._m03_m13_m23_m33));
// mul r0.xy, r0, r0.z
temp0.xy = temp0.xy * temp0.zz;
// add r0.z, r0.z, r0.z
temp0.z = temp0.z + temp0.z;
// dp4 r0.w, r2, c8
temp0.w = dot(temp2, (camera_proj_matrix._m00_m10_m20_m30));
// dp4 r1.x, r2, c9
temp1.x = dot(temp2, (camera_proj_matrix._m01_m11_m21_m31));
// mad r0.y, r1.x, -c14.y, r0.y
temp0.y = temp1.x * -vp_size.y + temp0.y;
// mad r0.x, r0.w, c14.x, r0.x
temp0.x = temp0.w * vp_size.x + temp0.x;
// mov r1.x, c17.x
temp1.x = float1(0.5);
// add r1.xy, r1.x, c12
temp1.xy = temp1.xx + render_target_texel_offset.xy;
// mad o2.x, r0.z, r1.x, r0.x
o.texcoord1.x = temp0.z * temp1.x + temp0.x;
// mad o2.y, r0.z, r1.y, r0.y
o.texcoord1.y = temp0.z * temp1.y + temp0.y;
// mov o2.w, r0.z
o.texcoord1.w = temp0.z;
// mov o1.xy, v1
o.texcoord = i.texcoord;
//
return o;
}
Decompiled by DXDecompiler.
Pixel Shader
sampler2D diffuse_texture : register(ps_3_0, s0);
float ref_falloff_exponent : register(ps_3_0, c2);
float ref_kernel_size : register(ps_3_0, c1);
float ref_opacity : register(ps_3_0, c3);
float3 render_target_size : register(ps_3_0, c0);
struct PixelMain_Input
{
float2 texcoord : TEXCOORD;
float4 texcoord1 : TEXCOORD1;
};
float4 PixelMain(PixelMain_Input i) : COLOR
{
float4 out_color;
float4 temp0, temp1, temp3;
float3 temp2;
// def c4, 0, 1, 0, 0
// def c5, 0.125, 0, -0.0001, -13.287712
// defi i0, 8, 0, 0, 0
// dcl_texcoord v0.xy
// dcl_texcoord1 v1.xyw
// dcl_2d s0
// rcp r0.x, c0.x
temp0.x = 1.0f / render_target_size.x;
// rcp r0.y, c0.y
temp0.y = 1.0f / render_target_size.y;
// mov r1.x, c5.x
temp1.x = float1(0.125);
// mul r0.z, r1.x, c1.x
temp0.z = temp1.x * ref_kernel_size.x;
// rcp r0.w, v1.w
temp0.w = 1.0f / i.texcoord1.w;
// mov r1.xy, v0
temp1.xy = i.texcoord.xy;
// mad r1.xy, v1, -r0.w, r1
temp1.xy = i.texcoord1.xy * -temp0.ww + temp1.xy;
// dp2add r0.w, r1, r1, c5.y
temp0.w = dot(temp1.xy, temp1.xy) + float1(0);
// rsq r0.w, r0.w
temp0.w = 1 / sqrt(temp0.w);
// rcp r1.z, r0.w
temp1.z = 1.0f / temp0.w;
// mul r1.xy, r0.w, r1
temp1.xy = temp0.ww * temp1.xy;
// add r0.w, r1.z, c5.z
temp0.w = temp1.z + float1(-0.0001);
// log r1.z, r1.z
temp1.z = log2(temp1.z);
// cmp r0.w, r0.w, r1.z, c5.w
temp0.w = (temp0.w >= 0) ? temp1.z : float1(-13.287712);
// mul r0.w, r0.w, c2.x
temp0.w = temp0.w * ref_falloff_exponent.x;
// exp_sat r0.w, r0.w
temp0.w = saturate(exp2(temp0.w));
// mul r0.z, r0.w, -r0.z
temp0.z = temp0.w * -temp0.z;
// mul r1.xy, r0.z, r1
temp1.xy = temp0.zz * temp1.xy;
// mov r2.xyz, c5.y
temp2.xyz = float3(0, 0, 0);
// mov r0.z, c5.y
temp0.z = float1(0);
// rep i0
for (int it0 = 0; it0 < int1(8); ++it0) {
// mul r1.zw, r1.xyxy, r0.z
temp1.zw = temp1.xy * temp0.zz;
// mad r1.zw, r1, r0.xyxy, v0.xyxy
temp1.zw = temp1.zw * temp0.xy + i.texcoord.xy;
// texld r3, r1.zwzw, s0
temp3 = tex2D(diffuse_texture, temp1.zw);
// add r2.xyz, r2, r3
temp2.xyz = temp2.xyz + temp3.xyz;
// add r0.z, r0.z, c4.y
temp0.z = temp0.z + float1(1);
// endrep
}
// mul oC0.xyz, r2, c5.x
out_color.xyz = temp2.xyz * float3(0.125, 0.125, 0.125);
// mul oC0.w, r0.w, c3.x
out_color.w = temp0.w * ref_opacity.x;
//
return out_color;
}
Decompiled by DXDecompiler.