Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- float4 Ac;
- Texture2D Bt;
- float4 Dc;
- Texture2D Dm;
- Texture2D Dm0;
- Texture2D Dm1;
- Texture2D Dt;
- float4 Ec;
- Texture2D Et;
- float Oc;
- float Alpha;
- float Fade;
- uint FlipU;
- uint FlipV;
- float Scale;
- float TileRate;
- float TileRate0;
- float TileRate1;
- float4 Inner;
- float4 Outer;
- TextureCube Cube;
- SamplerState Sampler;
- RasterizerState Raster[2];
- cbuffer Main
- {
- float4x4 WVP;
- float4x4 World;
- float4x4 View;
- float4x4 Proj;
- float4x4 Local;
- float3 Location;
- uint FVF;
- bool Instance;
- };
- cbuffer Illumination
- {
- bool Ambient;
- float3 AmbientColor;
- bool Lights;
- int LightsCount;
- float3 LightsPos[9];
- float3 LightsColor[9];
- float3 LightsAtten[9];
- float LightsRange[9];
- int LightsDirect[9];
- };
- cbuffer Picture
- {
- float Brightness = 1;
- float Contrast = 1;
- float Gamma = 1;
- };
- BlendState Transparent
- {
- BlendEnable[0] = TRUE;
- SrcBlend = SRC_ALPHA;
- DestBlend = INV_SRC_ALPHA;
- BlendOp = ADD;
- SrcBlendAlpha = ONE;
- DestBlendAlpha = ONE;
- BlendOpAlpha = ADD;
- RenderTargetWriteMask[0] = 0x0F;
- };
- BlendState Starsphere
- {
- BlendEnable[0] = TRUE;
- SrcBlend = SRC_ALPHA;
- DestBlend = ONE;
- BlendOp = ADD;
- SrcBlendAlpha = ONE;
- DestBlendAlpha = ONE;
- BlendOpAlpha = ADD;
- RenderTargetWriteMask[0] = 0x0F;
- };
- SamplerState Linear
- {
- Filter = MIN_MAG_MIP_LINEAR;
- };
- SamplerState Anisotropic
- {
- Filter = ANISOTROPIC;
- };
- struct TVertex
- {
- float4 pos : SV_POSITION;
- float2 tex : TEXCOORD1;
- float2 tex2 : TEXCOORD2;
- float3 normal : NORMAL;
- float3 tangent : TANGENT;
- float4 color : COLOR0;
- float4 tm0 : Transform0;
- float4 tm1 : Transform1;
- float4 tm2 : Transform2;
- float4 tm3 : Transform3;
- float3 origin : Originpos;
- float3 local : Localpos;
- };
- //--------------------------------------------------------------------------------------
- // VS
- //--------------------------------------------------------------------------------------
- TVertex VS ( float4 Pos: POSITION, float2 Tex: TEXCOORD1, float2 Tex2: TEXCOORD2, float3 Normal: NORMAL, float4 Color: COLOR0, float4 TM0: Transform0, float4 TM1: Transform1, float4 TM2: Transform2, float4 TM3: Transform3)
- {
- TVertex output = (TVertex)0;
- float4x4 Mat = Local;
- if (Instance)
- {
- Mat = mul(Mat, float4x4(TM0, TM1, TM2, TM3));
- }
- output.local = mul(mul(Pos, Mat), World);
- output.normal = normalize(mul(Normal, Mat));
- Mat = mul(Mat, WVP);
- output.pos = mul(Pos, Mat);
- output.tex = Tex;
- output.tex2 = Tex2;
- output.color = Color;
- output.origin = mul(Pos, World);
- return output;
- }
- //--------------------------------------------------------------------------------------
- // PS
- //--------------------------------------------------------------------------------------
- float4 PS (TVertex input) : SV_TARGET
- {
- return input.color;
- }
- //--------------------------------------------------------------------------------------
- // PXLight
- //--------------------------------------------------------------------------------------
- float4 PXLight (TVertex input, float4 tex) : SV_TARGET
- {
- if (FVF == 0x142)
- {
- tex *= input.color;
- }
- if ((FVF == 0x012 | FVF == 0x112 | FVF == 0x212) & (LightsCount > 0))
- {
- float3 d = float3(0,0,0);
- float3 p = float3(0,0,0);
- float lum = (0.299*AmbientColor.r) + (0.587*AmbientColor.g) + (0.114*AmbientColor.b);
- d = AmbientColor.rgb;// * Ac.rgb;
- for (int i = 0; i < LightsCount; i++)
- if (LightsDirect[i] == 1)
- {
- float dist = distance(LightsPos[i], input.local);
- if (LightsRange[i] >= dist)
- {
- float3 dir = normalize(LightsPos[i].xyz - input.local.xyz);
- float3 clr = saturate(LightsColor[i] * dot(input.normal, dir));
- float angle = dot(input.normal, dir);
- d += clr * Dc.rgb;// + AmbientColor.rgb * Ac.rgb;
- }
- }
- for (int i = 0; i < LightsCount; i++)
- if (LightsDirect[i] == 0)
- {
- float dist = distance(LightsPos[i], input.local);
- if (LightsRange[i] >= dist)
- {
- float3 dir = normalize(LightsPos[i].xyz - input.local.xyz);
- float3 clr = saturate(LightsColor[i] * dot(input.normal, dir));
- p += clr * Dc.rgb;
- }
- }
- tex.rgb *= saturate(d+p);
- }
- return tex;
- }
- //--------------------------------------------------------------------------------------
- // PXBrightness
- //--------------------------------------------------------------------------------------
- float4 PXBrightness (float4 tex) : SV_TARGET
- {
- tex.rgb *= float3(Brightness,Brightness,Brightness);
- return tex;
- }
- //--------------------------------------------------------------------------------------
- // PXContrast
- //--------------------------------------------------------------------------------------
- float4 PXContrast (float4 tex) : SV_TARGET
- {
- tex.rgb -= float3(0.5,0.5,0.5);
- tex.rgb *= max(Contrast, 0);
- tex.rgb += float3(0.5,0.5,0.5);
- return tex;
- }
- float4 PXGamma(float4 tex) : SV_TARGET
- {
- return pow(tex, 1/Gamma);
- }
- float4 PXBlend(float4 base, float4 blend)
- {
- float3 br = clamp(sign(base.rgb - float3(0.5,0.5,0.5)), float3(0,0,0), float3(1,1,1));
- float3 multiply = 2.0 * base.rgb * blend.rgb;
- float3 screen = float3(1,1,1) - 2.0 * (float3(1,1,1) - base.rgb)*(float3(1,1,1) - blend.rgb);
- float3 overlay = lerp(multiply, screen, br);
- return float4(overlay, 1);
- }
- //--------------------------------------------------------------------------------------
- // PX
- //--------------------------------------------------------------------------------------
- float4 PX (TVertex input, float4 tex) : SV_TARGET
- {
- if (Lights)
- {
- tex = PXLight(input, tex);
- }
- return tex;
- }
- float4 PXPost (float4 tex) : SV_TARGET
- {
- tex = PXBrightness(tex);
- tex = PXContrast(tex);
- tex = PXGamma(tex);
- return tex;
- };
- //--------------------------------------------------------------------------------------
- // ColorPS
- //--------------------------------------------------------------------------------------
- float4 ColorPS (TVertex input) : SV_TARGET
- {
- return Dc;
- }
- //--------------------------------------------------------------------------------------
- // DcDt
- //--------------------------------------------------------------------------------------
- float4 DcDtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- clip (tex.a - 0.01);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DcDtOcOt
- //--------------------------------------------------------------------------------------
- float4 DcDtOcOtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- tex.a *= Oc;
- clip (tex.a - 0.01);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DcDtBt
- //--------------------------------------------------------------------------------------
- float4 DcDtBtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- //float4 bump = Bt.Sample(Anisotropic, input.tex2);
- //tex *= bump;
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DcDtBtOcOtPS
- //--------------------------------------------------------------------------------------
- float4 DcDtBtOcOtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- //float4 bump = Bt.Sample (Anisotropic, input.tex2);
- //tex *= bump;
- tex.a *= Oc;
- clip (tex.a - 0.01);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DcDtBtEcPS
- //--------------------------------------------------------------------------------------
- float4 DcDtBtEcPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- //float4 bump = Bt.Sample(Anisotropic, input.tex2);
- //tex *= bump;
- tex *= Ec;
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DcDtBtEcEtPS
- //--------------------------------------------------------------------------------------
- float4 DcDtBtEcEtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- tex = PX(input, tex);
- //float4 bump = Bt.Sample (Anisotropic, input.tex2);
- float4 illum = Et.Sample (Anisotropic, input.tex);
- illum *= Ec;
- //tex *= bump;
- tex += illum;
- return PXPost(tex);
- }
- //--------------------------------------------------------------------------------------
- // DcDtEc
- //--------------------------------------------------------------------------------------
- float4 DcDtEcPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- tex *= Ec;
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DcDtEt
- //--------------------------------------------------------------------------------------
- float4 DcDtEtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- tex = PX(input, tex);
- float4 illum = Et.Sample (Anisotropic, input.tex);
- tex += illum;
- return PXPost(tex);
- }
- //--------------------------------------------------------------------------------------
- // DcDtEcEt
- //--------------------------------------------------------------------------------------
- float4 DcDtEcEtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- tex = PX(input, tex);
- float4 illum = Et.Sample (Anisotropic, input.tex);
- illum *= Ec;
- tex += illum;
- return PXPost(tex);
- }
- //--------------------------------------------------------------------------------------
- // DcDtEcOcOt
- //--------------------------------------------------------------------------------------
- float4 DcDtEcOcOtPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- tex.a *= Oc;
- tex *= Ec;
- clip (tex.a - 0.01);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // Nebula
- //--------------------------------------------------------------------------------------
- float4 NebulaPS (TVertex input) : SV_TARGET
- {
- float4 tex = Dt.Sample (Anisotropic, input.tex);
- [branch] if (FVF == 0x142)
- {
- tex *= input.color;
- tex *= Ec;
- return PXPost(PX(input, tex));
- }
- else
- {
- return PXPost(PX(input, tex));
- }
- }
- //--------------------------------------------------------------------------------------
- // AtmospherePS
- //--------------------------------------------------------------------------------------
- float4 AtmospherePS (TVertex input) : SV_TARGET
- {
- float3 dir = normalize(Location - input.local.xyz);
- float angle = clamp(dot(input.normal * Fade, dir),0,1);
- float4 tex = Dt.Sample(Anisotropic, float2(angle,angle));
- tex = PX(input, tex);
- float lum = (0.299*tex.r) + (0.587*tex.g) + (0.114*tex.b);
- tex.rgb = float3(lum,lum,lum) * (Dc * Ac + AmbientColor);
- tex.a *= Alpha;
- //tex.rgb = float3(lum,lum,lum) * Dc * Ac;
- //tex.a *= Alpha;
- //tex = PX(input, tex * Fade);
- //tex *= Dc * Ac;
- //tex.a *= Alpha;
- //tex = clamp(tex,0,1);
- return PXPost(tex);
- };
- //--------------------------------------------------------------------------------------
- // DetailMapPS
- //--------------------------------------------------------------------------------------
- float4 DetailMapPS (TVertex input) : SV_TARGET
- {
- float2 texcoord = input.tex;
- if (FlipU) texcoord.x = 1 - texcoord.x;
- if (FlipV) texcoord.y = 1 - texcoord.y;
- float3 pos = reflect(input.origin, float4(0,1,0,0));
- float4 tex = Cube.Sample (Anisotropic, pos);
- texcoord *= TileRate;
- float4 detail = Dm.Sample (Anisotropic, texcoord);
- float4 details = lerp(detail, detail, tex.a);
- tex *= details * sqrt(2);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // DetailMap2Dm1Msk2PassPS
- //--------------------------------------------------------------------------------------
- float4 DetailMap2Dm1Msk2PassPS (TVertex input) : SV_TARGET
- {
- float2 texcoord = input.tex;
- if (FlipU) texcoord.x = 1 - texcoord.x;
- if (FlipV) texcoord.y = 1 - texcoord.y;
- float3 pos = reflect(input.origin, float4(0,1,0,0));
- float4 tex = Cube.Sample (Anisotropic, pos);
- texcoord *= TileRate;
- float4 detail1 = Dm1.Sample (Anisotropic, texcoord);
- float4 details = lerp(detail1, detail1, tex.a);
- tex *= details * sqrt(2);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // Masked2DetailMapPS
- //--------------------------------------------------------------------------------------
- float4 Masked2DetailMapPS (TVertex input) : SV_TARGET
- {
- float2 texcoord = input.tex;
- if (FlipU) texcoord.x = 1 - texcoord.x;
- if (FlipV) texcoord.y = 1 - texcoord.y;
- float3 pos = reflect(input.origin, float4(0,1,0,0));
- float4 tex = Cube.Sample (Anisotropic, pos);
- float2 texcoord0 = texcoord * TileRate0;
- float4 detail0 = Dm0.Sample (Anisotropic, texcoord0);
- float2 texcoord1 = texcoord * TileRate1;
- float4 detail1 = Dm1.Sample (Anisotropic, texcoord1);
- float4 details = lerp(detail0, detail1, tex.a);
- tex *= details * sqrt(2);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // IllumDetailMapPS
- //--------------------------------------------------------------------------------------
- float4 IllumDetailMapPS (TVertex input) : SV_TARGET
- {
- float2 texcoord = input.tex;
- if (FlipU) texcoord.x = 1 - texcoord.x;
- if (FlipV) texcoord.y = 1 - texcoord.y;
- float3 pos = reflect(input.origin, float4(0,1,0,0));
- float4 tex = Cube.Sample (Anisotropic, pos);
- float2 texcoord0 = texcoord * TileRate0;
- float4 detail0 = Dm0.Sample (Anisotropic, texcoord0);
- float2 texcoord1 = texcoord * TileRate1;
- float4 detail1 = Dm1.Sample (Anisotropic, texcoord1);
- float4 details = lerp(detail0, detail1, tex.a);
- tex *= details * sqrt(2);
- return PXPost(PX(input, tex));
- }
- //--------------------------------------------------------------------------------------
- // Techniques
- // The very first technique and its first pass is used to create the general Input Layout (FLVertex).
- //--------------------------------------------------------------------------------------
- technique10 FLVertex
- {
- pass p0
- {
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, PS() ) );
- }
- }
- technique10 DcDt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtPS() ) );
- }
- }
- technique10 DcDtTwo
- {
- pass p0
- {
- SetRasterizerState( Raster[1] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtPS() ) );
- }
- pass p1
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtPS() ) );
- }
- }
- technique10 DcDtOcOt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtOcOtPS() ) );
- }
- }
- technique10 DcDtOcOtTwo
- {
- pass p0
- {
- SetRasterizerState( Raster[1] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtOcOtPS() ) );
- }
- pass p1
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtOcOtPS() ) );
- }
- }
- technique10 DcDtBt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtPS() ) );
- }
- }
- technique10 DcDtBtTwo
- {
- pass p0
- {
- SetRasterizerState( Raster[1] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtPS() ) );
- }
- pass p1
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtPS() ) );
- }
- }
- technique10 DcDtBtEc
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtEcPS() ) );
- }
- }
- technique10 DcDtBtEcEt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtEcEtPS() ) );
- }
- }
- technique10 DcDtBtOcOt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtOcOtPS() ) );
- }
- }
- technique10 DcDtBtOcOtTwo
- {
- pass p0
- {
- SetRasterizerState( Raster[1] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtOcOtPS() ) );
- }
- pass p1
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtBtOcOtPS() ) );
- }
- }
- technique10 DcDtEc
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtEcPS() ) );
- }
- }
- technique10 DcDtEt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtEtPS() ) );
- }
- }
- technique10 DcDtEcEt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtEcEtPS() ) );
- }
- }
- technique10 DcDtEcOcOt
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtEcOcOtPS() ) );
- }
- }
- technique10 DcDtEcOcOtTwo
- {
- pass p0
- {
- SetRasterizerState( Raster[1] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtEcOcOtPS() ) );
- }
- pass p1
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DcDtEcOcOtPS() ) );
- }
- }
- technique10 Nebula
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Starsphere, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, NebulaPS() ) );
- }
- }
- technique10 NebulaTwo
- {
- pass p0
- {
- SetRasterizerState( Raster[1] );
- SetBlendState( Starsphere, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, NebulaPS() ) );
- }
- pass p1
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Starsphere, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, NebulaPS() ) );
- }
- }
- technique10 Atmosphere
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( Transparent, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, AtmospherePS() ) );
- }
- }
- technique10 DetailMap
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DetailMapPS() ) );
- }
- }
- technique10 DetailMap2Dm1Msk2Pass
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, DetailMap2Dm1Msk2PassPS() ) );
- }
- }
- technique10 Masked2DetailMap
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, Masked2DetailMapPS () ) );
- }
- }
- technique10 IllumDetailMap
- {
- pass p0
- {
- SetRasterizerState( Raster[0] );
- SetBlendState( NULL, float4(0,0,0,0), 0xFFFFFFFF );
- SetVertexShader( CompileShader( vs_4_0, VS() ) );
- SetPixelShader( CompileShader( ps_4_0, IllumDetailMapPS() ) );
- }
- }
Add Comment
Please, Sign In to add comment