Results 1 to 2 of 2

Thread: QSurface to image

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2017
    Posts
    1
    Qt products
    Qt5
    Platforms
    Unix/X11 Windows

    Default QSurface to image

    Hello,

    how to export image or take a snapshot of QSurface Widget?

    I'm using QSurface example.

    Kking


    Edit: i have found a solution:

    Qt Code:
    1. QPixmap::grabWindow(graph->winId()).save("img.png");
    To copy to clipboard, switch view to plain text mode 
    Last edited by kkingstoun; 20th February 2017 at 20:01.

Similar Threads

  1. Replies: 1
    Last Post: 6th September 2016, 16:10
  2. Replies: 15
    Last Post: 24th July 2015, 22:33
  3. Replies: 4
    Last Post: 15th May 2013, 13:58
  4. Replies: 3
    Last Post: 3rd August 2012, 10:35
  5. Replies: 6
    Last Post: 21st September 2009, 10:55

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
  •  
Qt is a trademark of The Qt Company.