public void AddChildShape(float4x4 localTransform, ISphereShapeImp shape) { Debug.WriteLine("AddSphere"); var btChildShape = new SphereShape(shape.Radius); var btLocalTransform = Translater.Float4X4ToBtMatrix(localTransform); BtCompoundShape.AddChildShape(btLocalTransform, btChildShape); }
/// <summary> /// Adds the child shape. /// </summary> /// <param name="localTransform">The local transform.</param> /// <param name="shape">The shape.</param> public void AddChildShape(float4x4 localTransform, ISphereShapeImp shape) { Debug.WriteLine("AddSphere"); var btChildShape = new SphereShape(shape.Radius); var btLocalTransform = Translator.Float4X4ToBtMatrix(localTransform); BtCompoundShape.AddChildShape(btLocalTransform, btChildShape); }
//SphereShape public SphereShape AddSphereShape(float radius) { ISphereShapeImp iSphereShapeImp = _dwi.AddSphereShape(radius); var retval = new SphereShape(); retval._sphereShapeImp = iSphereShapeImp; iSphereShapeImp.UserObject = retval; return(retval); }