git-svn-id: svn://db.shs.com.ru/libs@286 a8b55f48-bf90-11e4-a774-851b48703e85

This commit is contained in:
2017-10-03 12:20:32 +00:00
parent b46b9329f3
commit 7ad19d72c5
40 changed files with 320 additions and 712 deletions

View File

@@ -42,6 +42,9 @@ GLFramebuffer::~GLFramebuffer() {
void GLFramebuffer::resize(int width, int height, bool force) {
if ((wid == width) && (hei == height) && !force) return;
#if QT_VERSION >= 0x050600
initializeOpenGLFunctions();
#endif
wid = width;
hei = height;
deleteGLFramebuffer(fbo);
@@ -88,6 +91,9 @@ QImage GLFramebuffer::grab() const {
void GLFramebuffer::bind() {
if (is_changed) resize(wid, hei);
if (fbo == 0) return;
#if QT_VERSION >= 0x050600
initializeOpenGLFunctions();
#endif
glFlush();
glGetIntegerv(GL_VIEWPORT, prev_view);
//glClearError();