Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: sfml and irrlicht  (Read 3964 times)

0 Members and 1 Guest are viewing this topic.

Boogiwoogie

  • Newbie
  • *
  • Posts: 19
    • View Profile
sfml and irrlicht
« on: March 21, 2009, 05:33:30 pm »
hi!
i want to use sfml and irrlicht, sfml for some gui elements, and irrlicht for displaying a mesh. i didnt try out to code it yet, so its pretty much a question in advance... ;)
how do i proceed the best way?
shall i set up the window using sfml, and create an irrlicht context based on the window handle (how do i get it from sfml?) - or the other way around: irrlicht for window creation, passing window handle to sfml... (i've seen something like that on the wxwidgets tut or so)

boogie :shock:

ps: i think theres a french thread about that topic, i cant speak french tho :(

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
sfml and irrlicht
« Reply #1 on: March 21, 2009, 05:46:41 pm »
I don't think it's a good idea. It might even not be possible, SFML and Irrlicht having each their own OpenGL context. Why not just using the GUI module of Irrlicht? SFML doesn't even have one, how can it be a better solution? :P
Laurent Gomila - SFML developer

Boogiwoogie

  • Newbie
  • *
  • Posts: 19
    • View Profile
sfml and irrlicht
« Reply #2 on: March 21, 2009, 07:51:26 pm »
hi laurent,
i would want to use the sfml library anyway (for sound, network, i/o), and want to use the irrlicht engine only for 3d drawing because of the scenegraph. so rather irrlicht is the optional library, not sfml.
irrlicht has its own gui, and as it looks like, its not the worst.
but i want to make some small immediate mode gui, and i like the sf::String class very much. its pretty much perfectly suitable, along with the sprite support that would skinning make easy.
maybe i should just try it out. is there a way to get the window handle out of sfml?
i think different opengl states may not be a problem, because the rendering can be done successively. first the 3d scene, then the gui. however, i have not much experience in opengl, so your opinion is definetly worth more...

boogie :shock:

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32504
    • View Profile
    • SFML's website
    • Email
sfml and irrlicht
« Reply #3 on: March 22, 2009, 10:27:03 am »
There's no public way of getting the handle of a SFML window, but you can add it easily for your tests. And you can do the other way: getting the handle of your Irrlicht's window and create a SFML window from it.
Laurent Gomila - SFML developer