mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-04 18:06:22 +03:00
0027944: Visualization, V3d_View - filter duplicates within ::AddClipPlane()
This commit is contained in:
parent
3c1624950a
commit
b88b0cf7fc
@ -150,6 +150,18 @@ void V3d_View::AddClipPlane (const Handle(Graphic3d_ClipPlane)& thePlane)
|
||||
{
|
||||
aSeqOfPlanes = new Graphic3d_SequenceOfHClipPlane();
|
||||
}
|
||||
else
|
||||
{
|
||||
for (Graphic3d_SequenceOfHClipPlane::Iterator aPlaneIt (*aSeqOfPlanes); aPlaneIt.More(); aPlaneIt.Next())
|
||||
{
|
||||
const Handle(Graphic3d_ClipPlane)& aPlane = aPlaneIt.Value();
|
||||
if (aPlane == thePlane)
|
||||
{
|
||||
// plane is already defined in view
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
aSeqOfPlanes->Append (thePlane);
|
||||
SetClipPlanes (aSeqOfPlanes);
|
||||
|
Loading…
x
Reference in New Issue
Block a user