Skip to content

Commit

Permalink
fix plane not found issue, constraint body id issue
Browse files Browse the repository at this point in the history
  • Loading branch information
fxia22 committed Oct 18, 2020
1 parent e203836 commit d065583
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
10 changes: 5 additions & 5 deletions examples/demo/igsdf_obj_viz.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,13 +97,13 @@ def main():

s.renderer.set_light_position_direction([0,0,10], [0,0,0])

s.renderer.load_object('plane/plane_z_up_0.obj', scale=[3,3,3])
s.renderer.add_instance(0)
s.renderer.set_pose([0,0,-1.5,1, 0, 0.0, 0.0], -1)

#s.renderer.load_object('plane/plane_z_up_0.obj', scale=[3,3,3])
#s.renderer.add_instance(0)
#s.renderer.set_pose([0,0,-1.5,1, 0, 0.0, 0.0], -1)
# removed the plane since it is in local dir

v = []
mesh_path = os.path.join(model_path, 'shape/visual')
mesh_path = os.path.join(model_path, 'shape', 'visual')
for fn in os.listdir(mesh_path):
if fn.endswith('obj'):
vertices, faces = load_obj_np(os.path.join(mesh_path, fn))
Expand Down
5 changes: 2 additions & 3 deletions gibson2/render/viewer.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,8 @@ def create_visual_object(self):
self.simulator.import_object(
self.constraint_marker2, use_pbr=False)
self.simulator.import_object(self.constraint_marker, use_pbr=False)

self.constraint_marker.set_position([0, 0, -1])
self.constraint_marker2.set_position([0, 0, -1])
self.constraint_marker.set_position([0, 0, -1])
self.constraint_marker2.set_position([0, 0, -1])

def apply_push_force(self, x, y, force):
camera_pose = np.array([self.px, self.py, self.pz])
Expand Down

0 comments on commit d065583

Please sign in to comment.