need this for calculating image overlay boxes