CFx SDK Documentation  2022 SP0
DbViewBorder.h
Go to the documentation of this file.
1 // Copyright (C) 2002-2017, Open Design Alliance (the "Alliance").
3 // All rights reserved.
4 //
5 // This software and its documentation and related materials are owned by
6 // the Alliance. The software may only be incorporated into application
7 // programs owned by members of the Alliance, subject to a signed
8 // Membership Agreement and Supplemental Software License Agreement with the
9 // Alliance. The structure and organization of this software are the valuable
10 // trade secrets of the Alliance and its suppliers. The software is also
11 // protected by copyright law and international treaty provisions. Application
12 // programs incorporating this software must include the following statement
13 // with their copyright notices:
14 //
15 // This application incorporates Teigha(R) software pursuant to a license
16 // agreement with Open Design Alliance.
17 // Teigha(R) Copyright (C) 2002-2017 by Open Design Alliance.
18 // All rights reserved.
19 //
20 // By use of this software, its documentation or related materials, you
21 // acknowledge and accept the above terms.
23 
24 #ifndef OD_VIEWBORDER_H
25 #define OD_VIEWBORDER_H
26 
27 #include "DbEntity.h"
28 #include "ModelDocObjExports.h"
29 
30 #include "TD_PackPush.h"
31 
39 {
40  friend class OdDbAssocViewRepActionBody;
41  friend class OdDbImpAssocViewRepActionBody;
42  //friend class OdDbViewBorderImpl;
43  //friend class OdDbViewSymbolImpl;
44 public:
46 
51  virtual ~OdDbViewBorder();
52 
53 
58  {
59  kFromBase = 0, // The style defined by the base view.
60  kWireframeVisibleEdges = 1, // Wireframe style with visible edges only.
61  kWireframeHiddenEdges = 2, // Wireframe style with hidden edges displayed.
62  kShadedVisibleEdges = 3, // Shaded style with visible edges only.
63  kShadedHiddenEdges = 4 // Shaded style with hidden edges displayed.
64  };
65 
70  {
71  kSourceNotDefined = 0, // Source type is not defined.
72  kInventorSource = 1, // Source data is from an Autodesk Inventor file.
73  kFusionSource = 2, // Source data is from an Autodesk Inventor Fusion file.
74  kModelSpaceSource = 3 // Source data is from model space.
75  };
76 
81 
85  double height() const;
86 
90  double width() const;
91 
96 
105 
110 
119  double rotationAngle() const;
120 
121 
126 
132  double scale() const;
133 
138 
143  OdResult setViewportId(const OdDbObjectId& viewportId);
144 
145 protected:
146  // OdGiDrawable methods :
147  virtual bool subWorldDraw(OdGiWorldDraw* pWd) const;
148  virtual void subHighlight(bool bDoIt = true, const OdDbFullSubentPath* pSubId = 0, bool highlightAll = false) const;
149 
151  //virtual OdResult subErase(bool erasing);
152  //virtual OdResult subDeepClone(OdDbObject* pOwnerObject, OdDbObject*& pClonedObject,
153  // OdDbIdMapping& idMap, bool isPrimary = true) const;
154  //virtual OdResult subWblockClone(OdRxObject* pOwnerObject, OdDbObject*& pClonedObject,
155  // OdDbIdMapping& idMap, bool isPrimary = true) const;
156 
158  virtual void dwgOutFields(OdDbDwgFiler* pFiler) const;
160  virtual void dxfOutFields(OdDbDxfFiler* pFiler) const;
161 
162 public:
163  //virtual void audit(OdDbAuditInfo* pAuditInfo);
164 
165  //virtual OdResult subGetStretchPoints(OdGePoint3dArray& stretchPoints) const;
166  //virtual OdResult subMoveStretchPointsAt(const OdIntArray& indices,
167  // const OdGeVector3d& offset);
168 
169  // OdDbEntity methods :
170  //virtual OdResult subGetGripPoints(OdDbGripDataPtrArray& grips,
171  // const double curViewUnitSize,
172  // const int gripSize,
173  // const OdGeVector3d& curViewDir,
174  // const int bitflags) const;
175  //virtual OdResult subGetGripPoints(OdGePoint3dArray& gripPoints,
176  // OdIntArray& osnapModes,
177  // OdIntArray& geomIds) const;
178  //virtual OdResult subMoveGripPointsAt(const OdDbVoidPtrArray& gripAppData,
179  // const OdGeVector3d& offset,
180  // const int bitflags);
181  //virtual OdResult subMoveGripPointsAt(const OdIntArray& indices,
182  // const OdGeVector3d& offset);
183  //virtual void subGripStatus(const OdDb::GripStat status);
184 
185  //virtual OdResult subGetOsnapPoints(OdDb::OsnapMode osnapMode,
186  // OdGsMarker gsSelectionMark,
187  // const OdGePoint3d& pickPoint,
188  // const OdGePoint3d& lastPoint,
189  // const OdGeMatrix3d& viewXform,
190  // OdGePoint3dArray& snapPoints,
191  // OdIntArray& geomIds) const;
192  //virtual OdResult subGetOsnapPoints(OdDb::OsnapMode osnapMode,
193  // OdGsMarker gsSelectionMark,
194  // const OdGePoint3d& pickPoint,
195  // const OdGePoint3d& lastPoint,
196  // const OdGeMatrix3d& viewXform,
197  // OdGePoint3dArray& snapPoints,
198  // OdIntArray& geomIds,
199  // const OdGeMatrix3d& insertionMat) const;
200 
201  //virtual OdResult subIntersectWith(const OdDbEntity* pEnt,
202  // OdDb::Intersect intType,
203  // const OdGePlane& projPlane,
204  // OdGePoint3dArray& points,
205  // OdGsMarker thisGsMarker = 0,
206  // OdGsMarker otherGsMarker = 0) const;
207 
208  //virtual OdResult subIntersectWith(const OdDbEntity* pEnt,
209  // OdDb::Intersect intType,
210  // OdGePoint3dArray& points,
211  // OdGsMarker thisGsMarker = 0,
212  // OdGsMarker otherGsMarker = 0) const;
213 
214  virtual OdResult subTransformBy(const OdGeMatrix3d& xform);
215 
216  //virtual OdResult subGetClassID(CLSID* pClsid) const;
217 
218  //virtual void subList() const;
219 
220  //virtual void subHighlight(bool bDoIt = true,
221  // const OdDbFullSubentPath* pSubId = 0,
222  // bool highlightAll = false) const;
223 
224  //virtual OdResult subGetSubentPathsAtGsMarker(OdDb::SubentType type,
225  // OdGsMarker gsMark,
226  // const OdGePoint3d& pickPoint,
227  // const OdGeMatrix3d& viewXform,
228  // int& numPaths,
229  // OdDbFullSubentPath*& subentPaths,
230  // int numInserts = 0,
231  // OdDbObjectId* entAndInsertStack = NULL) const;
232 
233  //virtual OdResult subGetGsMarkersAtSubentPath(const OdDbFullSubentPath* pSubPath,
234  // OdArray<OdGsMarker>& gsMarkers) const;
235 
236  //virtual OdResult subGetSubentClassId(const OdDbFullSubentPath* pSubPath, CLSID* clsId) const;
237 
238  //virtual void saveAs(OdGiWorldDraw* mode, OdDb::SaveType st);
239 
240  //virtual OdResult setLayer(const OdString& newVal,
241  // bool doSubents = true,
242  // bool allowHiddenLayer = false);
243  //virtual OdResult setLayer(OdDbObjectId newVal,
244  // bool doSubents = true,
245  // bool allowHiddenLayer = false);
246 
247 public:
248  // Internal use only methods:
249  //OdResult setViewportId(const OdDbObjectId& viewportId);
250  OdGePoint2d centerPoint(bool exludeSketchEnts = true) const;
251  OdGePoint3d centerPoint3d(bool exludeSketchEnts = true) const;
252  OdResult getSize(OdGePoint3d& minPt, OdGePoint3d& maxPt) const;
253  OdResult setSize(const OdGePoint3d& minPt, const OdGePoint3d& maxPt);
254  void setScale(double newScale);
255  //OdResult recalculateBorder();
256 
257  //void setTransientEnts(const OdArray<OdDbEntity*>& traientEnts);
258  //void setDisableUnHighlight(bool bIsDisable);
259  //bool hitTest(const OdGePoint3d& inputPt) const;
260 
261  // Internal use only methods: subentity related methods
262  //OdResult getSubentColor(const OdDbSubentId& subentId, OdCmColor& color) const;
263  //OdResult setSubentColor(const OdDbSubentId& subentId, const OdCmColor& color);
264 
265  //OdResult getSubentLayerId(const OdDbSubentId& subentId, OdDbObjectId& layerId) const;
266  //OdResult setSubentLayer(const OdDbSubentId& subentId, OdDbObjectId newVal);
267 
268  //OdResult getSubentLinetypeId(const OdDbSubentId& subentId, OdDbObjectId& linetypeId) const;
269  //OdResult setSubentLinetype(const OdDbSubentId& subentId, OdDbObjectId newVal);
270 
271  //OdResult getSubentLinetypeScale(const OdDbSubentId& subentId, double& linetypeScale) const;
272  //OdResult setSubentLinetypeScale(const OdDbSubentId& subentId, double newVal);
273 
274  //const OdString& getSubentPlotStyleName(const OdDbSubentId& subentId) const;
275  //OdResult setSubentPlotStyleName(const OdDbSubentId& subentId, const OdString& newName);
276 
277  //OdResult getSubentLineWeight(const OdDbSubentId& subentId, OdDb::LineWeight& lineweight) const;
278  //OdResult setSubentLineWeight(const OdDbSubentId& subentId, OdDb::LineWeight newVal);
279 
280  //OdResult getSubentVisibility(const OdDbSubentId& subentId, OdDb::Visibility& visVal) const;
281  //OdResult setSubentVisibility(const OdDbSubentId& subentId, OdDb::Visibility newVal);
282 
283  //OdResult subentIdToNestedEnts(const OdDbSubentId& subentId, OdDbFullSubentPathArray &nestedEnts) const;
284 
285  protected:
286 
288  void setScaleId( const OdDbObjectId scaleId );
289 
290 //private:
291 // OdGeMatrix3d transientXform() const;
292 
293 //private:
294 // static double sViewBoderOffset;
295 };
296 
301 
302 #include "TD_PackPop.h"
303 
304 #endif // OD_VIEWBORDER_H
OdSmartPtr< OdDbViewBorder > OdDbViewBorderPtr
Definition: DbViewBorder.h:300
#define MODELDOCOBJ_EXPORT
unsigned int OdUInt32
OdResult
Definition: OdResult.h:29
virtual OdResult dxfInFields(OdDbDxfFiler *pFiler)
virtual OdResult subTransformBy(const OdGeMatrix3d &xform)
virtual OdResult dwgInFields(OdDbDwgFiler *pFiler)
double scale() const
void setScaleId(const OdDbObjectId scaleId)
OdGePoint3d insertionPoint() const
OdDbViewBorder::SourceType sourceType() const
OdDbObjectId getScaleId() const
virtual bool subWorldDraw(OdGiWorldDraw *pWd) const
void setScale(double newScale)
OdResult setViewportId(const OdDbObjectId &viewportId)
OdGePoint3d centerPoint3d(bool exludeSketchEnts=true) const
OdGePoint2d centerPoint(bool exludeSketchEnts=true) const
double height() const
virtual void subHighlight(bool bDoIt=true, const OdDbFullSubentPath *pSubId=0, bool highlightAll=false) const
OdDbObjectId viewportId() const
double width() const
double rotationAngle() const
OdResult setSize(const OdGePoint3d &minPt, const OdGePoint3d &maxPt)
OdDbViewBorder::ViewStyleType viewStyleType() const
virtual void dxfOutFields(OdDbDxfFiler *pFiler) const
ODDB_DECLARE_MEMBERS(OdDbViewBorder)
virtual void dwgOutFields(OdDbDwgFiler *pFiler) const
OdUInt32 shadedDPI() const
bool isFirstAngleProjection() const
OdString inventorFileReference() const
virtual ~OdDbViewBorder()
OdResult getSize(OdGePoint3d &minPt, OdGePoint3d &maxPt) const