gwnavgeneration/boundary/boundarypolygon.h Source File

boundarypolygon.h
Go to the documentation of this file.
1 /*
2 * Copyright 2015 Autodesk, Inc. All rights reserved.
3 * Use of this software is subject to the terms of the Autodesk license agreement and any attachments or Appendices thereto provided at the time of installation or download,
4 * or which otherwise accompanies this software in either electronic or hard copy form, or which is signed by you and accepted by Autodesk.
5 */
6 
7 
8 
9 
10 
11 // primary contact: GUAL - secondary contact: NOBODY
12 #ifndef GwNavGen_BoundaryPolygon_H
13 #define GwNavGen_BoundaryPolygon_H
14 
15 
19 
20 
21 namespace Kaim
22 {
23 
24 
25 class BoundaryOrderedSimplifyPolyline
26 {
27  KY_DEFINE_NEW_DELETE_OPERATORS(Stat_Default_Mem)
28 public:
29  BoundaryOrderedSimplifyPolyline()
30  : m_polyline(KY_NULL), m_order(BoundaryOrder_Unset) {}
31 
32  BoundaryOrderedSimplifyPolyline(BoundarySimplifyPolyline* polyline, BoundaryOrder order)
33  : m_polyline(polyline), m_order(order) {}
34 
35 public:
36  BoundarySimplifyPolyline* m_polyline;
37  BoundaryOrder m_order;
38 };
39 
40 
41 class BoundaryContour
42 {
43  KY_DEFINE_NEW_DELETE_OPERATORS(Stat_Default_Mem)
44 public:
45  BoundaryContour()
46  : m_index(KyUInt32MAXVAL)
47  , m_edgeCount(0)
48  , m_begin(KY_NULL)
49  , m_winding(ContourWinding_Unset)
50  , m_leftColor(PixelColor_Unset)
51  , m_leftConnexIdx(KyUInt32MAXVAL)
52  {}
53 
54 public:
55  KyUInt32 m_index;
56  KyUInt32 m_edgeCount;
57  BoundaryEdge* m_begin;
58  ContourWinding m_winding;
59  PixelColor m_leftColor;
60  KyUInt32 m_leftConnexIdx;
61  KyArrayTLS<BoundaryOrderedSimplifyPolyline> m_orderedSimplifyPolylines;
62 };
63 
64 
65 class BoundaryPolygon
66 {
67  KY_DEFINE_NEW_DELETE_OPERATORS(Stat_Default_Mem)
68 public:
69  BoundaryPolygon() : m_leftColor(PixelColor_Unset) {}
70 public:
71  PixelColor m_leftColor; // == idx in the array of boundaryPolygon
72  KyArrayTLS_POD<BoundaryContour*> m_contours;
73 };
74 
75 
76 }
77 
78 
79 #endif
#define KY_NULL
Null value.
Definition: types.h:247
Definition: gamekitcrowddispersion.h:20
#define KY_DEFINE_NEW_DELETE_OPERATORS(MemStat)
This macro defines new and delete operators.
Definition: memory.h:137
unsigned int KyUInt32
Type used internally to represent an unsigned 32-bit integer.
Definition: types.h:36
#define KyUInt32MAXVAL
The maximum value that can be stored in the KyUInt32 variable type.
Definition: types.h:226