VOGONS


First post, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

graphics optimizations:
bitumove: 128 bit blit
modeoperation: skips calculation if same as last pixel (this speeds up this function 3x in wolf3d for example)
writehandler: inlining of the first invocation

http://sourceforge.net/tracker/index.php?func … 551&atid=467234

autocycle:
no more skips or lag from cycle transitions(prior, wasn't usable on my system)
displays current cycles(instead of "auto") & framerate once a second
for cycles set to a specific count, cycles auto adjust up to that count.
use for programs that need a specfic cycle setting so as to not run too fast but still adjusts cycles downward when cpu load is exceeded or to reduce cpu load. Set large enough it essentially mimics autocycle.

http://sourceforge.net/tracker/index.php?func … 551&atid=467234

edit: added autocycle patch.
edit: grab graphicsopt2.diff to avoid issue discussed in the thread. But if you want to check out the buggy changes, knock yourself out with graphicsopt.diff;)
edit: cleaned up autocycle.diff, it had a part of the graphicsopt changes ini it. attached is autocycledlean.diff

Attachments

  • Filename
    autocycleclean.diff
    File size
    8.07 KiB
    Downloads
    239 downloads
    File license
    Fair use/fair dealing exception
  • Filename
    autocycle.diff
    File size
    10.39 KiB
    Downloads
    233 downloads
    File license
    Fair use/fair dealing exception
  • Filename
    graphicsopt.diff
    File size
    12.82 KiB
    Downloads
    245 downloads
    File license
    Fair use/fair dealing exception
Last edited by ih8registrations on 2006-06-04, 20:47. Edited 4 times in total.

Reply 1 of 44, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

Executable for those who want a look-see without compiling.

Attachments

  • Filename
    dosbox.rar
    File size
    2.87 MiB
    Downloads
    253 downloads
    File license
    Fair use/fair dealing exception

Reply 3 of 44, by Spooon69

User metadata
Rank Newbie
Rank
Newbie

I downloaded this for the autocycle feature (max limit and display) because of the sound problems in the official version. This patch definitely helps as long as you set the limit correctly. Thanks and I hope this gets integrated into official!

Reply 5 of 44, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

If you're using the exe, it may be some other changes that are in the build I'm working on that's not in the patch. But perhaps bitumove.

Last edited by ih8registrations on 2006-06-04, 17:23. Edited 1 time in total.

Reply 7 of 44, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

Actually those changes did sneak into the patch, and are the cause of the bug. If you replace render_loops.h with that from cvs, you should be good to go.

I've attached a diff sans changes to render_loops.h

That said, I did find one game that has trouble with the modeop optimization; tornado. More bug squashing to do.

Attachments

  • Filename
    graphicsopt2.diff
    File size
    11.09 KiB
    Downloads
    210 downloads
    File license
    Fair use/fair dealing exception

Reply 12 of 44, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

I figured it out; needed to include vga.latch.d in the dirty check.

Fixed tornado. Check it against Prehistorik 2 and bumpy.

Attachments

  • Filename
    graphicsopt3.diff
    File size
    12.21 KiB
    Downloads
    219 downloads
    File license
    Fair use/fair dealing exception

Reply 13 of 44, by wd

User metadata
Rank DOSBox Author
Rank
DOSBox Author

Any big games that you tested the graphicsopt with? As most of those
(like Quake) use linear access to the graphics memory (mode13/vesa),
i didn't notice any speed gain. Suppose mode12-like games would
benefit from it, or tweaked-mode?

Reply 14 of 44, by ih8registrations

User metadata
Rank Oldbie
Rank
Oldbie

If you look at vga_memory, you'll notice modeoperation is only used by unchained vga(aka tweaked vga at mobygames), and chained/unchained ega modes. Even though wolf3d isn't one of the big games, it runs like a dog and modeoperation is one of its big-o calls, which is what led me to optimizing it. The most efficient is LFB, which does straight array accesses. I think games like quake use the map handler if not LFB. Just to reiterate, it's a 3x speed up just for that function(as shown by gprof), for wolf3d. For other games it will vary. Feh, I still get lost with c++'s inheritance so others may be using the writehandlers that call modeoperation.

Last edited by ih8registrations on 2006-06-06, 15:25. Edited 4 times in total.

Reply 15 of 44, by SysGOD

User metadata
Rank Member
Rank
Member

ive tested some SVGA games (Z, Quarantine 2, Exhumed, Hioctane, Rise of the Robots...) with your optimizations for some days now.

Z runs like a dream on my system, no sound stuttering with dynamic core above 60000 cycles anymore. also hioctane seems to benefit from the optimizations.

but quarantine 2 is unplayable. gamespeed goes from high to very slow all the time in hires. screen tearing and sound stuttering also. ive tryed many different settings without any better results.

Last edited by SysGOD on 2006-06-06, 15:46. Edited 1 time in total.

Reply 16 of 44, by ykhwong

User metadata
Rank Oldbie
Rank
Oldbie

SysGOD, if I am right, you applied svga patch, right?
Did you modify some lines in graphicsopt patch against SVGA patch?

ih8registrations, the third patch made the screen of prehistorik 2 much worse. There's still a bug in bumpy.

Reply 17 of 44, by SysGOD

User metadata
Rank Member
Rank
Member

SysGOD, if I am right, you applied svga patch, right?

no iam only using the precompiled dosbox.exe for now.
dont have any compilers on my system yet...

maybe ih8registrations has some other things changed in his .exe, i dont know.