I used the following code to add a gripper camera on my isaac environment, however i would like to have to possibility to render the camera only when is required (take the image for reinforcement learning observation). Rendering all the camera will slow down the whole application
stage = get_current_stage()
camera_path = prim_path + '/panda_hand' + '/gripper_cam'
camera_prim = UsdGeom.Camera(stage.DefinePrim(camera_path, "Camera"))
xform_api = UsdGeom.XformCommonAPI(camera_prim)
xform_api.SetRotate([ 0, 180, 90], UsdGeom.XformCommonAPI.RotationOrderXYZ)
xform_api.SetTranslate([0.05, 0.0, 0.0])
camera_prim.GetFocalLengthAttr().Set(50)
camera_prim.GetHorizontalApertureAttr().Set(90)
camera_prim.GetVerticalApertureAttr().Set(65)
camera_prim.GetClippingRangeAttr().Set(Gf.Vec2f(0.001, 1.5+0.5))
Thanks