Embed SDL_Surface into Widget

Hi All,

I am a newbie just starting to use SDL. I want to embed a SDL_Surface
into the Qt Gui toolkit. I have tried setting the environment variables
SDL_VIDEODRIVER & SDL_WINDOWID but I can’t seem to make SDL render in
the a Qt window.
I am using Qt4 on Windows.
Has anyone done this before? Does anyone have any ideas?

Thanks in advance

Andy

Hello !

I am a newbie just starting to use SDL. I want to embed a SDL_Surface
into the Qt Gui toolkit. I have tried setting the environment variables
SDL_VIDEODRIVER & SDL_WINDOWID but I can’t seem to make SDL render in
the a Qt window. I am using Qt4 on Windows.
Has anyone done this before? Does anyone have any ideas?

I don’t know if there is a SDL widget for QT.
But what you can do in nearly every GUI toolkit,
is having an Image Box somewhere or use an Image
Blitting function from the GUI toolkit.

That way you can use SDL for the image working stuff, blending
colorkeying and so on and use the GUI toolkit for displaying it.

An example using FLTK and SDL, but it should help to see the
way doing things like this :

http://www.syntheticsw.com/~wizard/projects/multiwin/

CU

Torsten Giebl wrote:

Hello !

I am a newbie just starting to use SDL. I want to embed a SDL_Surface
into the Qt Gui toolkit. I have tried setting the environment variables
SDL_VIDEODRIVER & SDL_WINDOWID but I can’t seem to make SDL render in
the a Qt window. I am using Qt4 on Windows.
Has anyone done this before? Does anyone have any ideas?

I don’t know if there is a SDL widget for QT.
But what you can do in nearly every GUI toolkit,
is having an Image Box somewhere or use an Image
Blitting function from the GUI toolkit.

That way you can use SDL for the image working stuff, blending
colorkeying and so on and use the GUI toolkit for displaying it.

An example using FLTK and SDL, but it should help to see the
way doing things like this :

http://www.syntheticsw.com/~wizard/projects/multiwin/

CU

Thanks. I am trying that but I can’t seem to get it painting on the
widget at the moment. What I am trying to do is to improve a Video
widget I am using as the Qt paint engine is slow. Is this the best
route to improve efficiency or am I going down the wrong path.

Andy