Obstacle avoidance by combining background subtraction, optical flow and proximity estimation