Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/archive/skybox/Media/materials/programs/Bloom_ps20.hlsl @ 12412

Last change on this file since 12412 was 390, checked in by landauf, 17 years ago

added materials

File size: 813 bytes
Line 
1sampler Blur1: register(s1);
2sampler RT: register(s0);
3
4
5float luminance(float3 c)
6{
7        return dot( c, float3(0.3, 0.59, 0.11) );
8}
9
10float4 main(float2 texCoord: TEXCOORD0) : COLOR {
11        float4 sharp = tex2D(RT,   texCoord);
12        float4 blur  = tex2D(Blur1, texCoord);
13
14
15
16        return ( sharp + blur * 1.8 ) / 2;
17
18//      float4 color    = lerp( sharp, blur, 0.4f );
19
20//      return color;
21
22
23/*
24        return ( sharp + blur * 1.8 ) / 2 +
25                         luminance(blur) *
26                         float4( 0.5, 0.5, 0.5, 0) +
27                         luminance(sharp) *
28                         float4( 0.3, 0.3, 0.3, 0);
29*/
30/*
31        return ( sharp + blur * 0.9) / 2 +
32                         luminance(blur) * float4(0.1, 0.15, 0.7, 0);
33*/
34
35/*
36        return ( sharp + blur * 0.9) / 2 +
37                         luminance(blur) * float4(0.1, 0.15, 0.7, 0);
38*/
39
40//      float4 retColor = luminance( sharp ) +
41//                                                      luminance( blur ) + blur / 2;
42//      return retColor;
43}
44
45
46
47
48
49
50
51
52
Note: See TracBrowser for help on using the repository browser.