home *** CD-ROM | disk | FTP | other *** search
- Path: ifi.uio.no!usenet
- From: ludvigp@ifi.uio.no (Ludvig Pedersen)
- Newsgroups: comp.sys.amiga.programmer
- Subject: Re: doubling pixels horizontally
- Date: 18 Feb 1996 14:09:00 GMT
- Organization: Dept. of Informatics, University of Oslo, Norway
- Message-ID: <3764.6622T781T478@ifi.uio.no>
- References: <4f4ibc$gl9@news.cs.tu-berlin.de> <591.6610T1165T2102@login.eunet.no><1045.6611T753T2256@vip.cybercity.dk><4faoe1$47@sunsystem5.informatik.tu-muenchen.de><2991.6612T1034T625@vip.cybercity.dk><576.6613T1070T1730@login.eunet.no><1257.6614T57T922@vip.cybercity.dk><1225.6615T1229T800@login.eunet.no><1140.6616T51T1538@vip.cybercity.dk>
- <1982.6617T1096T103@ifi.uio.no> <2175.6620T1429T2950@vip.cybercity.dk>
- NNTP-Posting-Host: gymir.ifi.uio.no
- X-Newsreader: THOR 2.22 (Amiga;TCP/IP)
-
- >> He was the first to use sprite-dither!
- >> He used a SCRAMBLED buffer and the source code was extremly hard to
- >> understand. (In my opinion this was the worst source I have ever seen!)
- >Yeah... that source was not to clever, but I used it to get information about
- >AGA 64bit sprites (and what a hard work that was).
- No the source was kind of weird, several asm-instructions on the same line
- etc! :)
-
- >> Anyway, I was inspired by the sprite-dither (A great idea!). This enabled
- >> the c2p to have faster frame rate and less computations.
- >> So I wrote a new and faster routine using a LINEAR buffer.
- >Interesting ;) Do you by LINEAR mean non-scrabled? Or do you mean linear
- >blits so one don't have to do so many blits (I use 6)?
- I mean a non-scrambled chunky buffer ofcourse.
-
- BTW: I use 4 blits.
-
- >> This routine was released here at "comp.sys.amiga.programmer"
- >I was not around at the time. So please if somebody e-mail it to me or tell
- >me where to get it.
- Kind of hard, because I don't have that old source anymore. :(
-
- But if you just wait a little I'll release the new version.
- Maybe I'll write a short doc today!
-
- >> Anyway, some time ago some friends of mine and I rewrote the algorithm.
- >> And made the code 30-40% faster. Now it is just as fast as to copy
- >> 5120 (160*128/4) longwords to chipram. (Try to beat that!)
- >Then you can't do a hole blitter pass. Are you using the blitter???
- Maybe it was a little unclear? The CPU-2-passes code is now 40% faster than
- in the first version. So there is much *more* time for *rendering*.
- (I don't care much about how much time the blitter uses as long as it
- finishes it work in less than a frame!)
-
- Mine current routine is using 48 cycles on 2 passes.
-
- move.l #160*128/8-1,d7
-
- Loop:
- move.l (a0)+,d0 ;Linear Chunky buffer
- move.l (a0)+,d1
-
- <2 passes = 48 cycles>
-
- move.l d0,(a1)+ ;chipram
- move.l d2,(a1)+
-
- dbra d7,Loop
-
- As you probably have noticed the example is not optimised for memory-access,
- but the purpose was just to show what I meant by 48 cycles.
-
- My old version which was released used 78 cycles.
-
- How fast are your CPU-passes anyway?
-
- >> It still uses a LINEAR buffer and can have a maximum framerate of 50 fps.
- >Is that for 20480 pixels? Because then it is almost the same as the old one.
- Yes it is 20480 chunky pixels. And Yes it not much different from the first
- version (well the algo is different!). But the CPU passes is much faster now
- so there is more time for rendering. Which is what we want! :-)
-
- >> I have also made a version without sprite-dither with the same algorithm.
- >> However this one can only have a framerate of 25 fps. But it uses no more
- >> CPU time. So its good for more complex rendering.
- >> We plan to release this routine as soon as possible. The only thing we need
- >> is a doc file! :-/
- >> BTW:
- >> I have also tried to write this routine as system-friendly as possible by
- >> using QBlit for the blitterpasses.
- >Yeah... I'm also trying to make everything as systemfriendly as posible.
- >I have tryed out system copperlists and I will make intuition screen version
- >of the blitterscreen (this will ofcause only work on AGA screens).
-
- How are you going to handle 64 pixels width sprites?
-
- What about double pixel height?
-
- What about multisync?
-
- Intuition screens are often promoted to another screenmodes.
-
- Have you thought about that the modulo registers work different in
- scandoubling modes like DBLPAL, DBLNTSC?
-
- There is a lot of things to think about! :(
-
- But it is possible more or less system-friendly. I'm finished a version
- without sprite dithering a copple of days ago.
-
-
-
-
- <sb>Ludde - Amiga Demo Coder
- <sb>Virtual Reality & Official Be developer
- <sb>ludvigp@ifi.uio.no
-
-