Ignore:
Timestamp:
03/08/07 11:44:30 (17 years ago)
Author:
szirmay
Message:
 
File:
1 edited

Legend:

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

    r2202 r2207  
    2828    output.pos = input.pos; 
    2929    output.tex = input.tex; 
     30    output.tex.y = 1.0 - output.tex.y; 
    3031    return output; 
    3132} 
     
    6263        float4 ret = cosa * cosb; 
    6364 
     65        float ize = 0; 
     66        if(pos.z > 0) ize = 1; 
    6467        //return float4(lightDir + ret.x * 0.00000000001, 1); 
    65         return ret; 
    66         //return ret.x*0.0000000001 + 0.5; 
     68        //return ret; 
     69        return ret.x*0.0000000001 + ize; 
    6770} 
    6871 
     
    8184                float2 coord1 = float2((float)(currentEntryPoint % nRadionColumns)  / (float) nRadionColumns, 
    8285                                                                currentEntryPoint / (float) nRadionColumns / 4096.0) + hp; 
    83                 coord1.y = 1.0 - coord1.y; 
    8486                float2 coord2 = coord1 + float2(hp.x / 2.0, 0); 
    8587                float radrad = tex2Dlod(radionSampler, float4(coord2, 0, 0)).a; 
     
    99101        return weight; 
    100102} 
     103 
     104void EntryPointDisplayVS(float4 position :POSITION0, 
     105                                                 float4 color :COLOR0, 
     106                                                 uniform float4x4 worldViewProj, 
     107                                                 out float4 hPos:POSITION, 
     108                                                 out float2 texCoord: TEXCOORD0) 
     109{ 
     110        hPos = mul(worldViewProj, position); 
     111        texCoord = color.xy; 
     112} 
     113 
     114float4 EntryPointDisplayPS(float2 texCoord : TEXCOORD0, 
     115                                                        uniform sampler2D weightTexture : register(s0)):COLOR0 
     116{ 
     117        //return texCoord.y; 
     118        return tex2D(weightTexture, texCoord).r; 
     119} 
     120                                                          
Note: See TracChangeset for help on using the changeset viewer.