Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; compiled from tags\rasterizer\pixel_shaders_dx9\shaders_shader_passes_hud_widget_simple_flash_0.txt
- ;
- #const C1.rgb= $normal_color
- #const C1.a= $flash_amount
- #const C2.rgb= $flash_color
- #const C2.a= $global_alpha
- sampler2D s0 : register(S0);
- float4 bumpenv : register(C0); // .r=m00 .g=m01 .b=m10 .a=m11
- float4 c1 : register(C1);
- float4 c2 : register(C2);
- float4 zwriteout : register(c16);
- struct MRT_return
- {
- float4 color :COLOR0;
- float4 depth :COLOR1;
- };
- #ifndef MRT
- float4 main(
- #else
- MRT_return main(
- #endif
- #ifdef CENTROID0
- float4 tc0 : TEXCOORD0_centroid,
- #else
- float4 tc0 : TEXCOORD0,
- #endif
- float4 tc7:TEXCOORD7,
- float4 color0 : COLOR0,
- float4 color1 : COLOR1
- )
- #ifndef MRT
- : COLOR
- #endif
- {
- float4 r0, r1;
- float3 e, f;
- r0.r= r0.g= r0.b= 0;
- r0.a= 1;
- float4 tex1;
- float4 tex2;
- float4 tex3;
- float4 tex4;
- float4 tex5;
- float4 tex6;
- float4 tex7;
- // texture stage 0 mode 0 dot 0 input-stage 0
- float4 tex0= tex2Dproj(s0, tc0);
- // exp.components=3 term=3 term=3
- // line 18: R0= C0*INVERT(C0a)+C1*C0a
- float3 temp0;
- float3 temp1;
- float3 temp2;
- float3 temp3;
- temp3= c1.rgb;
- float3 temp4;
- float temp5;
- temp5= 1-c1.a;
- float3 temp6;
- float3 temp7;
- temp7= temp3 * temp5;
- temp1= temp7;
- float3 temp8;
- temp8= c2.rgb;
- float3 temp9;
- float temp10;
- temp10= c1.a;
- float3 temp11;
- float3 temp12;
- temp12= temp8 * temp10;
- temp2= temp12;
- temp0= temp1 + temp2;
- // exp.components=1 term=1
- // line 19: T0a= T0a*C1a
- float temp13;
- float temp14;
- temp14= saturate(tex0.a);
- float3 temp15;
- float temp16;
- temp16= c2.a;
- float3 temp17;
- float temp18;
- temp18= temp14 * temp16;
- temp13= temp18;
- r0.rgb= temp0;
- tex0.a= temp13;
- // exp.components=3 term=3
- // line 22: SRCCOLOR= R0
- float3 temp19;
- float3 temp20;
- temp20= saturate(r0.rgb);
- float3 temp21;
- temp19= temp20;
- // exp.components=1 term=1
- // line 23: SRCALPHA= T0a
- float temp22;
- float temp23;
- temp23= saturate(tex0.a);
- float3 temp24;
- temp22= temp23;
- r0.rgb= temp19;
- r0.a= temp22;
- //fog zvalue
- float linear_depth = tc7.w / zwriteout.z;
- float3 depth_stripe;
- depth_stripe.r = floor(linear_depth*256)/256;
- depth_stripe.g = frac(floor(linear_depth*65536)/256);
- depth_stripe.b = frac(floor(linear_depth*65536*256)/256);
- #ifdef ZPRIME
- //r0.a has alpha kill value
- r0.rgb = depth_stripe.rgb;
- #endif
- #ifndef MRT
- return r0;
- #else
- MRT_return retval;
- retval.color = r0;
- retval.depth.rgb = depth_stripe.rgb;
- retval.depth.a = r0.a;
- return retval;
- #endif
- }
Add Comment
Please, Sign In to add comment