SDL Device correctly processing events?

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: SDL Device correctly processing events?

Post by CuteAlien »

Hm, OK. If you find out any reason why it fails on AmigaOS maybe we can do something else on Irrlicht then.

Strange stuff to debug btw, because directly after SDL_Init call it always does mess up the VS debugger for a while and the mouse can't be moved correctly anymore :-)
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
kas1e
Posts: 212
Joined: Sun Jan 21, 2018 8:39 am

Re: SDL Device correctly processing events?

Post by kas1e »

@CuteAlien
Hm, OK. If you find out any reason why it fails on AmigaOS maybe we can do something else on Irrlicht then.
We fix that in our SDL1 realisation (and also implement in our SDL2 realisation SDL_SetWindowResizable, so when SDL2 will come nothing will be needs changed, and current "resizable" flag can be keept for SDL1 and co).

But i found some other bug in SDL1Device support in irrlicht : lately we fix those issues with "active window and focus", but seems not fully. Now, window seems active all the time. As example i just compile 09.Meshviewer example for both win32 and sdl1 devices, and check how it reacts. And result are:

when you build with win32 device, and you made a window be not active (by clicking on any other window) , rendering in the example stop (as expected, as window is inactive).
when you build with sdl1 device, and you made a window be not active (by same clicking on any other window), rendering in the example _DIDN'T_ stop, while should.

I found firstly that issue in HCRAFT, which have that kind of code in the app::run()

Code: Select all

 
// inactive - just update less often
        if (!irrlichtDevice->isWindowActive() )
        {
            irrlichtDevice->sleep(10);
        }
 
And when i made window inactive, fps didn't drops. So i start checking, and found that in whole "inactive" is not working as expected in latest SDL1 device.

That all on win32 and on amigaos4 at least, didn't checked on linux.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: SDL Device correctly processing events?

Post by CuteAlien »

Thanks, I'll check tomorrow.
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
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: SDL Device correctly processing events?

Post by CuteAlien »

New fix checked in [r5898]. I hope I tested better this time.
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
kas1e
Posts: 212
Joined: Sun Jan 21, 2018 8:39 am

Re: SDL Device correctly processing events?

Post by kas1e »

Thanks will check it in all conditions now :)
Post Reply