Changed code to publish rgbd data on demand if required.