PDA

View Full Version : Transparent window with QGLWidget



ultr
24th November 2006, 10:55
Hello,

I need to create a window in Qt which will be transparent
(like in xeyes command) and will contain QGLWidget in it, also
transparent. So that the result of rendering i.e. a cube in the
QGLWidget will just draw the cube on the desktop.

Is it possible? Or does it require extensions to X or Xgl server to
allow this?

I have been looking for the solution quite much, but cannot find
anything interesting.

Thanks for your answers,
ultr

wysota
24th November 2006, 11:06
QWidget::setMask()

showhand
25th November 2006, 01:31
I met the same problem with you. How do you set the transparent window and draw graphics with opengl commands in QGLWidget. As I know, QWidget::setMask() does not take effective on QGLWidget. Would you please give some example code to me or picture of your program?

Thanks for any replay!

20khz
28th April 2008, 02:22
does the problem still remain unsolved?

wysota
28th April 2008, 07:01
I can think of using a regular widget instead of QGLWidget and rendering the GL data to a buffer instead of the screen, so that then you'll be able to apply a mask on the resulting image (at least in Qt4). Unfortunately it's not easy to have the mask itself... I can think of using the bluebox approach for it, if you don't use multisampling, it might just work.