0022048: Visualization, AIS_InteractiveContext - single object selection should alway...
[occt.git] / src / Intf / Intf_Tool.hxx
CommitLineData
42cf5bc1 1// Created on: 1993-06-23
2// Created by: Didier PIFFAULT
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#ifndef _Intf_Tool_HeaderFile
18#define _Intf_Tool_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_DefineAlloc.hxx>
22#include <Standard_Handle.hxx>
23
24#include <Standard_Integer.hxx>
25#include <Standard_Real.hxx>
26class Standard_OutOfRange;
27class gp_Lin2d;
28class Bnd_Box2d;
29class gp_Hypr2d;
30class gp_Parab2d;
31class gp_Lin;
32class Bnd_Box;
33class gp_Hypr;
34class gp_Parab;
35
36
37//! Provides services to create box for infinites
38//! lines in a given contexte.
39class Intf_Tool
40{
41public:
42
43 DEFINE_STANDARD_ALLOC
44
45
46 Standard_EXPORT Intf_Tool();
47
48 Standard_EXPORT void Lin2dBox (const gp_Lin2d& theLin2d, const Bnd_Box2d& bounding, Bnd_Box2d& boxLin);
49
50 Standard_EXPORT void Hypr2dBox (const gp_Hypr2d& theHypr2d, const Bnd_Box2d& bounding, Bnd_Box2d& boxHypr);
51
52 Standard_EXPORT void Parab2dBox (const gp_Parab2d& theParab2d, const Bnd_Box2d& bounding, Bnd_Box2d& boxHypr);
53
54 Standard_EXPORT void LinBox (const gp_Lin& theLin, const Bnd_Box& bounding, Bnd_Box& boxLin);
55
56 Standard_EXPORT void HyprBox (const gp_Hypr& theHypr, const Bnd_Box& bounding, Bnd_Box& boxHypr);
57
58 Standard_EXPORT void ParabBox (const gp_Parab& theParab, const Bnd_Box& bounding, Bnd_Box& boxHypr);
59
60 Standard_EXPORT Standard_Integer NbSegments() const;
61
62 Standard_EXPORT Standard_Real BeginParam (const Standard_Integer SegmentNum) const;
63
64 Standard_EXPORT Standard_Real EndParam (const Standard_Integer SegmentNum) const;
65
66
67
68
69protected:
70
71
72
73
74
75private:
76
77
78 Standard_EXPORT Standard_Integer Inters2d (const gp_Hypr2d& theCurve, const Bnd_Box2d& Domain);
79
80 Standard_EXPORT Standard_Integer Inters2d (const gp_Parab2d& theCurve, const Bnd_Box2d& Domain);
81
82 Standard_EXPORT Standard_Integer Inters3d (const gp_Hypr& theCurve, const Bnd_Box& Domain);
83
84 Standard_EXPORT Standard_Integer Inters3d (const gp_Parab& theCurve, const Bnd_Box& Domain);
85
86
87 Standard_Integer nbSeg;
88 Standard_Real beginOnCurve[6];
89 Standard_Real endOnCurve[6];
90 Standard_Integer bord[12];
91 Standard_Real xint[12];
92 Standard_Real yint[12];
93 Standard_Real zint[12];
94 Standard_Real parint[12];
95
96
97};
98
99
100
101
102
103
104
105#endif // _Intf_Tool_HeaderFile