Learning Visuo-Motor Behaviours for Robot Locomotion Over Difficult Terrain