Esempio n. 1
0
 def __init__(self, a, b, groove_a, groove_b, anchr2):
     """a and b are the two bodies to conenct, 
     groove_a and groove_b is two points or vectors or something.
     anchr2 is an anchor point
     """
     self._a = a 
     self._b = b
     self._joint = cp.cpGrooveJointNew(a._body, b._body, groove_a, groove_b, anchr2)
Esempio n. 2
0
 def __init__(self, a, b, groove_a, groove_b, anchr2):
     """The groove goes from groove_a to groove_b on body a, and the pivot 
     is attached to anchr2 on body b. All coordinates are body local. 
     """
     self._constraint = cp.cpGrooveJointNew(a._body, b._body, groove_a, groove_b, anchr2)
     self._ccontents = self._constraint.contents
     self._pjc = cp.cast(self._constraint, ct.POINTER(cp.cpGrooveJoint)).contents
     self._a = a
     self._b = b
Esempio n. 3
0
 def __init__(self, a, b, groove_a, groove_b, anchr2):
     """The groove goes from groove_a to groove_b on body a, and the pivot 
     is attached to anchr2 on body b. All coordinates are body local. 
     """
     self._constraint = cp.cpGrooveJointNew(a._body, b._body, groove_a,
                                            groove_b, anchr2)
     self._ccontents = self._constraint.contents
     self._pjc = cp.cast(self._constraint,
                         ct.POINTER(cp.cpGrooveJoint)).contents
     self._a = a
     self._b = b