Changeset 2213


Ignore:
Timestamp:
03/08/07 17:19:43 (17 years ago)
Author:
szirmay
Message:
 
Location:
GTP/trunk/App/Demos/Illum/Ogre/Media/PMDemo
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/App/Demos/Illum/Ogre/Media/PMDemo/PathMap.hlsl

    r2202 r2213  
    7676//return float4(1,0,0,1)+col.xxxx*0.0000000001; 
    7777//return prmAtlasTilesHalfPixel.x*allClusterCount*clusterCount*0.000000000001 + tex2D(filteredAtlasSampler, float2(input.texAtlas.x /32.0f, 1.0 - input.texAtlas.y)).r; 
    78         return float4(col, 1); 
     78        return float4(col * 200, 1); 
    7979} 
    8080 
  • GTP/trunk/App/Demos/Illum/Ogre/Media/PMDemo/PathMapWeightCompute.hlsl

    r2207 r2213  
    2727    vsOutputComputeWeights output = (vsOutputComputeWeights)0; 
    2828    output.pos = input.pos; 
    29     output.tex = input.tex; 
     29    output.tex = (input.pos + 1.0) / 2.0; 
    3030    output.tex.y = 1.0 - output.tex.y; 
    3131    return output; 
    3232} 
    3333 
    34 float4 
    35         psComputeWeights(vsOutputComputeWeights input) : COLOR0 
     34float4 psComputeWeights(vsOutputComputeWeights input) : COLOR0 
    3635{ 
    3736        float dataColumnWidth = 1.0 / (float)nRadionColumns; 
     
    6160        float visibility = 1; 
    6261         
    63         float4 ret = cosa * cosb; 
     62        float4 ret = pow(cosa, 9) * cosb / dist2; 
    6463 
    65         float ize = 0; 
    66         if(pos.z > 0) ize = 1; 
     64        //float ize = 0; 
     65        //if(pos.y > 0) ize = 1; 
    6766        //return float4(lightDir + ret.x * 0.00000000001, 1); 
    6867        //return ret; 
    69         return ret.x*0.0000000001 + ize; 
     68        return ret; 
    7069} 
    7170 
     
    8887                //weight += tex2Dlod(allWeightsSampler, float4(coord1, 0, 0)).r * radrad; 
    8988                weight += tex2Dlod(allWeightsSampler, float4(coord1, 0, 0)).r; 
    90                 //clusterRad += radrad; 
     89                clusterRad += radrad; 
    9190                currentEntryPoint++; 
    9291        }        
    93         /* 
    94         if(clusterRad >= 0) 
     92         
     93        /*if(clusterRad >= 0) 
    9594                weight /= clusterRad; 
    9695        else 
    9796                weight = 0;*/ 
    98          
     97                         
    9998    weight /= (float) entryPointCount; 
    10099                 
     
    116115{ 
    117116        //return texCoord.y; 
    118         return tex2D(weightTexture, texCoord).r; 
     117        return texCoord.r; 
    119118} 
    120119                                                          
Note: See TracChangeset for help on using the changeset viewer.