mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-26 01:53:47 +00:00
OpenGL Intel - Fix a error on DOF_DownSample_P.glsl.
This commit is contained in:
parent
d000a1e7c5
commit
0718875ac3
2 changed files with 8 additions and 2 deletions
|
|
@ -84,13 +84,16 @@ void main()
|
|||
// The CoC will be 1 if the depth is negative, so use "min" to pick
|
||||
// between "sceneCoc" and "viewCoc".
|
||||
|
||||
coc = half4(0);
|
||||
for ( int i = 0; i < 4; i++ )
|
||||
{
|
||||
depth[0] = prepassUncondition( depthSampler, ( IN_tcDepth0.xy + rowOfs[i] ) ).w;
|
||||
depth[1] = prepassUncondition( depthSampler, ( IN_tcDepth1.xy + rowOfs[i] ) ).w;
|
||||
depth[2] = prepassUncondition( depthSampler, ( IN_tcDepth2.xy + rowOfs[i] ) ).w;
|
||||
depth[3] = prepassUncondition( depthSampler, ( IN_tcDepth3.xy + rowOfs[i] ) ).w;
|
||||
coc[i] = clamp( dofEqWorld.x * depth + dofEqWorld.y, 0.0, maxWorldCoC );
|
||||
|
||||
// @todo OPENGL INTEL need review
|
||||
coc = max( coc, clamp( half4(dofEqWorld.x) * depth + half4(dofEqWorld.y), half4(0.0), half4(maxWorldCoC) ) );
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -84,13 +84,16 @@ void main()
|
|||
// The CoC will be 1 if the depth is negative, so use "min" to pick
|
||||
// between "sceneCoc" and "viewCoc".
|
||||
|
||||
coc = half4(0);
|
||||
for ( int i = 0; i < 4; i++ )
|
||||
{
|
||||
depth[0] = prepassUncondition( depthSampler, ( IN_tcDepth0.xy + rowOfs[i] ) ).w;
|
||||
depth[1] = prepassUncondition( depthSampler, ( IN_tcDepth1.xy + rowOfs[i] ) ).w;
|
||||
depth[2] = prepassUncondition( depthSampler, ( IN_tcDepth2.xy + rowOfs[i] ) ).w;
|
||||
depth[3] = prepassUncondition( depthSampler, ( IN_tcDepth3.xy + rowOfs[i] ) ).w;
|
||||
coc[i] = clamp( dofEqWorld.x * depth + dofEqWorld.y, 0.0, maxWorldCoC );
|
||||
|
||||
// @todo OPENGL INTEL need review
|
||||
coc = max( coc, clamp( half4(dofEqWorld.x) * depth + half4(dofEqWorld.y), half4(0.0), half4(maxWorldCoC) ) );
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue