PxParticleCreationData.h
Go to the documentation of this file.
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_PARTICLESYSTEM_NXPARTICLECREATIONDATA
15 #define PX_PARTICLESYSTEM_NXPARTICLECREATIONDATA
16 
20 #include "PxPhysXConfig.h"
21 #include "foundation/PxVec3.h"
23 
24 #ifndef PX_DOXYGEN
25 namespace physx
26 {
27 #endif
28 
38 {
39 public:
40 
45 
52 
59 
66 
75 
87 
91  PX_INLINE void setToDefault();
92 
96  PX_INLINE bool isValid() const;
97 
102 };
103 
105 {
106  indexBuffer = PxStrideIterator<const PxU32>();
107  positionBuffer = PxStrideIterator<const PxVec3>();
108  velocityBuffer = PxStrideIterator<const PxVec3>();
109  restOffsetBuffer = PxStrideIterator<const PxF32>();
110  flagBuffer = PxStrideIterator<const PxU32>();
111 }
112 
114 {
115  *this = PxParticleCreationData();
116 }
117 
119 {
120  if (numParticles > 0 && !(indexBuffer.ptr() && positionBuffer.ptr())) return false;
121  return true;
122 }
123 
124 #ifndef PX_DOXYGEN
125 } // namespace physx
126 #endif
127 
129 #endif


Copyright © 2008-2015 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved. www.nvidia.com