本文整理汇总了C++中PfxShape::getOffsetOrientation方法的典型用法代码示例。如果您正苦于以下问题:C++ PfxShape::getOffsetOrientation方法的具体用法?C++ PfxShape::getOffsetOrientation怎么用?C++ PfxShape::getOffsetOrientation使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PfxShape
的用法示例。
在下文中一共展示了PfxShape::getOffsetOrientation方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: pfxGetShapeAabbLargeTriMesh
void pfxGetShapeAabbLargeTriMesh(const PfxShape &shape,PfxVector3 &aabbMin,PfxVector3 &aabbMax)
{
const PfxLargeTriMesh *largemesh = shape.getLargeTriMesh();
PfxVector3 half = absPerElem(PfxMatrix3(shape.getOffsetOrientation())) * largemesh->m_half;
aabbMin = shape.getOffsetPosition() - half;
aabbMax = shape.getOffsetPosition() + half;
}
示例2: pfxGetShapeAabbConvexMesh
void pfxGetShapeAabbConvexMesh(const PfxShape &shape,PfxVector3 &aabbMin,PfxVector3 &aabbMax)
{
const PfxConvexMesh *convex = shape.getConvexMesh();
PfxVector3 half = absPerElem(PfxMatrix3(shape.getOffsetOrientation())) * convex->m_half;
aabbMin = shape.getOffsetPosition() - half;
aabbMax = shape.getOffsetPosition() + half;
}
示例3: pfxGetShapeAabbCylinder
void pfxGetShapeAabbCylinder(const PfxShape &shape,PfxVector3 &aabbMin,PfxVector3 &aabbMax)
{
PfxVector3 capSize = absPerElem(PfxMatrix3(shape.getOffsetOrientation())) *
PfxVector3(shape.getCylinder().m_halfLen,shape.getCylinder().m_radius,shape.getCylinder().m_radius);
aabbMin = shape.getOffsetPosition() - capSize;
aabbMax = shape.getOffsetPosition() + capSize;
}
示例4: pfxGetShapeAabbCapsule
void pfxGetShapeAabbCapsule(const PfxShape &shape,PfxVector3 &aabbMin,PfxVector3 &aabbMax)
{
PfxVector3 dir = rotate(shape.getOffsetOrientation(),PfxVector3(1.0f,0.0f,0.0f));
PfxVector3 capSize = absPerElem(dir) * shape.getCapsule().m_halfLen +
PfxVector3(shape.getCapsule().m_radius);
aabbMin = shape.getOffsetPosition() - capSize;
aabbMax = shape.getOffsetPosition() + capSize;
}
示例5: pfxGetShapeAabbBox
void pfxGetShapeAabbBox(const PfxShape &shape,PfxVector3 &aabbMin,PfxVector3 &aabbMax)
{
PfxVector3 boxSize = absPerElem(PfxMatrix3(shape.getOffsetOrientation())) * shape.getBox().m_half;
aabbMin = shape.getOffsetPosition() - boxSize;
aabbMax = shape.getOffsetPosition() + boxSize;
}