🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.amiga.tech
Article #10937

Re: Unsupported Programming Practices

#10937
From: Wayne Knapp
Date: Thu, 12 Jan 1989 19:08
35 lines
2044 bytes
In article <13389@cup.portal.com>, chad@cup.portal.com (Chad The-Walrus Netzer) writes:
.     This is the reason why you MUST use OwnBlitter() first!  The order of the
. calls is always:
. 	1) OwnBlitter();
. 	2) WaitBlit();
.     ...assuming you want to do your own mucking around with the blitter.  Of
. course, in some instances you may want to call only WaitBlit() by itself, or
. only OwnBlitter() by itself, although the first case is probably rare, and the
. second case is even rarer.
.     In general, when doing your own Blitter manipulations, you should do all
. your calculations for the Blitter registers, get control of the Blitter (via
. OwnBlitter(), then WaitBlit()), stuff the registers with you're values as
. quickly as possible, start the blit (by filling the size register last), and
. DisownBlitter() right away.  If you need to read the BZERO flag in DMACONR,
. then do a WaitBlit() and copy the register value somewhere before the
. DisownBlitter() call.
.     Doing all this will not only make the Blitter routine work correctly, it
. will also make it efficient.  Remember, Be Kind to Your Blitter!

Actually I prefer:
           
          MyBlitRoutine( ...)
            ...
          { 
               OwnBlitter();
               Compute blitter register values  /* let Blitter still run */ 
               WaitBlit();
               set blitter registers.
               DisownBlitter();
          }

One main point to remember is that very few ROM-kernal routines work between
the OwnBlitter and DisownBlitter() calls.

                                       Wayne Knapp 
Technical Details
Message-ID: <3669@tekig5.PEN.TEK.COM>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!tektronix!tekig5!wayneck
References: <8901060406.AA22607@postgres.Berkeley.EDU> <84277@sun.uucp> <13389@cup.portal.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!tektronix!tekig5!wayneck
From: wayneck@tekig5.PEN.TEK.COM (Wayne Knapp)
Newsgroups: comp.sys.amiga.tech
Subject: Re: Unsupported Programming Practices
Message-ID: <3669@tekig5.PEN.TEK.COM>
Date: 12 Jan 89 19:08:01 GMT
References: <8901060406.AA22607@postgres.Berkeley.EDU> <84277@sun.uucp> <13389@cup.portal.com>
Organization: Tektronix Inc., Beaverton, Or.
Lines: 35