The SDL forums have moved to discourse.libsdl.org.
This is just a read-only archive of the previous forums, to keep old links working.


SDL Forum Index
SDL
Simple Directmedia Layer Forums
SDL and Vista, computer freezes after input
jake
Guest

Hi everyone,

I just got Windows Vista and I have noticed that when running a program with
SDL, the program runs fine until I press a key, and then it freezes completely.
However, if I run right-click on the executable and set the compatibility mode
to Windows Server 2003, Windows 98/Windows ME, or Windows 95, it works fine
(but not Windows XP (SP2), Windows 2000, or Windows NT 4.0 (SP5)... all of these
compatibility modes freeze on key input as well). The programs use SDL
versions 1.2.5 to 1.2.7.

Has anyone else reported anything like this before? I've scoured the web, and
can't seem to find any others posting about this problem. Is this a Vista
problem? Is SDL still using DirectInput for input? -- I didn't find any
references to DirectInput on my quick skim of the source code. Have there been
any other concerns for development on the Vista OS?

Thanks a bunch,

Jake
SDL and Vista, computer freezes after input
Sam Lantinga
Guest

Quote:
I just got Windows Vista and I have noticed that when running a program with
SDL, the program runs fine until I press a key, and then it freezes completely.
However, if I run right-click on the executable and set the compatibility mode
to Windows Server 2003, Windows 98/Windows ME, or Windows 95, it works fine
(but not Windows XP (SP2), Windows 2000, or Windows NT 4.0 (SP5)... all of these
compatibility modes freeze on key input as well). The programs use SDL
versions 1.2.5 to 1.2.7.

Try this:
http://www.libsdl.org/tmp/SDL-1.2.12-win32.zip

I've had no trouble with this under Windows Vista.

-Sam Lantinga, Lead Software Engineer, Blizzard Entertainment
SDL and Vista, computer freezes after input
jake
Guest

Sam Lantinga <slouken <at> devolution.com> writes:

Quote:

Quote:
I just got Windows Vista and I have noticed that when running a program with
SDL, the program runs fine until I press a key, and then it freezes
completely.
Quote:
Quote:
However, if I run right-click on the executable and set the compatibility
mode
Quote:
Quote:
to Windows Server 2003, Windows 98/Windows ME, or Windows 95, it works fine
(but not Windows XP (SP2), Windows 2000, or Windows NT 4.0 (SP5)... all of
these
Quote:
Quote:
compatibility modes freeze on key input as well). The programs use SDL
versions 1.2.5 to 1.2.7.

Try this:
http://www.libsdl.org/tmp/SDL-1.2.12-win32.zip

I've had no trouble with this under Windows Vista.

-Sam Lantinga, Lead Software Engineer, Blizzard Entertainment



I've compiled my program using SDL 1.2.11, and tried swapping in the 1.2.12 dll
that Sam suggested, but I'm still getting the freeze issue on keypress.
I'll try compiling my program with the SDL source so that I can debug it and
find out where it's getting hung up. I'll post the results here shortly.
Thanks,
Jake
SDL and Vista, computer freezes after input
jake
Guest

jake <jakob.parks <at> gmail.com> writes:


After some analysis, here's what I've found.
1) The program freezing only effects windowed programs, not fullscreen.

2) Setting a breakpoint at the message pump (DIB_PumpEvents()) or message
handler (WinMessage()) does not catch the key message before it freezes.

3) If you breakpoint the SDL in the WinMessage() function when Windows receives
the WM_ACTIVATE message, and then press F5 to run the rest of the program, SDL
will catch the release of the F5 key and the program will work as normal (no
input freezes, hooray!).
If however, you reactivate the program by using the
mouse (clicking on Debug->Continue in Visual Studio), the program will never
receive an input message and still freezes on first keypress.

Sounds like if the program receives keyboard input before some crucial process
happens, everything runs fine.

This is my first time looking at SDL, so I'm still learning the interactions of
the modules.
But, I have to say: Kudos to the authors. Damn this thing is
well-written.

Any ideas?

Jake
SDL and Vista, computer freezes after input
Paul Duffy
Guest

On Wed, 2007-07-18 at 21:38 +0000, jake wrote:
Quote:
jake <jakob.parks <at> gmail.com> writes:



Assuming you're using SDL 1.2.11, this is a known and high priority bug.
I believe the very-soon-to-be-released 1.2.12 will fix this.



___________________________________________________________
The all-new Yahoo! Mail goes wherever you go - free your email address from your Internet provider. http://uk.docs.yahoo.com/nowyoucan.html