Put back in some features I took out from svg rendering
Refactored out the piece placement into a function interface that multiple implementations can take.