Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!agate!e260-3f.berkeley.edu!labc-3dc From: labc-3dc@e260-3f.berkeley.edu (Andy McFadden) Newsgroups: comp.sys.apple Subject: Re: 3-D vector graphics in assembly Summary: okay... Message-ID: <23551@agate.BERKELEY.EDU> Date: 25 Apr 89 02:33:32 GMT References: <8904220157.AA04218@amethyst> Sender: usenet@agate.BERKELEY.EDU Organization: University of California, Berkeley Lines: 23 In article <8904220157.AA04218@amethyst> hentosh@amethyst.bucknell.EDU writes: [chop chop] >I don't know what routines applesoft uses to draw a line, but a fast one I >know is to take the end point and subtract the other end point from it. [description of algorithm] I tried this once. It wound up being slightly slower than Applesoft, because I was using lookup tables... the fastest way to go about it seems to be this algorithm, doing some fancy calculations to get the next bit/line position. Probably the fastest way is to have 8 subroutines, one for movement in any given direction. Woz's routines (source can be found in the Programmer's Assitant #1 manual, along with the code relocator source, etc) manage to pull this off on an 8-bit computer, but bear a strong resemblance to spaghetti. Since the hires screen is non-linear, the computations involved are a little weird. >-- InterNet: hentosh@amethyst.bucknell.edu | 'Ever have deja vu and amnesia -- fadden@cory.berkeley.edu (Andy McFadden) ...!ucbvax!cory!fadden labc-3dc@widow.berkeley.edu