concepts.simulator.pybullet.camera.lookat_rpy#

lookat_rpy(camera_pos, target_pos, roll=0)[source]#

Construct the roll, pitch, yaw angles of a camera looking at a target. This function assumes that the camera is pointing to the z-axis ([0, 0, 1]), in the camera frame. :param camera_pos: the position of the camera. :param target_pos: the target position. :param roll: the roll angle of the camera.

Returns:

a numpy array of the roll, pitch, yaw angles in degrees.

Parameters:
Return type:

ndarray