|
Blender V5.0
|
#include "btBatchedConstraints.h"#include "LinearMath/btIDebugDraw.h"#include "LinearMath/btMinMax.h"#include "LinearMath/btStackAlloc.h"#include "LinearMath/btQuickprof.h"#include <string.h>#include <cmath>Go to the source code of this file.
Classes | |
| struct | btBatchedConstraintInfo |
| struct | btBatchInfo |
| struct | ReadSolverConstraintsLoop |
| struct | ExpandConstraintRowsLoop |
| struct | UpdateConstraintBatchIdsForMergesLoop |
| struct | WriteOutConstraintIndicesLoop |
| class | PreallocatedMemoryHelper< N > |
| struct | btIntVec3 |
| struct | AssignConstraintsToGridBatchesParams |
| struct | AssignConstraintsToGridBatchesLoop |
Functions | |
| static void | debugDrawSingleBatch (const btBatchedConstraints *bc, btConstraintArray *constraints, const btAlignedObjectArray< btSolverBody > &bodies, int iBatch, const btVector3 &color, const btVector3 &offset) |
| static void | debugDrawPhase (const btBatchedConstraints *bc, btConstraintArray *constraints, const btAlignedObjectArray< btSolverBody > &bodies, int iPhase, const btVector3 &color0, const btVector3 &color1, const btVector3 &offset) |
| static void | debugDrawAllBatches (const btBatchedConstraints *bc, btConstraintArray *constraints, const btAlignedObjectArray< btSolverBody > &bodies) |
| static void | initBatchedBodyDynamicFlags (btAlignedObjectArray< bool > *outBodyDynamicFlags, const btAlignedObjectArray< btSolverBody > &bodies) |
| static int | runLengthEncodeConstraintInfo (btBatchedConstraintInfo *outConInfos, int numConstraints) |
| static int | initBatchedConstraintInfo (btBatchedConstraintInfo *outConInfos, btConstraintArray *constraints) |
| static void | expandConstraintRowsInPlace (int *constraintBatchIds, const btBatchedConstraintInfo *conInfos, int numConstraints, int numConstraintRows) |
| static void | expandConstraintRows (int *destConstraintBatchIds, const int *srcConstraintBatchIds, const btBatchedConstraintInfo *conInfos, int numConstraints, int numConstraintRows) |
| static void | expandConstraintRowsMt (int *destConstraintBatchIds, const int *srcConstraintBatchIds, const btBatchedConstraintInfo *conInfos, int numConstraints, int numConstraintRows) |
| static void | initBatchedConstraintInfoArray (btAlignedObjectArray< btBatchedConstraintInfo > *outConInfos, btConstraintArray *constraints) |
| static void | mergeSmallBatches (btBatchInfo *batches, int iBeginBatch, int iEndBatch, int minBatchSize, int maxBatchSize) |
| static void | updateConstraintBatchIdsForMerges (int *constraintBatchIds, int numConstraints, const btBatchInfo *batches, int numBatches) |
| static void | updateConstraintBatchIdsForMergesMt (int *constraintBatchIds, int numConstraints, const btBatchInfo *batches, int numBatches) |
| bool | BatchCompare (const btBatchedConstraints::Range &a, const btBatchedConstraints::Range &b) |
| static void | writeOutConstraintIndicesForRangeOfBatches (btBatchedConstraints *bc, const int *constraintBatchIds, int numConstraints, int *constraintIdPerBatch, int batchBegin, int batchEnd) |
| static void | writeOutConstraintIndicesMt (btBatchedConstraints *bc, const int *constraintBatchIds, int numConstraints, int *constraintIdPerBatch, int maxNumBatchesPerPhase, int numPhases) |
| static void | writeGrainSizes (btBatchedConstraints *bc) |
| static void | writeOutBatches (btBatchedConstraints *bc, const int *constraintBatchIds, int numConstraints, const btBatchInfo *batches, int *batchWork, int maxNumBatchesPerPhase, int numPhases) |
| static btVector3 | findMaxDynamicConstraintExtent (btVector3 *bodyPositions, bool *bodyDynamicFlags, btBatchedConstraintInfo *conInfos, int numConstraints, int numBodies) |
| static void | assignConstraintsToGridBatches (const AssignConstraintsToGridBatchesParams ¶ms, int iConBegin, int iConEnd) |
| static void | setupSpatialGridBatchesMt (btBatchedConstraints *batchedConstraints, btAlignedObjectArray< char > *scratchMemory, btConstraintArray *constraints, const btAlignedObjectArray< btSolverBody > &bodies, int minBatchSize, int maxBatchSize, bool use2DGrid) |
| static void | setupSingleBatch (btBatchedConstraints *bc, int numConstraints) |
Variables | |
| const int | kNoMerge = -1 |
|
static |
Definition at line 705 of file btBatchedConstraints.cpp.
References btBatchedConstraintInfo::bodyIds, BT_PROFILE, btAssert, btClamp(), btMax(), btMin(), i, btIntVec3::m_ints, and params.
Referenced by AssignConstraintsToGridBatchesLoop::forLoop(), and setupSpatialGridBatchesMt().
|
inline |
Definition at line 432 of file btBatchedConstraints.cpp.
References b, btBatchedConstraints::Range::begin, and btBatchedConstraints::Range::end.
Referenced by writeOutBatches().
|
static |
Definition at line 145 of file btBatchedConstraints.cpp.
References b, BT_LARGE_FLOAT, BT_PROFILE, btVector3, constraints, debugDrawPhase(), float, btBatchedConstraints::m_debugDrawer, btBatchedConstraints::m_phases, pos, and btAlignedObjectArray< T >::size().
Referenced by btBatchedConstraints::setup().
|
static |
Definition at line 124 of file btBatchedConstraints.cpp.
References btBatchedConstraints::Range::begin, BT_PROFILE, btMax(), btVector3, col, constraints, debugDrawSingleBatch(), btBatchedConstraints::Range::end, float, lerp, btBatchedConstraints::m_debugDrawer, and btBatchedConstraints::m_phases.
Referenced by debugDrawAllBatches().
|
static |
Definition at line 101 of file btBatchedConstraints.cpp.
References b, btSolverConstraint, btVector3, constraints, btIDebugDraw::drawLine(), btBatchedConstraints::m_batches, btBatchedConstraints::m_constraintIndices, and btBatchedConstraints::m_debugDrawer.
Referenced by debugDrawPhase().
|
static |
Definition at line 286 of file btBatchedConstraints.cpp.
References BT_PROFILE, btAssert, btBatchedConstraintInfo::constraintIndex, i, btBatchedConstraintInfo::numConstraintRows, and numConstraints.
Referenced by ExpandConstraintRowsLoop::forLoop().
|
static |
Definition at line 265 of file btBatchedConstraints.cpp.
References BT_PROFILE, btAssert, btBatchedConstraintInfo::constraintIndex, i, btBatchedConstraintInfo::numConstraintRows, and numConstraints.
|
static |
Definition at line 323 of file btBatchedConstraints.cpp.
References BT_PROFILE, btParallelFor(), and numConstraints.
Referenced by setupSpatialGridBatchesMt().
|
static |
Definition at line 653 of file btBatchedConstraints.cpp.
References btBatchedConstraintInfo::bodyIds, BT_PROFILE, btAssert, btVector3, numBodies, and numConstraints.
Referenced by setupSpatialGridBatchesMt().
|
static |
Definition at line 175 of file btBatchedConstraints.cpp.
References BT_PROFILE, btSolverBody, i, btAlignedObjectArray< T >::resizeNoInitialize(), btAlignedObjectArray< T >::size(), and x.
|
static |
Definition at line 234 of file btBatchedConstraints.cpp.
References btBatchedConstraintInfo::bodyIds, BT_PROFILE, btParallelFor(), btSolverConstraint, btBatchedConstraintInfo::constraintIndex, constraints, i, btBatchedConstraintInfo::numConstraintRows, numConstraints, and runLengthEncodeConstraintInfo().
Referenced by initBatchedConstraintInfoArray(), and setupSpatialGridBatchesMt().
|
static |
Definition at line 331 of file btBatchedConstraints.cpp.
References btAlignedObjectArray< T >::at(), BT_PROFILE, constraints, initBatchedConstraintInfo(), numConstraints, and btAlignedObjectArray< T >::resizeNoInitialize().
|
static |
Definition at line 342 of file btBatchedConstraints.cpp.
References batch, BT_PROFILE, kNoMerge, btBatchInfo::mergeIndex, and btBatchInfo::numConstraints.
Referenced by setupSpatialGridBatchesMt().
|
static |
Definition at line 187 of file btBatchedConstraints.cpp.
References btBatchedConstraintInfo::bodyIds, BT_PROFILE, btBatchedConstraintInfo::constraintIndex, btBatchedConstraintInfo::numConstraintRows, and numConstraints.
Referenced by initBatchedConstraintInfo().
|
static |
Definition at line 1036 of file btBatchedConstraints.cpp.
References BT_PROFILE, i, btBatchedConstraints::m_batches, btBatchedConstraints::m_constraintIndices, btBatchedConstraints::m_phaseGrainSize, btBatchedConstraints::m_phaseOrder, btBatchedConstraints::m_phases, numConstraints, btAlignedObjectArray< T >::push_back(), btAlignedObjectArray< T >::resize(), and btAlignedObjectArray< T >::resizeNoInitialize().
Referenced by btBatchedConstraints::setup().
|
static |
Definition at line 816 of file btBatchedConstraints.cpp.
References PreallocatedMemoryHelper< N >::addChunk(), assignConstraintsToGridBatches(), btAlignedObjectArray< T >::at(), batch, BT_LARGE_FLOAT, BT_PROFILE, btAssert, btMax(), btParallelFor(), btSolverBody, btVector3, btAlignedObjectArray< T >::capacity(), constraints, expandConstraintRowsMt(), findMaxDynamicConstraintExtent(), float, PreallocatedMemoryHelper< N >::getSizeToAllocate(), i, initBatchedConstraintInfo(), btIntVec3::m_ints, mergeSmallBatches(), btBatchedConstraintInfo::numConstraintRows, numConstraints, params, btAlignedObjectArray< T >::reserve(), btAlignedObjectArray< T >::resizeNoInitialize(), PreallocatedMemoryHelper< N >::setChunkPointers(), btAlignedObjectArray< T >::size(), updateConstraintBatchIdsForMergesMt(), v, btBatchedConstraints::validate(), writeOutBatches(), and x.
Referenced by btBatchedConstraints::setup().
|
static |
Definition at line 388 of file btBatchedConstraints.cpp.
References BT_PROFILE, btAssert, i, kNoMerge, btBatchInfo::mergeIndex, and numConstraints.
Referenced by UpdateConstraintBatchIdsForMergesLoop::forLoop().
|
static |
Definition at line 424 of file btBatchedConstraints.cpp.
References BT_PROFILE, btParallelFor(), and numConstraints.
Referenced by setupSpatialGridBatchesMt().
|
static |
Definition at line 515 of file btBatchedConstraints.cpp.
References btGetTaskScheduler(), btMax(), btITaskScheduler::getNumThreads(), btBatchedConstraints::m_phaseGrainSize, btBatchedConstraints::m_phases, and btAlignedObjectArray< T >::resizeNoInitialize().
Referenced by writeOutBatches().
|
static |
Definition at line 530 of file btBatchedConstraints.cpp.
References batch, BatchCompare(), BT_PROFILE, btAssert, i, btBatchedConstraints::m_batches, btBatchedConstraints::m_constraintIndices, btBatchedConstraints::m_phaseOrder, btBatchedConstraints::m_phases, numConstraints, btAlignedObjectArray< T >::reserve(), btAlignedObjectArray< T >::resize(), btAlignedObjectArray< T >::resizeNoInitialize(), writeGrainSizes(), and writeOutConstraintIndicesMt().
Referenced by setupSpatialGridBatchesMt().
|
static |
Definition at line 439 of file btBatchedConstraints.cpp.
References BT_PROFILE, btBatchedConstraints::m_constraintIndices, and numConstraints.
Referenced by WriteOutConstraintIndicesLoop::forLoop().
|
static |
Definition at line 489 of file btBatchedConstraints.cpp.
References BT_PROFILE, btParallelFor(), btBatchedConstraints::m_constraintIndices, and numConstraints.
Referenced by writeOutBatches().
| const int kNoMerge = -1 |
Definition at line 27 of file btBatchedConstraints.cpp.
Referenced by btBatchInfo::btBatchInfo(), mergeSmallBatches(), and updateConstraintBatchIdsForMerges().