VOGONS

Common searches


Reply 180 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

I've found what was causing crash in one of WHATVGA modes with the latest version of my patch. The bug is not in the patch, it was just hidden before. In vga_draw function VGA_Draw_VGA_Line (EGA_Line as well) is overoptimized. There are some conditions when the returned address may be outside of allocated video memory. What's worse, the returned address may be inside the allocation but the line does not fit and there is no way scalers can wrap around properly. The reason it was triggered after my latest changes was that before there was enough memory allocated after needed video memory. So, the logic was still wrong but the crash was hidden. Not that there are many cases when the crash can happen but this needs to be fixed. The next version of the patch will have the fix.

EDIT: Fixing this issue has interesting side effect of fixing New Age Warrior. That game has been in the list of broken games for some time. It does not fix it in S3 mode but now I strongly suspect that the game does not run on real S3 either.

Reply 181 of 343, by rcblanke

User metadata
Rank Oldbie
Rank
Oldbie

Hi there,

Thanks for your hard work Vasyl!
Would you be so kind to test if the current CVS has correctly incorporated your fix for LodeRunner, because for me the fix does not seem to work??! I've tried both ykhwong's version and compiled my own straight from CVS, but they seem to behave exactly the same as 0.63. I must be missing something here...
Thanks in advance,

Ronald

Reply 183 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

rcblanke: Looks like I've missed something with my patch. It is correct but incomplete still. Back to the drawing board. Sorry about that.
DosFreak: Thanks for the suggestion. I rarely use VPC with games lately, only for sandboxing. At your suggestion I've tried it and that game works, kind of. I would not call that smooth scrolling in any case. The emulated card is S3 but it does not appear to be the same S3 so it may have better VGA compatibility. Another possibility is that "our" S3 has some memory extension enabled which was supposed to be disabled by default. If it is the case, I will find it. Broken address wrapping has to be fixed in any case.

Reply 184 of 343, by DosFreak

User metadata
Rank l33t++
Rank
l33t++

I believe Ben Armstrong from the VPC team has the original hardware that VPC emulates. He may have the card that DosBox uses laying around. I'll ask him.

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

Reply 185 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

Found what I've missed in Lode Runner: The Legend Returns (did not find how I've missed it though 😊 ). Function 1123h of int 10h (load 8x8 double dot font) was not implemented. It appears that LR does not use the loaded font itself but uses font metrics... The patch is up on the Sourceforge. As usually, this change may fix some other games but I would not hold my breath -- the way LR did that was quite unorthodox.

EDIT: DosFreak: One particular item I am wondering about is CRTC register 0x31. INT10_SetVideoMode explicitly sets it to enable 256+ memory access, there is even a comment on that effect. I am not as familiar with S3 as I am with Tseng so I cannot say if it is right or not.

Reply 187 of 343, by Stevie

User metadata
Rank Newbie
Rank
Newbie

@vasyl

thats amazing how much effort you put in this thing.
i would like to thank you for that. when i started with computers, that was like 12 years ago, DOS and Windows 3.11 were around. So its really a nice flashback when im now able to play all the old games and that even in VESA mode. DOS IS ALIVE!

Thanks again!

greets stevie

Reply 188 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

You are welcome. Most work was done by other developers, I just added a few touches.
New version of the patch is up at SF. This time a few cosmetic changes: ET4k can be selected as either et4000 or et4000new, only the second one will have 1280x1024x16 mode so TLIVESA1 is usable in the other one (did they ever test that utility at Tseng Labs???); chipset can be selected from command line.
There is one major architectural change. I've added video memory address wrapping. This immediately fixed crash I had in WHATVGA with 1280x960 mode, and made New Age Warrior playable (see Broken Games thread). Probably fixed a few other scrollers as well. Caveat: NAW works only with et4k (which it recognizes) and pure VGA ("none"). Either we have broken logic in S3 emulation or that game never worked with S3. The game does not recognize the other two emulated chipsets, that's either bug in the game or my bug, I don't know yet. Starting with this version of the patch, if you have old scroller-type game that produces black screen or garbage test it first with ET4000 and if that does not work with "none."
This change should not affect performance compared to the previous version as it superseeded "bank mask" I've used for similar purpose. That mechanism was not sufficient and is completely replaced.
Address wrap can be smaller than current video memory. Eventually, I am going to implement a few chipset tricks through it (S3 limited to 256K, pure VGA limited to 64K).
I hope I did not break anything but if I did, post it here, I will fix it immediately.

Reply 190 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

I am not done yet. The latest version still did not fix all VGA scrollers. I am looking into the remaining issues and it looks like there is something wrong about chain4 implementation. Current implementation treats chain4 as linear and uses that flag to detect linear memory modes. This is fast but apparently not always correct. Let's see if I can figure out good solution (or if I understand the issue fully).

Reply 191 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

Another patch update. Fixed some minor bugs and glitches but also implemented very interesting feature. In this version VGA chain4 modes use 64K memory wrapping unless any SVGA banked memory access was detected. This completely fixes all VGA scrollers I've tried (New Age Warrior, Drive-In, Hurdles) and seems to work well regardless of chipset. It also has zero effect on performance, does not affect SVGA 256-color modes, and does not break anything in WHATVGA that worked before.
There are some things that should be explained. 64K memory wrapping in that particular mode is technically correct (remember -- 320x200 had only one display page). The need to detect banked memory access is another story. This is workaround or hack but I could not find another way of fixing the issue without breaking WHATVGA in SVGA modes. There may be better solution but I've spent considerable time reading through docs and could not find any clue.
At this point all modes work perfectly in WHATVGA with ET4000 chipset, almost perfectly with other three SVGA chipsets due to insufficient bits in display start address on those (there is a possibility that it can be fixed but it is very low priority). Mode 13h in pure VGA has some problems with the second test (always had) but I am not sure if that thing was ever tested on the real VGA -- I don't see how that test could work. I have source code but it's in Pascal and just looking at it gives me headaches. One day I will figure out this puzzle as well, for now I am quite satisfied.

Reply 193 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

BTW, the latest ykhwong's build (8/31) does not include the latest SVGA patch update so it still breaks those scrollers. Posting this just in case if somebody is using that build for testing.

Reply 195 of 343, by DosFreak

User metadata
Rank l33t++
Rank
l33t++

What's the latest ver of WhatVGA? v2.40? Is this the "best" DOS video mode testing tool?

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

Reply 197 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

ykhwong: Works fine now. Thanks for updating it so fast.
DosFreak: Good question. Mine says "version 2.00 (beta)" so yours must be newer. It's the "best" only in the sense that I did not find any better yet. It does test very basic functionality (chipset id, mode switch, bank/ram access) but can miss a lot. I'd like to see more coverage. It is also written in Pascal and the source code is just painful to read and understand.

EDIT: I've found WHATVGA 2.40 and it is quite different from 2.00 in number of ways. On the positive side -- it seems to have some issues fixed in S3 test. This version can scroll all the way down without glitches. However, pure VGA mode is actually worse than before. Instead of code that could never work it now tries something that locks emulation. It is possible that it hits one of unimplemented features in this version.

Reply 199 of 343, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

ET4000 emulation is quite decent in the current version of the patch. All software that is supposed to detect this chipset does detect it. So far, everything that I tried on it just works. There are a few unimplemented features but I could not find any game that used them. Usually, if something does not work, the issue is in the underlying VGA emulation, not in SVGA part -- not suprising considering very straightforward and clean architecture of ET4000. The other two chipsets I've added are emulated on more basic level. ET3000 emulation is almost as good as ET4000 (zoom feature is not implemented and likely never will be) but I know at least one game that does not detect it properly (could be bug in the game, though). PVGA1A emulation is very basic, just like the card itself. It definitely needs more work as I could not get Paradise own VESA driver to install.
Putting it in other terms: ET4000 - 90%, ET3000 - 75%, PVGA1A - 50%. I cannot really tell how well S3 is emulated (I did not write or modify that one) but my estimate that it is between ET3000 and ET4000. S3 chipset is significantly more complex than other three.
ET4000 drivers in Win3.1? Go ahead. All the way up to 1024x768x256. WFW 3.11 even comes with proper drivers.