Minor tweaks.
Huge refactoring, more c++ style API. Allows multiple rendering contexts.