Minor bug fixes and add glError check.
2 files changed