From: Neil R. <ne...@co...> - 2003-09-29 03:24:54
|
Lee wrote: >Hello, > >I've been using Allegro version 4.0.2 with DJGPP version 2.03 in windows 98 >for a number of applications without problems until I tried running my >application on this one machine. It's a Compaq Deskpro and uses an Intel >810 Video chipset, and when I try to get allegro to come up in 1280x1024 >mode, it comes up in what looks like 320x320. The init code, which works >fine on other machines is: > > allegro_init(); > install_keyboard(); > install_timer(); > > rest(500); > > if (set_gfx_mode(GFX_SAFE, 1280, 1024, 0, 0) != 0) > { > set_gfx_mode(GFX_TEXT, 0, 0, 0, 0); > allegro_message("Unable to set any graphic mode\n%s\n", allegro_error); > return 1; > } > >One interesting thing that happened when I loaded win98 on this box is that >when windows came up originally in 640x480 and I went to increase the >resolution >in the control panel, the only choices were 640x480 16 color and 640x480 2 >color. >I went to the web and downloaded new drivers and that problem was solved. I >can >now set the windows resolution to 1024x768 or 1280x1024 and it works fine, >but >allegro won't work at 1280x1024 (it does work at 1024x768). > >If anyone can shed some light on this, it would sure be appreciated. > >Thanks in advance. > > You should switch to the MinGW compiler, it works like DJGPP does except it is for Windows and generates proper windows code. Also, if you compile your Allegro project with MinGW than Allegro will be using Windows DirectX code and your probabem will be solved (if the resolution workes in windows, it will work with a MinGW compiled allegro program). You compile the same way with mingw as you do with djgpp... You should also check the colours you are using. I don't know if your example above is from your actual code or not. Your card may not support the resolution you want with the number of colours you want. Also, a windows driver allowing windows to use a certain resolution won't effect your program, because you are using DJGPP so your program is a DOS application and may be limited by the video card's VESA implementation. -- Neil Roy - http://home.cogeco.ca/~nroy15 "O that there were such an heart in them, that they would fear me, and keep all my commandments always, that it might be well with them, and with their children for ever!" - Deuteronomy 5:29 |