1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-03 17:56:21 +03:00

0025059: Visualization - mutable transformed structure still invalidates BVH tree for culling

Take into account IsMutable flag within Visual3d_View::ReCompute() method.
This commit is contained in:
kgv 2014-07-08 19:23:47 +04:00 committed by bugmaster
parent 7ed22e71e0
commit 2a40d51c15

View File

@ -1635,12 +1635,12 @@ Standard_Integer Index = IsComputed (AStructure);
MyCOMPUTEDSequence.Value (Index)->GraphicTransform (ATrsf);
}
Standard_Integer aLayerId = AStructure->GetZLayer();
AStructure->CalculateBoundBox();
if (!AStructure->IsMutable()
&& !AStructure->CStructure()->IsForHighlight
&& !AStructure->CStructure()->IsInfinite)
{
AStructure->CalculateBoundBox();
Standard_Integer aLayerId = AStructure->GetZLayer();
MyGraphicDriver->InvalidateBVHData (MyCView, aLayerId);
}
}
@ -2104,9 +2104,11 @@ Graphic3d_SequenceOfStructure FooSequence;
}
void Visual3d_View::ReCompute (const Handle(Graphic3d_Structure)& AStructure) {
if (MyCView.IsCullingEnabled)
AStructure->CalculateBoundBox();
if (!AStructure->IsMutable()
&& !AStructure->CStructure()->IsForHighlight
&& !AStructure->CStructure()->IsInfinite)
{
AStructure->CalculateBoundBox();
Standard_Integer aLayerId = AStructure->DisplayPriority();
MyGraphicDriver->InvalidateBVHData(MyCView, aLayerId);
}