MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / OptimizedPolyList

Class OptimizedPolyList

Engine/source/collision/optimizedPolyList.h:41–160  ·  view source on GitHub ↗

A concrete, renderable PolyList This class is used to store geometry from a PolyList query. @see AbstractPolyList

Source from the content-addressed store, hash-verified

39///
40/// @see AbstractPolyList
41class OptimizedPolyList : public AbstractPolyList
42{
43 public:
44
45 enum PolyType
46 {
47 TriangleFan,
48 TriangleStrip,
49 TriangleList
50 };
51
52 struct VertIndex
53 {
54 S32 vertIdx;
55 S32 normalIdx;
56 S32 uv0Idx;
57 S32 uv1Idx;
58
59 VertIndex()
60 : vertIdx( -1 ),
61 normalIdx ( -1 ),
62 uv0Idx( -1 ),
63 uv1Idx( -1 )
64 {
65 }
66
67 bool operator==(const VertIndex& _test) const
68 {
69 return ( vertIdx == _test.vertIdx &&
70 normalIdx == _test.normalIdx &&
71 uv0Idx == _test.uv0Idx &&
72 uv1Idx == _test.uv1Idx );
73 }
74 };
75
76 struct Poly
77 {
78 S32 plane;
79 S32 material;
80 U32 vertexStart;
81 U32 vertexCount;
82 U32 surfaceKey;
83
84 SceneObject* object;
85
86 PolyType type;
87
88 Poly()
89 : plane( -1 ),
90 material( 0 ),
91 vertexStart(0),
92 vertexCount( 0 ),
93 surfaceKey(0),
94 object( NULL ),
95 type( TriangleFan )
96 {
97 }
98 };

Callers

nothing calls this directly

Calls 2

Point2FClass · 0.50
Point3FClass · 0.50

Tested by

no test coverage detected