// // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // * Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above copyright // notice, this list of conditions and the following disclaimer in the // documentation and/or other materials provided with the distribution. // * Neither the name of NVIDIA CORPORATION nor the names of its // contributors may be used to endorse or promote products derived // from this software without specific prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS ``AS IS'' AND ANY // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY // OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // // Copyright (c) 2008-2019 NVIDIA Corporation. All rights reserved. // Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved. // Copyright (c) 2001-2004 NovodeX AG. All rights reserved. #ifndef PX_METADATAOBJECTS_H #define PX_METADATAOBJECTS_H #include "foundation/PxMemory.h" // include the base headers instead of the PxPhysicsAPI.h //Geometry Library #include "geometry/PxBoxGeometry.h" #include "geometry/PxCapsuleGeometry.h" #include "geometry/PxConvexMesh.h" #include "geometry/PxConvexMeshGeometry.h" #include "geometry/PxGeometry.h" #include "geometry/PxGeometryHelpers.h" #include "geometry/PxGeometryQuery.h" #include "geometry/PxHeightField.h" #include "geometry/PxHeightFieldDesc.h" #include "geometry/PxHeightFieldFlag.h" #include "geometry/PxHeightFieldGeometry.h" #include "geometry/PxHeightFieldSample.h" #include "geometry/PxMeshQuery.h" #include "geometry/PxMeshScale.h" #include "geometry/PxPlaneGeometry.h" #include "geometry/PxSimpleTriangleMesh.h" #include "geometry/PxSphereGeometry.h" #include "geometry/PxTriangle.h" #include "geometry/PxTriangleMesh.h" #include "geometry/PxTriangleMeshGeometry.h" // PhysX Core SDK #include "PxActor.h" #include "PxAggregate.h" #include "PxArticulation.h" #include "PxArticulationJoint.h" #include "PxArticulationReducedCoordinate.h" #include "PxArticulationJointReducedCoordinate.h" #include "PxArticulationLink.h" #include "PxBatchQuery.h" #include "PxBatchQueryDesc.h" #include "PxClient.h" #include "PxConstraint.h" #include "PxConstraintDesc.h" #include "PxContact.h" #include "PxContactModifyCallback.h" #include "PxDeletionListener.h" #include "PxFiltering.h" #include "PxForceMode.h" #include "PxLockedData.h" #include "PxMaterial.h" #include "PxPhysics.h" #include "PxPhysicsVersion.h" #include "PxPhysXConfig.h" #include "PxQueryFiltering.h" #include "PxQueryReport.h" #include "PxRigidActor.h" #include "PxRigidBody.h" #include "PxRigidDynamic.h" #include "PxRigidStatic.h" #include "PxScene.h" #include "PxSceneDesc.h" #include "PxSceneLock.h" #include "PxShape.h" #include "PxSimulationEventCallback.h" #include "PxSimulationStatistics.h" #include "PxVisualizationParameter.h" #include "PxPruningStructure.h" /** \addtogroup physics @{ */ namespace physx { class PxArticulationLink; class PxArticulationJoint; class PxArticulationJointReducedCoordinate; class PxArticulationJointBase; struct PxPropertyInfoName { enum Enum { Unnamed = 0, #include "PxAutoGeneratedMetaDataObjectNames.h" LastPxPropertyInfoName }; }; struct PxU32ToName { const char* mName; PxU32 mValue; }; struct PxPropertyInfoBase { const char* mName; PxU32 mKey; PxPropertyInfoBase( const char* n, PxU32 inKey ) : mName( n ) , mKey( inKey ) { } }; template struct PxPropertyInfoParameterizedBase : public PxPropertyInfoBase { PxPropertyInfoParameterizedBase( const char* inName ) : PxPropertyInfoBase( inName, TKey ) {} }; template struct PxReadOnlyPropertyInfo : public PxPropertyInfoParameterizedBase { typedef TPropertyType (*TGetterType)( const TObjType* ); TGetterType mGetter; PxReadOnlyPropertyInfo( const char* inName, TGetterType inGetter ) : PxPropertyInfoParameterizedBase( inName ) , mGetter( inGetter ) {} TPropertyType get( const TObjType* inObj ) const { return mGetter( inObj ); } }; template struct PxWriteOnlyPropertyInfo : public PxPropertyInfoParameterizedBase { typedef void(*TSetterType)( TObjType*, TPropertyType inArg ); TSetterType mSetter; PxWriteOnlyPropertyInfo( const char* inName, TSetterType inSetter ) : PxPropertyInfoParameterizedBase( inName ) , mSetter( inSetter ) {} void set( TObjType* inObj, TPropertyType inArg ) const { mSetter( inObj, inArg ); } }; //Define the property types on the auto-generated objects. template struct PxPropertyInfo : public PxReadOnlyPropertyInfo { typedef typename PxReadOnlyPropertyInfo::TGetterType TGetterType; typedef void(*TSetterType)( TObjType*, TSetPropType inArg ); TSetterType mSetter; PxPropertyInfo( const char* inName, TSetterType inSetter, TGetterType inGetter ) : PxReadOnlyPropertyInfo( inName, inGetter ) , mSetter( inSetter ) {} void set( TObjType* inObj, TSetPropType inArg ) const { mSetter( inObj, inArg ); } }; template struct PxRangePropertyInfo : public PxPropertyInfoParameterizedBase { typedef void (*TSetterType)( TObjType*,TPropertyType,TPropertyType); typedef void (*TGetterType)( const TObjType*,TPropertyType&,TPropertyType&); const char* mArg0Name; const char* mArg1Name; TSetterType mSetter; TGetterType mGetter; PxRangePropertyInfo( const char* name, const char* arg0Name, const char* arg1Name , TSetterType setter, TGetterType getter ) : PxPropertyInfoParameterizedBase( name ) , mArg0Name( arg0Name ) , mArg1Name( arg1Name ) , mSetter( setter ) , mGetter( getter ) { } void set( TObjType* inObj, TPropertyType arg0, TPropertyType arg1 ) const { mSetter( inObj, arg0, arg1 ); } void get( const TObjType* inObj, TPropertyType& arg0, TPropertyType& arg1 ) const { mGetter( inObj, arg0, arg1 ); } }; template struct PxIndexedPropertyInfo : public PxPropertyInfoParameterizedBase { typedef void (*TSetterType)( TObjType*, TIndexType, TPropertyType ); typedef TPropertyType (*TGetterType)( const TObjType* inObj, TIndexType ); TSetterType mSetter; TGetterType mGetter; PxIndexedPropertyInfo( const char* name, TSetterType setter, TGetterType getter ) : PxPropertyInfoParameterizedBase( name ) , mSetter( setter ) , mGetter( getter ) { } void set( TObjType* inObj, TIndexType inIndex, TPropertyType arg ) const { mSetter( inObj, inIndex, arg ); } TPropertyType get( const TObjType* inObj, TIndexType inIndex ) const { return mGetter( inObj, inIndex ); } }; template struct PxExtendedIndexedPropertyInfo : public PxPropertyInfoParameterizedBase { typedef PxU32 (*TNbObjectsMember)( const TObjType* ); typedef void (*TSetterType)( TObjType*, TIndexType, TPropertyType ); typedef TPropertyType (*TGetterType)( const TObjType* inObj, TIndexType ); TSetterType mSetter; TGetterType mGetter; PxU32 mCount; TNbObjectsMember mNbObjectsMember; PxExtendedIndexedPropertyInfo( const char* name, TGetterType getter, TNbObjectsMember inNb, TSetterType setter) : PxPropertyInfoParameterizedBase( name ) , mSetter( setter ) , mGetter( getter ) , mNbObjectsMember( inNb ) { } PxU32 size( const TObjType* inObj ) const { return mNbObjectsMember( inObj ); } void set( TObjType* inObj, TIndexType inIndex, TPropertyType arg ) const { mSetter( inObj, inIndex, arg ); } TPropertyType get( const TObjType* inObj, TIndexType inIndex ) const { return mGetter( inObj, inIndex ); } }; template struct PxDualIndexedPropertyInfo : public PxPropertyInfoParameterizedBase { typedef void (*TSetterType)( TObjType*, TIndex1Type, TIndex2Type, TPropertyType ); typedef TPropertyType (*TGetterType)( const TObjType* inObj, TIndex1Type, TIndex2Type ); TSetterType mSetter; TGetterType mGetter; PxDualIndexedPropertyInfo( const char* name, TSetterType setter, TGetterType getter ) : PxPropertyInfoParameterizedBase( name ) , mSetter( setter ) , mGetter( getter ) { } void set( TObjType* inObj, TIndex1Type inIdx1, TIndex2Type inIdx2, TPropertyType arg ) const { mSetter( inObj, inIdx1, inIdx2, arg ); } TPropertyType get( const TObjType* inObj, TIndex1Type inIdx1, TIndex2Type inIdx2 ) const { return mGetter( inObj, inIdx1, inIdx2 ); } }; template struct PxExtendedDualIndexedPropertyInfo : public PxPropertyInfoParameterizedBase { typedef void (*TSetterType)( TObjType*, TIndex1Type, TIndex2Type, TPropertyType ); typedef TPropertyType (*TGetterType)( const TObjType* inObj, TIndex1Type, TIndex2Type ); TSetterType mSetter; TGetterType mGetter; PxU32 mId0Count; PxU32 mId1Count; PxExtendedDualIndexedPropertyInfo( const char* name, TSetterType setter, TGetterType getter, PxU32 id0Count, PxU32 id1Count ) : PxPropertyInfoParameterizedBase( name ) , mSetter( setter ) , mGetter( getter ) , mId0Count( id0Count ) , mId1Count( id1Count ) { } void set( TObjType* inObj, TIndex1Type inIdx1, TIndex2Type inIdx2, TPropertyType arg ) const { mSetter( inObj, inIdx1, inIdx2, arg ); } TPropertyType get( const TObjType* inObj, TIndex1Type inIdx1, TIndex2Type inIdx2 ) const { return mGetter( inObj, inIdx1, inIdx2 ); } }; template struct PxBufferCollectionPropertyInfo : public PxPropertyInfoParameterizedBase { typedef PxU32 (*TNbObjectsMember)( const TObjType* ); typedef PxU32 (*TGetObjectsMember)( const TObjType*, TCollectionType*, PxU32 ); typedef void (*TSetObjectsMember)( TObjType*, TCollectionType*, PxU32 ); TGetObjectsMember mGetObjectsMember; TNbObjectsMember mNbObjectsMember; TSetObjectsMember mSetObjectsMember; PxBufferCollectionPropertyInfo( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb, TSetObjectsMember inSet ) : PxPropertyInfoParameterizedBase( inName ) , mGetObjectsMember( inGetter ) , mNbObjectsMember( inNb ) , mSetObjectsMember( inSet ) { } PxU32 size( const TObjType* inObj ) const { return mNbObjectsMember( inObj ); } PxU32 get( const TObjType* inObj, TCollectionType* inBuffer, PxU32 inNumItems ) const { return mGetObjectsMember( inObj, inBuffer, inNumItems ); } void set( TObjType* inObj, TCollectionType* inBuffer, PxU32 inNumItems ) const { mSetObjectsMember( inObj, inBuffer, inNumItems); } }; template struct PxFixedSizeLookupTablePropertyInfo : public PxPropertyInfoParameterizedBase { typedef PxU32 (*TNbObjectsMember)( const TObjType* ); typedef PxReal (*TGetXMember)( const TObjType*, PxU32 ); typedef PxReal (*TGetYMember)( const TObjType*, PxU32 ); typedef void (*TAddPairMember)( TObjType*, PxReal, PxReal ); typedef void (*TClearMember)( TObjType* ); TGetXMember mGetXMember; TGetYMember mGetYMember; TNbObjectsMember mNbObjectsMember; TAddPairMember mAddPairMember; TClearMember mClearMember; PxFixedSizeLookupTablePropertyInfo( const char* inName, TGetXMember inGetterX, TGetYMember inGetterY, TNbObjectsMember inNb, TAddPairMember inAddPair, TClearMember inClear ) : PxPropertyInfoParameterizedBase( inName ) , mGetXMember( inGetterX ) , mGetYMember( inGetterY ) , mNbObjectsMember( inNb ) , mAddPairMember( inAddPair ) , mClearMember( inClear ) { } PxU32 size( const TObjType* inObj ) const { return mNbObjectsMember( inObj ); } PxReal getX( const TObjType* inObj, const PxU32 index ) const { return mGetXMember( inObj, index ); } PxReal getY( const TObjType* inObj, const PxU32 index ) const { return mGetYMember( inObj, index ); } void addPair( TObjType* inObj, const PxReal x, const PxReal y ) { mAddPairMember( inObj, x, y ); } void clear( TObjType* inObj ) { mClearMember( inObj ); } }; template struct PxReadOnlyCollectionPropertyInfo : public PxPropertyInfoParameterizedBase { typedef PxU32 (*TNbObjectsMember)( const TObjType* ); typedef PxU32 (*TGetObjectsMember)( const TObjType*, TCollectionType*, PxU32 ); TGetObjectsMember mGetObjectsMember; TNbObjectsMember mNbObjectsMember; PxReadOnlyCollectionPropertyInfo( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb ) : PxPropertyInfoParameterizedBase( inName ) , mGetObjectsMember( inGetter ) , mNbObjectsMember( inNb ) { } PxU32 size( const TObjType* inObj ) const { return mNbObjectsMember( inObj ); } PxU32 get( const TObjType* inObj, TCollectionType* inBuffer, PxU32 inBufSize ) const { return mGetObjectsMember( inObj, inBuffer, inBufSize); } }; template struct PxReadOnlyFilteredCollectionPropertyInfo : public PxPropertyInfoParameterizedBase { typedef PxU32 (*TNbObjectsMember)( const TObjType*, TFilterType ); typedef PxU32 (*TGetObjectsMember)( const TObjType*, TFilterType, TCollectionType*, PxU32 ); TGetObjectsMember mGetObjectsMember; TNbObjectsMember mNbObjectsMember; PxReadOnlyFilteredCollectionPropertyInfo( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb ) : PxPropertyInfoParameterizedBase( inName ) , mGetObjectsMember( inGetter ) , mNbObjectsMember( inNb ) { } PxU32 size( const TObjType* inObj, TFilterType inFilter ) const { return mNbObjectsMember( inObj, inFilter ); } PxU32 get( const TObjType* inObj, TFilterType inFilter, TCollectionType* inBuffer, PxU32 inBufSize ) const { return mGetObjectsMember( inObj, inFilter, inBuffer, inBufSize); } }; template struct PxFactoryCollectionPropertyInfo : public PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType > { typedef typename PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType >::TGetObjectsMember TGetObjectsMember; typedef typename PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType >::TNbObjectsMember TNbObjectsMember; typedef TCollectionType (*TCreateMember)( TObjType*, TCreateArg ); TCreateMember mCreateMember; PxFactoryCollectionPropertyInfo( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb, TCreateMember inMember ) : PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType >( inName, inGetter, inNb ) , mCreateMember( inMember ) { } TCollectionType create( TObjType* inObj, TCreateArg inArg ) const { return mCreateMember( inObj, inArg ); } }; template struct PxCollectionPropertyInfo : public PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType > { typedef typename PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType >::TGetObjectsMember TGetObjectsMember; typedef typename PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType >::TNbObjectsMember TNbObjectsMember; typedef void (*TAddMember)(TObjType*, TCollectionType&); typedef void (*TRemoveMember)(TObjType*, TCollectionType&); TAddMember mAddMember; TRemoveMember mRemoveMember; PxCollectionPropertyInfo( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb, TAddMember inMember, TRemoveMember inRemoveMember ) : PxReadOnlyCollectionPropertyInfo< TKey, TObjType, TCollectionType >( inName, inGetter, inNb ) , mAddMember( inMember ) , mRemoveMember( inRemoveMember ) { } void add( TObjType* inObj, TCollectionType& inArg ) const { mAddMember(inObj, inArg ); } void remove( TObjType* inObj, TCollectionType& inArg ) const { mRemoveMember( inObj, inArg ); } }; template struct PxFilteredCollectionPropertyInfo : public PxReadOnlyFilteredCollectionPropertyInfo { typedef typename PxReadOnlyFilteredCollectionPropertyInfo< TKey, TObjType, TCollectionType, TFilterType >::TGetObjectsMember TGetObjectsMember; typedef typename PxReadOnlyFilteredCollectionPropertyInfo< TKey, TObjType, TCollectionType, TFilterType >::TNbObjectsMember TNbObjectsMember; typedef void (*TAddMember)(TObjType*, TCollectionType&); typedef void (*TRemoveMember)(TObjType*, TCollectionType&); TAddMember mAddMember; TRemoveMember mRemoveMember; PxFilteredCollectionPropertyInfo( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb, TAddMember inMember, TRemoveMember inRemoveMember ) : PxReadOnlyFilteredCollectionPropertyInfo( inName, inGetter, inNb ) , mAddMember( inMember ) , mRemoveMember( inRemoveMember ) { } void add( TObjType* inObj, TCollectionType& inArg ) const { mAddMember(inObj, inArg ); } void remove( TObjType* inObj, TCollectionType& inArg ) const { mRemoveMember( inObj, inArg ); } }; //create a default info class for when we can't match //the type correctly. struct PxUnknownClassInfo { static const char* getClassName() { return "__unknown_class"; } template TReturnType visitType( TOperator ) { return TReturnType(); } template void visitBases( TOperator ) { } template PxU32 visitBaseProperties( TOperator, PxU32 inStartIndex = 0 ) const { return inStartIndex; } template PxU32 visitInstanceProperties( TOperator, PxU32 inStartIndex = 0 ) const { return inStartIndex; } }; template struct PxClassInfoTraits { PxUnknownClassInfo Info; static bool getInfo() { return false;} }; //move the bool typedef to the global namespace. typedef bool _Bool; template struct PxPropertyToValueStructMemberMap { bool Offset; }; #define DEFINE_PROPERTY_TO_VALUE_STRUCT_MAP( type, prop, valueStruct ) \ template<> struct PxPropertyToValueStructMemberMap< PxPropertyInfoName::type##_##prop > \ { \ PxU32 Offset; \ PxPropertyToValueStructMemberMap< PxPropertyInfoName::type##_##prop >() : Offset( PX_OFFSET_OF_RT( valueStruct, prop ) ) {} \ template void visitProp( TOperator inOperator, valueStruct& inStruct ) { inOperator( inStruct.prop ); } \ }; struct PxShapeGeometryPropertyHelper { PX_PHYSX_CORE_API PxGeometryType::Enum getGeometryType(const PxShape* inShape) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxBoxGeometry& geometry) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxSphereGeometry& geometry) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxCapsuleGeometry& geometry) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxPlaneGeometry& geometry) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxConvexMeshGeometry& geometry) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxTriangleMeshGeometry& geometry) const; PX_PHYSX_CORE_API bool getGeometry(const PxShape* inShape, PxHeightFieldGeometry& geometry) const; }; struct PxShapeGeometryProperty : public PxWriteOnlyPropertyInfo< PxPropertyInfoName::PxShape_Geometry, PxShape, const PxGeometry & > , public PxShapeGeometryPropertyHelper { typedef PxWriteOnlyPropertyInfo< PxPropertyInfoName::PxShape_Geometry, PxShape, const PxGeometry & >::TSetterType TSetterType; typedef PxGeometryHolder (*TGetterType)( const PxShape* inObj ); PxShapeGeometryProperty( const char* inName, TSetterType inSetter, TGetterType ) : PxWriteOnlyPropertyInfo< PxPropertyInfoName::PxShape_Geometry, PxShape, const PxGeometry & >( inName, inSetter ) { } }; struct PxShapeMaterialsPropertyHelper { PX_PHYSX_CORE_API void setMaterials(PxShape* inShape, PxMaterial*const* materials, PxU16 materialCount) const; }; struct PxShapeMaterialsProperty : public PxReadOnlyCollectionPropertyInfo , public PxShapeMaterialsPropertyHelper { typedef PxReadOnlyCollectionPropertyInfo< PxPropertyInfoName::PxShape_Materials, PxShape, PxMaterial* >::TGetObjectsMember TGetObjectsMember; typedef PxReadOnlyCollectionPropertyInfo< PxPropertyInfoName::PxShape_Materials, PxShape, PxMaterial* >::TNbObjectsMember TNbObjectsMember; PxShapeMaterialsProperty( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb ) : PxReadOnlyCollectionPropertyInfo( inName, inGetter, inNb ) { } }; typedef PxPropertyInfo PxRigidActorGlobalPosePropertyInfo; struct PxRigidActorShapeCollectionHelper { PX_PHYSX_CORE_API PxShape* createShape(PxRigidActor* inActor, const PxGeometry& geometry, PxMaterial& material, PxShapeFlags shapeFlags = PxShapeFlag::eVISUALIZATION | PxShapeFlag::eSCENE_QUERY_SHAPE | PxShapeFlag::eSIMULATION_SHAPE) const; PX_PHYSX_CORE_API PxShape* createShape(PxRigidActor* inActor, const PxGeometry& geometry, PxMaterial *const* materials, PxU16 materialCount, PxShapeFlags shapeFlags = PxShapeFlag::eVISUALIZATION | PxShapeFlag::eSCENE_QUERY_SHAPE | PxShapeFlag::eSIMULATION_SHAPE) const; }; struct PxRigidActorShapeCollection : public PxReadOnlyCollectionPropertyInfo , public PxRigidActorShapeCollectionHelper { typedef PxReadOnlyCollectionPropertyInfo< PxPropertyInfoName::PxRigidActor_Shapes, PxRigidActor, PxShape* >::TGetObjectsMember TGetObjectsMember; typedef PxReadOnlyCollectionPropertyInfo< PxPropertyInfoName::PxRigidActor_Shapes, PxRigidActor, PxShape* >::TNbObjectsMember TNbObjectsMember; PxRigidActorShapeCollection( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb ) : PxReadOnlyCollectionPropertyInfo( inName, inGetter, inNb ) { } }; struct PxArticulationLinkCollectionPropHelper { PX_PHYSX_CORE_API PxArticulationLink* createLink(PxArticulation* inArticulation, PxArticulationLink* parent, const PxTransform& pose) const; }; struct PxArticulationReducedCoordinateLinkCollectionPropHelper { PX_PHYSX_CORE_API PxArticulationLink* createLink(PxArticulationReducedCoordinate* inArticulation, PxArticulationLink* parent, const PxTransform& pose) const; }; struct PxArticulationLinkCollectionProp : public PxReadOnlyCollectionPropertyInfo , public PxArticulationLinkCollectionPropHelper { PxArticulationLinkCollectionProp( const char* inName, TGetObjectsMember inGetter, TNbObjectsMember inNb ) : PxReadOnlyCollectionPropertyInfo( inName, inGetter, inNb ) { } }; template struct PxEnumTraits { PxEnumTraits() : NameConversion( false ) {} bool NameConversion; }; struct NbShapesProperty : public PxIndexedPropertyInfo { PX_PHYSX_CORE_API NbShapesProperty(); }; struct NbDiscreteContactPairsProperty : public PxDualIndexedPropertyInfo { PX_PHYSX_CORE_API NbDiscreteContactPairsProperty(); }; struct NbModifiedContactPairsProperty : public PxDualIndexedPropertyInfo { PX_PHYSX_CORE_API NbModifiedContactPairsProperty(); }; struct NbCCDPairsProperty : public PxDualIndexedPropertyInfo { PX_PHYSX_CORE_API NbCCDPairsProperty(); }; struct NbTriggerPairsProperty : public PxDualIndexedPropertyInfo { PX_PHYSX_CORE_API NbTriggerPairsProperty(); }; struct SimulationStatisticsProperty : public PxReadOnlyPropertyInfo { PX_PHYSX_CORE_API SimulationStatisticsProperty(); }; struct PxMetaDataPlane { PxVec3 normal; PxReal distance; PxMetaDataPlane( PxVec3 n = PxVec3( 0, 0, 0 ), PxReal d = 0 ) : normal( n ) , distance( d ) { } }; #include "PxAutoGeneratedMetaDataObjects.h" #undef DEFINE_PROPERTY_TO_VALUE_STRUCT_MAP static PxU32ToName g_physx__PxQueryFlag__EnumConversion[] = { { "eSTATIC", static_cast( PxQueryFlag::eSTATIC ) }, { "eDYNAMIC", static_cast( PxQueryFlag::eDYNAMIC ) }, { "ePREFILTER", static_cast( PxQueryFlag::ePREFILTER ) }, { "ePOSTFILTER", static_cast( PxQueryFlag::ePOSTFILTER ) }, { NULL, 0 } }; template<> struct PxEnumTraits { PxEnumTraits() : NameConversion( g_physx__PxQueryFlag__EnumConversion ) {} const PxU32ToName* NameConversion; }; template inline PxU32 visitAllProperties( TOperator inOperator ) { PxU32 thePropCount = PxClassInfoTraits().Info.visitBaseProperties( inOperator ); return PxClassInfoTraits().Info.visitInstanceProperties( inOperator, thePropCount ); } template inline void visitInstanceProperties( TOperator inOperator ) { PxClassInfoTraits().Info.visitInstanceProperties( inOperator, 0 ); } } /** @} */ #endif