mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-19 20:24:49 +00:00
Fixed issue #256: "$pref::TS::smallestVisiblePixelSize doesn't work".
This commit is contained in:
parent
65099897f4
commit
939061ef59
|
|
@ -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…
Reference in a new issue