delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/02/02/19:48:24

From: Shawn Hargreaves <Shawn AT talula DOT demon DOT co DOT uk>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Modex Scrolling
Date: Mon, 2 Feb 1998 19:37:25 +0000
Organization: None
Distribution: world
Message-ID: <Xnl29aA1Bi10EwB4@talula.demon.co.uk>
References: <34D553B3 DOT 552 AT mailexcite DOT com>
NNTP-Posting-Host: talula.demon.co.uk
MIME-Version: 1.0
Lines: 16
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

BlueShade writes:
>I have been fooling around trying to write my own ModeX graphics
>library, but I can't get scrolling to work.  Vertical is scrolling is
>pretty self-explanatory, but I can't figure out how to do horizontal. 

Horizontal and vertical scrolling work in exactly the same way, just
using different offsets from the start of the video memory. Put the high
sixteen bits of the address into port 0x3D4 registers 0xC and 0xD, and
the low two bits into the pelpan register (port 0x3C0 register 0x33).
See the Allegro modex.c file for a working example, or one of the many
mode-X related documents on x2ftp.


--
Shawn Hargreaves - shawn AT talula DOT demon DOT co DOT uk - http://www.talula.demon.co.uk/
"Pigs use it for a tambourine" - Frank Zappa

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019