slice the visible objects by adjusting a max and min x coordinate