Converted to C++11, using unique_ptr to wrap QGLFramebufferObject