04 June 2016, 18:49 | #21 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
I'm using an old version 2.3.3 but I just tried latest 3.2.2 and get the same result.
|
04 June 2016, 18:59 | #22 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,504
|
It was already answered. It uses BLTCDAT which is uninitialized. (=garbage depends on KS version and what you did before you run the code)
|
04 June 2016, 19:10 | #23 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
Oh, so you're saying I should change the function to include BLTCDAT initialization like this?
BlitFillVertical: bsr BlitWait move.w d2,BLTAMOD(a5) ;set modulo A move.w d2,BLTCMOD(a5) ;set modulo C move.w d2,BLTDMOD(a5) ;set modulo D move.w #0,BLTADAT(a5) move.w #0,BLTCDAT(a5) move.w #0,BLTDDAT(a5) move.w #SRCA|SRCC|DEST|A_XOR_C,BLTCON0(a5) move.w #0,BLTCON1(a5) ;fill mode move.l #-1,BLTAFWM(a5) move.l a0,BLTAPT(a5) ;source A add.l d1,a0 move.l a0,BLTCPT(a5) ;source C move.l a0,BLTDPT(a5) ;destination D move.w d0,BLTSIZE(a5) rts |
06 June 2016, 11:25 | #24 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
My minterm is $5a by the way, which I believe to be correct.
|
06 June 2016, 12:52 | #25 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,504
|
Something like that. Probably. I will only debug existing binary code
|
06 June 2016, 13:41 | #26 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
Heh - fair enough!
|
08 June 2016, 15:09 | #27 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
Found the problem!
A_XOR_C EQU NABC|ABNC | NANBC|ANBNC Can you see the mistake? |
08 June 2016, 17:31 | #28 |
move.l #$c0ff33,throat
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
|
|
09 June 2016, 20:29 | #29 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
Thanks StingRay for pointing out that the minterm wasn't compiled correctly because of the space between the constants!
...thanks to everyone else as well! |
09 June 2016, 23:30 | #30 |
Join Date: Jul 2008
Location: Sweden
Posts: 2,269
|
If your assembler gives you a different result when adding a space in there, you need to find a better assembler
|
11 June 2016, 10:55 | #31 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
Too right!!!
|
12 June 2016, 06:31 | #32 |
Registered User
Join Date: Feb 2011
Location: Italy/Rome
Posts: 2,281
|
what would be the advantage to have vertical fill?
|
12 June 2016, 10:30 | #33 |
Registered User
Join Date: May 2016
Location: London
Posts: 14
|
As Dan said, you can do huge sin scrollers
|
16 November 2017, 21:55 | #34 |
tulou
Join Date: Jun 2006
Location: Gothenburg / Sweden
Posts: 88
|
I'm trying to realize the following function using the blitter. It effectively fills one 16-bit column of a 28-byte wide bitmap. The height is 256 rows.
This loop does the job: Code:
eor.w d0,(a0) ; first row move.w #HEIGHT-2,d1 .loop move.w (a0),d0 lea 28(a0),a0 eor.w d0,(a0) dbf d1,.loop Code:
move.w #$0b5a,bltcon0(a1) ; D = A~C + ~AC move.w #$0000,bltcon1(a1) move.w #$ffff,bltafwm(a1) move.w #$ffff,bltalwm(a1) move.w #26,bltamod(a1) move.w #26,bltcmod(a1) move.w #26,bltdmod(a1) move.l a0,bltapt(a1) lea 28(a0),a0 move.l a0,bltcpt(a1) move.l a0,bltdpt(a1) move.w #64*(HEIGHT-1)+1,bltsize(a1) I have some very similar code to clear the very same area, and that works just fine. Code:
move.w #$01f0,bltcon0(a1) ; D = A~C + ~AC move.w #$0000,bltcon1(a1) move.w #$ffff,bltafwm(a1) move.w #$ffff,bltalwm(a1) move.w (a0),bltadat(a1) move.w #26,bltdmod(a1) lea 28(a0),a0 move.l a0,bltdpt(a1) move.w #64*(HEIGHT-1)+1,bltsize(a1) I'm banging my head against the wall here. |
16 November 2017, 22:31 | #35 |
tulou
Join Date: Jun 2006
Location: Gothenburg / Sweden
Posts: 88
|
I believe I figured it out. Due to pipelining in the blitter, the sources are fetched twice before the destination is written. Effectively making it impossible to do vertical fill on just one column.
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Blitter fill timing | leonard | Coders. Asm / Hardware | 42 | 01 September 2014 11:00 |
Clipping line for blitter fill | leonard | Coders. Asm / Hardware | 12 | 27 April 2013 12:03 |
80 GB HD to fill! | fatboy | Amiga scene | 16 | 20 July 2011 14:13 |
Sector fill pattern | absence | Coders. General | 7 | 21 March 2009 21:50 |
Fill 'em | Tim Janssen | request.Old Rare Games | 1 | 27 June 2003 09:25 |
|
|