0026969: Visualization - support custom vertex attributes in GLSL program
[occt.git] / src / HLRBRep / HLRBRep_HLRToShape.hxx
CommitLineData
42cf5bc1 1// Created on: 1993-10-11
2// Created by: Christophe MARION
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 _HLRBRep_HLRToShape_HeaderFile
18#define _HLRBRep_HLRToShape_HeaderFile
19
20#include <Standard.hxx>
21#include <Standard_DefineAlloc.hxx>
22#include <Standard_Handle.hxx>
23
24#include <TopoDS_Shape.hxx>
25#include <Standard_Integer.hxx>
26#include <Standard_Boolean.hxx>
27class HLRBRep_Algo;
28class TopoDS_Shape;
29class HLRBRep_Data;
30class HLRBRep_EdgeData;
31
32
33//! A framework for filtering the computation
34//! results of an HLRBRep_Algo algorithm by extraction.
35//! From the results calculated by the algorithm on
36//! a shape, a filter returns the type of edge you
37//! want to identify. You can choose any of the following types of output:
38//! - visible sharp edges
39//! - hidden sharp edges
40//! - visible smooth edges
41//! - hidden smooth edges
42//! - visible sewn edges
43//! - hidden sewn edges
44//! - visible outline edges
45//! - hidden outline edges.
46//! - visible isoparameters and
47//! - hidden isoparameters.
48//! Sharp edges present a C0 continuity (non G1).
49//! Smooth edges present a G1 continuity (non G2).
50//! Sewn edges present a C2 continuity.
51//! The result is composed of 2D edges in the
52//! projection plane of the view which the
53//! algorithm has worked with. These 2D edges
54//! are not included in the data structure of the visualized shape.
55//! In order to obtain a complete image, you must
56//! combine the shapes given by each of the chosen filters.
57//! The construction of the shape does not call a
58//! new computation of the algorithm, but only
59//! reads its internal results.
60//! The methods of this shape are almost identic to those of the HLRBrep_PolyHLRToShape class.
61class HLRBRep_HLRToShape
62{
63public:
64
65 DEFINE_STANDARD_ALLOC
66
67
68 //! Constructs a framework for filtering the
69 //! results of the HLRBRep_Algo algorithm, A.
70 //! Use the extraction filters to obtain the results you want for A.
71 Standard_EXPORT HLRBRep_HLRToShape(const Handle(HLRBRep_Algo)& A);
72
73 TopoDS_Shape VCompound();
74
75 TopoDS_Shape VCompound (const TopoDS_Shape& S);
76
77 TopoDS_Shape Rg1LineVCompound();
78
79 TopoDS_Shape Rg1LineVCompound (const TopoDS_Shape& S);
80
81 TopoDS_Shape RgNLineVCompound();
82
83 TopoDS_Shape RgNLineVCompound (const TopoDS_Shape& S);
84
85 TopoDS_Shape OutLineVCompound();
86
87 TopoDS_Shape OutLineVCompound3d();
88
89 TopoDS_Shape OutLineVCompound (const TopoDS_Shape& S);
90
91 TopoDS_Shape IsoLineVCompound();
92
93 TopoDS_Shape IsoLineVCompound (const TopoDS_Shape& S);
94
95 TopoDS_Shape HCompound();
96
97 TopoDS_Shape HCompound (const TopoDS_Shape& S);
98
99 TopoDS_Shape Rg1LineHCompound();
100
101 TopoDS_Shape Rg1LineHCompound (const TopoDS_Shape& S);
102
103 TopoDS_Shape RgNLineHCompound();
104
105 TopoDS_Shape RgNLineHCompound (const TopoDS_Shape& S);
106
107 TopoDS_Shape OutLineHCompound();
108
109 TopoDS_Shape OutLineHCompound (const TopoDS_Shape& S);
110
111 TopoDS_Shape IsoLineHCompound();
112
113 TopoDS_Shape IsoLineHCompound (const TopoDS_Shape& S);
114
115
116
117
118protected:
119
120
121
122
123
124private:
125
126
127 Standard_EXPORT TopoDS_Shape InternalCompound (const Standard_Integer typ, const Standard_Boolean visible, const TopoDS_Shape& S, const Standard_Boolean In3d = Standard_False);
128
129 Standard_EXPORT void DrawFace (const Standard_Boolean visible, const Standard_Integer typ, const Standard_Integer iface, Handle(HLRBRep_Data)& DS, TopoDS_Shape& Result, Standard_Boolean& added, const Standard_Boolean In3d = Standard_False) const;
130
131 Standard_EXPORT void DrawEdge (const Standard_Boolean visible, const Standard_Boolean inFace, const Standard_Integer typ, HLRBRep_EdgeData& ed, TopoDS_Shape& Result, Standard_Boolean& added, const Standard_Boolean In3d = Standard_False) const;
132
133
134 Handle(HLRBRep_Algo) myAlgo;
135
136
137};
138
139
140#include <HLRBRep_HLRToShape.lxx>
141
142
143
144
145
146#endif // _HLRBRep_HLRToShape_HeaderFile