#include <manualViewBaseContour.h>
Public Member Functions | |
manualViewBaseContour () | |
virtual | ~manualViewBaseContour () |
virtual int | GetType () |
virtual void | Save (FILE *pFile) |
virtual void | Open (FILE *pFile) |
void | AddPoint () |
void | AddPoint (manualViewPoint *manualViewPoint) |
void | InsertPoint (int id) |
void | DeleteContour () |
void | DeletePoint (int x, int y, int z) |
virtual void | DeletePoint (int id) |
virtual void | UpdateViewPoint (int id) |
virtual void | UpdateViewPoints () |
void | SetSelected (bool selected) |
void | SetPosibleSelected (bool posibleSelected) |
bool | GetSelected () |
bool | GetPosibleSelected () |
void | DeleteSelectedPoints () |
bool | GetEditable () |
void | SetEditable (bool *condition) |
virtual int | GetIdPoint (int x, int y, int z) |
void | SelectPoint (int i, bool select) |
void | SelectLstPoints () |
void | SelectAllPoints (bool select) |
virtual int | SelectPosiblePoint (int x, int y, int z) |
bool | SelectPosibleContour (int x, int y, int z) |
void | SelectAllPossibleSelected (bool select) |
void | SetPointSelected (int id, bool select) |
void | SetPointPosibleSelected (int id, bool select) |
void | SetIfViewControlPoints (bool ifShow) |
bool | GetIfViewControlPoints () |
void | UnSelectPoint (int i) |
void | UnSelectLstPoints () |
void | UnSelectAllPoints () |
void | SetModel (manualContourModel *manContModel) |
void | SetWxVtkBaseView (wxVtkBaseView *wxvtkbaseview) |
virtual void | Refresh () |
int | GetNumberOfPoints () |
void | CreateNewContour () |
double * | GetVectorPointsXManualContour () |
double * | GetVectorPointsYManualContour () |
double * | GetVectorPointsZManualContour () |
virtual bool | ifTouchContour (int x, int y, int z) |
void | UpdateColorActor () |
void | SetRange (int range) |
int | GetRange () |
void | SetZ (int z) |
int | GetZ () |
wxVtkBaseView * | GetWxVtkBaseView () |
virtual void | InitMove (int x, int y, int z) |
virtual void | MoveContour (int x, int y, int z) |
virtual void | MoveContour (int horizontalUnits, int verticalUnits) |
virtual void | GetMinMax (double &minX, double &minY, double &minZ, double &maxX, double &maxY, double &maxZ) |
virtual void | TransfromCoordViewWorld (double &X, double &Y, double &Z, int type=2) |
void | ClearContour () |
virtual void | ClearPoint (int id) |
void | SetVisible (bool ok) |
void | SetShowText (bool ok) |
void | GetSpacing (double spc[3]) |
void | SetSpacing (double spc[3]) |
void | SetColorNormalContour (double r, double g, double b) |
void | GetColorNormalContour (double &r, double &g, double &b) |
void | SetColorEditContour (double r, double g, double b) |
void | GetColorEditContour (double &r, double &g, double &b) |
void | SetColorSelectContour (double r, double g, double b) |
void | GetColorSelectContour (double &r, double &g, double &b) |
void | AddCompleteContourActor (bool ifControlPoints=false) |
void | RemoveCompleteContourActor () |
virtual void | AddSplineActor () |
virtual void | RemoveSplineActor () |
void | AddControlPoints () |
void | RemoveControlPoints () |
void | AddTextActor () |
void | RemoveTextActor () |
virtual manualViewBaseContour * | Clone () |
void | CopyAttributesTo (manualViewBaseContour *cloneObject) |
virtual void | RefreshContour () |
void | SetWidthLine (double width) |
double | GetWidthLine () |
virtual void | ConstructVTKObjects () |
Protected Attributes | |
bool | _show_text |
int | _id_viewPoint_for_text |
vtkTextActor * | _textActor |
manualContourModel * | _manContModel |
vtkPoints * | _pts |
int | _sizePointsContour |
std::vector< manualViewPoint * > | _lstViewPoints |
double | _spc [3] |
Private Member Functions | |
void | DeleteVtkObjects () |
virtual void | RefreshText () |
Private Attributes | |
int | _range |
wxVtkBaseView * | _wxvtkbaseview |
bool | _selected |
bool * | _editable |
bool | _posibleSelected |
bool | _viewControlPoints |
vtkPolyData * | _pd |
vtkActor * | _contourVtkActor |
vtkPolyDataMapper * | _bboxMapper |
double | _coulorEdit_r |
double | _coulorEdit_g |
double | _coulorEdit_b |
double | _coulorNormal_r |
double | _coulorNormal_g |
double | _coulorNormal_b |
double | _coulorSelection_r |
double | _coulorSelection_g |
double | _coulorSelection_b |
double | _widthline |
Definition at line 52 of file manualViewBaseContour.h.
manualViewBaseContour::manualViewBaseContour | ( | ) |
Definition at line 8 of file manualViewBaseContour.cpp.
References _bboxMapper, _contourVtkActor, _coulorEdit_b, _coulorEdit_g, _coulorEdit_r, _coulorNormal_b, _coulorNormal_g, _coulorNormal_r, _coulorSelection_b, _coulorSelection_g, _coulorSelection_r, _manContModel, _pd, _posibleSelected, _pts, _range, _selected, _show_text, _sizePointsContour, _spc, _textActor, _viewControlPoints, _widthline, and _wxvtkbaseview.
Referenced by Clone().
00009 { 00010 _show_text = true; 00011 _textActor = NULL; 00012 _manContModel = NULL; 00013 _wxvtkbaseview = NULL; 00014 _selected = false; 00015 _posibleSelected = false; 00016 _viewControlPoints = false; 00017 _pts = NULL; 00018 _pd = NULL; 00019 _contourVtkActor = NULL; 00020 _bboxMapper = NULL; 00021 _range = 1; 00022 _sizePointsContour = 100; 00023 _spc[0] = 1; 00024 _spc[1] = 1; 00025 _spc[2] = 1; 00026 00027 _coulorEdit_r = 1; 00028 _coulorEdit_g = 1; 00029 _coulorEdit_b = 0; 00030 00031 _coulorNormal_r = 1; 00032 _coulorNormal_g = 0; 00033 _coulorNormal_b = 1; 00034 00035 _coulorSelection_r = 0; 00036 _coulorSelection_g = 1; 00037 _coulorSelection_b = 0; 00038 00039 _widthline = 1; 00040 00041 }
manualViewBaseContour::~manualViewBaseContour | ( | ) | [virtual] |
Definition at line 43 of file manualViewBaseContour.cpp.
References _lstViewPoints.
00044 { 00045 int i,size=_lstViewPoints.size(); 00046 for (i=0;i<size; i++){ 00047 delete _lstViewPoints[i]; 00048 } 00049 _lstViewPoints.clear(); 00050 }
void manualViewBaseContour::AddCompleteContourActor | ( | bool | ifControlPoints = false |
) |
Definition at line 80 of file manualViewBaseContour.cpp.
References _viewControlPoints, _wxvtkbaseview, AddControlPoints(), AddSplineActor(), AddTextActor(), wxVtkBaseView::GetRenderer(), Refresh(), and RefreshContour().
Referenced by CreateNewContour().
00081 { 00082 _viewControlPoints = ifControlPoints; 00083 /*vtkRenderer * theRenderer = */ _wxvtkbaseview->GetRenderer(); // JPRx ?? 00084 //Adding the spline 00085 AddSplineActor(); 00086 00087 AddTextActor(); 00088 //Adding each control point 00089 if( ifControlPoints ) 00090 AddControlPoints(); 00091 RefreshContour(); 00092 Refresh(); 00093 }
void manualViewBaseContour::AddControlPoints | ( | ) |
Definition at line 171 of file manualViewBaseContour.cpp.
References _lstViewPoints, _viewControlPoints, _wxvtkbaseview, wxVtkBaseView::GetRenderer(), and SetIfViewControlPoints().
Referenced by AddCompleteContourActor(), and manualContourControler::MouseDLeft().
00172 { 00173 vtkRenderer * theRenderer = _wxvtkbaseview->GetRenderer(); 00174 SetIfViewControlPoints( true ); 00175 if( _viewControlPoints ) 00176 { 00177 int i,size=_lstViewPoints.size(); 00178 for (i=0;i<size; i++) 00179 { 00180 vtkActor * pointActor = _lstViewPoints[i]->GetVtkActor(); 00181 theRenderer->AddActor( pointActor ); 00182 } 00183 } 00184 }
void manualViewBaseContour::AddPoint | ( | manualViewPoint * | manualViewPoint | ) |
Definition at line 332 of file manualViewBaseContour.cpp.
References _lstViewPoints, _spc, _wxvtkbaseview, manualViewPoint::CreateVtkPointActor(), wxVtkBaseView::GetRenderer(), and manualViewPoint::SetSpacing().
00333 { 00334 _lstViewPoints.push_back( manualViewPoint ); 00335 00336 // EED 3 oct 2006 00337 manualViewPoint->SetSpacing(_spc); 00338 00339 vtkActor *actor = manualViewPoint->CreateVtkPointActor(); 00340 _wxvtkbaseview->GetRenderer()->AddActor( actor ); 00341 }
void manualViewBaseContour::AddPoint | ( | ) |
Definition at line 326 of file manualViewBaseContour.cpp.
References GetWxVtkBaseView().
Referenced by manualContourBaseControler::AddPoint(), manualContour3VControler::AddPoint(), manualContour3VControler::AddPoint_Others(), CopyAttributesTo(), manualContourBaseControler::InsertPoint(), manualContourContainer::refreshLumen(), manualContourContainer::refreshWall(), and wxMaracasCoutourTool::SetControlPoints().
00327 { 00328 manualViewPoint *mvp = new manualViewPoint( this->GetWxVtkBaseView() ); 00329 AddPoint( mvp ); 00330 }
void manualViewBaseContour::AddSplineActor | ( | ) | [virtual] |
Reimplemented in manualViewBullEye.
Definition at line 143 of file manualViewBaseContour.cpp.
References _contourVtkActor, _wxvtkbaseview, and wxVtkBaseView::GetRenderer().
Referenced by AddCompleteContourActor().
00144 { 00145 vtkRenderer * theRenderer = _wxvtkbaseview->GetRenderer(); 00146 if (_contourVtkActor!=NULL) 00147 theRenderer->AddActor( _contourVtkActor ); 00148 }
void manualViewBaseContour::AddTextActor | ( | ) |
Definition at line 186 of file manualViewBaseContour.cpp.
References _textActor, _wxvtkbaseview, and wxVtkBaseView::GetRenderer().
Referenced by AddCompleteContourActor(), and manualContourControler::MouseDLeft().
00187 { 00188 _wxvtkbaseview->GetRenderer()->AddActor2D( _textActor ); 00189 }
void manualViewBaseContour::ClearContour | ( | ) |
Definition at line 842 of file manualViewBaseContour.cpp.
References _contourVtkActor, _lstViewPoints, _wxvtkbaseview, ClearPoint(), DeleteVtkObjects(), wxVtkBaseView::GetRenderer(), and Refresh().
Referenced by manualContourContainer::clearLumen(), and manualContourContainer::clearWall().
00843 { 00844 if (_contourVtkActor!=NULL){ 00845 _wxvtkbaseview->GetRenderer()->RemoveActor( _contourVtkActor ); 00846 } 00847 DeleteVtkObjects(); 00848 int i,size=_lstViewPoints.size(); 00849 for (i=0;i<size;i++){ 00850 ClearPoint(0); 00851 } 00852 Refresh(); 00853 }
void manualViewBaseContour::ClearPoint | ( | int | id | ) | [virtual] |
Reimplemented in manualViewContour.
Definition at line 855 of file manualViewBaseContour.cpp.
References DeletePoint().
Referenced by ClearContour().
00856 { 00857 DeletePoint(id); 00858 }
manualViewBaseContour * manualViewBaseContour::Clone | ( | ) | [virtual] |
Reimplemented in manualView3DContour, manualView3VContour, manualViewBullEye, manualViewCircle, manualViewContour, manualViewLine, manualViewRoi, and manualViewPerpPlaneContour.
Definition at line 109 of file manualViewBaseContour.cpp.
References CopyAttributesTo(), and manualViewBaseContour().
00110 { 00111 manualViewBaseContour * clone = new manualViewBaseContour(); 00112 CopyAttributesTo(clone); 00113 return clone; 00114 00115 }
void manualViewBaseContour::ConstructVTKObjects | ( | ) | [virtual] |
Reimplemented in manualViewBullEye.
Definition at line 231 of file manualViewBaseContour.cpp.
References _bboxMapper, _contourVtkActor, _manContModel, _pd, _pts, _textActor, DeleteVtkObjects(), manualContourModel::GetNumberOfPointsSpline(), and UpdateColorActor().
Referenced by manualViewBullEye::ConstructVTKObjects(), and CreateNewContour().
00232 { 00233 //JSTG 29-02-08 ----------------------------------------------- 00234 //int i , nps = _sizePointsContour; 00235 int i; 00236 int nps = _manContModel->GetNumberOfPointsSpline(); 00237 //------------------------------------------------------------- 00238 DeleteVtkObjects(); 00239 _pts = vtkPoints::New(); 00240 _pts->SetNumberOfPoints(nps); 00241 00242 for (i=0 ; i<nps ; i++){ 00243 _pts->SetPoint(i, 0 , 0 , 0 ); 00244 } 00245 // This is for the boundaring inicialisation 00246 00247 //EED 29Mars2009 00248 _pts->SetPoint(0, 0 , 0 , -1000 ); 00249 _pts->SetPoint(1, 0 , 0 , 1000 ); 00250 // _pts->SetPoint(0, -1000 , -1000 , -1000 ); 00251 // _pts->SetPoint(1, 1000 , 1000 , 1000 ); 00252 00253 00254 vtkCellArray *lines = vtkCellArray::New(); 00255 lines->InsertNextCell( nps /* +1 */ ); 00256 for ( i=0 ; i<nps+1 ; i++ ){ 00257 lines->InsertCellPoint(i % nps ); 00258 } 00259 00260 _pd = vtkPolyData::New(); 00261 _pd->SetPoints( _pts ); 00262 _pd->SetLines( lines ); 00263 lines->Delete(); //do not delete lines ?? 00264 00265 _contourVtkActor = vtkActor::New(); 00266 _bboxMapper = vtkPolyDataMapper::New(); 00267 _bboxMapper->ScalarVisibilityOff( ); 00268 00269 _bboxMapper->SetInput(_pd); 00270 _bboxMapper->ImmediateModeRenderingOn(); 00271 _contourVtkActor->SetMapper(_bboxMapper); 00272 _contourVtkActor->GetProperty()->BackfaceCullingOff(); 00273 00274 UpdateColorActor(); 00275 00276 _pd->ComputeBounds(); 00277 00278 // Text 00279 _textActor = vtkTextActor::New(); 00280 // _textActor->SetDisplayPosition(200, 200); 00281 _textActor->SetInput("00"); 00282 // Set coordinates to match the old vtkScaledTextActor default value 00283 // _textActor->GetPosition2Coordinate()->SetCoordinateSystemToNormalizedViewport(); 00284 // _textActor->GetPosition2Coordinate()->SetValue( 0.2 , 0.2 ); 00285 _textActor->GetPositionCoordinate()->SetCoordinateSystemToWorld (); 00286 // _textActor->GetPositionCoordinate()->SetValue( 0.8 , 0.8 ); 00287 00288 vtkTextProperty *tprop = _textActor->GetTextProperty(); 00289 tprop->SetFontSize(14); 00290 tprop->SetFontFamilyToArial(); 00291 tprop->SetColor(0, 0, 1); 00292 }
void manualViewBaseContour::CopyAttributesTo | ( | manualViewBaseContour * | cloneObject | ) |
Definition at line 119 of file manualViewBaseContour.cpp.
References _coulorEdit_b, _coulorEdit_g, _coulorEdit_r, _coulorNormal_b, _coulorNormal_g, _coulorNormal_r, _coulorSelection_b, _coulorSelection_g, _coulorSelection_r, _lstViewPoints, _spc, _wxvtkbaseview, AddPoint(), GetIfViewControlPoints(), GetPosibleSelected(), GetRange(), GetSelected(), GetZ(), SetColorEditContour(), SetColorNormalContour(), SetColorSelectContour(), SetIfViewControlPoints(), SetPosibleSelected(), SetRange(), SetSelected(), SetSpacing(), SetWxVtkBaseView(), and SetZ().
Referenced by Clone().
00120 { 00121 // Fathers object 00122 //XXXX::CopyAttributesTo(cloneObject); 00123 00124 cloneObject-> SetWxVtkBaseView( this->_wxvtkbaseview ); 00125 cloneObject-> SetSelected( this->GetSelected() ); 00126 cloneObject-> SetPosibleSelected( this->GetPosibleSelected() ); 00127 cloneObject-> SetIfViewControlPoints( this->GetIfViewControlPoints() ); 00128 cloneObject-> SetRange( this->GetRange() ); 00129 cloneObject-> SetZ( this->GetZ() ); 00130 cloneObject-> SetSpacing( _spc ); 00131 cloneObject-> SetColorNormalContour( _coulorNormal_r, _coulorNormal_g, _coulorNormal_b ); 00132 cloneObject-> SetColorEditContour( _coulorEdit_r, _coulorEdit_g, _coulorEdit_b ); 00133 cloneObject-> SetColorSelectContour( _coulorSelection_r, _coulorSelection_g, _coulorSelection_b ); 00134 00135 int i, size = _lstViewPoints.size(); 00136 for ( i=0; i<size; i++ ) 00137 { 00138 cloneObject->AddPoint( ); 00139 } 00140 }
void manualViewBaseContour::CreateNewContour | ( | ) |
Definition at line 294 of file manualViewBaseContour.cpp.
References AddCompleteContourActor(), and ConstructVTKObjects().
Referenced by manualContourBaseControler::CreateNewManualContour(), manualContourBaseControler::ResetContour(), manualContour3VControler::ResetContour_Others(), and wxMaracasCoutourTool::SetControlPoints().
00295 { 00296 ConstructVTKObjects(); 00297 /* 00298 _wxvtkbaseview->GetRenderer()->AddActor( _contourVtkActor ); 00299 _wxvtkbaseview->GetRenderer()->AddActor2D(_textActor);*/ 00300 AddCompleteContourActor(); 00301 }
void manualViewBaseContour::DeleteContour | ( | ) |
Definition at line 356 of file manualViewBaseContour.cpp.
References _lstViewPoints, DeletePoint(), DeleteVtkObjects(), Refresh(), and RemoveCompleteContourActor().
Referenced by manualContourBaseControler::DeleteContour(), manualContour3VControler::ResetContour_Others(), and wxMaracasCoutourTool::SetControlPoints().
00357 { 00358 RemoveCompleteContourActor(); 00359 /*if (_contourVtkActor!=NULL){ 00360 _wxvtkbaseview->GetRenderer()->RemoveActor( _contourVtkActor ); 00361 }*/ 00362 DeleteVtkObjects(); 00363 int i,size=_lstViewPoints.size(); 00364 for (i=0;i<size;i++){ 00365 manualViewBaseContour::DeletePoint(0); 00366 } 00367 Refresh(); 00368 }
void manualViewBaseContour::DeletePoint | ( | int | id | ) | [virtual] |
Reimplemented in manualViewContour.
Definition at line 370 of file manualViewBaseContour.cpp.
References _lstViewPoints, _wxvtkbaseview, wxVtkBaseView::GetRenderer(), manualViewPoint::GetVtkActor(), and Refresh().
00371 { 00372 int size=_lstViewPoints.size(); 00373 if ( (id>=0) && (id<size) ){ 00374 manualViewPoint *mvp =_lstViewPoints[id]; 00375 //EED ups1 00376 // _handlePicker->DeletePickList(mvp->GetVtkActor()); 00377 _wxvtkbaseview->GetRenderer()->RemoveActor( mvp->GetVtkActor() ); 00378 std::vector<manualViewPoint*>::iterator itNum = _lstViewPoints.begin() + id; 00379 _lstViewPoints.erase(itNum); 00380 delete mvp; 00381 Refresh(); 00382 } 00383 }
void manualViewBaseContour::DeletePoint | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 385 of file manualViewBaseContour.cpp.
References GetIdPoint().
Referenced by ClearPoint(), manualContourBaseControler::DeleteActualMousePoint(), manualContour3VControler::DeleteActualMousePoint_Others(), DeleteContour(), and DeleteSelectedPoints().
00386 { 00387 int id=GetIdPoint(x,y,z); 00388 if (id!=-1){ 00389 DeletePoint(id); 00390 } 00391 }
void manualViewBaseContour::DeleteSelectedPoints | ( | ) |
Definition at line 423 of file manualViewBaseContour.cpp.
References _lstViewPoints, DeletePoint(), GetSelected(), and Refresh().
00424 { 00425 int i,size=_lstViewPoints.size(); 00426 for (i=size-1;i>=0;i--){ 00427 if (_lstViewPoints[i]->GetSelected()==true){ 00428 DeletePoint(i); 00429 } 00430 } 00431 Refresh(); 00432 }
void manualViewBaseContour::DeleteVtkObjects | ( | ) | [private] |
Definition at line 196 of file manualViewBaseContour.cpp.
References _bboxMapper, _contourVtkActor, _pd, and _pts.
Referenced by ClearContour(), ConstructVTKObjects(), and DeleteContour().
00197 { 00198 if ( _contourVtkActor != NULL ) { _contourVtkActor -> Delete(); } 00199 if ( _bboxMapper != NULL ) { _bboxMapper -> Delete(); } 00200 if ( _pts != NULL ) { _pts -> Delete(); } 00201 if ( _pd != NULL ) { _pd -> Delete(); } 00202 _contourVtkActor = NULL; 00203 _bboxMapper = NULL; 00204 _pts = NULL; 00205 _pd = NULL; 00206 }
void manualViewBaseContour::GetColorEditContour | ( | double & | r, | |
double & | g, | |||
double & | b | |||
) |
Definition at line 649 of file manualViewBaseContour.cpp.
References _coulorEdit_b, _coulorEdit_g, and _coulorEdit_r.
00650 { 00651 r = _coulorEdit_r; 00652 g = _coulorEdit_g; 00653 b = _coulorEdit_b; 00654 }
void manualViewBaseContour::GetColorNormalContour | ( | double & | r, | |
double & | g, | |||
double & | b | |||
) |
Definition at line 635 of file manualViewBaseContour.cpp.
References _coulorNormal_b, _coulorNormal_g, and _coulorNormal_r.
00636 { 00637 r = _coulorNormal_r; 00638 g = _coulorNormal_g; 00639 b = _coulorNormal_b; 00640 }
void manualViewBaseContour::GetColorSelectContour | ( | double & | r, | |
double & | g, | |||
double & | b | |||
) |
Definition at line 663 of file manualViewBaseContour.cpp.
References _coulorSelection_b, _coulorSelection_g, and _coulorSelection_r.
00664 { 00665 r = _coulorSelection_r; 00666 g = _coulorSelection_g; 00667 b = _coulorSelection_b; 00668 }
bool manualViewBaseContour::GetEditable | ( | ) |
Definition at line 403 of file manualViewBaseContour.cpp.
References _editable.
Referenced by SelectPosibleContour(), and UpdateColorActor().
00404 { 00405 return *_editable; 00406 }
int manualViewBaseContour::GetIdPoint | ( | int | x, | |
int | y, | |||
int | z | |||
) | [virtual] |
Reimplemented in manualView3VContour.
Definition at line 687 of file manualViewBaseContour.cpp.
References _manContModel, _range, manualContourModel::GetIdPoint(), and TransfromCoordViewWorld().
Referenced by manualContourPerpPlaneControler::DeleteActualMousePoint(), manualContourBaseControler::DeleteActualMousePoint(), manualContour3VControler::DeleteActualMousePoint(), manualContour3V3DControler::DeleteActualMousePoint(), DeletePoint(), manualContourBaseControler::Magnet(), manualRoiControler::MouseClickLeft(), manualLineControler::MouseClickLeft(), manualContourControler::MouseClickLeft(), manualCircleControler::MouseClickLeft(), manualContourPerpPlaneControler::MouseMove(), manualContour3VControler::MouseMove(), manualContour3V3DControler::MouseMove(), SelectPosibleContour(), and SelectPosiblePoint().
00688 { 00689 int ii = -1; 00690 if (_manContModel!=NULL){ 00691 double xx = x; 00692 double yy = y; 00693 double zz = z; 00694 TransfromCoordViewWorld(xx,yy,zz); 00695 ii=_manContModel->GetIdPoint(xx,yy,zz,_range,-1); 00696 } 00697 return ii; 00698 }
bool manualViewBaseContour::GetIfViewControlPoints | ( | ) |
Definition at line 457 of file manualViewBaseContour.cpp.
References _viewControlPoints.
Referenced by CopyAttributesTo().
00458 { 00459 return _viewControlPoints; 00460 }
void manualViewBaseContour::GetMinMax | ( | double & | minX, | |
double & | minY, | |||
double & | minZ, | |||
double & | maxX, | |||
double & | maxY, | |||
double & | maxZ | |||
) | [virtual] |
Definition at line 771 of file manualViewBaseContour.cpp.
References _manContModel, manualContourModel::GetManualPoint(), manualContourModel::GetSizeLstPoints(), manualPoint::GetX(), manualPoint::GetY(), and manualPoint::GetZ().
00772 { 00773 double pp[3]; 00774 manualPoint *mp; 00775 int i; 00776 int size=_manContModel->GetSizeLstPoints(); 00777 minX=99999; 00778 minY=99999; 00779 maxX=-99999; 00780 maxY=-99999; 00781 bool ifFindZ = minZ!=-1.0 && maxZ!=-1.0; 00782 if ( ifFindZ ) 00783 { 00784 minZ=99999; 00785 maxZ=-99999; 00786 } 00787 for( i = 0; i < size; i++ ) 00788 { 00789 mp=_manContModel->GetManualPoint(i); 00790 pp[0]=mp->GetX(); 00791 pp[1]=mp->GetY(); 00792 if ( ifFindZ ) 00793 pp[2]=mp->GetZ(); 00794 00795 // min X 00796 if (pp[0]<minX) 00797 { 00798 minX=pp[0]; 00799 } 00800 //min Y 00801 if (pp[1]<minY) 00802 { 00803 minY=pp[1]; 00804 } 00805 //max X 00806 if (pp[0]>maxX) 00807 { 00808 maxX=pp[0]; 00809 } 00810 // max Y 00811 if (pp[1]>maxY) 00812 { 00813 maxY=pp[1]; 00814 } 00815 if ( ifFindZ ) 00816 { 00817 // min Z 00818 if (pp[2]<minZ) 00819 { 00820 minZ=pp[2]; 00821 } 00822 // max Z 00823 if (pp[2]>maxZ) 00824 { 00825 maxZ=pp[2]; 00826 } 00827 } 00828 } 00829 if ( size<1 ) 00830 { 00831 minX = 0; 00832 maxX = 0; 00833 00834 minY = 0; 00835 maxY = 0; 00836 00837 minZ = 0; 00838 maxZ = 0; 00839 } 00840 }
int manualViewBaseContour::GetNumberOfPoints | ( | ) |
Definition at line 703 of file manualViewBaseContour.cpp.
References _lstViewPoints.
Referenced by wxMaracasCoutourTool::AnalisisContourInside(), manualViewCircle::GetMinMax(), manualContourBaseControler::GetNumberOfPointsManualContour(), manualRoiControler::MouseClickLeft(), manualLineControler::MouseClickLeft(), manualContourControler::MouseClickLeft(), manualCircleControler::MouseClickLeft(), manualViewPerpPlaneContour::RefreshContour(), manualViewRoi::RefreshContour(), manualViewContour::RefreshContour(), manualViewBullEye::RefreshContour(), and manualViewContour::RefreshText().
00704 { 00705 return _lstViewPoints.size(); 00706 }
bool manualViewBaseContour::GetPosibleSelected | ( | ) |
Definition at line 418 of file manualViewBaseContour.cpp.
References _posibleSelected.
Referenced by CopyAttributesTo(), and manualViewContour::RefreshText().
00419 { 00420 return _posibleSelected; 00421 }
int manualViewBaseContour::GetRange | ( | ) |
Definition at line 741 of file manualViewBaseContour.cpp.
References _range.
Referenced by CopyAttributesTo(), manualView3VContour::GetIdPoint(), manualView3DContour::GetIdPoint2(), manualViewRoi::ifTouchContour(), manualViewContour::RefreshText(), manualViewPerpPlaneContour::UpdateViewPoint(), and manualView3VContour::UpdateViewPoint().
00742 { 00743 return _range; 00744 }
bool manualViewBaseContour::GetSelected | ( | ) |
Definition at line 413 of file manualViewBaseContour.cpp.
References _selected.
Referenced by CopyAttributesTo(), and DeleteSelectedPoints().
00414 { 00415 return _selected; 00416 }
void manualViewBaseContour::GetSpacing | ( | double | spc[3] | ) |
Definition at line 895 of file manualViewBaseContour.cpp.
References _spc.
Referenced by manualViewBullEye::ConstructVTKObjects().
int manualViewBaseContour::GetType | ( | ) | [virtual] |
Reimplemented in manualView3VContour, manualViewBullEye, manualViewCircle, manualViewContour, manualViewLine, and manualViewRoi.
Definition at line 54 of file manualViewBaseContour.cpp.
Referenced by Save().
00055 { 00056 // Information... 00057 //int manualViewBaseContour::GetType() 0; 00058 //int manualViewContour::GetType() 1; 00059 //int manualViewRoi::GetType() 2; 00060 //int manualViewCircle::GetType() 3; 00061 //int manualViewStar::GetType() 4; 00062 //int manualViewLine::GetType() 6; 00063 00064 00065 return 0; 00066 }
double * manualViewBaseContour::GetVectorPointsXManualContour | ( | ) |
Definition at line 562 of file manualViewBaseContour.cpp.
References _pts, and _sizePointsContour.
Referenced by manualContourBaseControler::GetVectorPointsXManualContour().
00562 { 00563 double pp[3]; 00564 int i,size = _sizePointsContour; 00565 double *vx = (double*)malloc(sizeof(double)*size); 00566 for (i=0;i<size;i++){ 00567 _pts->GetPoint(i,pp); 00568 vx[i]=pp[0]; 00569 } 00570 return vx; 00571 }
double * manualViewBaseContour::GetVectorPointsYManualContour | ( | ) |
Definition at line 573 of file manualViewBaseContour.cpp.
References _pts, and _sizePointsContour.
Referenced by manualContourBaseControler::GetVectorPointsYManualContour().
00574 { 00575 double pp[3]; 00576 int i,size = _sizePointsContour; 00577 double *vy = (double*)malloc(sizeof(double)*size); 00578 for (i=0;i<size;i++){ 00579 _pts->GetPoint(i,pp); 00580 vy[i]=pp[1]; 00581 } 00582 return vy; 00583 }
double * manualViewBaseContour::GetVectorPointsZManualContour | ( | ) |
Definition at line 585 of file manualViewBaseContour.cpp.
References _pts, and _sizePointsContour.
00586 { 00587 double pp[3]; 00588 int i,size = _sizePointsContour; 00589 double *vz = (double*)malloc(sizeof(double)*size); 00590 for (i=0;i<size;i++){ 00591 _pts->GetPoint(i,pp); 00592 vz[i]=pp[2]; 00593 } 00594 return vz; 00595 }
double manualViewBaseContour::GetWidthLine | ( | ) |
Definition at line 225 of file manualViewBaseContour.cpp.
References _widthline.
Referenced by manualViewBullEye::ConstructVTKObjects().
00226 { 00227 return _widthline; 00228 }
wxVtkBaseView * manualViewBaseContour::GetWxVtkBaseView | ( | ) |
Definition at line 890 of file manualViewBaseContour.cpp.
References _wxvtkbaseview.
Referenced by AddPoint(), manualViewBullEye::ConstructVTKObjects(), manualViewPerpPlaneContour::FilterCordinateXYZ(), manualView3DContour::GetIdPoint2(), manualViewPerpPlaneContour::ifTouchContour(), InsertPoint(), manualViewPerpPlaneContour::RefreshContour(), and manualViewPerpPlaneContour::TransfromCoordViewWorld().
00891 { 00892 return this->_wxvtkbaseview; 00893 }
int manualViewBaseContour::GetZ | ( | ) |
Definition at line 751 of file manualViewBaseContour.cpp.
Referenced by CopyAttributesTo().
bool manualViewBaseContour::ifTouchContour | ( | int | x, | |
int | y, | |||
int | z | |||
) | [virtual] |
Reimplemented in manualView3VContour, manualViewContour, manualViewRoi, and manualViewPerpPlaneContour.
Definition at line 528 of file manualViewBaseContour.cpp.
Referenced by SelectPosibleContour().
void manualViewBaseContour::InitMove | ( | int | x, | |
int | y, | |||
int | z | |||
) | [virtual] |
Reimplemented in manualViewCircle, manualViewContour, manualViewLine, and manualViewRoi.
Definition at line 757 of file manualViewBaseContour.cpp.
Referenced by manualRoiControler::MouseClickLeft(), manualLineControler::MouseClickLeft(), manualContourControler::MouseClickLeft(), manualCircleControler::MouseClickLeft(), and manualContourBaseControler::OnMiddleButtonDown().
void manualViewBaseContour::InsertPoint | ( | int | id | ) |
Definition at line 344 of file manualViewBaseContour.cpp.
References _lstViewPoints, _spc, _wxvtkbaseview, manualViewPoint::CreateVtkPointActor(), wxVtkBaseView::GetRenderer(), GetWxVtkBaseView(), and manualViewPoint::SetSpacing().
Referenced by manualContourBaseControler::InsertPoint(), manualContour3VControler::InsertPoint(), and manualContour3VControler::InsertPoint_Others().
00345 { 00346 manualViewPoint *mvp = new manualViewPoint( this->GetWxVtkBaseView() ); 00347 00348 // EED 3 oct 2006 00349 mvp->SetSpacing(_spc); 00350 00351 std::vector<manualViewPoint*>::iterator itNum = _lstViewPoints.begin() + id; 00352 _lstViewPoints.insert(itNum,mvp); 00353 _wxvtkbaseview->GetRenderer()->AddActor( mvp->CreateVtkPointActor() ); 00354 }
void manualViewBaseContour::MoveContour | ( | int | horizontalUnits, | |
int | verticalUnits | |||
) | [virtual] |
void manualViewBaseContour::MoveContour | ( | int | x, | |
int | y, | |||
int | z | |||
) | [virtual] |
Reimplemented in manualViewCircle, manualViewContour, manualViewLine, and manualViewRoi.
Definition at line 762 of file manualViewBaseContour.cpp.
Referenced by manualRoiControler::MouseMove(), manualLineControler::MouseMove(), manualContourControler::MouseMove(), manualCircleControler::MouseMove(), and manualContourBaseControler::OnChar().
void manualViewBaseContour::Open | ( | FILE * | pFile | ) | [virtual] |
void manualViewBaseContour::Refresh | ( | ) | [virtual] |
Definition at line 597 of file manualViewBaseContour.cpp.
References _contourVtkActor, _lstViewPoints, _show_text, _wxvtkbaseview, wxVtkBaseView::GetRenWin(), wxVtkBaseView::GetWxVTKRenderWindowInteractor(), RefreshContour(), RefreshText(), UpdateColorActor(), and UpdateViewPoint().
Referenced by AddCompleteContourActor(), ClearContour(), wxImageViewerWidget::CreateNewManualContour(), manualContour3VControler::DeleteActualMousePoint_Others(), DeleteContour(), DeletePoint(), DeleteSelectedPoints(), manualRoiControler::InitRoi(), manualLineControler::InitRoi(), manualCircleControler::InitRoi(), manualRoiControler::MouseClickLeft(), manualLineControler::MouseClickLeft(), manualContourControler::MouseClickLeft(), manualCircleControler::MouseClickLeft(), manualContourControler::MouseDLeft(), manualRoiControler::MouseMove(), manualLineControler::MouseMove(), manualContourControler::MouseMove(), manualCircleControler::MouseMove(), manualContour3VControler::MouseMove_Others(), manualContourBaseControler::OnChar(), manualContour3VControler::OnChar_Others(), wxWidgetMesure2D::OnCloseContour(), wxWidgetMesure2D::OnVisibleInformation(), wxWidgetMesure2D::OnVisibleMessureTool(), manualContourContainer::refreshLumen(), manualContourContainer::refreshWall(), RemoveCompleteContourActor(), manualContourContainer::setLumenVisibility(), manualContourContainer::setWallVisibility(), UnSelectAllPoints(), and UnSelectPoint().
00598 { 00599 if (_contourVtkActor!=NULL){ 00600 RefreshContour(); 00601 } 00602 int i,size=_lstViewPoints.size(); 00603 for (i=0;i<size;i++){ 00604 UpdateViewPoint(i); 00605 _lstViewPoints[i]->UpdateColorActor(); 00606 } 00607 UpdateColorActor(); 00608 00609 if (_show_text==true) 00610 { 00611 RefreshText(); 00612 } 00613 00614 vtkRenderWindowInteractor *vri = _wxvtkbaseview->GetWxVTKRenderWindowInteractor (); 00615 if (vri==NULL) 00616 { 00617 _wxvtkbaseview->GetRenWin()->Render(); 00618 } 00619 00620 }
void manualViewBaseContour::RefreshContour | ( | ) | [virtual] |
Reimplemented in manualView3VContour, manualViewBullEye, manualViewBullEyeSector, manualViewContour, manualViewRoi, and manualViewPerpPlaneContour.
Definition at line 558 of file manualViewBaseContour.cpp.
Referenced by AddCompleteContourActor(), Refresh(), and RemoveCompleteContourActor().
void manualViewBaseContour::RefreshText | ( | ) | [private, virtual] |
Reimplemented in manualViewContour.
Definition at line 622 of file manualViewBaseContour.cpp.
References _textActor.
Referenced by Refresh().
00623 { 00624 if( _textActor!=NULL) 00625 _textActor -> SetInput("00"); 00626 }
void manualViewBaseContour::RemoveCompleteContourActor | ( | ) |
Definition at line 96 of file manualViewBaseContour.cpp.
References _wxvtkbaseview, wxVtkBaseView::GetRenderer(), Refresh(), RefreshContour(), RemoveControlPoints(), RemoveSplineActor(), and RemoveTextActor().
Referenced by DeleteContour().
00097 { 00098 /*vtkRenderer * theRenderer =*/ _wxvtkbaseview->GetRenderer(); // JPRx ?? 00099 //Removing the spline 00100 RemoveSplineActor(); 00101 RemoveTextActor(); 00102 00103 //Removing each point 00104 RemoveControlPoints(); 00105 RefreshContour(); 00106 Refresh(); 00107 }
void manualViewBaseContour::RemoveControlPoints | ( | ) |
Definition at line 157 of file manualViewBaseContour.cpp.
References _lstViewPoints, _wxvtkbaseview, wxVtkBaseView::GetRenderer(), and SetIfViewControlPoints().
Referenced by manualContourControler::MouseMove(), RemoveCompleteContourActor(), and manualContourBaseControler::SetEditable().
00158 { 00159 if (_wxvtkbaseview!=NULL){ 00160 vtkRenderer * theRenderer = _wxvtkbaseview->GetRenderer(); 00161 int i,size=_lstViewPoints.size(); 00162 for (i=0;i<size; i++) 00163 { 00164 vtkActor * pointActor = _lstViewPoints[i]->GetVtkActor(); 00165 theRenderer->RemoveActor( pointActor ); 00166 } // for 00167 } // if 00168 SetIfViewControlPoints( false ); 00169 }
void manualViewBaseContour::RemoveSplineActor | ( | ) | [virtual] |
Reimplemented in manualViewBullEye.
Definition at line 150 of file manualViewBaseContour.cpp.
References _contourVtkActor, _wxvtkbaseview, and wxVtkBaseView::GetRenderer().
Referenced by RemoveCompleteContourActor().
00151 { 00152 vtkRenderer * theRenderer = _wxvtkbaseview->GetRenderer(); 00153 if (_contourVtkActor!=NULL) 00154 theRenderer->RemoveActor( _contourVtkActor ); 00155 }
void manualViewBaseContour::RemoveTextActor | ( | ) |
Definition at line 191 of file manualViewBaseContour.cpp.
References _textActor, _wxvtkbaseview, and wxVtkBaseView::GetRenderer().
Referenced by RemoveCompleteContourActor().
00192 { 00193 _wxvtkbaseview->GetRenderer()->RemoveActor2D( _textActor ); 00194 }
void manualViewBaseContour::Save | ( | FILE * | pFile | ) | [virtual] |
Reimplemented in manualViewContour.
Definition at line 69 of file manualViewBaseContour.cpp.
References GetType().
00070 { 00071 fprintf(pFile,"TypeView %d\n", GetType() ); 00072 }
void manualViewBaseContour::SelectAllPoints | ( | bool | select | ) |
Definition at line 444 of file manualViewBaseContour.cpp.
References _lstViewPoints, and SelectPoint().
00445 { 00446 int i,size=_lstViewPoints.size(); 00447 for (i=0;i<size;i++){ 00448 SelectPoint(i,select); 00449 } 00450 }
void manualViewBaseContour::SelectAllPossibleSelected | ( | bool | select | ) |
Definition at line 473 of file manualViewBaseContour.cpp.
References _lstViewPoints, and SetPointPosibleSelected().
Referenced by manualContour3VControler::MouseMove_Others(), SelectPosiblePoint(), and manualView3DContour::SelectPosiblePoint().
00474 { 00475 int i,size=_lstViewPoints.size(); 00476 for (i=0;i<size;i++){ 00477 SetPointPosibleSelected(i,select); 00478 } 00479 }
void manualViewBaseContour::SelectLstPoints | ( | ) |
void manualViewBaseContour::SelectPoint | ( | int | i, | |
bool | select | |||
) |
Definition at line 434 of file manualViewBaseContour.cpp.
References _lstViewPoints.
Referenced by SelectAllPoints().
00435 { 00436 _lstViewPoints[i]->SetSelected(select); 00437 }
bool manualViewBaseContour::SelectPosibleContour | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 493 of file manualViewBaseContour.cpp.
References _lstViewPoints, _selected, GetEditable(), GetIdPoint(), ifTouchContour(), and SetPosibleSelected().
Referenced by manualContourBaseControler::MouseDLeft(), manualRoiControler::MouseMove(), manualLineControler::MouseMove(), manualContourControler::MouseMove(), manualCircleControler::MouseMove(), and manualContourBaseControler::MouseReleaseLeft().
00494 { 00495 bool result=false; 00496 SetPosibleSelected(result); 00497 int id = GetIdPoint(x,y,z); 00498 if( !GetEditable() && !_selected && id!= -1) 00499 { 00500 result=true; 00501 SetPosibleSelected(result); 00502 } 00503 else 00504 { 00505 if ( (GetEditable()==true) && (id==-1 ) && (this->_lstViewPoints.size()>=2) ) 00506 { 00507 if (ifTouchContour(x,y,z)==true) 00508 { 00509 result=true; 00510 SetPosibleSelected(result); 00511 } 00512 } 00513 00514 if (GetEditable()==false) 00515 { 00516 if (ifTouchContour(x,y,z)==true) 00517 { 00518 result=true; 00519 SetPosibleSelected(result); 00520 } 00521 } 00522 00523 00524 } 00525 return result; 00526 }
int manualViewBaseContour::SelectPosiblePoint | ( | int | x, | |
int | y, | |||
int | z | |||
) | [virtual] |
Reimplemented in manualView3DContour.
Definition at line 481 of file manualViewBaseContour.cpp.
References GetIdPoint(), SelectAllPossibleSelected(), and SetPointPosibleSelected().
Referenced by manualContourBaseControler::MouseDLeft(), manualRoiControler::MouseMove(), manualLineControler::MouseMove(), manualContourControler::MouseMove(), and manualCircleControler::MouseMove().
00482 { 00483 SelectAllPossibleSelected(false); 00484 00485 int id = GetIdPoint(x,y,z); 00486 if (id!=-1) 00487 { 00488 SetPointPosibleSelected(id,true); 00489 } 00490 return id; 00491 }
void manualViewBaseContour::SetColorEditContour | ( | double | r, | |
double | g, | |||
double | b | |||
) |
Definition at line 642 of file manualViewBaseContour.cpp.
References _coulorEdit_b, _coulorEdit_g, and _coulorEdit_r.
Referenced by wxEmptyPanel_3_Widget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), CopyAttributesTo(), manualContourContainer::createLumenContour(), manualContourContainer::createWallContour(), manualContourContainer::restartLumenContour(), and manualContourContainer::restartWallContour().
00643 { 00644 _coulorEdit_r = r; 00645 _coulorEdit_g = g; 00646 _coulorEdit_b = b; 00647 }
void manualViewBaseContour::SetColorNormalContour | ( | double | r, | |
double | g, | |||
double | b | |||
) |
Definition at line 628 of file manualViewBaseContour.cpp.
References _coulorNormal_b, _coulorNormal_g, and _coulorNormal_r.
Referenced by wxEmptyPanel_3_Widget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), manualViewBullEye::ConstructVTKObjects(), CopyAttributesTo(), manualContourContainer::createLumenContour(), manualContourContainer::createWallContour(), manualContourContainer::restartLumenContour(), and manualContourContainer::restartWallContour().
00629 { 00630 _coulorNormal_r = r; 00631 _coulorNormal_g = g; 00632 _coulorNormal_b = b; 00633 }
void manualViewBaseContour::SetColorSelectContour | ( | double | r, | |
double | g, | |||
double | b | |||
) |
Definition at line 656 of file manualViewBaseContour.cpp.
References _coulorSelection_b, _coulorSelection_g, and _coulorSelection_r.
Referenced by CopyAttributesTo().
00657 { 00658 _coulorSelection_r = r; 00659 _coulorSelection_g = g; 00660 _coulorSelection_b = b; 00661 }
void manualViewBaseContour::SetEditable | ( | bool * | condition | ) |
Definition at line 408 of file manualViewBaseContour.cpp.
References _editable.
Referenced by manualContourBaseControler::SetModelView().
00409 { 00410 _editable = condition; 00411 }
void manualViewBaseContour::SetIfViewControlPoints | ( | bool | ifShow | ) |
Definition at line 452 of file manualViewBaseContour.cpp.
References _viewControlPoints.
Referenced by AddControlPoints(), CopyAttributesTo(), and RemoveControlPoints().
00453 { 00454 _viewControlPoints = ifShow; 00455 }
void manualViewBaseContour::SetModel | ( | manualContourModel * | manContModel | ) |
Definition at line 550 of file manualViewBaseContour.cpp.
References _manContModel.
Referenced by wxWidgetMesure2D::ConfigureA(), wxManualTree_MPRWidget::ConfigureContour(), wxEmptyPanel_3_Widget::ConfigureVTK(), ContourVOIWidget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), wxImageViewerWidget::ConstructVTK(), manualViewBullEye::ConstructVTKObjects(), manualContourContainer::createLumenContour(), manualContourContainer::createWallContour(), wxMaracasImageBrowser02::LoadData(), manualContourContainer::restartLumenContour(), and manualContourContainer::restartWallContour().
00550 { 00551 _manContModel=manContModel; 00552 }
void manualViewBaseContour::SetPointPosibleSelected | ( | int | id, | |
bool | select | |||
) |
Definition at line 463 of file manualViewBaseContour.cpp.
References _lstViewPoints.
Referenced by manualContour3VControler::MouseMove_Others(), SelectAllPossibleSelected(), SelectPosiblePoint(), and manualView3DContour::SelectPosiblePoint().
00464 { 00465 _lstViewPoints[id]->SetPosibleSelected(select); 00466 }
void manualViewBaseContour::SetPointSelected | ( | int | id, | |
bool | select | |||
) |
Definition at line 468 of file manualViewBaseContour.cpp.
References _lstViewPoints.
00469 { 00470 _lstViewPoints[id]->SetSelected(select); 00471 }
void manualViewBaseContour::SetPosibleSelected | ( | bool | posibleSelected | ) |
Definition at line 398 of file manualViewBaseContour.cpp.
References _posibleSelected.
Referenced by CopyAttributesTo(), manualContour3VControler::MouseMove_Others(), and SelectPosibleContour().
00399 { 00400 _posibleSelected=posibleSelected; 00401 }
void manualViewBaseContour::SetRange | ( | int | range | ) |
Definition at line 736 of file manualViewBaseContour.cpp.
References _range.
Referenced by manualContourContainer::addCalcificationContour(), manualContourContainer::addHypodenseContour(), wxWidgetMesure2D::ConfigureA(), wxManualTree_MPRWidget::ConfigureContour(), wxEmptyPanel_3_Widget::ConfigureVTK(), ContourVOIWidget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), wxImageViewerWidget::ConstructVTK(), manualViewBullEye::ConstructVTKObjects(), CopyAttributesTo(), manualContourContainer::createLumenContour(), manualContourContainer::createWallContour(), wxMaracasImageBrowser02::LoadData(), manualContourContainer::restartLumenContour(), and manualContourContainer::restartWallContour().
00737 { 00738 _range=range; 00739 }
void manualViewBaseContour::SetSelected | ( | bool | selected | ) |
Definition at line 393 of file manualViewBaseContour.cpp.
References _selected.
Referenced by CopyAttributesTo(), manualContourControler::MouseClickLeft(), and manualContourBaseControler::SetEditable().
00394 { 00395 _selected=selected; 00396 }
void manualViewBaseContour::SetShowText | ( | bool | ok | ) |
Definition at line 881 of file manualViewBaseContour.cpp.
References _show_text, and _textActor.
Referenced by wxWidgetMesure2D::OnVisibleInformation().
00882 { 00883 _show_text = ok; 00884 if (_show_text==false) 00885 { 00886 _textActor->SetInput("00"); 00887 } 00888 }
void manualViewBaseContour::SetSpacing | ( | double | spc[3] | ) |
Definition at line 902 of file manualViewBaseContour.cpp.
References _spc.
Referenced by wxManualTree_MPRWidget::ConfigureContour(), wxEmptyPanel_3_Widget::ConfigureVTK(), ContourVOIWidget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), manualViewBullEye::ConstructVTKObjects(), CopyAttributesTo(), and wxMaracasImageBrowser02::LoadData().
void manualViewBaseContour::SetVisible | ( | bool | ok | ) |
Definition at line 860 of file manualViewBaseContour.cpp.
References _contourVtkActor, _lstViewPoints, and _textActor.
Referenced by wxWidgetMesure2D::OnActiveMessureTool(), wxWidgetMesure2D::OnVisibleMessureTool(), manualContourContainer::setLumenVisibility(), and manualContourContainer::setWallVisibility().
00861 { 00862 double opacity; 00863 if (ok==true) 00864 { 00865 opacity=1; 00866 } else { 00867 opacity=0.5; 00868 } 00869 vtkActor *actor; 00870 int i,size=_lstViewPoints.size(); 00871 for (i=0;i<size;i++){ 00872 actor = _lstViewPoints[i]->GetVtkActor(); 00873 actor->GetProperty()->SetOpacity( opacity ); 00874 } 00875 _contourVtkActor->GetProperty()->SetOpacity( opacity ); 00876 _textActor->GetProperty()->SetOpacity( opacity ); 00877 _textActor->SetInput("00"); 00878 00879 }
void manualViewBaseContour::SetWidthLine | ( | double | width | ) |
Definition at line 210 of file manualViewBaseContour.cpp.
References _lstViewPoints, _widthline, and UpdateColorActor().
Referenced by manualViewBullEye::ConstructVTKObjects().
00211 { 00212 _widthline = width; 00213 this->UpdateColorActor(); 00214 00215 // for the control points 00216 int id, size = _lstViewPoints.size(); 00217 for( id=0; id<size; id++) 00218 { 00219 this->_lstViewPoints[id]->SetWidthLine(_widthline); 00220 } 00221 00222 }
void manualViewBaseContour::SetWxVtkBaseView | ( | wxVtkBaseView * | wxvtkbaseview | ) |
Definition at line 554 of file manualViewBaseContour.cpp.
References _wxvtkbaseview.
Referenced by wxWidgetMesure2D::ConfigureA(), wxManualTree_MPRWidget::ConfigureContour(), wxEmptyPanel_3_Widget::ConfigureVTK(), ContourVOIWidget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), wxImageViewerWidget::ConstructVTK(), manualViewBullEye::ConstructVTKObjects(), CopyAttributesTo(), manualContourContainer::createLumenContour(), manualContourContainer::createWallContour(), wxMaracasImageBrowser02::LoadData(), manualContourContainer::restartLumenContour(), and manualContourContainer::restartWallContour().
00554 { 00555 _wxvtkbaseview = wxvtkbaseview; 00556 }
void manualViewBaseContour::SetZ | ( | int | z | ) |
Definition at line 746 of file manualViewBaseContour.cpp.
Referenced by wxEmptyPanel_3_Widget::ConfigureVTK(), ContourVOIWidget::ConfigureVTK(), wxMaracasCoutourTool::ConfigureVTK(), manualViewBullEye::ConstructVTKObjects(), CopyAttributesTo(), manualContourContainer::createLumenContour(), manualContourContainer::createWallContour(), manualContourContainer::restartLumenContour(), and manualContourContainer::restartWallContour().
void manualViewBaseContour::TransfromCoordViewWorld | ( | double & | X, | |
double & | Y, | |||
double & | Z, | |||
int | type = 2 | |||
) | [virtual] |
Reimplemented in manualView3DContour, and manualViewPerpPlaneContour.
Definition at line 724 of file manualViewBaseContour.cpp.
References _wxvtkbaseview, and wxVtkBaseView::TransFromCoordScreenToWorld().
Referenced by manualContourBaseControler::AddPoint(), manualContour3VControler::AddPoint(), GetIdPoint(), manualView3VContour::GetIdPoint(), manualViewRoi::ifTouchContour(), manualViewContour::ifTouchContour(), manualView3VContour::ifTouchContour(), manualViewRoi::InitMove(), manualViewLine::InitMove(), manualViewContour::InitMove(), manualViewCircle::InitMove(), manualContourBaseControler::InsertPoint(), manualContour3VControler::InsertPoint(), manualContourBaseControler::Magnet(), manualViewRoi::MoveContour(), manualViewLine::MoveContour(), manualViewContour::MoveContour(), manualViewCircle::MoveContour(), manualContourBaseControler::SetPoint(), manualContour3VControler::SetPoint(), manualContourBaseControler::SetPointX(), manualContourBaseControler::SetPointY(), and manualContourBaseControler::SetPointZ().
00725 { 00726 _wxvtkbaseview->TransFromCoordScreenToWorld(X, Y, Z,false, type); 00727 00728 00729 //EED 27 sep 2007 00730 // //EEDx6 00731 // wxVtk2DBaseView *wxvtk2Dbaseview = (wxVtk2DBaseView*)_wxvtkbaseview; 00732 // wxvtk2Dbaseview->TransformCoordinate_spacing_ModelToView(X,Y,Z); 00733 00734 }
void manualViewBaseContour::UnSelectAllPoints | ( | ) |
Definition at line 542 of file manualViewBaseContour.cpp.
References _lstViewPoints, Refresh(), and UnSelectPoint().
00542 { 00543 int i,size=_lstViewPoints.size(); 00544 for (i=0;i<size;i++){ 00545 UnSelectPoint(i); 00546 } 00547 Refresh(); 00548 }
void manualViewBaseContour::UnSelectLstPoints | ( | ) |
void manualViewBaseContour::UnSelectPoint | ( | int | i | ) |
Definition at line 533 of file manualViewBaseContour.cpp.
References _lstViewPoints, and Refresh().
Referenced by UnSelectAllPoints().
00533 { 00534 _lstViewPoints[i]->SetSelected(false); 00535 Refresh(); 00536 }
void manualViewBaseContour::UpdateColorActor | ( | ) |
Definition at line 670 of file manualViewBaseContour.cpp.
References _contourVtkActor, _coulorEdit_b, _coulorEdit_g, _coulorEdit_r, _coulorNormal_b, _coulorNormal_g, _coulorNormal_r, _coulorSelection_b, _coulorSelection_g, _coulorSelection_r, _posibleSelected, _selected, _widthline, and GetEditable().
Referenced by ConstructVTKObjects(), Refresh(), and SetWidthLine().
00671 { 00672 if (_contourVtkActor!=NULL) 00673 { 00674 _contourVtkActor->GetProperty()->SetLineWidth( _widthline ); 00675 _contourVtkActor->GetProperty()->SetDiffuseColor( _coulorNormal_r , _coulorNormal_g , _coulorNormal_b ); 00676 if (_posibleSelected || (_posibleSelected && GetEditable() ) ) 00677 { 00678 _contourVtkActor->GetProperty()->SetDiffuseColor( _coulorEdit_r , _coulorEdit_g , _coulorEdit_b ); 00679 } 00680 if( _selected ) 00681 { 00682 _contourVtkActor->GetProperty()->SetDiffuseColor( _coulorSelection_r , _coulorSelection_g , _coulorSelection_b ); 00683 } 00684 } 00685 }
void manualViewBaseContour::UpdateViewPoint | ( | int | id | ) | [virtual] |
Reimplemented in manualView3VContour, and manualViewPerpPlaneContour.
Definition at line 303 of file manualViewBaseContour.cpp.
References _lstViewPoints, _manContModel, _range, manualContourModel::GetManualPoint(), manualPoint::GetX(), manualPoint::GetY(), and manualPoint::GetZ().
Referenced by manualRoiControler::InitRoi(), manualLineControler::InitRoi(), manualCircleControler::InitRoi(), manualViewRoi::MoveContour(), manualViewLine::MoveContour(), manualViewCircle::MoveContour(), Refresh(), manualContourBaseControler::SetPoint(), manualContourBaseControler::SetPointX(), manualContourBaseControler::SetPointY(), manualContourBaseControler::SetPointZ(), manualRoiControler::SetRoi(), and UpdateViewPoints().
00304 { 00305 manualPoint *mp = _manContModel->GetManualPoint(id); 00306 00307 //EEDx6 00308 double XX=mp->GetX(),YY=mp->GetY(),ZZ=mp->GetZ(); 00309 // wxVtk2DBaseView *wxvtk2Dbasevie = (wxVtk2DBaseView*)this->GetWxVtkBaseView(); 00310 // wxvtk2Dbasevie->TransformCoordinate_spacing_ModelToView(XX,YY,ZZ); 00311 00312 _lstViewPoints[id]->SetPositionXY( XX , YY ,_range, ZZ ); 00313 }
void manualViewBaseContour::UpdateViewPoints | ( | ) | [virtual] |
Definition at line 316 of file manualViewBaseContour.cpp.
References _lstViewPoints, and UpdateViewPoint().
Referenced by manualViewContour::MoveContour().
00317 { 00318 int id, size = _lstViewPoints.size(); 00319 for( id=0; id<size; id++) 00320 { 00321 UpdateViewPoint( id ); 00322 } 00323 }
vtkPolyDataMapper* manualViewBaseContour::_bboxMapper [private] |
Definition at line 173 of file manualViewBaseContour.h.
Referenced by ConstructVTKObjects(), DeleteVtkObjects(), and manualViewBaseContour().
vtkActor* manualViewBaseContour::_contourVtkActor [private] |
Definition at line 172 of file manualViewBaseContour.h.
Referenced by AddSplineActor(), ClearContour(), ConstructVTKObjects(), DeleteVtkObjects(), manualViewBaseContour(), Refresh(), RemoveSplineActor(), SetVisible(), and UpdateColorActor().
double manualViewBaseContour::_coulorEdit_b [private] |
Definition at line 177 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorEditContour(), manualViewBaseContour(), SetColorEditContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorEdit_g [private] |
Definition at line 176 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorEditContour(), manualViewBaseContour(), SetColorEditContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorEdit_r [private] |
Definition at line 175 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorEditContour(), manualViewBaseContour(), SetColorEditContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorNormal_b [private] |
Definition at line 180 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorNormalContour(), manualViewBaseContour(), SetColorNormalContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorNormal_g [private] |
Definition at line 179 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorNormalContour(), manualViewBaseContour(), SetColorNormalContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorNormal_r [private] |
Definition at line 178 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorNormalContour(), manualViewBaseContour(), SetColorNormalContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorSelection_b [private] |
Definition at line 183 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorSelectContour(), manualViewBaseContour(), SetColorSelectContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorSelection_g [private] |
Definition at line 182 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorSelectContour(), manualViewBaseContour(), SetColorSelectContour(), and UpdateColorActor().
double manualViewBaseContour::_coulorSelection_r [private] |
Definition at line 181 of file manualViewBaseContour.h.
Referenced by CopyAttributesTo(), GetColorSelectContour(), manualViewBaseContour(), SetColorSelectContour(), and UpdateColorActor().
bool* manualViewBaseContour::_editable [private] |
Definition at line 166 of file manualViewBaseContour.h.
Referenced by GetEditable(), and SetEditable().
int manualViewBaseContour::_id_viewPoint_for_text [protected] |
Definition at line 194 of file manualViewBaseContour.h.
Referenced by manualViewContour::manualViewContour(), and manualViewContour::RefreshText().
std::vector<manualViewPoint*> manualViewBaseContour::_lstViewPoints [protected] |
Definition at line 201 of file manualViewBaseContour.h.
Referenced by AddControlPoints(), AddPoint(), ClearContour(), CopyAttributesTo(), DeleteContour(), manualViewContour::DeletePoint(), DeletePoint(), DeleteSelectedPoints(), GetNumberOfPoints(), InsertPoint(), Refresh(), manualViewContour::RefreshText(), RemoveControlPoints(), SelectAllPoints(), SelectAllPossibleSelected(), SelectPoint(), SelectPosibleContour(), SetPointPosibleSelected(), SetPointSelected(), SetVisible(), SetWidthLine(), UnSelectAllPoints(), UnSelectPoint(), manualViewPerpPlaneContour::UpdateViewPoint(), UpdateViewPoint(), manualView3VContour::UpdateViewPoint(), UpdateViewPoints(), and ~manualViewBaseContour().
manualContourModel* manualViewBaseContour::_manContModel [protected] |
Definition at line 196 of file manualViewBaseContour.h.
Referenced by manualViewBullEye::ConstructVTKObjects(), ConstructVTKObjects(), GetIdPoint(), manualView3VContour::GetIdPoint(), manualView3DContour::GetIdPoint2(), manualViewRoi::GetMinMax(), manualViewCircle::GetMinMax(), GetMinMax(), manualViewContour::ifTouchContour(), manualView3VContour::ifTouchContour(), manualViewRoi::InitMove(), manualViewLine::InitMove(), manualViewContour::InitMove(), manualViewCircle::InitMove(), manualViewBaseContour(), manualViewRoi::MoveContour(), manualViewLine::MoveContour(), manualViewContour::MoveContour(), manualViewCircle::MoveContour(), manualViewPerpPlaneContour::RefreshContour(), manualViewRoi::RefreshContour(), manualViewContour::RefreshContour(), manualViewBullEyeSector::RefreshContour(), manualViewBullEye::RefreshContour(), manualView3VContour::RefreshContour(), manualViewContour::RefreshText(), SetModel(), manualViewPerpPlaneContour::UpdateViewPoint(), UpdateViewPoint(), and manualView3VContour::UpdateViewPoint().
vtkPolyData* manualViewBaseContour::_pd [private] |
Definition at line 171 of file manualViewBaseContour.h.
Referenced by ConstructVTKObjects(), DeleteVtkObjects(), and manualViewBaseContour().
bool manualViewBaseContour::_posibleSelected [private] |
Definition at line 167 of file manualViewBaseContour.h.
Referenced by GetPosibleSelected(), manualViewBaseContour(), SetPosibleSelected(), and UpdateColorActor().
vtkPoints* manualViewBaseContour::_pts [protected] |
Definition at line 197 of file manualViewBaseContour.h.
Referenced by ConstructVTKObjects(), DeleteVtkObjects(), GetVectorPointsXManualContour(), GetVectorPointsYManualContour(), GetVectorPointsZManualContour(), manualViewPerpPlaneContour::ifTouchContour(), manualViewContour::ifTouchContour(), manualView3VContour::ifTouchContour(), manualViewBaseContour(), manualViewPerpPlaneContour::RefreshContour(), manualViewRoi::RefreshContour(), manualViewContour::RefreshContour(), manualViewBullEyeSector::RefreshContour(), and manualView3VContour::RefreshContour().
int manualViewBaseContour::_range [private] |
Definition at line 162 of file manualViewBaseContour.h.
Referenced by GetIdPoint(), GetRange(), manualViewBaseContour(), SetRange(), and UpdateViewPoint().
bool manualViewBaseContour::_selected [private] |
Definition at line 165 of file manualViewBaseContour.h.
Referenced by GetSelected(), manualViewBaseContour(), SelectPosibleContour(), SetSelected(), and UpdateColorActor().
bool manualViewBaseContour::_show_text [protected] |
Definition at line 193 of file manualViewBaseContour.h.
Referenced by manualViewBaseContour(), Refresh(), and SetShowText().
int manualViewBaseContour::_sizePointsContour [protected] |
Definition at line 199 of file manualViewBaseContour.h.
Referenced by GetVectorPointsXManualContour(), GetVectorPointsYManualContour(), GetVectorPointsZManualContour(), manualViewContour::ifTouchContour(), manualView3VContour::ifTouchContour(), manualViewBaseContour(), manualViewLine::manualViewLine(), and manualViewRoi::manualViewRoi().
double manualViewBaseContour::_spc[3] [protected] |
Definition at line 202 of file manualViewBaseContour.h.
Referenced by AddPoint(), CopyAttributesTo(), GetSpacing(), manualViewContour::ifTouchContour(), manualView3VContour::ifTouchContour(), InsertPoint(), manualViewBaseContour(), manualViewPerpPlaneContour::RefreshContour(), manualViewRoi::RefreshContour(), manualViewContour::RefreshContour(), manualViewBullEyeSector::RefreshContour(), manualViewContour::RefreshText(), and SetSpacing().
vtkTextActor* manualViewBaseContour::_textActor [protected] |
Definition at line 195 of file manualViewBaseContour.h.
Referenced by AddTextActor(), ConstructVTKObjects(), manualViewBaseContour(), manualViewContour::RefreshText(), RefreshText(), RemoveTextActor(), SetShowText(), and SetVisible().
bool manualViewBaseContour::_viewControlPoints [private] |
Definition at line 168 of file manualViewBaseContour.h.
Referenced by AddCompleteContourActor(), AddControlPoints(), GetIfViewControlPoints(), manualViewBaseContour(), and SetIfViewControlPoints().
double manualViewBaseContour::_widthline [private] |
Definition at line 184 of file manualViewBaseContour.h.
Referenced by GetWidthLine(), manualViewBaseContour(), SetWidthLine(), and UpdateColorActor().
Definition at line 164 of file manualViewBaseContour.h.
Referenced by AddCompleteContourActor(), AddControlPoints(), AddPoint(), AddSplineActor(), AddTextActor(), ClearContour(), CopyAttributesTo(), DeletePoint(), GetWxVtkBaseView(), InsertPoint(), manualViewBaseContour(), Refresh(), RemoveCompleteContourActor(), RemoveControlPoints(), RemoveSplineActor(), RemoveTextActor(), SetWxVtkBaseView(), and TransfromCoordViewWorld().