As long as the Camera in your player has Lock to HMD checked, the position and rotation of the camera coincide with those of the HMD. In other words, to get the position and rotation of the HMD, just get the location and orientation of the camera.
As long as the Camera in your player has Lock to HMD checked, the position and rotation of the camera coincide with those of the HMD. In other words, to get the position and rotation of the HMD, just get the location and orientation of the camera.