| 1 | /* |
| 2 | * Copyright (c) 2008-2015, NVIDIA CORPORATION. All rights reserved. |
| 3 | * |
| 4 | * NVIDIA CORPORATION and its licensors retain all intellectual property |
| 5 | * and proprietary rights in and to this software, related documentation |
| 6 | * and any modifications thereto. Any use, reproduction, disclosure or |
| 7 | * distribution of this software and related documentation without an express |
| 8 | * license agreement from NVIDIA CORPORATION is strictly prohibited. |
| 9 | */ |
| 10 | // Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved. |
| 11 | // Copyright (c) 2001-2004 NovodeX AG. All rights reserved. |
| 12 | |
| 13 | |
| 14 | #ifndef PX_PHYSICS_EXTENSIONS_CLOTH_EDGE_QUADIFIER_H |
| 15 | #define PX_PHYSICS_EXTENSIONS_CLOTH_EDGE_QUADIFIER_H |
| 16 | |
| 17 | #include "common/PxPhysXCommonConfig.h" |
| 18 | #include "PxClothMeshDesc.h" |
| 19 | |
| 20 | #ifndef PX_DOXYGEN |
| 21 | namespace physx |
| 22 | { |
| 23 | #endif |
| 24 | |
| 25 | struct PxClothMeshQuadifierImpl; |
| 26 | |
| 27 | class PxClothMeshQuadifier |
| 28 | { |
| 29 | public: |
| 30 | /** |
| 31 | \brief Convert triangles of PxClothMeshDesc to quads. |
| 32 | \details In PxCloth, quad dominant mesh representations are preferable to pre-triangulated versions. |
| 33 | In cases where the mesh has been already triangulated, this class provides a meachanism to |
| 34 | convert (quadify) some triangles back to quad representations. |
| 35 | \see PxClothFabricCooker |
| 36 | \param desc The cloth mesh descriptor prepared for cooking |
| 37 | */ |
| 38 | PxClothMeshQuadifier(const PxClothMeshDesc &desc); |
| 39 | ~PxClothMeshQuadifier(); |
| 40 | |
| 41 | /** |
| 42 | \brief Returns a mesh descriptor with some triangle pairs converted to quads. |
| 43 | \note The returned descriptor is valid only within the lifespan of PxClothMeshQuadifier class. |
| 44 | */ |
| 45 | PxClothMeshDesc getDescriptor() const; |
| 46 | |
| 47 | private: |
| 48 | PxClothMeshQuadifierImpl* mImpl; |
| 49 | |
| 50 | }; |
| 51 | |
| 52 | #ifndef PX_DOXYGEN |
| 53 | } // namespace physx |
| 54 | #endif |
| 55 | |
| 56 | #endif // PX_PHYSICS_EXTENSIONS_CLOTH_EDGE_QUADIFIER_H |
| 57 | |