Huge refactoring.
Removed warnings.
Fixed issue with Program -> GPUProgram in renderMesh.