diff options
author | Melanie | 2013-01-16 01:11:20 +0000 |
---|---|---|
committer | Melanie | 2013-01-16 01:11:20 +0000 |
commit | fc5711fa7ab3bcd0d81737735d098f070a7132bb (patch) | |
tree | 06fbc4ebf2a4788f4ffd65010d6abadfb2ffafae /OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs | |
parent | Merge branch 'avination' into careminster (diff) | |
parent | BulletSim: disable center-of-mass computation for linksets until debugged. Mo... (diff) | |
download | opensim-SC-fc5711fa7ab3bcd0d81737735d098f070a7132bb.zip opensim-SC-fc5711fa7ab3bcd0d81737735d098f070a7132bb.tar.gz opensim-SC-fc5711fa7ab3bcd0d81737735d098f070a7132bb.tar.bz2 opensim-SC-fc5711fa7ab3bcd0d81737735d098f070a7132bb.tar.xz |
Merge commit '8bf0a9f85dda4b1831630b65620d5c6868196c11' into careminster
Conflicts:
OpenSim/Region/Framework/Scenes/SceneObjectPart.cs
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs')
-rwxr-xr-x | OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs index e8575f6..185f111 100755 --- a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs | |||
@@ -73,6 +73,8 @@ public abstract class BSPhysObject : PhysicsActor | |||
73 | 73 | ||
74 | // A linkset of just me | 74 | // A linkset of just me |
75 | Linkset = BSLinkset.Factory(PhysicsScene, this); | 75 | Linkset = BSLinkset.Factory(PhysicsScene, this); |
76 | PositionDisplacement = OMV.Vector3.Zero; | ||
77 | |||
76 | LastAssetBuildFailed = false; | 78 | LastAssetBuildFailed = false; |
77 | 79 | ||
78 | // Default material type | 80 | // Default material type |
@@ -135,6 +137,7 @@ public abstract class BSPhysObject : PhysicsActor | |||
135 | public virtual OMV.Vector3 Scale { get; set; } | 137 | public virtual OMV.Vector3 Scale { get; set; } |
136 | public abstract bool IsSolid { get; } | 138 | public abstract bool IsSolid { get; } |
137 | public abstract bool IsStatic { get; } | 139 | public abstract bool IsStatic { get; } |
140 | public abstract bool IsSelected { get; } | ||
138 | 141 | ||
139 | // Materialness | 142 | // Materialness |
140 | public MaterialAttributes.Material Material { get; private set; } | 143 | public MaterialAttributes.Material Material { get; private set; } |
@@ -156,6 +159,14 @@ public abstract class BSPhysObject : PhysicsActor | |||
156 | public abstract OMV.Vector3 RawPosition { get; set; } | 159 | public abstract OMV.Vector3 RawPosition { get; set; } |
157 | public abstract OMV.Vector3 ForcePosition { get; set; } | 160 | public abstract OMV.Vector3 ForcePosition { get; set; } |
158 | 161 | ||
162 | // Position is what the simulator thinks the positions of the prim is. | ||
163 | // Because Bullet needs the zero coordinate to be the center of mass of the linkset, | ||
164 | // sometimes it is necessary to displace the position the physics engine thinks | ||
165 | // the position is. PositionDisplacement must be added and removed from the | ||
166 | // position as the simulator position is stored and fetched from the physics | ||
167 | // engine. | ||
168 | public virtual OMV.Vector3 PositionDisplacement { get; set; } | ||
169 | |||
159 | public abstract OMV.Quaternion RawOrientation { get; set; } | 170 | public abstract OMV.Quaternion RawOrientation { get; set; } |
160 | public abstract OMV.Quaternion ForceOrientation { get; set; } | 171 | public abstract OMV.Quaternion ForceOrientation { get; set; } |
161 | 172 | ||