How do I use SDL2 with Irrlicht?

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
n00bc0de
Posts: 38
Joined: Tue Oct 04, 2022 1:21 am

How do I use SDL2 with Irrlicht?

Post by n00bc0de »

I tried googling this and it brings up some old forum post that mention that it is possible. I would like to use SDL2 to setup the window so I can use the SDL2 input system since irrlicht's input system doesn't seem to handle controllers or touch events.
CuteAlien
Admin
Posts: 9652
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: How do I use SDL2 with Irrlicht?

Post by CuteAlien »

Just use SDL2 as additional library for input, it can be independent of Irrlicht.
Unless you also want to use an SDL2 device for some reason. Which is strange enough the thing that's been blocking me for the last weeks. Blocking as in - I started working on putting that in Irrlicht, then got a bunch of bugs to work on and now have a half finished patch around which is no fun to work at *sigh*. Anyway - that patch is based on this one from Minetest: https://github.com/minetest/irrlicht/co ... 9624cf3d61
So if you want to modify Irrlicht directly you could use that one, although it will get into Irrlicht in a somewhat changed form (it will be additional to SDL1 device, not replacing it - not sure yet about other changes, I'm still going through that line-by-line).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Post Reply