Mouse cursor stealing

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
Pianist
Posts: 14
Joined: Wed Apr 22, 2009 12:47 pm
Location: Czech Republic

Mouse cursor stealing

Post by Pianist »

Hello everybody,

I've .NET project with Irrlicht based visualization component. This component is driven by my custom interface. I need help with setting mouse cursor.

I have interface for changing camera (first person, maya, orthogonal). Everytime, when I'm setting new camera using .NET API the mouse cursor is stolen and moved in the center of Irrlicht visualization window.

Do you have any ideas how to avoid this unwanted mouse cursor moving??

Thanks a lot!
greenya
Posts: 1012
Joined: Sun Jan 21, 2007 1:46 pm
Location: Ukraine
Contact:

Post by greenya »

Maybe try to save mouse cursor position, set new camera, restore previously saved position?
B@z
Posts: 876
Joined: Thu Jan 31, 2008 5:05 pm
Location: Hungary

Post by B@z »

or try to call camera->setEventReceiver(0)?
also, wrong topic. try to post to beginners help, not code snippets
Image
Image
CuteAlien
Admin
Posts: 9930
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

moved.

And I think it might be the first-person camera that does disable the mouse and moves it to the center. If that's the case I'm not sure if it can be avoided easily as it's basically the desired behavior for a fps-cam.
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
slavik262
Posts: 753
Joined: Sun Nov 22, 2009 9:25 pm
Location: Wisconsin, USA

Post by slavik262 »

Call camera->setInputReceiverEnabled(false) to have the FPS camera release your mouse.
Post Reply