VOGONS


First post, by Bitou

User metadata
Rank Newbie
Rank
Newbie

Hello,

I have just installed DosBox 0.73, but when I launch it, I cannot type anything in the DOS window. It is just as if I had no keyboard at all. Is this a known bug ? Or I am missing something with the configuration ? I am running Windows Seven x64.

Reply 1 of 3, by Bitou

User metadata
Rank Newbie
Rank
Newbie

I built the code and found in sdlmain.cpp a block of code that makes DosBox behaving crazily about keyboard events.

if (getenv("SDL_VIDEODRIVER")==NULL) {
if (SDL_VideoDriverName(sdl_drv_name,128)!=NULL) {
sdl.using_windib=false;
if (strcmp(sdl_drv_name,"directx")!=0) {
SDL_QuitSubSystem(SDL_INIT_VIDEO);
putenv("SDL_VIDEODRIVER=directx");
if (SDL_InitSubSystem(SDL_INIT_VIDEO)<0) {
putenv("SDL_VIDEODRIVER=windib");
if (SDL_InitSubSystem(SDL_INIT_VIDEO)<0) E_Exit("Can't init SDL Video %s",SDL_GetError());
sdl.using_windib=true;
}
}
}

If I remove this block, I get everything working. That's a first clue.

Reply 2 of 3, by DosFreak

User metadata
Rank l33t++
Rank
l33t++

Try setting SDL_Videodriver=windib variable before starting DOSBox.

That will probably fix you're keyboard issue.

Removing the above code probably does the same thing. (DOSBox tries to force DirectX whereas SDL default is to use WINDIB)

Last edited by DosFreak on 2009-12-22, 21:48. Edited 1 time in total.

How To Ask Questions The Smart Way
Make your games work offline

Reply 3 of 3, by Bitou

User metadata
Rank Newbie
Rank
Newbie

Indeed, setting SDL_VIDEODRIVER=windib before running DosBox works. It will be a good workaround until I find the root cause (SDL ? x64 drivers ?).