0031642: Visualization - crash in Graphic3d_Structure::SetVisual() on redisplaying...
[occt.git] / src / IntCurve / IntCurve_IntConicConic.hxx
CommitLineData
42cf5bc1 1// Created on: 1992-04-27
2// Created by: Laurent BUCHARD
3// Copyright (c) 1992-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#ifndef _IntCurve_IntConicConic_HeaderFile
18#define _IntCurve_IntConicConic_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_DefineAlloc.hxx>
22#include <Standard_Handle.hxx>
23
24#include <IntCurve_IntImpConicParConic.hxx>
25#include <IntRes2d_Intersection.hxx>
26#include <Standard_Real.hxx>
27class Standard_ConstructionError;
28class gp_Lin2d;
29class IntRes2d_Domain;
30class gp_Circ2d;
31class gp_Elips2d;
32class gp_Parab2d;
33class gp_Hypr2d;
34
35
36//! Provides methods to intersect two conics.
37//! The exception ConstructionError is raised in constructors
38//! or in Perform methods when a domain (Domain from IntRes2d)
39//! is not correct, i-e when a Circle (Circ2d from gp) or
40//! an Ellipse (i-e Elips2d from gp) do not have a closed
41//! domain (use the SetEquivalentParameters method for a domain
42//! on a circle or an ellipse).
43class IntCurve_IntConicConic : public IntRes2d_Intersection
44{
45public:
46
47 DEFINE_STANDARD_ALLOC
48
49
50 //! Empty Constructor
51 IntCurve_IntConicConic();
52
53 //! Intersection between 2 lines from gp.
54 IntCurve_IntConicConic(const gp_Lin2d& L1, const IntRes2d_Domain& D1, const gp_Lin2d& L2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
55
56 //! Intersection between 2 lines from gp.
57 Standard_EXPORT void Perform (const gp_Lin2d& L1, const IntRes2d_Domain& D1, const gp_Lin2d& L2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
58
59 //! Intersection between a line and a circle.
60 //! The exception ConstructionError is raised if the method
61 //! IsClosed of the domain of the circle returns False.
62 IntCurve_IntConicConic(const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Circ2d& C, const IntRes2d_Domain& DC, const Standard_Real TolConf, const Standard_Real Tol);
63
64 //! Intersection between a line and a circle.
65 //! The exception ConstructionError is raised if the method
66 //! IsClosed of the domain of the circle returns False.
67 Standard_EXPORT void Perform (const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Circ2d& C, const IntRes2d_Domain& DC, const Standard_Real TolConf, const Standard_Real Tol);
68
69 //! Intersection between a line and an ellipse.
70 //! The exception ConstructionError is raised if the method
71 //! IsClosed of the domain of the ellipse returns False.
72 IntCurve_IntConicConic(const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Elips2d& E, const IntRes2d_Domain& DE, const Standard_Real TolConf, const Standard_Real Tol);
73
74 //! Intersection between a line and an ellipse.
75 //! The exception ConstructionError is raised if the method
76 //! IsClosed of the domain of the ellipse returns False.
77 Standard_EXPORT void Perform (const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Elips2d& E, const IntRes2d_Domain& DE, const Standard_Real TolConf, const Standard_Real Tol);
78
79 //! Intersection between a line and a parabola from gp.
80 IntCurve_IntConicConic(const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Parab2d& P, const IntRes2d_Domain& DP, const Standard_Real TolConf, const Standard_Real Tol);
81
82 //! Intersection between a line and a parabola from gp.
83 Standard_EXPORT void Perform (const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Parab2d& P, const IntRes2d_Domain& DP, const Standard_Real TolConf, const Standard_Real Tol);
84
85 //! Intersection between a line and an hyperbola.
86 IntCurve_IntConicConic(const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
87
88 //! Intersection between a line and an hyperbola.
89 Standard_EXPORT void Perform (const gp_Lin2d& L, const IntRes2d_Domain& DL, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
90
91 //! Intersection between 2 circles from gp.
92 //! The exception ConstructionError is raised if the method
93 //! IsClosed of one of the domain returns False.
94 IntCurve_IntConicConic(const gp_Circ2d& C1, const IntRes2d_Domain& D1, const gp_Circ2d& C2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
95
96 //! Intersection between 2 circles from gp.
97 //! The exception ConstructionError is raised if the method
98 //! IsClosed of the domain of one of the circle returns False.
99 Standard_EXPORT void Perform (const gp_Circ2d& C1, const IntRes2d_Domain& D1, const gp_Circ2d& C2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
100
101 //! Intersection between a circle and an ellipse.
102 //! The exception ConstructionError is raised if the method
103 //! IsClosed of one the domain returns False.
104 IntCurve_IntConicConic(const gp_Circ2d& C, const IntRes2d_Domain& DC, const gp_Elips2d& E, const IntRes2d_Domain& DE, const Standard_Real TolConf, const Standard_Real Tol);
105
106 //! Intersection between a circle and an ellipse.
107 //! The exception ConstructionError is raised if the method
108 //! IsClosed of one the domain returns False.
109 Standard_EXPORT void Perform (const gp_Circ2d& C, const IntRes2d_Domain& DC, const gp_Elips2d& E, const IntRes2d_Domain& DE, const Standard_Real TolConf, const Standard_Real Tol);
110
111 //! Intersection between a circle and a parabola.
112 //! The exception ConstructionError is raised if the method
113 //! IsClosed of the domain of the circle returns False.
114 IntCurve_IntConicConic(const gp_Circ2d& C, const IntRes2d_Domain& DC, const gp_Parab2d& P, const IntRes2d_Domain& DP, const Standard_Real TolConf, const Standard_Real Tol);
115
116 //! Intersection between a circle and a parabola.
117 //! The exception ConstructionError is raised if the method
118 //! IsClosed of the domain of the circle returns False.
119 Standard_EXPORT void Perform (const gp_Circ2d& C, const IntRes2d_Domain& DC, const gp_Parab2d& P, const IntRes2d_Domain& DP, const Standard_Real TolConf, const Standard_Real Tol);
120
121 //! Intersection between a circle and an hyperbola.
122 //! The exception ConstructionError is raised if the method
123 //! IsClosed of the domain of the circle returns False.
124 IntCurve_IntConicConic(const gp_Circ2d& C, const IntRes2d_Domain& DC, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
125
126 //! Intersection between a circle and an hyperbola.
127 //! The exception ConstructionError is raised if the method
128 //! IsClosed of the domain of the circle returns False.
129 Standard_EXPORT void Perform (const gp_Circ2d& C, const IntRes2d_Domain& DC, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
130
131 //! Intersection between 2 ellipses.
132 //! The exception ConstructionError is raised if the method
133 //! IsClosed of one of the domain returns False.
134 IntCurve_IntConicConic(const gp_Elips2d& E1, const IntRes2d_Domain& D1, const gp_Elips2d& E2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
135
136 //! Intersection between 2 ellipses.
137 //! The exception ConstructionError is raised if the method
138 //! IsClosed of one of the domain returns False.
139 Standard_EXPORT void Perform (const gp_Elips2d& E1, const IntRes2d_Domain& D1, const gp_Elips2d& E2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
140
141 //! Intersection between an ellipse and a parabola.
142 //! The exception ConstructionError is raised if the method
143 //! IsClosed of the domain of the ellipse returns False.
144 IntCurve_IntConicConic(const gp_Elips2d& E, const IntRes2d_Domain& DE, const gp_Parab2d& P, const IntRes2d_Domain& DP, const Standard_Real TolConf, const Standard_Real Tol);
145
146 //! Intersection between an ellipse and a parabola.
147 //! The exception ConstructionError is raised if the method
148 //! IsClosed of the domain of the ellipse returns False.
149 Standard_EXPORT void Perform (const gp_Elips2d& E, const IntRes2d_Domain& DE, const gp_Parab2d& P, const IntRes2d_Domain& DP, const Standard_Real TolConf, const Standard_Real Tol);
150
151 //! Intersection between an ellipse and an hyperbola.
152 //! The exception ConstructionError is raised if the method
153 //! IsClosed of the domain of the ellipse returns False.
154 IntCurve_IntConicConic(const gp_Elips2d& E, const IntRes2d_Domain& DE, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
155
156 //! Intersection between an ellipse and an hyperbola.
157 //! The exception ConstructionError is raised if the method
158 //! IsClosed of the domain of the ellipse returns False.
159 Standard_EXPORT void Perform (const gp_Elips2d& E, const IntRes2d_Domain& DE, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
160
161 //! Intersection between 2 parabolas.
162 IntCurve_IntConicConic(const gp_Parab2d& P1, const IntRes2d_Domain& D1, const gp_Parab2d& P2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
163
164 //! Intersection between 2 parabolas.
165 Standard_EXPORT void Perform (const gp_Parab2d& P1, const IntRes2d_Domain& D1, const gp_Parab2d& P2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
166
167 //! Intersection between a parabola and an hyperbola.
168 IntCurve_IntConicConic(const gp_Parab2d& P, const IntRes2d_Domain& DP, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
169
170 //! Intersection between a parabola and an hyperbola.
171 Standard_EXPORT void Perform (const gp_Parab2d& P, const IntRes2d_Domain& DP, const gp_Hypr2d& H, const IntRes2d_Domain& DH, const Standard_Real TolConf, const Standard_Real Tol);
172
173 //! Intersection between 2 hyperbolas.
174 IntCurve_IntConicConic(const gp_Hypr2d& H1, const IntRes2d_Domain& D1, const gp_Hypr2d& H2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
175
176 //! Intersection between 2 hyperbolas.
177 Standard_EXPORT void Perform (const gp_Hypr2d& H1, const IntRes2d_Domain& D1, const gp_Hypr2d& H2, const IntRes2d_Domain& D2, const Standard_Real TolConf, const Standard_Real Tol);
178
179
180
181
182protected:
183
184
185
186
187
188private:
189
190
191
192 IntCurve_IntImpConicParConic Inter;
193
194
195};
196
197
198#include <IntCurve_IntConicConic.lxx>
199
200
201
202
203
204#endif // _IntCurve_IntConicConic_HeaderFile