Allegro.cc - Online Community

Allegro.cc Forums » Programming Questions » mouse and dosbox

This thread is locked; no one can reply to it. rss feed Print
mouse and dosbox
Member #4,675
June 2004
avatar

Hi,
1.I'm looking for a possibility for polling the mouse without getting screen coordinates but just movement vectors (that means, possible infinite mouse movement). Furthermore, I'd like to get the mouse cursor hidden (in OpenGL mode).

2.Does anybody know how to compile an allegro program on Windows platforms without getting a dosbox opened with every program call?

I'm using Allegro 4.0.3, AllegroGL 0.2.2 and DevCpp 4.9.9.2

I'd be glad if anybody could help!

tapir
Member #6,629
November 2005

I don't use allegro for a while, but if you selected win32 gui app in Dev-Cpp I think you shouldn't see a console, if you still see one,"properties > compiler > linker > do not create console window = YES" will do the job I think...

Thomas Harte
Member #33
April 2000
avatar

Quote:

I'm looking for a possibility for polling the mouse without getting screen coordinates but just movement vectors (that means, possible infinite mouse movement).

In Allegro, use get_mouse_mickeys. For pure Win32, check out the raw input API.

Member #4,675
June 2004
avatar

@cosku bas: Yeah, thanks! I didn't think it was that easy.

Archon
Member #4,195
January 2004
avatar

Compile with -mwindows

Elverion
Member #6,239
September 2005
avatar

Go to Project->Project Options. In there, change your project type from Console to GUI, and then click OK. No more DOS prompt.

--
SolarStrike Software - MicroMacro home - Automation software.

Member #4,675
June 2004
avatar

The problem with the dosbox is solved. Thank you all.

But how to remove the mouse cursor in OpenGL mode?

Kitty Cat
Member #2,815
October 2002
avatar

You should probably update Allegro and AllegroGL. IIRC, the mouse problem was a bug fixed in AllegroGL 0.2.4, and Allegro 4.0.3 is outdated. Get Allegro 4.2 and see if someone here has an AllegroGL CVS archive that's ready to compile (eg. the misc generation scripts have been pre-run).

EDIT: Attached a fresh CVS checkout, should be ready to compile on MinGW. Just extract it, go into the directory, and run make or mingw32-make.

--
"Do not meddle in the affairs of cats, for they are subtle and will pee on your computer." -- Bruce Graham

Arthur Kalliokoski
Second in Command
February 2005
avatar

To kill the mouse in a Windows window, there's some ShowMouse(0) or am I confusing it with allegro? I have a pretty good win32 help file from
ftp://ftp.cs.virginia.edu/pub/lcc-win32/win32hlp.exe
that has a lot of Direct X and OpenGL stuff in it as well as the usual Windows stuff.

They all watch too much MSNBC... they get ideas.

Member #4,675
June 2004
avatar

Wow, thank you all for these friendly advices.
Now I'm going to try out all that stuff.

Go to: