Code: Select all
visualShift = [0, 0, 0]
shift = [0, 0, -0.1]
meshScale=[0.1, 0.1, 0.1]
path = os.path.abspath(os.path.dirname(__file__))
self.groundColId = p.createCollisionShape(shapeType=p.GEOM_MESH,
fileName=os.path.join(path, "ground.obj"),
collisionFramePosition=shift,
meshScale=meshScale)
self.groundVisID = p.createVisualShape(shapeType=p.GEOM_MESH,
fileName=os.path.join(path, "ground.obj"),
rgbaColor=[1,1,1,1],
specularColor=[0.4,.4,0],
visualFramePosition=visualShift,
meshScale=meshScale)
self.groundId = p.createMultiBody(baseMass=0,
baseInertialFramePosition=[0,0,0],
baseCollisionShapeIndex=self.groundColId,
baseVisualShapeIndex=self.groundVisID,
basePosition=[0,0,0],
useMaximalCoordinates=True)
I am not importing anything else apart from this object and the robot seen in the image above.
Is there any mistake I am doing in importing the mesh?
Thank you