Ignore:
Timestamp:
10/08/08 17:39:20 (16 years ago)
Author:
mattausch
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/mrt.cg

    r3009 r3016  
    7878pixel fragtex(fragin IN,  
    7979                          uniform sampler2D dirtTex, 
    80                           uniform float maxDepth, 
    8180                          uniform sampler2D tex, 
    8281                          uniform float3 eyePos, 
     
    110109        const float2 screenCoord = projPos.xy * 0.5f + 0.5f; 
    111110        const float magView = length(Interpol(screenCoord, bl, br, tl, tr)); 
    112         pix.col.w = length(eyePos - IN.worldPos.xyz) * maxDepth / magView; 
     111        pix.col.w = length(eyePos - IN.worldPos.xyz) / magView; 
    113112 
    114113#if 0 
     
    122121 
    123122pixel frag(fragin IN,  
    124                    uniform float maxDepth,  
    125123                   uniform float3 eyePos, 
    126124                   uniform float3 bl, 
     
    147145        float2 screenCoord = projPos.xy * 0.5f + 0.5f; 
    148146        const float magView = length(Interpol(screenCoord, bl, br, tl, tr)); 
    149         pix.col.w = length(eyePos - IN.worldPos.xyz) * maxDepth / magView; 
     147        pix.col.w = length(eyePos - IN.worldPos.xyz) / magView; 
    150148 
    151149#if 0 
Note: See TracChangeset for help on using the changeset viewer.