1 //NOTE: This is an interface to a function for the Chamfer and creation.
4 #include "GEOM_Function.hxx"
9 #define CHAM_ARG_LENG 4
10 #define CHAM_ARG_LAST 4
12 class GEOMImpl_IChamfer
16 GEOMImpl_IChamfer(Handle(GEOM_Function) theFunction): _func(theFunction) {}
18 void SetShape(Handle(GEOM_Function) theRef) { _func->SetReference(CHAM_ARG_SH, theRef); }
20 Handle(GEOM_Function) GetShape() { return _func->GetReference(CHAM_ARG_SH); }
22 void SetD (double theD) { _func->SetReal(CHAM_ARG_D1, theD); }
23 void SetD1(double theD) { _func->SetReal(CHAM_ARG_D1, theD); }
24 void SetD2(double theD) { _func->SetReal(CHAM_ARG_D2, theD); }
26 double GetD () { return _func->GetReal(CHAM_ARG_D1); }
27 double GetD1() { return _func->GetReal(CHAM_ARG_D1); }
28 double GetD2() { return _func->GetReal(CHAM_ARG_D2); }
30 void SetLength(int theLen) { _func->SetInteger(CHAM_ARG_LENG, theLen); }
32 int GetLength() { return _func->GetInteger(CHAM_ARG_LENG); }
34 void SetFace(int theInd, int theFace)
35 { _func->SetInteger(CHAM_ARG_LAST + theInd, theFace); }
36 void SetFace1(int theFace)
37 { _func->SetInteger(CHAM_ARG_LAST + 1, theFace); }
38 void SetFace2(int theFace)
39 { _func->SetInteger(CHAM_ARG_LAST + 2, theFace); }
41 int GetFace(int theInd) { return _func->GetInteger(CHAM_ARG_LAST + theInd); }
42 int GetFace1() { return _func->GetInteger(CHAM_ARG_LAST + 1); }
43 int GetFace2() { return _func->GetInteger(CHAM_ARG_LAST + 2); }
47 Handle(GEOM_Function) _func;