MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/PhysX / basisExtentV

Function basisExtentV

physx/source/geomutils/src/GuBounds.cpp:195–208  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

193}
194
195static PX_FORCE_INLINE Vec4V basisExtentV(const PxMat33Padded& basis, const PxVec3& extent, float offset, float inflation)
196{
197 // extended basis vectors
198 const Vec4V c0V = V4Scale(V4LoadU(&basis.column0.x), FLoad(extent.x));
199 const Vec4V c1V = V4Scale(V4LoadU(&basis.column1.x), FLoad(extent.y));
200 const Vec4V c2V = V4Scale(V4LoadU(&basis.column2.x), FLoad(extent.z));
201
202 // find combination of base vectors that produces max. distance for each component = sum of abs()
203 Vec4V extentsV = V4Add(V4Abs(c0V), V4Abs(c1V));
204 extentsV = V4Add(extentsV, V4Abs(c2V));
205 extentsV = V4Add(extentsV, V4Load(offset));
206 extentsV = V4Scale(extentsV, FLoad(inflation));
207 return extentsV;
208}
209
210void Gu::computeBounds(PxBounds3& bounds, const PxGeometry& geometry, const PxTransform& pose, float contactOffset, const CenterExtentsPadded* PX_RESTRICT localSpaceBounds, float inflation)
211{

Callers 2

computeBoundsMethod · 0.85
ShapeDataMethod · 0.85

Calls 6

V4ScaleFunction · 0.50
V4LoadUFunction · 0.50
FLoadFunction · 0.50
V4AddFunction · 0.50
V4AbsFunction · 0.50
V4LoadFunction · 0.50

Tested by

no test coverage detected