7fd59977 |
1 | //-------------------------------------------------------------------- |
2 | // |
3 | // File Name : IGESSolid_SelectedComponent.cxx |
4 | // Date : |
5 | // Author : CKY / Contract Toubro-Larsen |
6 | // Copyright : MATRA-DATAVISION 1993 |
7 | // |
8 | //-------------------------------------------------------------------- |
9 | |
10 | #include <IGESSolid_SelectedComponent.ixx> |
11 | #include <gp_GTrsf.hxx> |
12 | |
13 | |
14 | IGESSolid_SelectedComponent::IGESSolid_SelectedComponent () { } |
15 | |
16 | |
17 | void IGESSolid_SelectedComponent::Init |
18 | (const Handle(IGESSolid_BooleanTree)& anEntity, const gp_XYZ& SelectPnt) |
19 | { |
20 | theEntity = anEntity; |
21 | theSelectPoint = SelectPnt; |
22 | InitTypeAndForm(182,0); |
23 | } |
24 | |
25 | Handle(IGESSolid_BooleanTree) IGESSolid_SelectedComponent::Component () const |
26 | { |
27 | return theEntity; |
28 | } |
29 | |
30 | gp_Pnt IGESSolid_SelectedComponent::SelectPoint () const |
31 | { |
32 | return gp_Pnt(theSelectPoint); |
33 | } |
34 | |
35 | gp_Pnt IGESSolid_SelectedComponent::TransformedSelectPoint () const |
36 | { |
37 | if (!HasTransf()) return gp_Pnt(theSelectPoint); |
38 | else |
39 | { |
40 | gp_XYZ tmp = theSelectPoint; |
41 | Location().Transforms(tmp); |
42 | return gp_Pnt(tmp); |
43 | } |
44 | } |