updated renderBaseline function with view and obstacles and added timer function