Rviz doesn't do the rectification, you would have to use image_proc to
do that. I believe that Rviz assumes that you are pointing at a
rectified image and uses the camera_info so that it can place a
synthetic view of the robot on top of the camera image. So Rviz uses the
projection matrix, but not the distortion parameters. (Please do not
consider this statement as authoritative.)