Refactor Renderer object

This permits extensibility and reduces the number of variables that need
to be passed into functions.