Skip to content

Commit

Permalink
defaulting render to tracking camera
Browse files Browse the repository at this point in the history
  • Loading branch information
zuoxingdong committed Apr 15, 2019
1 parent ec12ed0 commit 1fa3b8f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions dm2gym/dm_control_env.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ def reset(self):
return timestep.observation

def render(self, mode='human', **kwargs):
if 'camera_id' not in kwargs:
kwargs['camera_id'] = 0 # tracking camera
img = self.env.physics.render(**kwargs)
if mode == 'rgb_array':
return img
Expand Down

0 comments on commit 1fa3b8f

Please sign in to comment.