Debugging using GDB: disabling mouse grabbing

Topics about the general development of Orxonox.

Moderator: PPS-Leaders

Post Reply
smerkli
Human Space Navy Lieutenant
Posts: 20
Joined: Mon Mar 01, 2010 7:28 pm

Debugging using GDB: disabling mouse grabbing

Post by smerkli » Tue May 07, 2013 1:51 pm

Hey,

So far, when debugging Orxonox with GDB, the problem has been that
when GDB runs into a Breakpoint, Orxonox cannot release the mouse.
Me and fmauro figured out that one solution is to (for debugging purposes only) disable mouse grabbing fully by changing the InputManager::loadDevices() function to not grab the mouse even if exclusiveMouse_ is specified.
Now we need a way to quickly enable/disable this at build time, for example via a make target for debugging or some other settable option. What would be the correct way to do this?

- smerkli

User avatar
x3n
Baron Vladimir Harkonnen
Posts: 810
Joined: Mon Oct 30, 2006 5:40 pm
Contact:

Re: Debugging using GDB: disabling mouse grabbing

Post by x3n » Wed May 08, 2013 8:05 pm

A make target doesn't sound right... you probably want to change the behaviour at runtime, don't you? I'd rather suggest a config value or a console command for this purpose.
However, I don't know what InputManager::loadDevices() does nor when it is called, and whether you can change any of those settings later... so maybe my suggestion doesn't work.

Edit: I tought there was already a solution to this problem? After all, this isn't new (though exclusively a Linux issue)
Fabian 'x3n' Landau, Orxonox developer

smerkli
Human Space Navy Lieutenant
Posts: 20
Joined: Mon Mar 01, 2010 7:28 pm

Re: Debugging using GDB: disabling mouse grabbing

Post by smerkli » Tue May 14, 2013 11:40 am

Hey, it looks like there is a developer mode, but I have not found any listeners to the developer mode setting yet - I could possibly add another in-game setting to disable mouse grab altogether or make it automatically be disabled when developer mode is turned on. Does that make sense?

-s

User avatar
x3n
Baron Vladimir Harkonnen
Posts: 810
Joined: Mon Oct 30, 2006 5:40 pm
Contact:

Re: Debugging using GDB: disabling mouse grabbing

Post by x3n » Thu May 16, 2013 7:37 pm

Yea I remember there's a developer mode, Reto implemented it, but I think it's always active unless you build Orxonox in release or install mode. So it's probably not exactly what you want
Fabian 'x3n' Landau, Orxonox developer

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest