b46d17c5dcd9db6dcba55b74b4d0ed0d5d097f80
[occt.git] / src / GeomToStep / GeomToStep_MakeAxis1Placement.cxx
1 // Created on: 1993-06-15
2 // Created by: Martine LANGLOIS
3 // Copyright (c) 1993-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
5 //
6 // This file is part of Open CASCADE Technology software library.
7 //
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
13 //
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
16
17 #include <GeomToStep_MakeAxis1Placement.ixx>
18 #include <GeomToStep_MakeDirection.hxx>
19 #include <StdFail_NotDone.hxx>
20 #include <gp_Ax1.hxx>
21 #include <gp_Ax2d.hxx>
22 #include <Geom_Axis1Placement.hxx>
23 #include <Geom2d_AxisPlacement.hxx>
24 #include <StepGeom_Axis1Placement.hxx>
25 #include <StepGeom_CartesianPoint.hxx>
26 #include <GeomToStep_MakeCartesianPoint.hxx>
27 #include <StepGeom_Direction.hxx>
28 #include <GeomToStep_MakeDirection.hxx>
29 #include <TCollection_HAsciiString.hxx>
30
31 //=============================================================================
32 // Creation d' un axis1_placement de prostep a partir d' un Ax1 de gp
33 //=============================================================================
34
35 GeomToStep_MakeAxis1Placement::GeomToStep_MakeAxis1Placement( const gp_Ax1& A)
36 {
37 #include <GeomToStep_MakeAxis1Placement_gen.pxx>
38 }
39 //=============================================================================
40 // Creation d' un axis1_placement de prostep a partir d' un Ax2d de gp
41 //=============================================================================
42
43 GeomToStep_MakeAxis1Placement::GeomToStep_MakeAxis1Placement( const gp_Ax2d& A)
44 {
45 #include <GeomToStep_MakeAxis1Placement_gen.pxx>
46 }
47
48 //=============================================================================
49 // Creation d' un axis1_placement de prostep a partir d' un Ax1Placement de
50 // Geom
51 //=============================================================================
52
53 GeomToStep_MakeAxis1Placement::GeomToStep_MakeAxis1Placement
54   ( const Handle(Geom_Axis1Placement)& Axis1)
55 {
56   gp_Ax1 A;
57   A = Axis1->Ax1();
58 #include<GeomToStep_MakeAxis1Placement_gen.pxx>
59 }
60
61 //=============================================================================
62 // Creation d' un axis1_placement de prostep a partir d' un AxPlacement de
63 // Geom2d
64 //=============================================================================
65
66 GeomToStep_MakeAxis1Placement::GeomToStep_MakeAxis1Placement
67   ( const Handle(Geom2d_AxisPlacement)& Axis1)
68 {
69   gp_Ax2d A;
70   A = Axis1->Ax2d();
71 #include<GeomToStep_MakeAxis1Placement_gen.pxx>
72 }
73
74 //=============================================================================
75 // renvoi des valeurs
76 //=============================================================================
77
78 const Handle(StepGeom_Axis1Placement) &
79       GeomToStep_MakeAxis1Placement::Value() const
80 {
81   StdFail_NotDone_Raise_if(!done == Standard_True,"");
82   return theAxis1Placement;
83 }