gwnavgeneration/boundary/boundarypolygon.h Source File

boundarypolygon.h
Go to the documentation of this file.
1 /*
2 * Copyright 2016 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 #pragma once
8 
12 
13 namespace Kaim
14 {
15 
16 class BoundaryOrderedSimplifyPolyline
17 {
18  KY_DEFINE_NEW_DELETE_OPERATORS(Stat_Default_Mem)
19 public:
20  BoundaryOrderedSimplifyPolyline()
21  : m_polyline(nullptr), m_order(BoundaryOrder_Unset) {}
22 
23  BoundaryOrderedSimplifyPolyline(BoundarySimplifyPolyline* polyline, BoundaryOrder order)
24  : m_polyline(polyline), m_order(order) {}
25 
26 public:
27  BoundarySimplifyPolyline* m_polyline;
28  BoundaryOrder m_order;
29 };
30 
31 
32 class BoundaryContour
33 {
34  KY_DEFINE_NEW_DELETE_OPERATORS(Stat_Default_Mem)
35 public:
36  BoundaryContour()
37  : m_index(KyUInt32MAXVAL)
38  , m_edgeCount(0)
39  , m_begin(nullptr)
40  , m_winding(ContourWinding_Unset)
41  , m_leftColor(PixelColor_Unset)
42  , m_leftConnexIdx(KyUInt32MAXVAL)
43  {}
44 
45 public:
46  KyUInt32 m_index;
47  KyUInt32 m_edgeCount;
48  BoundaryEdge* m_begin;
49  ContourWinding m_winding;
50  PixelColor m_leftColor;
51  KyUInt32 m_leftConnexIdx;
52  KyArrayTLS<BoundaryOrderedSimplifyPolyline> m_orderedSimplifyPolylines;
53 };
54 
55 
56 class BoundaryPolygon
57 {
58  KY_DEFINE_NEW_DELETE_OPERATORS(Stat_Default_Mem)
59 public:
60  BoundaryPolygon() : m_leftColor(PixelColor_Unset) {}
61 public:
62  PixelColor m_leftColor; // == idx in the array of boundaryPolygon
63  KyArrayTLS_POD<BoundaryContour*> m_contours;
64 };
65 
66 }
67 
68 
std::uint32_t KyUInt32
uint32_t
Definition: types.h:29
#define KY_DEFINE_NEW_DELETE_OPERATORS(MemStat)
This macro defines new and delete operators.
Definition: memory.h:132
The Autodesk Navigation namespace.
Definition: gamekitcrowddispersion.cpp:17
#define KyUInt32MAXVAL
KyUInt32 max value
Definition: types.h:68