aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs
diff options
context:
space:
mode:
authorRobert Adams2012-11-02 10:35:12 -0700
committerRobert Adams2012-11-03 21:15:39 -0700
commit1dc23b2b9713f4099534ae0d08c2caf5c8b036b4 (patch)
tree0893dce779215125374d29e918f5b278c97ba937 /OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs
parentBulletSim: debugging of compound shape implementation of linksets. (diff)
downloadopensim-SC-1dc23b2b9713f4099534ae0d08c2caf5c8b036b4.zip
opensim-SC-1dc23b2b9713f4099534ae0d08c2caf5c8b036b4.tar.gz
opensim-SC-1dc23b2b9713f4099534ae0d08c2caf5c8b036b4.tar.bz2
opensim-SC-1dc23b2b9713f4099534ae0d08c2caf5c8b036b4.tar.xz
BulletSim: parameterize selection of linkset implementation
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs')
-rwxr-xr-xOpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs28
1 files changed, 18 insertions, 10 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs b/OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs
index 8f973f4..3a92f93 100755
--- a/OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSLinkset.cs
@@ -36,21 +36,29 @@ public abstract class BSLinkset
36{ 36{
37 // private static string LogHeader = "[BULLETSIM LINKSET]"; 37 // private static string LogHeader = "[BULLETSIM LINKSET]";
38 38
39 public enum LinksetImplementation
40 {
41 Constraint = 0, // linkset tied together with constraints
42 Compound = 1, // linkset tied together as a compound object
43 Manual = 2 // linkset tied together manually (code moves all the pieces)
44 }
39 // Create the correct type of linkset for this child 45 // Create the correct type of linkset for this child
40 public static BSLinkset Factory(BSScene physScene, BSPhysObject parent) 46 public static BSLinkset Factory(BSScene physScene, BSPhysObject parent)
41 { 47 {
42 BSLinkset ret = null; 48 BSLinkset ret = null;
43 /*
44 if (parent.IsPhysical)
45 ret = new BSLinksetConstraints(physScene, parent);
46 else
47 ret = new BSLinksetManual(physScene, parent);
48 */
49
50 // at the moment, there is only one
51 // ret = new BSLinksetConstraints(physScene, parent);
52 ret = new BSLinksetCompound(physScene, parent);
53 49
50 switch ((int)physScene.Params.linksetImplementation)
51 {
52 case (int)LinksetImplementation.Compound:
53 ret = new BSLinksetCompound(physScene, parent);
54 break;
55 case (int)LinksetImplementation.Manual:
56 // ret = new BSLinksetManual(physScene, parent);
57 break;
58 default:
59 ret = new BSLinksetConstraints(physScene, parent);
60 break;
61 }
54 return ret; 62 return ret;
55 } 63 }
56 64