Ignore:
Timestamp:
08/24/08 12:48:59 (16 years ago)
Author:
mattausch
Message:

repaired view vector correction for ssao

File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/App/Demos/Vis/FriendlyCulling/src/SsaoShader.cpp

    r2861 r2863  
    149149        swap(mNewFbo, mOldFbo);  
    150150 
    151         FirstPass(fbo, expFactor); 
     151        ComputeSsao(fbo, expFactor); 
    152152        // the second pass just renders the combined solution 
    153         SecondPass(fbo); 
    154 } 
    155  
    156  
    157 void SsaoShader::FirstPass(FrameBufferObject *fbo, float expFactor) 
     153        DisplayTexture(); 
     154} 
     155 
     156 
     157void SsaoShader::ComputeSsao(FrameBufferObject *fbo, float expFactor) 
    158158{ 
    159159        GLuint colorsTex = fbo->GetColorBuffer(0)->GetTexture(); 
     
    259259 
    260260 
    261 void SsaoShader::SecondPass(FrameBufferObject *fbo) 
     261void SsaoShader::DisplayTexture() 
    262262{ 
    263263        glEnable(GL_TEXTURE_2D); 
     
    309309        mCamera->ComputePoints(ftl, ftr, fbl, fbr, ntl, ntr, nbl, nbr); 
    310310 
    311 #if 0 // matT: debug this!! 
    312          
    313         bl = Normalize(nbl - fbl); 
    314         br = Normalize(nbr - fbr); 
    315         tl = Normalize(ftl - ntl); 
    316         tr = Normalize(ftr - ntr); 
     311#if 1 // matT: debug this!! 
     312         
     313        bl = -Normalize(nbl - fbl); 
     314        br = -Normalize(nbr - fbr); 
     315        tl = -Normalize(ntl - ftl); 
     316        tr = -Normalize(ntr - ftr); 
    317317 
    318318#else // just take camera direction 
Note: See TracChangeset for help on using the changeset viewer.