1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
|
<html>
<head>
<title>NVIDIA(R) PhysX(R) SDK 3.4 API Reference: PxContactModifyCallback.h Source File</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<LINK HREF="NVIDIA.css" REL="stylesheet" TYPE="text/css">
</head>
<body bgcolor="#FFFFFF">
<div id="header">
<hr class="first">
<img alt="" src="images/PhysXlogo.png" align="middle"> <br>
<center>
<a class="qindex" href="main.html">Main Page</a>
<a class="qindex" href="hierarchy.html">Class Hierarchy</a>
<a class="qindex" href="annotated.html">Compound List</a>
<a class="qindex" href="functions.html">Compound Members</a>
</center>
<hr class="second">
</div>
<!-- Generated by Doxygen 1.5.8 -->
<h1>PxContactModifyCallback.h</h1><a href="PxContactModifyCallback_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">// This code contains NVIDIA Confidential Information and is disclosed to you</span>
<a name="l00002"></a>00002 <span class="comment">// under a form of NVIDIA software license agreement provided separately to you.</span>
<a name="l00003"></a>00003 <span class="comment">//</span>
<a name="l00004"></a>00004 <span class="comment">// Notice</span>
<a name="l00005"></a>00005 <span class="comment">// NVIDIA Corporation and its licensors retain all intellectual property and</span>
<a name="l00006"></a>00006 <span class="comment">// proprietary rights in and to this software and related documentation and</span>
<a name="l00007"></a>00007 <span class="comment">// any modifications thereto. Any use, reproduction, disclosure, or</span>
<a name="l00008"></a>00008 <span class="comment">// distribution of this software and related documentation without an express</span>
<a name="l00009"></a>00009 <span class="comment">// license agreement from NVIDIA Corporation is strictly prohibited.</span>
<a name="l00010"></a>00010 <span class="comment">//</span>
<a name="l00011"></a>00011 <span class="comment">// ALL NVIDIA DESIGN SPECIFICATIONS, CODE ARE PROVIDED "AS IS.". NVIDIA MAKES</span>
<a name="l00012"></a>00012 <span class="comment">// NO WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO</span>
<a name="l00013"></a>00013 <span class="comment">// THE MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF NONINFRINGEMENT,</span>
<a name="l00014"></a>00014 <span class="comment">// MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE.</span>
<a name="l00015"></a>00015 <span class="comment">//</span>
<a name="l00016"></a>00016 <span class="comment">// Information and code furnished is believed to be accurate and reliable.</span>
<a name="l00017"></a>00017 <span class="comment">// However, NVIDIA Corporation assumes no responsibility for the consequences of use of such</span>
<a name="l00018"></a>00018 <span class="comment">// information or for any infringement of patents or other rights of third parties that may</span>
<a name="l00019"></a>00019 <span class="comment">// result from its use. No license is granted by implication or otherwise under any patent</span>
<a name="l00020"></a>00020 <span class="comment">// or patent rights of NVIDIA Corporation. Details are subject to change without notice.</span>
<a name="l00021"></a>00021 <span class="comment">// This code supersedes and replaces all information previously supplied.</span>
<a name="l00022"></a>00022 <span class="comment">// NVIDIA Corporation products are not authorized for use as critical</span>
<a name="l00023"></a>00023 <span class="comment">// components in life support devices or systems without express written approval of</span>
<a name="l00024"></a>00024 <span class="comment">// NVIDIA Corporation.</span>
<a name="l00025"></a>00025 <span class="comment">//</span>
<a name="l00026"></a>00026 <span class="comment">// Copyright (c) 2008-2017 NVIDIA Corporation. All rights reserved.</span>
<a name="l00027"></a>00027 <span class="comment">// Copyright (c) 2004-2008 AGEIA Technologies, Inc. All rights reserved.</span>
<a name="l00028"></a>00028 <span class="comment">// Copyright (c) 2001-2004 NovodeX AG. All rights reserved. </span>
<a name="l00029"></a>00029
<a name="l00030"></a>00030
<a name="l00031"></a>00031 <span class="preprocessor">#ifndef PX_CONTACT_MODIFY_CALLBACK</span>
<a name="l00032"></a>00032 <span class="preprocessor"></span><span class="preprocessor">#define PX_CONTACT_MODIFY_CALLBACK</span>
<a name="l00033"></a>00033 <span class="preprocessor"></span>
<a name="l00037"></a>00037 <span class="preprocessor">#include "<a class="code" href="PxPhysXConfig_8h.html">PxPhysXConfig.h</a>"</span>
<a name="l00038"></a>00038 <span class="preprocessor">#include "<a class="code" href="PxShape_8h.html">PxShape.h</a>"</span>
<a name="l00039"></a>00039 <span class="preprocessor">#include "<a class="code" href="PxContact_8h.html">PxContact.h</a>"</span>
<a name="l00040"></a>00040 <span class="preprocessor">#include "<a class="code" href="PxTransform_8h.html">foundation/PxTransform.h</a>"</span>
<a name="l00041"></a>00041
<a name="l00042"></a>00042 <span class="preprocessor">#if !PX_DOXYGEN</span>
<a name="l00043"></a>00043 <span class="preprocessor"></span><span class="keyword">namespace </span>physx
<a name="l00044"></a>00044 {
<a name="l00045"></a>00045 <span class="preprocessor">#endif</span>
<a name="l00046"></a>00046 <span class="preprocessor"></span>
<a name="l00047"></a>00047 <span class="keyword">class </span><a class="code" href="classPxShape.html" title="Abstract class for collision shapes.">PxShape</a>;
<a name="l00048"></a>00048
<a name="l00061"></a><a class="code" href="classPxContactSet.html">00061</a> <span class="keyword">class </span><a class="code" href="classPxContactSet.html" title="An array of contact points, as passed to contact modification.">PxContactSet</a>
<a name="l00062"></a>00062 {
<a name="l00063"></a>00063 <span class="keyword">public</span>:
<a name="l00069"></a><a class="code" href="classPxContactSet.html#bf3a8b911e7d304ce1008b23bb575361">00069</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keyword">const</span> <a class="code" href="classPxVec3.html" title="3 Element vector class.">PxVec3</a>& <a class="code" href="classPxContactSet.html#bf3a8b911e7d304ce1008b23bb575361" title="Get the position of a specific contact point in the set.">getPoint</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mContacts[i].contact; }
<a name="l00070"></a>00070
<a name="l00076"></a><a class="code" href="classPxContactSet.html#21cfe31aa14065c8b3ee6390c312e178">00076</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> <a class="code" href="classPxContactSet.html#21cfe31aa14065c8b3ee6390c312e178" title="Alter the position of a specific contact point in the set.">setPoint</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i, <span class="keyword">const</span> <a class="code" href="classPxVec3.html" title="3 Element vector class.">PxVec3</a>& p) { mContacts[i].contact = p; }
<a name="l00077"></a>00077
<a name="l00083"></a><a class="code" href="classPxContactSet.html#225b2714ca66ddb6cdf6c8a00664464e">00083</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keyword">const</span> <a class="code" href="classPxVec3.html" title="3 Element vector class.">PxVec3</a>& <a class="code" href="classPxContactSet.html#225b2714ca66ddb6cdf6c8a00664464e" title="Get the contact normal of a specific contact point in the set.">getNormal</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mContacts[i].normal; }
<a name="l00084"></a>00084
<a name="l00092"></a><a class="code" href="classPxContactSet.html#fdc45b285e1aaedd29690571b2098daa">00092</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setNormal(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i, <span class="keyword">const</span> <a class="code" href="classPxVec3.html" title="3 Element vector class.">PxVec3</a>& n)
<a name="l00093"></a>00093 {
<a name="l00094"></a>00094 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00095"></a>00095 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb9e58c6eb59a2e441c78dbbdc831d375f4" title="This is required if the application modified either the contact normal or the material...">PxContactPatch::eREGENERATE_PATCHES</a>;
<a name="l00096"></a>00096 mContacts[i].normal = n;
<a name="l00097"></a>00097 }
<a name="l00098"></a>00098
<a name="l00104"></a><a class="code" href="classPxContactSet.html#08bf7523401a88b6481ae49bedc858f3">00104</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> <a class="code" href="classPxContactSet.html#08bf7523401a88b6481ae49bedc858f3" title="Get the separation of a specific contact point in the set.">getSeparation</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mContacts[i].separation; }
<a name="l00105"></a>00105
<a name="l00111"></a><a class="code" href="classPxContactSet.html#dd1b219393a21fdbb6e6db51400aa900">00111</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> <a class="code" href="classPxContactSet.html#dd1b219393a21fdbb6e6db51400aa900" title="Alter the separation of a specific contact point in the set.">setSeparation</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i, <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> s) { mContacts[i].separation = s; }
<a name="l00112"></a>00112
<a name="l00119"></a><a class="code" href="classPxContactSet.html#25ab720b769e29f0a40aeb6bae693591">00119</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keyword">const</span> <a class="code" href="classPxVec3.html" title="3 Element vector class.">PxVec3</a>& <a class="code" href="classPxContactSet.html#25ab720b769e29f0a40aeb6bae693591" title="Get the target velocity of a specific contact point in the set.">getTargetVelocity</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mContacts[i].targetVelocity; }
<a name="l00120"></a>00120
<a name="l00126"></a><a class="code" href="classPxContactSet.html#2e374d99ff72fcf410a070ee3bf17abb">00126</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setTargetVelocity(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i, <span class="keyword">const</span> <a class="code" href="classPxVec3.html" title="3 Element vector class.">PxVec3</a>& v)
<a name="l00127"></a>00127 {
<a name="l00128"></a>00128 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00129"></a>00129 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb9caf67d93398b35860d340dd017b13d43" title="Indicates this contact stream has target velocities set.">PxContactPatch::eHAS_TARGET_VELOCITY</a>;
<a name="l00130"></a>00130 mContacts[i].targetVelocity = v;
<a name="l00131"></a>00131 }
<a name="l00132"></a>00132
<a name="l00138"></a><a class="code" href="classPxContactSet.html#02f160a1a9135d6d7f1e5f77557ce63e">00138</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> <a class="code" href="classPxContactSet.html#02f160a1a9135d6d7f1e5f77557ce63e" title="Get the face index with respect to the first shape of the pair for a specific contact...">getInternalFaceIndex0</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i) { <a class="code" href="group__foundation.html#g3b618390d8743c532c4131cb931df43a">PX_UNUSED</a>(i); <span class="keywordflow">return</span> <a class="code" href="PxContact_8h.html#d7d63e592ac0d23d42e12e10572039fe">PXC_CONTACT_NO_FACE_INDEX</a>; }
<a name="l00139"></a>00139
<a name="l00145"></a><a class="code" href="classPxContactSet.html#6535e80819a6d2a5bbe38db6aa86684e">00145</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> <a class="code" href="classPxContactSet.html#6535e80819a6d2a5bbe38db6aa86684e" title="Get the face index with respect to the second shape of the pair for a specific contact...">getInternalFaceIndex1</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i) { <a class="code" href="group__foundation.html#g3b618390d8743c532c4131cb931df43a">PX_UNUSED</a>(i); <span class="keywordflow">return</span> <a class="code" href="PxContact_8h.html#d7d63e592ac0d23d42e12e10572039fe">PXC_CONTACT_NO_FACE_INDEX</a>; }
<a name="l00146"></a>00146
<a name="l00152"></a><a class="code" href="classPxContactSet.html#cfe031fe04223af2e28b026d125a6d41">00152</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> <a class="code" href="classPxContactSet.html#cfe031fe04223af2e28b026d125a6d41" title="Get the maximum impulse for a specific contact point in the set.">getMaxImpulse</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mContacts[i].maxImpulse; }
<a name="l00153"></a>00153
<a name="l00161"></a><a class="code" href="classPxContactSet.html#145d98e983e46057f0fa57903f671c06">00161</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setMaxImpulse(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i, <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> s)
<a name="l00162"></a>00162 {
<a name="l00163"></a>00163 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00164"></a>00164 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb99e30c7fa533ce8776828ca9908126991" title="Indicates this contact stream has max impulses set.">PxContactPatch::eHAS_MAX_IMPULSE</a>;
<a name="l00165"></a>00165 mContacts[i].maxImpulse = s;
<a name="l00166"></a>00166 }
<a name="l00167"></a>00167
<a name="l00173"></a><a class="code" href="classPxContactSet.html#930b0b6a5450e9b2e83634d6803f4045">00173</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> <a class="code" href="classPxContactSet.html#930b0b6a5450e9b2e83634d6803f4045" title="Ignore the contact point.">ignore</a>(<a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> i) { mContacts[i].maxImpulse = 0.f; }
<a name="l00174"></a>00174
<a name="l00178"></a><a class="code" href="classPxContactSet.html#63434463f6bea994645e3dcbdc2cf2d0">00178</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> <a class="code" href="classPxContactSet.html#63434463f6bea994645e3dcbdc2cf2d0" title="The number of contact points in the set.">size</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> mCount; }
<a name="l00179"></a>00179
<a name="l00186"></a><a class="code" href="classPxContactSet.html#8179bfc84e3433909eb82553ddd9afeb">00186</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> getInvMassScale0()<span class="keyword"> const </span>
<a name="l00187"></a>00187 <span class="keyword"> </span>{
<a name="l00188"></a>00188 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00189"></a>00189 <span class="keywordflow">return</span> patch->mMassModification.mInvMassScale0;
<a name="l00190"></a>00190 }
<a name="l00191"></a>00191
<a name="l00198"></a><a class="code" href="classPxContactSet.html#23297c2c731c90d482a6553140b3afb6">00198</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> getInvMassScale1()<span class="keyword"> const </span>
<a name="l00199"></a>00199 <span class="keyword"> </span>{
<a name="l00200"></a>00200 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00201"></a>00201 <span class="keywordflow">return</span> patch->mMassModification.mInvMassScale1;
<a name="l00202"></a>00202 }
<a name="l00203"></a>00203
<a name="l00210"></a><a class="code" href="classPxContactSet.html#107184e5d6bbd33e445ca52de23c4016">00210</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> getInvInertiaScale0()<span class="keyword"> const </span>
<a name="l00211"></a>00211 <span class="keyword"> </span>{
<a name="l00212"></a>00212 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00213"></a>00213 <span class="keywordflow">return</span> patch->mMassModification.mInvInertiaScale0;
<a name="l00214"></a>00214 }
<a name="l00215"></a>00215
<a name="l00222"></a><a class="code" href="classPxContactSet.html#4ce891dceb271dab78a4d9001de5c95b">00222</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> getInvInertiaScale1()<span class="keyword"> const </span>
<a name="l00223"></a>00223 <span class="keyword"> </span>{
<a name="l00224"></a>00224 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00225"></a>00225 <span class="keywordflow">return</span> patch->mMassModification.mInvInertiaScale1;
<a name="l00226"></a>00226 }
<a name="l00227"></a>00227
<a name="l00234"></a><a class="code" href="classPxContactSet.html#74648acc75bce20cfd555e76298b514f">00234</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setInvMassScale0(<span class="keyword">const</span> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> scale)
<a name="l00235"></a>00235 {
<a name="l00236"></a>00236 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00237"></a>00237 patch->mMassModification.mInvMassScale0 = scale;
<a name="l00238"></a>00238 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb90b3667ec3f96024527acc84fc850cbb1" title="Indicates this contact stream has modified mass ratios.">PxContactPatch::eHAS_MODIFIED_MASS_RATIOS</a>;
<a name="l00239"></a>00239 }
<a name="l00240"></a>00240
<a name="l00247"></a><a class="code" href="classPxContactSet.html#d77be76292fb196ff129d70c372c5d97">00247</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setInvMassScale1(<span class="keyword">const</span> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> scale)
<a name="l00248"></a>00248 {
<a name="l00249"></a>00249 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00250"></a>00250 patch->mMassModification.mInvMassScale1 = scale;
<a name="l00251"></a>00251 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb90b3667ec3f96024527acc84fc850cbb1" title="Indicates this contact stream has modified mass ratios.">PxContactPatch::eHAS_MODIFIED_MASS_RATIOS</a>;
<a name="l00252"></a>00252 }
<a name="l00253"></a>00253
<a name="l00260"></a><a class="code" href="classPxContactSet.html#e145d9eec7403316390478f401837dcf">00260</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setInvInertiaScale0(<span class="keyword">const</span> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> scale)
<a name="l00261"></a>00261 {
<a name="l00262"></a>00262 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00263"></a>00263 patch->mMassModification.mInvInertiaScale0 = scale;
<a name="l00264"></a>00264 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb90b3667ec3f96024527acc84fc850cbb1" title="Indicates this contact stream has modified mass ratios.">PxContactPatch::eHAS_MODIFIED_MASS_RATIOS</a>;
<a name="l00265"></a>00265 }
<a name="l00266"></a>00266
<a name="l00273"></a><a class="code" href="classPxContactSet.html#74a22b5ae3140aba546b66415427a7d5">00273</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <span class="keywordtype">void</span> setInvInertiaScale1(<span class="keyword">const</span> <a class="code" href="namespacephysx.html#727d2d8426e2a21ebbc522fa65c3f97a">PxReal</a> scale)
<a name="l00274"></a>00274 {
<a name="l00275"></a>00275 <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* patch = getPatch();
<a name="l00276"></a>00276 patch->mMassModification.mInvInertiaScale1 = scale;
<a name="l00277"></a>00277 patch-><a class="code" href="structPxContactPatch.html#6dd6eed1e599102e1c2cc16fab3a5ddb">internalFlags</a> |= <a class="code" href="structPxContactPatch.html#704320591170cbad6698b74b5d1d9eb90b3667ec3f96024527acc84fc850cbb1" title="Indicates this contact stream has modified mass ratios.">PxContactPatch::eHAS_MODIFIED_MASS_RATIOS</a>;
<a name="l00278"></a>00278 }
<a name="l00279"></a>00279
<a name="l00280"></a>00280 <span class="keyword">protected</span>:
<a name="l00281"></a>00281
<a name="l00282"></a><a class="code" href="classPxContactSet.html#0aef84a136055ad90c1af8a53f2fe8a8">00282</a> <a class="code" href="group__foundation.html#g6a774eed3cad34b0f636332a3d28c6bb">PX_FORCE_INLINE</a> <a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>* getPatch()<span class="keyword"> const</span>
<a name="l00283"></a>00283 <span class="keyword"> </span>{
<a name="l00284"></a>00284 <span class="keyword">const</span> <span class="keywordtype">size_t</span> headerOffset = <span class="keyword">sizeof</span>(<a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>)*mCount;
<a name="l00285"></a>00285 <span class="keywordflow">return</span> <span class="keyword">reinterpret_cast<</span><a class="code" href="structPxContactPatch.html" title="Header for contact patch where all points share same material and normal.">PxContactPatch</a>*<span class="keyword">></span>(<span class="keyword">reinterpret_cast<</span><a class="code" href="namespacephysx.html#3849f86abc21d3a58949481603fe8309">PxU8</a>*<span class="keyword">></span>(mContacts) - headerOffset);
<a name="l00286"></a>00286 }
<a name="l00287"></a>00287
<a name="l00288"></a><a class="code" href="classPxContactSet.html#fcc7a677fe3cf662ebab5a49f5a454b9">00288</a> <a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> mCount;
<a name="l00289"></a><a class="code" href="classPxContactSet.html#614a3d5bbdfe9fccce114e0ce64913a8">00289</a> <a class="code" href="structPxModifiableContact.html" title="A modifiable contact point. This has additional fields per-contact to permit modification...">PxModifiableContact</a>* mContacts;
<a name="l00290"></a>00290 };
<a name="l00291"></a>00291
<a name="l00292"></a>00292
<a name="l00293"></a>00293
<a name="l00300"></a><a class="code" href="classPxContactModifyPair.html">00300</a> <span class="keyword">class </span><a class="code" href="classPxContactModifyPair.html" title="An array of instances of this class is passed to PxContactModifyCallback::onContactModify()...">PxContactModifyPair</a>
<a name="l00301"></a>00301 {
<a name="l00302"></a>00302 <span class="keyword">public</span>:
<a name="l00303"></a>00303
<a name="l00310"></a><a class="code" href="classPxContactModifyPair.html#5102f62e13acc449f81670353cdac114">00310</a> <span class="keyword">const</span> <a class="code" href="classPxRigidActor.html" title="PxRigidActor represents a base class shared between dynamic and static rigid bodies...">PxRigidActor</a>* actor[2];
<a name="l00317"></a><a class="code" href="classPxContactModifyPair.html#e562e272dd6588e55139200aed047c38">00317</a> <span class="keyword">const</span> <a class="code" href="classPxShape.html" title="Abstract class for collision shapes.">PxShape</a>* shape[2];
<a name="l00318"></a>00318
<a name="l00327"></a><a class="code" href="classPxContactModifyPair.html#8d6715a77c2fb18a8ee9906813149d22">00327</a> <a class="code" href="classPxTransform.html" title="class representing a rigid euclidean transform as a quaternion and a vector">PxTransform</a> transform[2];
<a name="l00328"></a>00328
<a name="l00333"></a><a class="code" href="classPxContactModifyPair.html#9266a6cd1e9604f2bc6f7104064bb388">00333</a> <a class="code" href="classPxContactSet.html" title="An array of contact points, as passed to contact modification.">PxContactSet</a> contacts;
<a name="l00334"></a>00334 };
<a name="l00335"></a>00335
<a name="l00336"></a>00336
<a name="l00355"></a><a class="code" href="classPxContactModifyCallback.html">00355</a> <span class="keyword">class </span><a class="code" href="classPxContactModifyCallback.html" title="An interface class that the user can implement in order to modify contact constraints...">PxContactModifyCallback</a>
<a name="l00356"></a>00356 {
<a name="l00357"></a>00357 <span class="keyword">public</span>:
<a name="l00358"></a>00358
<a name="l00369"></a>00369 <span class="keyword">virtual</span> <span class="keywordtype">void</span> onContactModify(<a class="code" href="classPxContactModifyPair.html" title="An array of instances of this class is passed to PxContactModifyCallback::onContactModify()...">PxContactModifyPair</a>* <span class="keyword">const</span> pairs, <a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> count) = 0;
<a name="l00370"></a>00370
<a name="l00371"></a>00371 <span class="keyword">protected</span>:
<a name="l00372"></a><a class="code" href="classPxContactModifyCallback.html#d6c57abf114d4c594973c2d365a98b6f">00372</a> <span class="keyword">virtual</span> <a class="code" href="classPxContactModifyCallback.html#d6c57abf114d4c594973c2d365a98b6f">~PxContactModifyCallback</a>(){}
<a name="l00373"></a>00373 };
<a name="l00374"></a>00374
<a name="l00393"></a><a class="code" href="classPxCCDContactModifyCallback.html">00393</a> <span class="keyword">class </span><a class="code" href="classPxCCDContactModifyCallback.html" title="An interface class that the user can implement in order to modify CCD contact constraints...">PxCCDContactModifyCallback</a>
<a name="l00394"></a>00394 {
<a name="l00395"></a>00395 <span class="keyword">public</span>:
<a name="l00396"></a>00396
<a name="l00407"></a>00407 <span class="keyword">virtual</span> <span class="keywordtype">void</span> onCCDContactModify(<a class="code" href="classPxContactModifyPair.html" title="An array of instances of this class is passed to PxContactModifyCallback::onContactModify()...">PxContactModifyPair</a>* <span class="keyword">const</span> pairs, <a class="code" href="namespacephysx.html#9b7fbd746d18bf5b6545713a8d818f41">PxU32</a> count) = 0;
<a name="l00408"></a>00408
<a name="l00409"></a>00409 <span class="keyword">protected</span>:
<a name="l00410"></a><a class="code" href="classPxCCDContactModifyCallback.html#323e56a126465efff8afccade4d72642">00410</a> <span class="keyword">virtual</span> <a class="code" href="classPxCCDContactModifyCallback.html#323e56a126465efff8afccade4d72642">~PxCCDContactModifyCallback</a>(){}
<a name="l00411"></a>00411 };
<a name="l00412"></a>00412
<a name="l00413"></a>00413
<a name="l00414"></a>00414 <span class="preprocessor">#if !PX_DOXYGEN</span>
<a name="l00415"></a>00415 <span class="preprocessor"></span>} <span class="comment">// namespace physx</span>
<a name="l00416"></a>00416 <span class="preprocessor">#endif</span>
<a name="l00417"></a>00417 <span class="preprocessor"></span>
<a name="l00419"></a>00419 <span class="preprocessor">#endif</span>
</pre></div></div>
<hr style="width: 100%; height: 2px;"><br>
Copyright © 2008-2017 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved. <a href="http://www.nvidia.com ">www.nvidia.com</a>
</body>
</html>
|