mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-04 02:41:19 +00:00
Merge branch 'UseSameDistanceForAllLodsOfTheCurrentChunk' into 'master'
Use same distance for all lods of the current chunk Closes #6061 See merge request OpenMW/openmw!940
This commit is contained in:
commit
071786aff6
@ -477,6 +477,8 @@ namespace MWRender
|
||||
constexpr auto copyMask = ~Mask_UpdateVisitor;
|
||||
|
||||
AnalyzeVisitor analyzeVisitor(copyMask);
|
||||
osg::Vec3f center3 = { center.x(), center.y(), 0.f };
|
||||
analyzeVisitor.mCurrentDistance = (viewPoint - center3).length2();
|
||||
float minSize = mMinSize;
|
||||
if (mMinSizeMergeFactor)
|
||||
minSize *= mMinSizeMergeFactor;
|
||||
@ -546,7 +548,6 @@ namespace MWRender
|
||||
continue;
|
||||
}
|
||||
|
||||
analyzeVisitor.mCurrentDistance = dSqr;
|
||||
auto emplaced = nodes.emplace(cnode, InstanceList());
|
||||
if (emplaced.second)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user