TIP: Click on subject to list as thread! ANSI
echo: 80xxx
to: BRIAN MCCLOUD
from: PETER VAN HERTUM
date: 1997-03-08 15:51:00
subject: scrolling

Yo Brian McCloud,
PVH> How do I move image blocks - not with the CPU ?
PVH> With the video hardware ?
 BM> Really, you can't do it without the CPU... but I think what
 BM> you really mean here is without BIOS calls.
 ...
 BM> CX...REP MOVSW...
 ...
I did it like this :
mov ax,$a000
mov es,ax
mov ds,ax
mov si,SOURCE_ADDRESS
mov di,DESTINATION_ADDRESS
mov cx,size
***WaitForVBlank***
rep movsw
On my 100Mhz computer, this works without flicker, but in school I have
to program for a 33Mhz486 and there the deplacement can't be done within
one vblank and the result is awful.
On my 7Mhz Commodore Amiga I can scroll a whole 320*200*32c object without
flicker, 'cause there I just have to give the source, destination and size
of the object to the BLITTER (a coprocessor, optimized for block deplacement
and area filling) which works 10 times faster then the CPU.
I thought there must be a coprocessor like that on PC videocards. How else
would they move large graphical objects in games.
e.g. I ran the game 'mortal kombat' on the 33Mhz486 and it was able to
animate the two characters of almost 3/4 of screen height without flicker.
This can't be done with REP MOVSW, I think.
I'm aware of double buffering and page swapping methods, but still it's hard
to believe there's no other way than REP MOVSW...
 -=> PVH <=-
Have a nice day, Brian!
Peter Van Hertum - Brussels, Belgium, Saturday, 8 March 1997 at 15:51.
Fido : 2:291/766.176 - Internet : pvh@p176.f766.n291.z2.fidonet.org
.!. Second star to the right and straight on till morning.
--- Terminate 4.00/Pro
---------------
* Origin: PVH Mail System, Brussels, Belgium (2:291/766.176)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.