"L. Spiro Engine"
Classes | Enumerations | Functions | Variables

lsp Namespace Reference

Classes

class  CAabb
 A min-max axis-aligned bounding box. More...
class  CAabb2d
 A min-max axis-aligned 2D bounding box. More...
class  CCappedKDop
 A k-DOP with a maximum number of planes when performance is needed. More...
class  CKDop
 A k-DOP is a bounding box of any number of planes. More...
class  CObb
 An oriented bounding box. More...
class  CObb2d
 An oriented bounding box in 2D. More...
class  CIntersect
 Performs intersection tests between various primitive types. More...
class  CPhysicsLib
 The main header for the physics library. More...
class  CPolygon3Base
 A template allowing to create polygons with a variable number of edges. More...
class  CQuadTreeNode
 A node in a quad-tree. More...
class  CQuadTreeObject
 An object that can be fit into a quad-tree must inherit from this. More...
class  CSolidLeafBspBase

Enumerations

enum  LSP_AABB_2D_CORNERS { LSP_A2C_UPPER_LEFT, LSP_A2C_UPPER_RIGHT, LSP_A2C_LOWER_LEFT, LSP_A2C_LOWER_RIGHT }

Functions

LSBOOL LSE_CALL CreateQuadTree (LSREAL _fSize)
LSVOID LSE_CALL Reset ()
const CQuadTreeNode *LSE_CALL Root () const
LSBOOL LSE_CALL InsertObject (CQuadTreeObject *_pqtoObject)
LSBOOL LSE_CALL FindObjects (const CAabb2d &_a2Box, CVector< CQuadTreeObject *, LSUINT32 > &_vReturn)

Variables

__pad0__
LSP_AC_FORWARD_LEFT_TOP
LSP_AC_FORWARD_RIGHT_BOTTOM
LSP_AC_FORWARD_RIGHT_TOP
LSP_AC_BACK_LEFT_BOTTOM
LSP_AC_BACK_LEFT_TOP
LSP_AC_BACK_RIGHT_BOTTOM
LSP_AC_BACK_RIGHT_TOP
F const CPlane3 & _pPlane
F const CFrustum & _fFrustum
F const CVector3 * _pvPoints
F const CVector3 LSUINT32 _ui32TotalPoints
F const CVector3 LSUINT32
LSUINT32 & 
_ui32Min
F const CVector3 LSUINT32
LSUINT32 LSUINT32 & 
_ui32Max
LSUINT8 * m_pui8Nodes
CQuadTreeNodem_pqtnLevels [8]
LSREAL m_fRadius
LSREAL m_fInvRadius
_tVecType
_tPlaneType

Detailed Description

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A min-max axis-aligned bounding box.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A min-max axis-aligned 2D bounding box.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A capped k-DOP is a k-DOP with a maximum number of planes. This stores enough planes to hold the maximum, so allocations are avoided, making this the choice for a limited number of planes in high-performance situations.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A k-DOP is a bounding box of any number of planes.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: An oriented bounding box. Oriented bounding boxes attempt to make the tightest rectangular block around an object, using any axis for the fit. Because their orientations can be arbitrary, collision tests against them can be more expensive, but they provide fewer false-positives.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: An oriented bounding box in 2D. Oriented bounding boxes attempt to make the tightest rectangular block around an object, using any axis for the fit. Because their orientations can be arbitrary, collision tests against them can be more expensive, but they provide fewer false-positives.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: Handles classifications of primitives. Specifically, it classifies primitives in relation with planes.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: Performs intersection tests between various primitive types.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: Provides functions for testing if primitives overlap or intersect. As it only performs a boolean test, these functions are faster than the CIntersect and CCollide functions.

Copyright L. Spiro 2011 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: Miscellaneous helper functions for the physics library.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A template allowing to create polygons with a variable number of edges.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: An 8-layer quad-tree with fast insertion times. Uses a bit hack to increase insertion speed for high-performance use.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A node in a quad-tree.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: An object that can be fit into a quad-tree must inherit from this.

Copyright L. Spiro 2012 All rights reserved.

Written by: Shawn (L. Spiro) Wilcoxen

This code may not be sold or traded for any personal gain without express written consent. You may use this code in your own projects and modify it to suit your needs as long as this disclaimer remains intact. You may not take credit for having written this code.

Description: A template for a solid-leaf BSP. The BSP class splits polygons as its sends them to either side of nodes.


Enumeration Type Documentation

The axis of each side of the AABB.


Function Documentation

LSBOOL LSE_CALL lsp::CreateQuadTree ( LSREAL  _fSize)

Creates the quad-tree with the given size. The created quad-tree has 8 nested layers.

Parameters:
_fSizeThe size of the quad-tree to create.
Returns:
Returns true if there were no memory failures during the creation of the quad-tree.
LSBOOL LSE_CALL lsp::FindObjects ( const CAabb2d &  _a2Box,
CVector< CQuadTreeObject *, LSUINT32 > &  _vReturn 
)

Gets all objects in the quad-tree whose 2D AABB's overlap or are contained by the given 2D AABB.

Parameters:
_a2BoxThe 2D AABB within which objects are tested.
_vReturnThe returned array of objects.
Returns:
Returns true if the full list of objects could be returned without encountering memory failures.
LSBOOL LSE_CALL lsp::InsertObject ( CQuadTreeObject *  _pqtoObject)

Inserts an object into the quad-tree. Any items not fully inside the bounds of the quad-tree are inserted at the root level. The insertion process is extremely efficient.

Parameters:
_pqtoObjectThe quad-tree-object to insert.
Returns:
Returns true if there are no memory failures during the insert.
LSVOID LSE_CALL lsp::Reset ( )

Resets the quad-tree back to nothing.

Reset everything. Clears all resources created by this instance.

Reset all contents.

LSE_INLINE CQuadTreeNode *LSE_CALL lsp::Root ( ) const

Gets the root node of the tree, which can be NULL.

Returns:
Returns the root node of the tree, which can be NULL.

Variable Documentation

The inverse radius of the quad-tree.

The radius of this quad-tree.

Pointers to each level of the tree, with index 0 being the root node.

LSUINT8* lsp::m_pui8Nodes

Pointer to the nodes of the quad-tree. The first node encompasses the entire bounding box of this tree.

 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator