Revision 2809,
590 bytes
checked in by mattausch, 16 years ago
(diff) |
working on ssao deferred shading approach (debug version!!)
|
Rev | Line | |
---|
[2809] | 1 | struct fragment
|
---|
| 2 | {
|
---|
| 3 | float4 pos: WPOS; // world position
|
---|
| 4 | float4 color0 : COLOR0;
|
---|
| 5 | float4 texCoord: TEXCOORD0;
|
---|
| 6 | float4 lindepth: TEXCOORD1;
|
---|
| 7 | };
|
---|
| 8 |
|
---|
| 9 |
|
---|
| 10 | struct pixel
|
---|
| 11 | {
|
---|
| 12 | float4 color0: COLOR0;
|
---|
| 13 | float4 color1: COLOR1;
|
---|
| 14 | };
|
---|
| 15 |
|
---|
| 16 |
|
---|
| 17 | pixel main(fragment IN, uniform sampler2D tex, uniform float maxDepth)
|
---|
| 18 | //pixel main(fragment IN, uniform sampler2D tex)
|
---|
| 19 | {
|
---|
| 20 | pixel pix;
|
---|
| 21 |
|
---|
| 22 | pix.color0 = IN.color0 * tex2D(tex, IN.texCoord.xy);
|
---|
| 23 | pix.color1 = IN.lindepth.z * maxDepth;// * IN.pos.z / IN.pos.w;
|
---|
| 24 | // pix.color1.w = 1;
|
---|
| 25 |
|
---|
| 26 | return pix;
|
---|
| 27 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.