Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-19705

Extend QPixmap::grabWidget to grab OpenGL widget contents on Windows XP

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Duplicate
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • None
    • None

      The following modification of the grabber example will produce a black area in the place of the OpenGL widget on Windows XP.

      @@ -102,8 +102,8 @@ void MainWindow::renderIntoPixmap()
      
       void MainWindow::grabFrameBuffer()
       {
      -    QImage image = glWidget->grabFrameBuffer();
      -    setPixmap(QPixmap::fromImage(image));
      +    QPixmap pixmap = QPixmap::grabWidget(this);
      +    setPixmap(pixmap);
       }
      
       void MainWindow::clearPixmap()
      
      

      The OpenGL widget is grabbed correctly on Windows 7 and Linux.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Unassigned Unassigned
            mpejcoch Martin Pejcoch (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes