Generate the minimap surface only once.
New drawing functions.

Clear the screen, or just part of it.
Draw a dashed line.
Add bounding box to the minimap.