Hi guys,

I'm trying to combine Irrlicht and FLTK into one window.

This works well on a Windows machine, but when I try it on a Mac I have some 
problems.
I can get it to work when using Irrlicht's software renderer, but when using 
the OpenGL renderer it doesn't work and I get an "invalid drawable" error (I 
also get this error with the software renderer, although it works).

I hope someone on this Forums use both libraries and can help me.

Thank you in advance,
-Lu



PS:
Here is the code that works (although using the software renderer):

[code]
#include "FL/Fl.H"
#include <FL/Fl_Window.H>
#include "FL/x.H"
#include "irrlicht.h"

int main(int argc,char** argv)
{
        //Create FLTK window
        Fl_Window* win = new Fl_Window(340,180,"muh");
        win->end();
        win->show(argc, argv);

        //Create Irrlicht device
        irr::SIrrlichtCreationParameters params;
        params.WindowId = (void*)fl_xid( win );
        params.DriverType = irr::video::EDT_SOFTWARE;
        params.WindowSize = irr::core::dimension2du(340,180);

        irr::IrrlichtDevice* device = irr::createDeviceEx(params);

        //Update FLTK and Irrlicht
        while(Fl::check()) {
                device->getVideoDriver()->beginScene();
                device->getSceneManager()->drawAll();
                device->getVideoDriver()->endScene();
        }

        return 0;
}
[/code]
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to