1 #include "manualViewLine.h"
4 // ----------------------------------------------------------------------------
5 // ----------------------------------------------------------------------------
6 // ----------------------------------------------------------------------------
10 manualViewLine::manualViewLine()
12 _sizePointsContour=20;
14 // ----------------------------------------------------------------------------
15 manualViewLine::~manualViewLine()
20 // ----------------------------------------------------------------------------
21 manualViewLine * manualViewLine :: Clone()
23 manualViewLine * clone = new manualViewLine();
24 CopyAttributesTo(clone);
28 // ---------------------------------------------------------------------------
30 void manualViewLine::CopyAttributesTo( manualViewLine * cloneObject)
33 manualViewBaseContour::CopyAttributesTo(cloneObject);
36 // ----------------------------------------------------------------------------
37 int manualViewLine::GetType() // virtual
43 // ----------------------------------------------------------------------------
45 void manualViewLine::InitMove(int x, int y, int z) // virtual
51 TransfromCoordViewWorld(XX,YY,ZZ);
53 if (_manContModel->GetSizeLstPoints()==2)
55 mp = _manContModel->GetManualPoint(0);
56 _dp0[0]= mp->GetX() - XX;
57 _dp0[1]= mp->GetY() - YY;
60 mp = _manContModel->GetManualPoint(1);
61 _dp1[0]= mp->GetX() - XX;
62 _dp1[1]= mp->GetY() - YY;
69 // ----------------------------------------------------------------------------
70 void manualViewLine::MoveContour(int x, int y, int z) // virtual
76 TransfromCoordViewWorld(XX,YY,ZZ);
78 mp = _manContModel->GetManualPoint(0);
79 mp->SetPoint(_dp0[0]+XX,_dp0[1]+YY,_dp0[2]);
81 mp = _manContModel->GetManualPoint(1);
82 mp->SetPoint(_dp1[0]+XX,_dp1[1]+YY,_dp0[2]);