mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0031341: Visualization - Graphic3d_Layer::UpdateCulling() ignores Presentation range
Graphic3d_Layer::UpdateCulling() now takes into account BVH_Tree::EndPrimitive(). 'vstatprofiler structs' now properly prints number of structures in case of no culling.
This commit is contained in:
@@ -557,14 +557,18 @@ void Graphic3d_Layer::UpdateCulling (Standard_Integer theViewId,
|
||||
}
|
||||
else
|
||||
{
|
||||
Standard_Integer aIdx = aBVHTree->BegPrimitive (aNode);
|
||||
const Graphic3d_CStructure* aStruct = isTrsfPers
|
||||
? myBVHPrimitivesTrsfPers.GetStructureById (aIdx)
|
||||
: myBVHPrimitives.GetStructureById (aIdx);
|
||||
if (aStruct->IsVisible (theViewId))
|
||||
const Standard_Integer aStartIdx = aBVHTree->BegPrimitive (aNode);
|
||||
const Standard_Integer anEndIdx = aBVHTree->EndPrimitive (aNode);
|
||||
for (Standard_Integer anIdx = aStartIdx; anIdx <= anEndIdx; ++anIdx)
|
||||
{
|
||||
aStruct->MarkAsNotCulled();
|
||||
++myNbStructuresNotCulled;
|
||||
const Graphic3d_CStructure* aStruct = isTrsfPers
|
||||
? myBVHPrimitivesTrsfPers.GetStructureById (anIdx)
|
||||
: myBVHPrimitives.GetStructureById (anIdx);
|
||||
if (aStruct->IsVisible (theViewId))
|
||||
{
|
||||
aStruct->MarkAsNotCulled();
|
||||
++myNbStructuresNotCulled;
|
||||
}
|
||||
}
|
||||
if (aHead < 0)
|
||||
{
|
||||
|
Reference in New Issue
Block a user