NW4F G3d
Loading...
Searching...
No Matches
g3d_ShapeObj.h
Go to the documentation of this file.
1
2#ifndef NW_G3D_SHAPEOBJ_H_
3#define NW_G3D_SHAPEOBJ_H_
4
5#include <nw/g3d/g3d_config.h>
6#include <nw/g3d/fnd/g3d_GfxObject.h>
7#include <nw/g3d/res/g3d_ResShape.h>
8#include <nw/g3d/g3d_Sizer.h>
9
10namespace nw { namespace g3d {
11
12namespace math {
13
14class Vec2;
15class Mtx34;
16
17} // namespace math
18
19class SkeletonObj;
20
27
28struct Sphere
29{
30 void Transform(const Sphere& sphere, const Mtx34& mtx);
31
32 void Merge(const Sphere& lhs, const Sphere& rhs);
33
35 float radius;
36};
37
38struct AABB
39{
40 void Set(const Vec3* pPointArray, int count);
41
42 void Transform(const Bounding& aabb, const Mtx34& mtx);
43
44 void Merge(const AABB& lhs, const AABB& rhs);
45
48};
49
50struct Plane
51{
52 void Set(const Vec3& p0, const Vec3& p1, const Vec3& p2);
53
55 float dist;
56};
57
59{
60 void SetPerspective(float fovy, float aspect, float zNear, float zFar, const Mtx34& viewToWorld);
61 void SetPerspectiveOffset(float fovy, float aspect, float zNear, float zFar, const Mtx34& viewToWorld, const Vec2& offset);
62 void SetFrustum(float top, float bottom, float left, float right, float zNear, float zFar,
63 const Mtx34& viewToWorld);
64 void SetOrtho(float top, float bottom, float left, float right, float zNear, float zFar,
65 const Mtx34& viewToWorld);
66
67 bool TestIntersection(const Sphere& sphere) const;
68
69 int TestIntersectionEx(const Sphere& sphere) const;
70
71 bool TestIntersection(const AABB& aabb) const;
72
73 int TestIntersectionEx(const AABB& aabb) const;
74
75 void EnableAABB() { flag = 1; }
76 void DisableAABB() { flag = 0; }
77 bool IsAABBEnabled() const { return !!flag; }
78
82 int flag;
83};
84
93
95{
96public:
97 class InitArg;
98
105
107
108 static size_t CalcBufferSize(const InitArg& arg);
109
110 bool Init(const InitArg& arg, void* pBuffer, size_t bufferSize);
111
113
114 bool SetupBlockBuffer(void* pBuffer, size_t bufferSize);
115
117
118 void CalcBounding(const SkeletonObj* pSkeleton);
119
120 void CalcSubBounding(const SkeletonObj* pSkeleton);
121
122 void CalcShpBlock(int viewIndex, const Mtx34& worldMtx, int bufferIndex = 0);
123
125
126 const ResShape* GetResource() const { return m_pRes; }
127
128 void* GetBufferPtr() { return m_pBufferPtr; }
129
131
132 bool IsBlockBufferValid() const { return (m_Flag & BLOCK_BUFFER_VALID) != 0; }
133
135
136 int GetBoneIndex() const { return m_pRes->GetBoneIndex(); }
137
139
141
142 bool IsRigidBody() const { return m_pRes->IsRigidBody(); }
143
145
147
148 ResMesh* GetResMesh(int meshIndex = 0) { return m_pRes->GetMesh(meshIndex); }
149
150 const ResMesh* GetResMesh(int meshIndex = 0) const { return m_pRes->GetMesh(meshIndex); }
151
152 int GetMeshCount() const { return m_pRes->GetMeshCount(); }
153
154 int GetViewCount() const { return m_NumView; }
155
157
158 bool IsViewDependent() const { return m_ViewDependent != 0; }
159
160 int GetShpBlockCount() const { return m_NumShpBlock; }
161
162 GfxBuffer& GetShpBlock(int viewIndex)
163 {
164 NW_G3D_ASSERT_INDEX_BOUNDS(viewIndex, m_NumView);
165 return m_pShpBlockArray[viewIndex * m_ViewDependent];
166 }
167
168 const GfxBuffer& GetShpBlock(int viewIndex) const
169 {
170 NW_G3D_ASSERT_INDEX_BOUNDS(viewIndex, m_NumView);
171 return m_pShpBlockArray[viewIndex * m_ViewDependent];
172 }
173
174 int GetBufferingCount() const { return m_NumBuffering; }
175
177
179
180 bool IsBlockSwapEnabled() const { return (m_Flag & BLOCK_BUFFER_SWAP) != 0; }
181
182 void SetUserPtr(void* pUserPtr) { m_pUserPtr = pUserPtr; }
183
184 void* GetUserPtr() { return m_pUserPtr; }
185
186 const void* GetUserPtr() const { return m_pUserPtr; }
187
188 template <typename T>
189 T* GetUserPtr() { return static_cast<T*>(m_pUserPtr); }
190
191 template <typename T>
192 const T* GetUserPtr() const { return static_cast<const T*>(m_pUserPtr); }
193
194 ResVertex* GetResVertex() { return m_pRes->GetVertex(); }
195
196 const ResVertex* GetResVertex() const { return m_pRes->GetVertex(); }
197
198 int GetVtxAttribCount() const { return GetResVertex()->GetVtxAttribCount(); }
199
201 {
202 return GetResVertex()->GetVtxAttrib(attribIndex);
203 }
204
205 const ResVtxAttrib* GetResVtxAttrib(int attribIndex) const
206 {
207 return GetResVertex()->GetVtxAttrib(attribIndex);
208 }
209
210 ResVtxAttrib* GetResVtxAttrib(const char* name)
211 {
212 return GetResVertex()->GetVtxAttrib(name);
213 }
214
215 const ResVtxAttrib* GetResVtxAttrib(const char* name) const
216 {
217 return GetResVertex()->GetVtxAttrib(name);
218 }
219
220 const char* GetVtxAttribName(int attribIndex) const
221 {
222 return GetResVertex()->GetVtxAttribName(attribIndex);
223 }
224
225 int GetVtxAttribIndex(const char* name) const
226 {
227 return GetResVertex()->GetVtxAttribIndex(name);
228 }
229
230 int GetVertexBufferCount() const { return GetResVertex()->GetVtxBufferCount(); }
231
232 GfxBuffer& GetVertexBuffer(int bufferIndex)
233 {
234 return *GetResVertex()->GetVtxBuffer(bufferIndex)->GetGfxBuffer();
235 }
236
237 const GfxBuffer& GetVertexBuffer(int bufferIndex) const
238 {
239 return *GetResVertex()->GetVtxBuffer(bufferIndex)->GetGfxBuffer();
240 }
241
243
244 const Sphere* GetBounding() const { return m_pBounding; }
245
246 const AABB* GetSubBoundingArray() const { return m_pSubBounding; }
247
248 const u16* GetSubMeshIndexArray() const { return m_pRes->GetSubMeshIndexArray(); }
249
250 bool TestSubMeshIntersection(CullingContext* pCtx, const ViewVolume& volume) const;
251
252 int GetKeyShapeCount() const { return m_pRes->GetKeyShapeCount(); }
253
254 ResKeyShape* GetResKeyShape(int keyShapeIndex)
255 {
256 return m_pRes->GetKeyShape(keyShapeIndex);
257 }
258
259 const ResKeyShape* GetResKeyShape(int keyShapeIndex) const
260 {
261 return m_pRes->GetKeyShape(keyShapeIndex);
262 }
263
264 ResKeyShape* GetResKeyShape(const char* name)
265 {
266 return m_pRes->GetKeyShape(name);
267 }
268
269 const ResKeyShape* GetResKeyShape(const char* name) const
270 {
271 return m_pRes->GetKeyShape(name);
272 }
273
274 const char* GetKeyShapeName(int keyShapeIndex) const
275 {
276 return m_pRes->GetKeyShapeName(keyShapeIndex);
277 }
278
279 int GetKeyShapeIndex(const char* name) const
280 {
281 return m_pRes->GetKeyShapeIndex(name);
282 }
283
285
286 void ClearBlendWeights();
287
288 NW_G3D_DEPRECATED_FUNCTION(bool IsBlendWeightValid() const) { return 0 != (m_Flag & BLEND_WEIGHT_VALID); }
289
290 bool HasValidBlendWeight() const { return 0 != (m_Flag & BLEND_WEIGHT_VALID); }
291
292 void SetBlendWeight(int keyShapeIndex, float weight)
293 {
294 NW_G3D_ASSERT_INDEX_BOUNDS(keyShapeIndex, GetKeyShapeCount());
295 m_pBlendWeightArray[keyShapeIndex] = weight;
297
298 }
299
300 float GetBlendWeight(int keyShapeIndex) const
301 {
302 NW_G3D_ASSERT_INDEX_BOUNDS(keyShapeIndex, GetKeyShapeCount());
303 return m_pBlendWeightArray[keyShapeIndex];
304 }
305
306protected:
307 enum Flag
308 {
312 };
313
320
321private:
322 class Sizer;
324
326
333
336
340
342};
343
344class ShapeObj::Sizer : public nw::g3d::Sizer
345{
346public:
348
349 void Calc(const InitArg& arg);
350
351 enum
352 {
356
358
360 };
361
363};
364
366{
367public:
368 explicit InitArg(ResShape* resource)
369 : m_pRes(resource)
370 , m_NumBuffering(1)
371 , m_NumView(1)
372 , m_ViewDependent(false)
373 , m_BoundingEnabled(false)
374
375 {
376 NW_G3D_ASSERT_NOT_NULL(resource);
377 }
378
379 void BufferingCount(int count) { m_NumBuffering = count; m_Sizer.Invalidate(); }
380
381 void ViewCount(int count) { m_NumView = count; m_Sizer.Invalidate(); }
382
383 void ViewDependent() { m_ViewDependent = true; m_Sizer.Invalidate(); }
384
385 void ViewIndependent() { m_ViewDependent = false; m_Sizer.Invalidate(); }
386
387 void EnableBounding() { m_BoundingEnabled = true; m_Sizer.Invalidate(); }
388
389 void DisableBounding() { m_BoundingEnabled = false; m_Sizer.Invalidate(); }
390
391 int GetBufferingCount() const { return m_NumBuffering; }
392
393 int GetViewCount() const { return m_NumView; }
394
395 bool IsViewDependent() const { return m_ViewDependent; }
396
397 bool IsBoundingEnabled() const { return m_BoundingEnabled; }
398
399 ResShape* GetResource() const { return m_pRes; }
400
401 Sizer& GetSizer() const { return m_Sizer; }
402
403private:
409
410 mutable Sizer m_Sizer;
411};
412
413} } // namespace nw::g3d
414
415#endif // NW_G3D_SHAPEOBJ_H_
Definition g3d_ShapeObj.h:366
void DisableBounding()
Definition g3d_ShapeObj.h:389
ResShape * GetResource() const
Definition g3d_ShapeObj.h:399
bool IsViewDependent() const
Definition g3d_ShapeObj.h:395
void EnableBounding()
Definition g3d_ShapeObj.h:387
void ViewDependent()
Definition g3d_ShapeObj.h:383
void BufferingCount(int count)
Definition g3d_ShapeObj.h:379
bool m_BoundingEnabled
Definition g3d_ShapeObj.h:408
void ViewCount(int count)
Definition g3d_ShapeObj.h:381
int GetViewCount() const
Definition g3d_ShapeObj.h:393
Sizer m_Sizer
Definition g3d_ShapeObj.h:410
int m_NumBuffering
Definition g3d_ShapeObj.h:405
int m_NumView
Definition g3d_ShapeObj.h:406
int GetBufferingCount() const
Definition g3d_ShapeObj.h:391
bool m_ViewDependent
Definition g3d_ShapeObj.h:407
Sizer & GetSizer() const
Definition g3d_ShapeObj.h:401
ResShape * m_pRes
Definition g3d_ShapeObj.h:404
void ViewIndependent()
Definition g3d_ShapeObj.h:385
InitArg(ResShape *resource)
Definition g3d_ShapeObj.h:368
bool IsBoundingEnabled() const
Definition g3d_ShapeObj.h:397
Definition g3d_ShapeObj.h:345
Chunk chunk[NUM_CHUNK]
Definition g3d_ShapeObj.h:362
Sizer()
Definition g3d_ShapeObj.h:347
void Calc(const InitArg &arg)
Definition g3d_ShapeObj.cpp:240
@ BLEND_WEIGHT_ARRAY
Definition g3d_ShapeObj.h:355
@ SUBBOUNDING_ARRAY
Definition g3d_ShapeObj.h:353
@ BOUNDING_ARRAY
Definition g3d_ShapeObj.h:357
@ SHAPE_BLOCK_ARRAY
Definition g3d_ShapeObj.h:354
@ NUM_CHUNK
Definition g3d_ShapeObj.h:359
Definition g3d_ShapeObj.h:95
int GetVertexIndex() const
Definition g3d_ShapeObj.h:138
int GetMeshCount() const
Definition g3d_ShapeObj.h:152
int GetKeyShapeCount() const
Definition g3d_ShapeObj.h:252
ResVtxAttrib * GetResVtxAttrib(int attribIndex)
Definition g3d_ShapeObj.h:200
ResShape * GetResource()
Definition g3d_ShapeObj.h:124
const char * GetVtxAttribName(int attribIndex) const
Definition g3d_ShapeObj.h:220
Sphere * m_pBounding
Definition g3d_ShapeObj.h:334
T * GetUserPtr()
Definition g3d_ShapeObj.h:189
GfxBuffer & GetShpBlock(int viewIndex)
Definition g3d_ShapeObj.h:162
int GetVertexBufferCount() const
Definition g3d_ShapeObj.h:230
const AABB * GetSubBoundingArray() const
Definition g3d_ShapeObj.h:246
int GetKeyShapeIndex(const char *name) const
Definition g3d_ShapeObj.h:279
GfxBuffer & GetVertexBuffer(int bufferIndex)
Definition g3d_ShapeObj.h:232
int GetVtxAttribCount() const
Definition g3d_ShapeObj.h:198
void EnableBlockSwap()
Definition g3d_ShapeObj.h:176
bool SetupBlockBuffer(void *pBuffer, size_t bufferSize)
Definition g3d_ShapeObj.cpp:329
void * m_pBlockBuffer
Definition g3d_ShapeObj.h:339
void * m_pBufferPtr
Definition g3d_ShapeObj.h:338
void * m_pUserPtr
Definition g3d_ShapeObj.h:337
bool HasValidBlendWeight() const
Definition g3d_ShapeObj.h:290
Flag
Definition g3d_ShapeObj.h:308
@ BLOCK_BUFFER_SWAP
Definition g3d_ShapeObj.h:310
@ BLEND_WEIGHT_VALID
Definition g3d_ShapeObj.h:311
@ BLOCK_BUFFER_VALID
Definition g3d_ShapeObj.h:309
int GetShpBlockCount() const
Definition g3d_ShapeObj.h:160
void CalcSubBounding(const SkeletonObj *pSkeleton)
Definition g3d_ShapeObj.cpp:444
void * GetUserPtr()
Definition g3d_ShapeObj.h:184
ResKeyShape * GetResKeyShape(const char *name)
Definition g3d_ShapeObj.h:264
ResMesh * GetResMesh(int meshIndex=0)
Definition g3d_ShapeObj.h:148
int GetMaterialIndex() const
Definition g3d_ShapeObj.h:134
const ResShape * GetResource() const
Definition g3d_ShapeObj.h:126
void CalcShpBlock(int viewIndex, const Mtx34 &worldMtx, int bufferIndex=0)
Definition g3d_ShapeObj.cpp:476
int GetBufferingCount() const
Definition g3d_ShapeObj.h:174
float * m_pBlendWeightArray
Definition g3d_ShapeObj.h:332
bit32 m_Flag
Definition g3d_ShapeObj.h:325
bool IsSmoothSkinning() const
Definition g3d_ShapeObj.h:146
u8 m_NumBuffering
Definition g3d_ShapeObj.h:330
bool IsRigidSkinning() const
Definition g3d_ShapeObj.h:144
int GetSubMeshCount() const
Definition g3d_ShapeObj.h:156
u8 m_NumView
Definition g3d_ShapeObj.h:327
ResShape * m_pRes
Definition g3d_ShapeObj.h:323
BoundingCoord
Definition g3d_ShapeObj.h:315
@ NUM_COORD
Definition g3d_ShapeObj.h:318
@ LOCAL_COORD
Definition g3d_ShapeObj.h:317
@ WORLD_COORD
Definition g3d_ShapeObj.h:316
const char * GetKeyShapeName(int keyShapeIndex) const
Definition g3d_ShapeObj.h:274
Alignment
Definition g3d_ShapeObj.h:100
@ BLOCK_BUFFER_ALIGNMENT
Definition g3d_ShapeObj.h:103
@ BUFFER_ALIGNMENT
Definition g3d_ShapeObj.h:101
Sphere * GetBounding()
Definition g3d_ShapeObj.h:242
const ResVertex * GetResVertex() const
Definition g3d_ShapeObj.h:196
void SetUserPtr(void *pUserPtr)
Definition g3d_ShapeObj.h:182
const ResMesh * GetResMesh(int meshIndex=0) const
Definition g3d_ShapeObj.h:150
float GetBlendWeight(int keyShapeIndex) const
Definition g3d_ShapeObj.h:300
void * GetBlockBufferPtr()
Definition g3d_ShapeObj.h:130
const GfxBuffer & GetShpBlock(int viewIndex) const
Definition g3d_ShapeObj.h:168
const u16 * GetSubMeshIndexArray() const
Definition g3d_ShapeObj.h:248
int GetBoneIndex() const
Definition g3d_ShapeObj.h:136
void ClearBlendWeights()
Definition g3d_ShapeObj.cpp:501
int GetVtxSkinCount() const
Definition g3d_ShapeObj.h:140
ShapeObj()
Definition g3d_ShapeObj.h:106
void SetBlendWeight(int keyShapeIndex, float weight)
Definition g3d_ShapeObj.h:292
int GetViewCount() const
Definition g3d_ShapeObj.h:154
int GetVtxAttribIndex(const char *name) const
Definition g3d_ShapeObj.h:225
bool IsBlockSwapEnabled() const
Definition g3d_ShapeObj.h:180
void DisableBlockSwap()
Definition g3d_ShapeObj.h:178
const void * GetUserPtr() const
Definition g3d_ShapeObj.h:186
void CalcBounding(const SkeletonObj *pSkeleton)
Definition g3d_ShapeObj.cpp:381
const ResVtxAttrib * GetResVtxAttrib(const char *name) const
Definition g3d_ShapeObj.h:215
u8 m_ViewDependent
Definition g3d_ShapeObj.h:328
GfxBuffer * m_pShpBlockArray
Definition g3d_ShapeObj.h:331
size_t CalcBlockBufferSize() const
Definition g3d_ShapeObj.cpp:324
const ResVtxAttrib * GetResVtxAttrib(int attribIndex) const
Definition g3d_ShapeObj.h:205
const Sphere * GetBounding() const
Definition g3d_ShapeObj.h:244
const ResKeyShape * GetResKeyShape(int keyShapeIndex) const
Definition g3d_ShapeObj.h:259
bool Init(const InitArg &arg, void *pBuffer, size_t bufferSize)
Definition g3d_ShapeObj.cpp:270
bool IsRigidBody() const
Definition g3d_ShapeObj.h:142
void * GetBufferPtr()
Definition g3d_ShapeObj.h:128
static size_t CalcBufferSize(const InitArg &arg)
Definition g3d_ShapeObj.cpp:263
const T * GetUserPtr() const
Definition g3d_ShapeObj.h:192
void CleanupBlockBuffer()
bool TestSubMeshIntersection(CullingContext *pCtx, const ViewVolume &volume) const
Definition g3d_ShapeObj.cpp:512
ResKeyShape * GetResKeyShape(int keyShapeIndex)
Definition g3d_ShapeObj.h:254
bool IsViewDependent() const
Definition g3d_ShapeObj.h:158
ResVtxAttrib * GetResVtxAttrib(const char *name)
Definition g3d_ShapeObj.h:210
u8 m_NumShpBlock
Definition g3d_ShapeObj.h:329
int GetTargetAttribCount() const
Definition g3d_ShapeObj.h:284
const ResKeyShape * GetResKeyShape(const char *name) const
Definition g3d_ShapeObj.h:269
AABB * m_pSubBounding
Definition g3d_ShapeObj.h:335
const GfxBuffer & GetVertexBuffer(int bufferIndex) const
Definition g3d_ShapeObj.h:237
ResVertex * GetResVertex()
Definition g3d_ShapeObj.h:194
bool IsBlockBufferValid() const
Definition g3d_ShapeObj.h:132
Definition g3d_Sizer.h:10
Sizer()
Definition g3d_Sizer.h:18
Definition g3d_SkeletonObj.h:102
Definition g3d_GfxObject.h:48
Definition g3d_Matrix34.h:34
Definition g3d_Vector2.h:26
Definition g3d_Vector3.h:30
GfxBuffer * GetGfxBuffer()
Definition g3d_ResShape.h:28
const GfxBuffer * GetGfxBuffer() const
Definition g3d_ResShape.h:33
Definition g3d_ResShape.h:180
Definition g3d_ResShape.h:152
Definition g3d_ResShape.h:237
bool IsSmoothSkinning() const
Definition g3d_ResShape.h:274
int GetMaterialIndex() const
Definition g3d_ResShape.h:256
bool IsRigidBody() const
Definition g3d_ResShape.h:270
int GetSubMeshCount() const
Definition g3d_ResShape.h:296
int GetTargetAttribCount() const
Definition g3d_ResShape.h:300
int GetBoneIndex() const
Definition g3d_ResShape.h:258
bool IsRigidSkinning() const
Definition g3d_ResShape.h:272
int GetVertexIndex() const
Definition g3d_ResShape.h:260
int GetVtxSkinCount() const
Definition g3d_ResShape.h:268
Definition g3d_ResShape.h:89
Definition g3d_ResShape.h:57
#define NW_G3D_ASSERT_NOT_NULL(exp)
Definition g3d_assert.h:20
#define NW_G3D_ASSERT_INDEX_BOUNDS(index, size)
Definition g3d_assert.h:23
#define NW_G3D_DEPRECATED_FUNCTION(MFunc)
Definition g3d_defs.h:87
#define NW_G3D_DISALLOW_COPY_AND_ASSIGN(TypeName)
Definition g3d_defs.h:81
u32 bit32
Definition g3d_defs.h:131
Definition g3d_MathCommon.h:6
Definition g3d_GfxManage.cpp:10
Definition g3d_ShapeObj.h:39
Vec3 max
Definition g3d_ShapeObj.h:47
void Merge(const AABB &lhs, const AABB &rhs)
Definition g3d_ShapeObj.cpp:73
void Transform(const Bounding &aabb, const Mtx34 &mtx)
Definition g3d_ShapeObj.cpp:56
Vec3 min
Definition g3d_ShapeObj.h:46
void Set(const Vec3 *pPointArray, int count)
Definition g3d_ShapeObj.cpp:39
Definition g3d_ShapeObj.h:86
int nodeIndex
Definition g3d_ShapeObj.h:89
CullingContext()
Definition g3d_ShapeObj.h:87
int submeshIndex
Definition g3d_ShapeObj.h:90
int submeshCount
Definition g3d_ShapeObj.h:91
Definition g3d_ShapeObj.h:51
Vec3 normal
Definition g3d_ShapeObj.h:54
float dist
Definition g3d_ShapeObj.h:55
void Set(const Vec3 &p0, const Vec3 &p1, const Vec3 &p2)
Definition g3d_ShapeObj.cpp:88
Definition g3d_ShapeObj.h:22
u32 reserved[51]
Definition g3d_ShapeObj.h:25
s32 vtxSkinCount
Definition g3d_ShapeObj.h:24
Mtx34 worldMtx
Definition g3d_ShapeObj.h:23
Definition g3d_Sizer.h:13
Definition g3d_ShapeObj.h:29
float radius
Definition g3d_ShapeObj.h:35
Vec3 center
Definition g3d_ShapeObj.h:34
void Transform(const Sphere &sphere, const Mtx34 &mtx)
Definition g3d_ShapeObj.cpp:9
void Merge(const Sphere &lhs, const Sphere &rhs)
Definition g3d_ShapeObj.cpp:19
Definition g3d_ShapeObj.h:59
int flag
Definition g3d_ShapeObj.h:82
Plane planes[6]
Definition g3d_ShapeObj.h:80
void SetFrustum(float top, float bottom, float left, float right, float zNear, float zFar, const Mtx34 &viewToWorld)
Definition g3d_ShapeObj.cpp:97
void SetPerspective(float fovy, float aspect, float zNear, float zFar, const Mtx34 &viewToWorld)
void SetOrtho(float top, float bottom, float left, float right, float zNear, float zFar, const Mtx34 &viewToWorld)
AABB aabb
Definition g3d_ShapeObj.h:79
void SetPerspectiveOffset(float fovy, float aspect, float zNear, float zFar, const Mtx34 &viewToWorld, const Vec2 &offset)
bool TestIntersection(const Sphere &sphere) const
Definition g3d_ShapeObj.cpp:136
bool IsAABBEnabled() const
Definition g3d_ShapeObj.h:77
void EnableAABB()
Definition g3d_ShapeObj.h:75
int TestIntersectionEx(const Sphere &sphere) const
Definition g3d_ShapeObj.cpp:150
bool TestIntersection(const AABB &aabb) const
Definition g3d_ShapeObj.cpp:169
int numPlanes
Definition g3d_ShapeObj.h:81
int TestIntersectionEx(const AABB &aabb) const
Definition g3d_ShapeObj.cpp:200
void DisableAABB()
Definition g3d_ShapeObj.h:76
Definition g3d_ResShape.h:201