mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
Fixed issue #256: "$pref::TS::smallestVisiblePixelSize doesn't work".
This commit is contained in:
parent
65099897f4
commit
939061ef59
1 changed files with 5 additions and 0 deletions
|
|
@ -616,6 +616,11 @@ S32 TSShapeInstance::setDetailFromDistance( const SceneRenderState *state, F32 s
|
|||
F32 pixelRadius = ( mShape->radius / scaledDistance ) * state->getWorldToScreenScale().y * pixelScale;
|
||||
F32 pixelSize = pixelRadius * smDetailAdjust;
|
||||
|
||||
if ( pixelSize < smSmallestVisiblePixelSize ) {
|
||||
mCurrentDetailLevel = -1;
|
||||
return mCurrentDetailLevel;
|
||||
}
|
||||
|
||||
if ( pixelSize > smSmallestVisiblePixelSize &&
|
||||
pixelSize <= mShape->mSmallestVisibleSize )
|
||||
pixelSize = mShape->mSmallestVisibleSize + 0.01f;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue