helper method to scale a sprite according to a size.