Results 1 to 2 of 2

Thread: QGLWidget::setContext: Context must refer to this widget

  1. #1

    Default QGLWidget::setContext: Context must refer to this widget

    Hi gang,

    I am trying to share QGLContext amongst different QGLWidgets and am getting an error on the second widget. The basic code is as follows :

    commonContext = new QGLContext(QGLFormat(QGL:oubleBuffer));

    QGLWidget *w1 = new QGLWidget(commonContext, NULL )

    QGLWidget *w2 = new QGLWidget(commonContext, NULL, w1 );

    Any thoughts you might have is appreciated.

    Freddy

  2. #2
    Join Date
    Aug 2008
    Posts
    60
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QGLWidget::setContext: Context must refer to this widget

    might be you need to call QGLContext::create before passing it to the QGLWidgets...

Similar Threads

  1. QDockWidget inside another widget in the center?
    By Antebios in forum Qt Programming
    Replies: 1
    Last Post: 16th February 2010, 07:06
  2. Tricky problem with ARGB widget / UpdateLayeredWindow
    By nooky59 in forum Qt Programming
    Replies: 3
    Last Post: 21st February 2008, 10:35

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.