Defines | Functions | Variables

btSoftBodySolver_DX11SIMDAware.cpp File Reference

#include <cstdio>
#include "BulletCollision/CollisionShapes/btTriangleIndexVertexArray.h"
#include "vectormath/vmInclude.h"
#include "btSoftBodySolverLinkData_DX11SIMDAware.h"
#include "btSoftBodySolver_DX11SIMDAware.h"
#include "btSoftBodySolverVertexBuffer_DX11.h"
#include "BulletSoftBody/btSoftBody.h"
#include "BulletCollision/CollisionShapes/btCapsuleShape.h"
#include "HLSL/UpdatePositionsFromVelocities.hlsl"
#include "HLSL/SolvePositionsSIMDBatched.hlsl"
#include "HLSL/UpdateNodes.hlsl"
#include "HLSL/UpdatePositions.hlsl"
#include "HLSL/UpdateConstants.hlsl"
#include "HLSL/Integrate.hlsl"
#include "HLSL/ApplyForces.hlsl"
#include "HLSL/UpdateNormals.hlsl"
#include "HLSL/OutputToVertexArray.hlsl"
#include "HLSL/VSolveLinks.hlsl"
#include "HLSL/ComputeBounds.hlsl"
#include "HLSL/solveCollisionsAndUpdateVelocitiesSIMDBatched.hlsl"
Include dependency graph for btSoftBodySolver_DX11SIMDAware.cpp:

Go to the source code of this file.

Defines

#define WAVEFRONT_SIZE   32
#define WAVEFRONT_BLOCK_MULTIPLIER   2
#define GROUP_SIZE   (WAVEFRONT_SIZE*WAVEFRONT_BLOCK_MULTIPLIER)
#define LINKS_PER_SIMD_LANE   16
#define STRINGIFY(S)   STRINGIFY2( S )
#define STRINGIFY2(S)   #S
#define MSTRINGIFY(A)   #A

Functions

static char m_d3dDeviceContext (d3dDeviceContext)
static char m_wavefrontSize (WAVEFRONT_SIZE)
static char m_linksPerWorkItem (LINKS_PER_SIMD_LANE)
static char m_maxBatchesWithinWave (0)
static char m_maxLinksPerWavefront (m_wavefrontSize *m_linksPerWorkItem)
static char m_numWavefronts (0)
static char m_maxVertex (0)
static char m_dx11NumBatchesAndVerticesWithinWaves (d3dDevice, d3dDeviceContext,&m_numBatchesAndVerticesWithinWaves, true)
static char m_dx11WavefrontVerticesGlobalAddresses (d3dDevice, d3dDeviceContext,&m_wavefrontVerticesGlobalAddresses, true)
static char m_dx11LinkVerticesLocalAddresses (d3dDevice, d3dDeviceContext,&m_linkVerticesLocalAddresses, true)
static char m_dx11LinkStrength (d3dDevice, d3dDeviceContext,&m_linkStrength, true)
static char m_dx11LinksMassLSC (d3dDevice, d3dDeviceContext,&m_linksMassLSC, true)
static char m_dx11LinksRestLengthSquared (d3dDevice, d3dDeviceContext,&m_linksRestLengthSquared, true)
static char m_dx11LinksRestLength (d3dDevice, d3dDeviceContext,&m_linksRestLength, true)
static char m_dx11LinksMaterialLinearStiffnessCoefficient (d3dDevice, d3dDeviceContext,&m_linksMaterialLinearStiffnessCoefficient, true)
static Vectormath::Aos::Vector3 toVector3 (const btVector3 &vec)
static Vectormath::Aos::Transform3 toTransform3 (const btTransform &transform)
static void generateBatchesOfWavefronts (btAlignedObjectArray< btAlignedObjectArray< int > > &linksForWavefronts, btSoftBodyLinkData &linkData, int numVertices, btAlignedObjectArray< btAlignedObjectArray< int > > &wavefrontBatches)
template<typename T >
static void removeFromVector (btAlignedObjectArray< T > &vectorToUpdate, int indexToRemove)
template<typename T >
static void insertAtIndex (btAlignedObjectArray< T > &vectorToUpdate, int index, T element)
 Insert element into vectorToUpdate at index index.
template<typename T >
static void insertUniqueAndOrderedIntoVector (btAlignedObjectArray< T > &vectorToUpdate, T element)
 Insert into btAlignedObjectArray assuming the array is ordered and maintaining both ordering and uniqueness.
static void generateLinksPerVertex (int numVertices, btSoftBodyLinkData &linkData, btAlignedObjectArray< int > &listOfLinksPerVertex, btAlignedObjectArray< int > &numLinksPerVertex, int &maxLinks)
static void computeBatchingIntoWavefronts (btSoftBodyLinkData &linkData, int wavefrontSize, int linksPerWorkItem, int maxLinksPerWavefront, btAlignedObjectArray< btAlignedObjectArray< int > > &linksForWavefronts, btAlignedObjectArray< btAlignedObjectArray< btAlignedObjectArray< int > > > &batchesWithinWaves, btAlignedObjectArray< btAlignedObjectArray< int > > &verticesForWavefronts)

Variables

static char * UpdatePositionsFromVelocitiesHLSLString

Define Documentation

#define GROUP_SIZE   (WAVEFRONT_SIZE*WAVEFRONT_BLOCK_MULTIPLIER)

Definition at line 21 of file btSoftBodySolver_DX11SIMDAware.cpp.

#define LINKS_PER_SIMD_LANE   16

Definition at line 22 of file btSoftBodySolver_DX11SIMDAware.cpp.

#define MSTRINGIFY (   A  )     #A

Definition at line 36 of file btSoftBodySolver_DX11SIMDAware.cpp.

#define STRINGIFY (   S  )     STRINGIFY2( S )

Definition at line 24 of file btSoftBodySolver_DX11SIMDAware.cpp.

#define STRINGIFY2 (   S  )     #S

Definition at line 25 of file btSoftBodySolver_DX11SIMDAware.cpp.

#define WAVEFRONT_BLOCK_MULTIPLIER   2

Definition at line 20 of file btSoftBodySolver_DX11SIMDAware.cpp.

#define WAVEFRONT_SIZE   32

Definition at line 19 of file btSoftBodySolver_DX11SIMDAware.cpp.


Function Documentation

static void computeBatchingIntoWavefronts ( btSoftBodyLinkData linkData,
int  wavefrontSize,
int  linksPerWorkItem,
int  maxLinksPerWavefront,
btAlignedObjectArray< btAlignedObjectArray< int > > &  linksForWavefronts,
btAlignedObjectArray< btAlignedObjectArray< btAlignedObjectArray< int > > > &  batchesWithinWaves,
btAlignedObjectArray< btAlignedObjectArray< int > > &  verticesForWavefronts 
) [static]

Definition at line 723 of file btSoftBodySolver_DX11SIMDAware.cpp.

static void generateBatchesOfWavefronts ( btAlignedObjectArray< btAlignedObjectArray< int > > &  linksForWavefronts,
btSoftBodyLinkData linkData,
int  numVertices,
btAlignedObjectArray< btAlignedObjectArray< int > > &  wavefrontBatches 
) [static]

Definition at line 575 of file btSoftBodySolver_DX11SIMDAware.cpp.

static void generateLinksPerVertex ( int  numVertices,
btSoftBodyLinkData linkData,
btAlignedObjectArray< int > &  listOfLinksPerVertex,
btAlignedObjectArray< int > &  numLinksPerVertex,
int &  maxLinks 
) [static]

Definition at line 677 of file btSoftBodySolver_DX11SIMDAware.cpp.

template<typename T >
static void insertAtIndex ( btAlignedObjectArray< T > &  vectorToUpdate,
int  index,
element 
) [static]

Insert element into vectorToUpdate at index index.

Definition at line 652 of file btSoftBodySolver_DX11SIMDAware.cpp.

template<typename T >
static void insertUniqueAndOrderedIntoVector ( btAlignedObjectArray< T > &  vectorToUpdate,
element 
) [static]

Insert into btAlignedObjectArray assuming the array is ordered and maintaining both ordering and uniqueness.

ie it treats vectorToUpdate as an ordered set.

Definition at line 666 of file btSoftBodySolver_DX11SIMDAware.cpp.

static char m_d3dDeviceContext ( d3dDeviceContext   )  [static]
static char m_dx11LinksMassLSC ( d3dDevice  ,
d3dDeviceContext  ,
m_linksMassLSC,
true   
)
static char m_dx11LinksMaterialLinearStiffnessCoefficient ( d3dDevice  ,
d3dDeviceContext  ,
m_linksMaterialLinearStiffnessCoefficient,
true   
)

Definition at line 80 of file btSoftBodySolver_DX11SIMDAware.cpp.

static char m_dx11LinksRestLength ( d3dDevice  ,
d3dDeviceContext  ,
m_linksRestLength,
true   
)
static char m_dx11LinksRestLengthSquared ( d3dDevice  ,
d3dDeviceContext  ,
m_linksRestLengthSquared,
true   
)
static char m_dx11LinkStrength ( d3dDevice  ,
d3dDeviceContext  ,
m_linkStrength,
true   
)
static char m_dx11LinkVerticesLocalAddresses ( d3dDevice  ,
d3dDeviceContext  ,
m_linkVerticesLocalAddresses,
true   
)
static char m_dx11NumBatchesAndVerticesWithinWaves ( d3dDevice  ,
d3dDeviceContext  ,
m_numBatchesAndVerticesWithinWaves,
true   
)
static char m_dx11WavefrontVerticesGlobalAddresses ( d3dDevice  ,
d3dDeviceContext  ,
m_wavefrontVerticesGlobalAddresses,
true   
)
static char m_linksPerWorkItem ( LINKS_PER_SIMD_LANE   ) 
static char m_maxBatchesWithinWave (  ) 
static char m_maxLinksPerWavefront ( m_wavefrontSize *  m_linksPerWorkItem  ) 
static char m_maxVertex (  ) 
static char m_numWavefronts (  ) 
static char m_wavefrontSize ( WAVEFRONT_SIZE   ) 
template<typename T >
static void removeFromVector ( btAlignedObjectArray< T > &  vectorToUpdate,
int  indexToRemove 
) [static]

Definition at line 638 of file btSoftBodySolver_DX11SIMDAware.cpp.

static Vectormath::Aos::Transform3 toTransform3 ( const btTransform transform  )  [static]

Definition at line 554 of file btSoftBodySolver_DX11SIMDAware.cpp.

static Vectormath::Aos::Vector3 toVector3 ( const btVector3 vec  )  [static]

Definition at line 90 of file btSoftBodySolver_DX11SIMDAware.cpp.


Variable Documentation

Initial value:
"/home/ryan/bullet-svn/src/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolver_DX11SIMDAware.cpp" 2



btSoftBodyLinkDataDX11SIMDAware::btSoftBodyLinkDataDX11SIMDAware( ID3D11Device *d3dDevice, ID3D11DeviceContext *d3dDeviceContext ) : 
                m_d3dDevice( d3dDevice )

Definition at line 37 of file btSoftBodySolver_DX11SIMDAware.cpp.