From 76b1ede0bddcb62b460f88a0edf893a1785cfac3 Mon Sep 17 00:00:00 2001 From: ouv Date: Mon, 17 Oct 2005 06:48:16 +0000 Subject: [PATCH] Fixed Bug GVIEW10293 : Low plane of Segmentation cursor is invisible and unselectable on the low fase of bounding box --- src/PIPELINE/VISU_ImplicitFunctionWidget.cxx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/PIPELINE/VISU_ImplicitFunctionWidget.cxx b/src/PIPELINE/VISU_ImplicitFunctionWidget.cxx index fb8f407f..258fcafa 100644 --- a/src/PIPELINE/VISU_ImplicitFunctionWidget.cxx +++ b/src/PIPELINE/VISU_ImplicitFunctionWidget.cxx @@ -1005,6 +1005,13 @@ void VISU_ImplicitFunctionWidget::Push(double *p1, double *p2) v[1] = p2[1] - p1[1]; v[2] = p2[2] - p1[2]; + float z0 = this->Plane->GetOrigin()[2]; + double distance = vtkMath::Dot( v, myPlane2->GetNormal() ); + float z1 = z0 + distance * myPlane2->GetNormal()[2]; + + if( z1 <= this->Box->GetOrigin()[2] ) + return; + this->Plane->Push( vtkMath::Dot(v,this->Plane->GetNormal()) ); this->SetOrigin(this->Plane->GetOrigin()); myPlane2->Push( vtkMath::Dot(v,this->Plane->GetNormal()) ); -- 2.39.2