Changeset 3363 for GTP


Ignore:
Timestamp:
04/27/09 18:58:18 (15 years ago)
Author:
mattausch
Message:

still having ugly artifacts because of missed disocclusions

Location:
GTP/trunk/App/Demos/Vis/FriendlyCulling/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaderenv.h

    r3362 r3363  
    1313//#define NUM_SAMPLES 16 
    1414//#define NUM_SAMPLES 24 
    15 #define NUM_SAMPLES 32 
    16 //#define NUM_SAMPLES 48 
     15//#define NUM_SAMPLES 32 
     16#define NUM_SAMPLES 48 
    1717 
     18#define MIN_SAMPLES 8 
    1819//#define MIN_SAMPLES 48 
    19 #define MIN_SAMPLES 8 
    2020 
    2121#define DISTANCE_SCALE 1e-2f 
  • GTP/trunk/App/Demos/Vis/FriendlyCulling/src/shaders/combineSsaoSep.cg

    r3362 r3363  
    110110        const float3 centerPos = ReconstructSamplePos(colorsTex, texCoord, bl, br, tl, tr); 
    111111 
    112 #if 0 
     112#if 1 
    113113        //const float scale = saturate((SSAO_CONVERGENCE_THRESHOLD - convergence + 100) / SSAO_CONVERGENCE_THRESHOLD); 
    114114        const float scale = saturate((SSAO_CONVERGENCE_THRESHOLD - convergence) / SSAO_CONVERGENCE_THRESHOLD); 
    115115         
    116         //for (int i = -SSAO_FILTER_RADIUS; i <= SSAO_FILTER_RADIUS; ++ i) 
     116        for (int i = -SSAO_FILTER_RADIUS; i <= SSAO_FILTER_RADIUS; ++ i) 
    117117        { 
    118118                const float4 sampleTexCoord = float4(texCoord + i * xyStep * scale, .0f, .0f); 
     
    121121#else 
    122122 
    123         const int radius = SSAO_FILTER_RADIUS * saturate((SSAO_CONVERGENCE_THRESHOLD - convergence + 100) / SSAO_CONVERGENCE_THRESHOLD); 
     123        const float radius = SSAO_FILTER_RADIUS * saturate((SSAO_CONVERGENCE_THRESHOLD - convergence + 100) / SSAO_CONVERGENCE_THRESHOLD); 
    124124 
    125125        for (int i = -radius; i <= radius; ++ i) 
     
    205205 
    206206        // filter up to a certain convergance value and leave out background (sky) by checking depth 
    207         if ((!USE_OPTIMIZATION || convergence < SSAO_CONVERGENCE_THRESHOLD) && (depth < DEPTH_THRESHOLD)) 
     207        if ((!USE_OPTIMIZATION || convergence < SSAO_CONVERGENCE_THRESHOLD) &&  
     208                (depth < DEPTH_THRESHOLD)) 
    208209        { 
    209210                // the filtered ssao value 
Note: See TracChangeset for help on using the changeset viewer.