Results 1 to 3 of 3

Thread: QglWidget: get depth buffer allowed values

  1. #1
    Join Date
    Jan 2011
    Posts
    55
    Thanks
    12
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default QglWidget: get depth buffer allowed values

    There is a possibility to gather depth buffer possible values so that I know, prior calling QGLFormat::setDepthBufferSize, if the system supports 24 or 32bit depth buffer size?

  2. #2
    Join Date
    Oct 2007
    Location
    Lake Forest, CA, USA
    Posts
    132
    Thanks
    10
    Thanked 27 Times in 22 Posts
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android

    Default Re: QglWidget: get depth buffer allowed values

    Maybe using QDesktopWidget::depth() will help?

    Qt Code:
    1. int depth = qApp->desktop()->depth();
    To copy to clipboard, switch view to plain text mode 

    But it will return the current depth really, not all supported.
    Oleg Shparber

  3. The following user says thank you to Oleg for this useful post:

    papillon (28th November 2011)

  4. #3
    Join Date
    Jan 2011
    Posts
    55
    Thanks
    12
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: QglWidget: get depth buffer allowed values

    Thank you very much Oleg. It doesn't really matter if I can't get all the depth buffer sizes supported; setting the Qt application to use the actual desktop depth is OK!

Similar Threads

  1. QGLWidget and GL Frame Buffer Object
    By ArlexBee-871RBO in forum Qt Programming
    Replies: 0
    Last Post: 17th August 2010, 23:49
  2. Replies: 1
    Last Post: 9th November 2009, 14:16
  3. other windows affecting depth buffer in QGLwidget
    By mullwaden in forum Qt Programming
    Replies: 0
    Last Post: 10th September 2008, 13:43
  4. Image 32 bit depth to 8 bit depth
    By ^NyAw^ in forum Qt Programming
    Replies: 2
    Last Post: 2nd September 2008, 09:35
  5. How to diagnose why a drop isn't allowed?
    By eean in forum Qt Programming
    Replies: 2
    Last Post: 17th July 2007, 05:18

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.