VOGONS


First post, by thp

User metadata
Rank Member
Rank
Member

I noticed this week that some VGA chipsets seem to have a problem outputting the 320x240 resolution of VGA Mode X (tweaked mode 0x13) and display the mode as 320x200 instead, cutting off the bottom 40 pixel rows.

In my case, a "VIA/S3G UniChrome Pro IGP" seems to have this bug. With the same monitor (initially I thought it could be an issue with the monitor I'm using), a GeForce GTX960 doesn't have the same issue, and displays Mode X correctly. Also, VESA modes such as 640x480x8bpp (mode 0x101) are not affected in this particular case and work just fine without any cropping.

First I thought it was my cargo-culted Mode X modesetting code, but then I tried "VGATEST" and it had the same issue.

VGATEST source: https://github.com/barotto/VGATEST
VGATEST binaries: https://github.com/barotto/VGATEST/releases/tag/v1.4

For VGATEST, if you want to test on your card and report your findings:

* Run `VGATEST.EXE`
* Press "g" for graphics
* Press "c" for circles
* Enter "18" for Mode X

If the outermost circle is fully visible top-to-bottom, your card doesn't have the issue. However, if the outermost circle is cut off at the bottom (it intersects with the bottom edge of the screen at ~ 1/5 of the screen on the left and right side), you might also have this issue. The same issue can be tested with e.g. "Quake" (Shareware) and setting its mode to 320x240 (note the text will fit, but the "status bar" at the bottom will be cut off).

Also, in my particular case, the card didn't advertise supporting a 320x240x8bpp VESA mode, which can be checked with "VESACHK.EXE"'s output from here: https://www.orbitals.com/cp/vesa.html

I tried searching online if such a list already exists, but apart from https://gona.mactar.hu/DOS_TESTS/ (which deals with VGA issues in general) I couldn't find any specific information about this particular issue -- any pointers welcome 😀

It might be interesting to know if this is just an issue specific to my S3 UniChrome Pro graphics card (so maybe test with "weird" cards, niche-vendor IGPs, and also post-DOS-era cards?), or if it's a more widespread compatibility issue, so feel free to post the VGA card you tested and if you are experiencing

Last edited by thp on 2023-06-26, 09:40. Edited 1 time in total.

Reply 1 of 5, by Tom..

User metadata
Rank Newbie
Rank
Newbie

I did some tests with these settings:

* Run `VGATEST.EXE`
* Press "g" for graphics
* Press "c" for circles
* Enter "18" for Mode X

GeForce 2 mx 200 , Win XP SP3 , ForceWare 52.16

Geforce-2mx200-52-16-xp.jpg

GeForce 6600GT , WinXP SP3 , ForceWare 175.19

Ge-Force-6600-Gt-175-19-xp.jpg

Radeon 9550 , Win XP SP3 , Catalyst 4.11

Radeon-9550-catalyst-4-11-xp.jpg

Radeon 9800 Pro , Win XP SP3 , Catalyst 7.3

Radeon-9800-PRO-catalyst-7-3-xp.jpg

PCI MACH 64 VT , Win 98 SE

Mach64-vt.jpg

I don't know if these tests will be helpful..

Reply 2 of 5, by thp

User metadata
Rank Member
Rank
Member
Tom.. wrote on 2022-09-05, 16:01:

I did some tests with these settings:

...

I don't know if these tests will be helpful..

Thanks! Seems like all your cards support Mode X properly. Interestingly, some cards have broken fonts. I haven't checked if VGATEST reads font data from the VGA font ROM or how it does it, maybe that's just missing in those cards?

Reply 3 of 5, by thp

User metadata
Rank Member
Rank
Member

So I've tested this a bit more on the same machine I've experienced this bug initially, and found a page with games using non-standard VGA modes (interestingly, I thought Mode X was much mode wide-spread): https://www.classicdosgames.com/video/vgans.html

Shareware Mode X at 320x240 games that are affected on the Via/S3 UniChrome Pro (both VGA and DVI output are affected):

  • Starfire by Silver Lightning Software (320x240x256c)
  • The Jelly Bean Factory by Summit Software (320x240x256c)

Again, VESA modes are not affected, the UniChrome Pro here has the following info (info extracted via vesamod + vesainfo from here):

OEM String: "VIA P4N800 PRO" (this is probably this card on vgamuseum)

Available modes:

257:  640: 640x 480 Pl:1 Bt:8 Md: 4 P:101 RM:0 RF:0 GM:0 GF:0 BM:0 BF:0 Rs:0 Rp:0
259: 800: 800x 600 Pl:1 Bt:8 Md: 4 P:63 RM:0 RF:0 GM:0 GF:0 BM:0 BF:0 Rs:0 Rp:0
261: 1024:1024x 768 Pl:1 Bt:8 Md: 4 P:41 RM:0 RF:0 GM:0 GF:0 BM:0 BF:0 Rs:0 Rp:0
263: 1280:1280x1024 Pl:1 Bt:8 Md: 4 P:24 RM:0 RF:0 GM:0 GF:0 BM:0 BF:0 Rs:0 Rp:0
273: 1280: 640x 480 Pl:1 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

The machine is fast enough that any Mode X game ought to run "just fine" on DOSBox running inside Windows or Linux, but it's interesting that late VGA chipsets might not support Mode X fully (while supporting VESA modes just fine out-of-the-box).

Reply 5 of 5, by thp

User metadata
Rank Member
Rank
Member

After some investigation, it turned out to most likely have been a VGA BIOS bug. The same bug also caused the Windows 98 driver to not work correctly. Somebody created a custom BIOS that injects an old version of the VGA BIOS, and flashing the custom BIOS this seems to fix - among other things - Mode X display output via VGA (while disabling DVI, which I can live with in this case).

The BIOS in question is here: https://www.philscomputerlab.com/wortmann-ter … ek-tk-3772.html