[Qt-interest] Problem in creating empty QGLFrameBufferObject

trinathpujari trinathpujari at tataelxsi.co.in
Thu Nov 5 06:29:04 CET 2009


I want to use QGLFrameBufferObject for writing texts into
another LCD device.
But when i am creating by entering the below
 
             makeCurrent();
             fbo = new QGLFramebufferObject(100, 100);
 
and when i run the program some data from previous example
program is seen.
Can anybody tell how to create a empty QGLFramebufferObject so i
can use it for the second LCD device.
 
The example which i am trying, i am attaching here please
confirm if it is correct way of creating the object.
 
          makeCurrent();
          fbo = new QGLFramebufferObject(100, 100);
          setWindowTitle(tr("OpenGL framebuffers 99999999999"));
          fbo->bind();
          fbo->drawTexture(QRectF(25,25,25,25),222,GL_TEXTURE_2D);
          QPainter paint(fbo);
          paint.fillRect(25,25,25,25,QColor(Qt::red));
          fbo->release();

 Thanks in Advance.....



Regards

Trinath










More information about the Qt-interest-old mailing list