4. Rolling image on BIG copperbar

Download LHA-package.

This time we will look at the same effec as last time, but this time on a larger copperbar. When we have a larger copperbar horizontalshifting of 16px will not be sufficent. Larger shifts could be done with bitplane modulos like in the Hshift tutorials, but here we know exactly where we need to get more than 16px shifts, and the copperbars are static, so this won't change from frame to frame. When knowing this we can use an other method instead of the slightly problematic modulos. We can set the startingpoint of the bitplane rasterline earlier than the rasterline before, and thus get 16px of Hshift to the right for every word we start earlier. This is very easy to do on an Amiga, we only have to change the BPLxPTH/L, and as we have to change the Hshift value on each rasterline we already have a suitable copperlistgenerator set up, and only need to add 2 copper MOVE-statement (BPLxPTH & BPLxPTL) for each used bitplane. For this tutorial I tested different routines to get the best looking effect, this time the more matemathically correct method rendered a much worse effect. In this tutorial we just move the image upwards, and every pixelline will be rendered until it "falls off the top of the copperbar. I include an executable for the mathematically more correct version, where not evrey pixelline is rendered, but according to what part of the image should be visible when moving along a circle. The pixellines that get skipped makes the rollereffect uglier. This goes to show, that it's good to test different approaches and chose the one that works best.

 
   1 
; Copperbarscroller-2
   2 
 
   3 
DMACONR        EQU        $dff002
   4 
ADKCONR        EQU        $dff010
   5 
INTENAR        EQU        $dff01c
   6 
INTREQR        EQU        $dff01e
   7 
 
   8 
DMACON        EQU        $dff096
   9 
ADKCON        EQU        $dff09e
  10 
INTENA        EQU        $dff09a
  11 
INTREQ        EQU        $dff09c
  12 
 
  13 
    incdir "windows:amigavikke/"
  14 
 
  15 
; Optimizations could easily be made to the small/tight loops in the code by using incremental addressing 
(An)+ or decremental addressing -(An) and REPT <n> / ERPT
  16 
 
  17 
init:
  18 
; store hardware registers, store view- and copperaddresses, load blank view, wait 2x for top of frame,
 own blitter, wait for blitter AND finally forbid multitasking!
  19 
; all this just to be able to exit gracely
  20 
 
  21 
    ; store data in hardwareregisters ORed with $8000 (bit 15 is a write-set bit when values are written
 back into the system)
  22 
    move.w    DMACONR,d0
  23 
    or.w #$8000,d0
  24 
    move.w d0,olddmareq
  25 
    move.w    INTENAR,d0
  26 
    or.w #$8000,d0
  27 
    move.w d0,oldintena
  28 
    move.w    INTREQR,d0
  29 
    or.w #$8000,d0
  30 
    move.w d0,oldintreq
  31 
    move.w    ADKCONR,d0
  32 
    or.w #$8000,d0
  33 
    move.w d0,oldadkcon
  34 
 
  35 
    move.l    $4,a6                 ; execBase ==> a6
  36 
    move.l    #gfxname,a1         ; pointer to gfxname ==> a1 : used in openLibrary
  37 
    moveq    #0,d0                 ; d0 = 0 any version of graphics.library will do
  38 
    jsr    -552(a6)                ; d0 = openLibrary(a1,d0)
  39 
    move.l    d0,gfxbase             ; store the returned pointer ==> gfxbase
  40 
    move.l     d0,a6                 ; d0 ==> a6 : a6 used as addressing base below
  41 
    move.l     34(a6),oldview         ; store old Viewport
  42 
    move.l     38(a6),oldcopper     ; store old Copperlist
  43 
 
  44 
    move.l #0,a1
  45 
    jsr -222(a6)    ; LoadView
  46 
    jsr -270(a6)    ; WaitTOF
  47 
    jsr -270(a6)    ; WaitTOF
  48 
    jsr -456(a6)    ; OwnBlitter
  49 
    jsr -228(a6)    ; WaitBlit
  50 
    move.l    $4,a6
  51 
    jsr -132(a6)    ; Forbid
  52 
 
  53 
; end exit gracely preparations!
  54 
 
  55 
    ; clear Bitplanes from garbage - very slow routine! should be done with the Blitter, or unrolled loop
  56 
    move.w #352/8*200/4,d0     ; d0 is a counter for number of longwords to get cleared
  57 
    move.l #bpl0,a0     ; bpl0 => a0
  58 
    move.l #bpl1,a1     ; bpl1 => a1
  59 
    move.l #bpl2,a2     ; bpl2 => a2
  60 
    screen_clear:
  61 
        move.l #0,(a0)+    ; #0 => (a0), and increment a0 to next longword (a0=a0+4)
  62 
        move.l #0,(a1)+    ; #0 => (a1), and increment a1 to next longword (a1=a1+4)
  63 
        move.l #0,(a2)+    ; #0 => (a2), and increment a1 to next longword (a2=a2+4)
  64 
        subq.w #1,d0
  65 
        bne screen_clear
  66 
        
  67 
    ; copy bitmap to bitplanes
  68 
    move.w #352/8*200/4,d0
  69 
    move.l #bpl0,a0     ; bpl0 => a0
  70 
    move.l #bpl1,a1     ; bpl1 => a1
  71 
    move.l #bpl2,a2     ; bpl1 => a2
  72 
    move.l #img_av,a6
  73 
;    add.l #2,a6
  74 
    copy_img:
  75 
        move.l 352/8*200*2(a6),(a2)+    ; bpl2
  76 
        move.l 352/8*200*1(a6),(a1)+    ; bpl1
  77 
        move.l (a6)+,(a0)+                ; bpl0
  78 
        subq.w #1,d0
  79 
        bne copy_img
  80 
        
  81 
 
  82 
; setup displayhardware to show a 320x200px 3 bitplanes playfield, 
with zero horizontal scroll and 4 modulos
  83 
    move.w    #$3200,$dff100                ; 3 bitplane lowres
  84 
    move.w    #$0000,$dff102                ; horizontal scroll 0
  85 
    move.w    #$0002,$dff108                ; odd modulo 4
  86 
    move.w    #$0002,$dff10a                ; even modulo 4
  87 
    move.w    #$2c81,$dff08e                ; DIWSTRT - topleft corner (2c81)
  88 
    move.w    #$f4d1,$dff090                ; DIVSTOP - bottomright corner (f4d1)
  89 
    move.w    #$0030,$dff092                ; DDFSTRT - max overscan $0018
  90 
    move.w    #$00d0,$dff094                ; DDFSTOP - max overscan $00d8
  91 
    move.w     #%1000010111000000,DMACON    ; DMA set ON
  92 
    move.w     #%0000000000111111,DMACON    ; DMA set OFF
  93 
    move.w     #%1100000000000000,INTENA    ; IRQ set ON
  94 
    move.w     #%0011111111111111,INTENA    ; IRQ set OFF
  95 
 
  96 
 
  97 
mainloop:
  98 
; increase framecounter by 1
  99 
    move.l frame,d0
 100 
    addq.l #1,d0
 101 
    move.l d0,frame
 102 
 
 103 
 
 104 
; make copperlist
 105 
; doubblebuffering of copperlists, defined at copper1 and copper2, chosen by LSB in framecounter
 106 
; copper (and a6) will hold the address to the copperlist we will write to (not the one currently in use)
 107 
    and.l #1,d0
 108 
    bne usecopper2
 109 
    move.l #copper1,a6
 110 
    bra usecopper1
 111 
    usecopper2:
 112 
    move.l #copper2,a6
 113 
    usecopper1:
 114 
    move.l a6,copper
 115 
 
 116 
 
 117 
; *********************************************************
 118 
;
 119 
; 32px high copperbars for scrolling (p=32*pi ==> p~100 ==> image 100px high)
 120 
;
 121 
; *********************************************************
 122 
 
 123 
 
 124 
    move.l #$2c+$50,d2
 125 
    jsr make_Copper_scrolly
 126 
 
 127 
 
 128 
 
 129 
 
 130 
    ; end of copperlist (copperlist ALWAYS ends with WAIT $fffffffe)
 131 
    move.l #$fffffffe,(a6)+     ; end copperlist
 132 
 
 133 
testMouseButton:
 134 
    ; if mousebutton/joystick 1  or 2 pressed then exit
 135 
    btst.b #6,$bfe001
 136 
    beq exit
 137 
    btst.b #7,$bfe001
 138 
    beq exit
 139 
 
 140 
; display is ready, or atleast we have done everything we wanted and the copper continues on its own
 141 
; we have to wait for Vertical Blanking before making the next frame
 142 
 
 143 
waitVB:
 144 
    move.l $dff004,d0
 145 
    and.l #$1ff00,d0
 146 
    cmp.l #300<<8,d0
 147 
    bne waitVB
 148 
 
 149 
    ; use next copperlist - as we are using doubblebuffering on copperlists
 we now take the new one into use
 150 
    move.l copper,d0
 151 
    move.l d0,$dff080
 152 
    bra mainloop
 153 
 
 154 
exit:
 155 
; exit gracely - reverse everything done in init
 156 
    move.w #$7fff,DMACON         ; set bits[0,14] = 0 (bit15 is a set/clear bit)
 157 
    move.w    olddmareq,DMACON     ; and set bits[0,14] as they were at init
 158 
    move.w #$7fff,INTENA         ; set bits[0,14] = 0 (bit15 is a set/clear bit)
 159 
    move.w    oldintena,INTENA     ; and set bits[0,14] as they were at init
 160 
    move.w #$7fff,INTREQ         ; set bits[0,14] = 0 (bit15 is a set/clear bit)
 161 
    move.w    oldintreq,INTREQ     ; and set bits[0,14] as they were at init
 162 
    move.w #$7fff,ADKCON         ; set bits[0,14] = 0 (bit15 is a set/clear bit)
 163 
    move.w    oldadkcon,ADKCON     ; and set bits[0,14] as they were at init
 164 
 
 165 
    move.l    oldcopper,$dff080     ; load old Copperlist
 166 
    ; graphics.library calls
 167 
    move.l     gfxbase,a6     ; gfxBase ==> a6
 168 
    move.l     oldview,a1     ; oldView ==> a1 (used in LoadView)
 169 
    jsr -222(a6)        ; LoadView : load back the view at start of program
 170 
    jsr -270(a6)        ; WaitTOF : Wait for Top Of Frame to get everything synced up
 171 
    jsr -270(a6)        ; WaitTOF : (2 times for interlaced screens)
 172 
    jsr -228(a6)        ; WaitBlit : wait for Blitter to finish running task (if any)
 173 
    jsr -462(a6)        ; DisownBlitter : release Blitter to system
 174 
    ; exec.library calls
 175 
    move.l    $4,a6         ; execBase ==> a6
 176 
    move.l    gfxbase,a1     ; gfxBase ==> a1 (used in closeLibrary)
 177 
    jsr -414(a6)         ; closeLibrary : close graphics.library
 178 
    jsr -138(a6)        ; Permit multitasking
 179 
 
 180 
    ; end program
 181 
    rts
 182 
 
 183 
; subroutines
 184 
 
 185 
make_Copper_scrolly:
 186 
 
 187 
    move.l #c0,a0                 ; pointer to colortables ==> a0
 188 
    move.l #hshift,a4
 189 
    move.l #mshift,a5
 190 
    move.l #$07<<16+$fffe,d1     ; this is optimized code compared to earlier tutorials
 191 
                                ; $07<<16 = $00070000,
 192 
                                ; and then +$fffe gives $0007fffe
 193 
    lsl.l #8,d2                 ; d2 = d2 * 2^24
 194 
    lsl.l #8,d2
 195 
    lsl.l #8,d2
 196 
    add.l d2,d1                 ; add d2 to d1 ==> first time: d1 = $2c07fffe, which is:
 197 
                                ; Copper WAIT <$2c07>,<$fffe>: V:$2c & H:$07 & mask:$fffe
 198 
 
 199 
    moveq #0,d0                 ; d0 = 0
 200 
    move.w cbar_img_line1,d0     ; startingline index ==> d0
 201 
    add.w #44,d0                 ; d0 = d0 + 44 (352px/8 = 44 bytes)
 202 
    cmp.w #200*44,d0             ; compare if larger than the height of the image
 203 
    bcs .10
 204 
    sub.w #200*44,d0             ; if it is, then subract the overgoing part from it
 205 
    .10:
 206 
    move.w d0,cbar_img_line1     ; store new startingline index for next frame
 207 
 
 208 
    moveq #64,d7
 209 
    loop_cbar1:
 210 
        move.l d1,(a6)+         ; copper WAIT
 211 
        move.w #$0180,(a6)+     ; color0-
 212 
        move.w 0*128(a0),(a6)+     ;        value
 213 
        move.w #$0102,(a6)+        ; h-shift-
 214 
        move.w (a4)+,(a6)+         ;         value
 215 
 
 216 
        moveq #0,d3
 217 
        move.w (a5)+,d3
 218 
        ; bitplane 0
 219 
        move.l #bpl0,d2
 220 
        add.l d0,d2         ; add startingline index to address
 221 
        add.l d3,d2         ; add 16-bit Hshift
 222 
        move.w #$00e2,(a6)+    ; LO-bits of start of bitplane
 223 
        move.w d2,(a6)+        ; go into $dff0e2
 224 
        swap d2
 225 
        move.w #$00e0,(a6)+    ; HI-bits of start of bitplane
 226 
        move.w d2,(a6)+        ; go into $dff0e0
 227 
        
 228 
        ; bitplane 1
 229 
        move.l #bpl1,d2
 230 
        add.l d0,d2         ; add startingline index to address
 231 
        add.l d3,d2         ; add 16-bit Hshift
 232 
        move.w #$00e6,(a6)+    ; LO-bits of start of bitplane
 233 
        move.w d2,(a6)+        ; go into $dff0e6
 234 
        swap d2
 235 
        move.w #$00e4,(a6)+    ; HI-bits of start of bitplane
 236 
        move.w d2,(a6)+        ; go into $dff0e4
 237 
        
 238 
        ; bitplane 2
 239 
        move.l #bpl2,d2
 240 
        add.l d0,d2         ; add startingline index to address
 241 
        add.l d3,d2         ; add 16-bit Hshift
 242 
        move.w #$00ea,(a6)+    ; LO-bits of start of bitplane
 243 
        move.w d2,(a6)+        ; go into $dff0e6
 244 
        swap d2
 245 
        move.w #$00e8,(a6)+    ; HI-bits of start of bitplane
 246 
        move.w d2,(a6)+        ; go into $dff0e4
 247 
 
 248 
        move.w #$0182,(a6)+     ; color1-
 249 
        move.w 1*128(a0),(a6)+     ;        value
 250 
        move.w #$0184,(a6)+     ; color2-
 251 
        move.w 2*128(a0),(a6)+     ;        value
 252 
        move.w #$0186,(a6)+     ; color3-
 253 
        move.w 3*128(a0),(a6)+     ;        value
 254 
        move.w #$0188,(a6)+     ; color4-
 255 
        move.w 4*128(a0),(a6)+     ;        value
 256 
        move.w #$018a,(a6)+     ; color5-
 257 
        move.w 5*128(a0),(a6)+     ;        value
 258 
        move.w #$018c,(a6)+     ; color6-
 259 
        move.w 6*128(a0),(a6)+     ;        value
 260 
        move.w #$018e,(a6)+     ; color7-
 261 
        move.w 7*128(a0),(a6)+     ;        value
 262 
        add.l #2,a0
 263 
 
 264 
        
 265 
        add.l #1<<24,d1     ; here the optimization continues,
 266 
                            ; we know that the verticalvalues are in bits[24,31],
 267 
                            ; so we add 1*2^24 to get to the next line
 268 
 
 269 
        add.w #44,d0                 ; d0 = d0 + 44 (352px/8 = 44 bytes)
 270 
        cmp.w #200*44,d0             ; compare if larger than the height of the image
 271 
        bcs .20
 272 
        sub.w #200*44,d0             ; if it is, then subract the overgoing part from it
 273 
        .20:
 274 
 
 275 
        subq #1,d7
 276 
        bne loop_cbar1
 277 
 
 278 
    rts                     ; end subroutine and get back to main code
 279 
 
 280 
 
 281 
 
 282 
; *******************************************************************************
 283 
; *******************************************************************************
 284 
; DATA
 285 
; *******************************************************************************
 286 
; *******************************************************************************
 287 
 
 288 
 
 289 
; storage for 32-bit addresses and data
 290 
    CNOP 0,4
 291 
oldview:    dc.l 0
 292 
oldcopper:    dc.l 0
 293 
gfxbase:    dc.l 0
 294 
frame:        dc.l 0
 295 
copper:        dc.l 0
 296 
 
 297 
; storage for 16-bit data
 298 
    CNOP 0,4
 299 
olddmareq:    dc.w 0
 300 
oldintreq:    dc.w 0
 301 
oldintena:    dc.w 0
 302 
oldadkcon:    dc.w 0
 303 
 
 304 
    CNOP 0,4
 305 
; storage for 8-bit data and text
 306 
gfxname:        dc.b 'graphics.library',0
 307 
author:            dc.b 'AmigaVikke',0
 308 
 
 309 
    CNOP 0,4
 310 
c0:    dc.w $000,$100,$101,$201,$202,$302,$303,$403,$404,$504,$505,$605,$606,$706,$707,$807,
$808,$908,$909,$a09,$a0a,$b0a,$b0b,$c0b,$c0b,$c0c,$d0c,$d0d,$e0d,$e0e,$f0e,$f0f,$f0f,$f0e,$e0e,
$e0d,$d0d,$d0c,$c0c,$c0b,$c0b,$b0b,$b0a,$a0a,$a09,$909,$908,$808,$807,$707,$706,$606,$605,
$505,$504,$404,$403,$303,$302,$202,$201,$101,$100,$000
 311 
c1:    dc.w $000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,
$000,$000,$000,$000,$000,$000,$000,$000,$111,$111,$111,$111,$222,$222,$222,$333,$333,$222,
$222,$222,$111,$111,$111,$111,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,
$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000,$000
 312 
c2: dc.w $000,$000,$100,$100,$200,$200,$300,$300,$400,$400,$500,$500,$600,$600,$700,$700,
$800,$800,$900,$900,$A00,$A00,$B00,$B00,$C00,$C00,$D00,$D00,$E00,$E00,$F00,$F00,$F00,
$F00,$E00,$E00,$D00,$D00,$C00,$C00,$B00,$B00,$A00,$A00,$900,$900,$800,$800,$700,$700,
$600,$600,$500,$500,$400,$400,$300,$300,$200,$200,$100,$100,$000,$000
 313 
c3: dc.w $000,$000,$010,$010,$020,$020,$030,$030,$040,$040,$050,$050,$060,$060,$070,$070,
$080,$080,$090,$090,$0A0,$0A0,$0B0,$0B0,$0C0,$0C0,$0D0,$0D0,$0E0,$0E0,$0F0,$0F0,$0F0,
$0F0,$0E0,$0E0,$0D0,$0D0,$0C0,$0C0,$0B0,$0B0,$0A0,$0A0,$090,$090,$080,$080,$070,$070,
$060,$060,$050,$050,$040,$040,$030,$030,$020,$020,$010,$010,$000,$000
 314 
c4: dc.w $000,$000,$001,$001,$002,$002,$003,$003,$004,$004,$005,$005,$006,$006,$007,$007,
$008,$008,$009,$009,$00A,$00A,$00B,$00B,$00C,$00C,$00D,$00D,$00E,$00E,$00F,$00F,$00F,
$00F,$00E,$00E,$00D,$00D,$00C,$00C,$00B,$00B,$00A,$00A,$009,$009,$008,$008,$007,$007,
$006,$006,$005,$005,$004,$004,$003,$003,$002,$002,$001,$001,$000,$000
 315 
c5: dc.w $000,$000,$110,$110,$220,$220,$330,$330,$440,$440,$550,$550,$660,$660,$770,$770,
$880,$880,$990,$990,$AA0,$AA0,$BB0,$BB0,$CC0,$CC0,$DD0,$DD0,$EE0,$EE0,$FF0,$FF0,
$FF0,$FF0,$EE0,$EE0,$DD0,$DD0,$CC0,$CC0,$BB0,$BB0,$AA0,$AA0,$990,$990,$880,$880,
$770,$770,$660,$660,$550,$550,$440,$440,$330,$330,$220,$220,$110,$110,$000,$000
 316 
c6: dc.w $000,$000,$111,$111,$222,$222,$333,$333,$444,$444,$555,$555,$666,$666,$777,$777,
$888,$888,$999,$999,$AAA,$AAA,$BBB,$BBB,$CCC,$CCC,$DDD,$DDD,$EEE,$EEE,$FFF,$FFF,
$FFF,$FFF,$EEE,$EEE,$DDD,$DDD,$CCC,$CCC,$BBB,$BBB,$AAA,$AAA,$999,$999,$888,$888,
$777,$777,$666,$666,$555,$555,$444,$444,$333,$333,$222,$222,$111,$111,$000,$000
 317 
c7: dc.w $000,$000,$011,$011,$022,$022,$033,$033,$044,$044,$055,$055,$066,$066,$077,$077,
$088,$088,$099,$099,$0AA,$0AA,$0BB,$0BB,$0CC,$0CC,$0DD,$0DD,$0EE,$0EE,$0FF,$0FF,$0FF,
$0FF,$0EE,$0EE,$0DD,$0DD,$0CC,$0CC,$0BB,$0BB,$0AA,$0AA,$099,$099,$088,$088,$077,$077,
$066,$066,$055,$055,$044,$044,$033,$033,$022,$022,$011,$011,$000,$000
 318 
 
 319 
 
 320 
cbar_img_line1:    dc.w 0
 321 
 
 322 
shift1:        dc.w $00,$11,$33,$44,$66,$77,$99,$AA,$BB,$CC,$DD,$EE,$FF,$FF,$FF,$FF,$FF,$FF,$FF,
$FF,$EE,$DD,$CC,$BB,$AA,$99,$77,$66,$44,$33,$11,$00
 323 
 
 324 
 
 325 
sin255_60:    dc.b 30,31,31,32,33,34,34,35,36,37,37,38,39,39,40,41,42,42,43,44,44,45,45,46,47,47,48,
49,49,50,50,51,51,52,52,53,53,54,54,55,55,55,56,56,57,57,57,57,58,58,58,59,59,59,59,59,59,60,60,60,
60,60,60,60,60,60,60,60,60,60,60,60,59,59,59,59,59,58,58,58,58,57,57,57,56,56,56,55,55,54,54,53,53,
53,52,52,51,50,50,49,49,48,48,47,46,46,45,45,44,43,43,42,41,40,40,39,38,38,37,36,36,35,34,33,33,32,
31,30,30,29,28,27,27,26,25,24,24,23,22,22,21,20,20,19,18,17,17,16,15,15,14,14,13,12,12,11,11,10,10,
9,8,8,7,7,7,6,6,5,5,4,4,4,3,3,3,2,2,2,2,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,2,2,2,3,3,3,3,4,4,5,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,13,13,14,15,15,16,16,17,18,18,19,20,21,21,22,23,23,24,25,26,26,27,
28,29,29,30
 326 
    CNOP 0,4
 327 
cos255:        dc.b 255,255,255,255,254,254,254,253,253,252,251,250,249,249,248,246,245,244,243,
241,240,238,237,235,233,232,230,228,226,224,222,220,218,215,213,211,208,206,203,201,198,196,
193,190,187,185,182,179,176,173,170,167,164,161,158,155,152,149,146,143,140,137,133,130,127,
124,121,118,115,112,109,105,102,99,96,93,90,87,84,81,78,76,73,70,67,65,62,59,57,54,51,49,47,44,
42,40,37,35,33,31,29,27,25,23,22,20,18,17,15,14,13,11,10,9,8,7,6,5,4,4,3,3,2,2,1,1,1,1,1,1,1,1,2,2,3,
3,4,4,5,6,7,8,9,10,11,13,14,15,17,18,20,22,23,25,27,29,31,33,35,37,40,42,44,47,49,51,54,57,59,62,64,
67,70,73,76,78,81,84,87,90,93,96,99,102,105,109,112,115,118,121,124,127,130,133,137,140,143,146,
149,152,155,158,161,164,167,170,173,176,179,182,185,187,190,193,196,198,201,203,206,208,211,213,
215,218,220,222,224,226,228,230,232,233,235,237,238,240,241,243,244,245,246,248,249,249,250,251,
252,253,253,254,254,254,255,255,255,255
 328 
    CNOP 0,4
 329 
 
 330 
hshift:    dc.w $00,$88,$BB,$DD,$FF,$11,$22,$44,$55,$66,$77,$88,$88,$99,$AA,$BB,$BB,$CC,$CC,
$DD,$DD,$DD,$EE,$EE,$EE,$EE,$FF,$FF,$FF,$FF,$FF,$FF,$FF,$FF,$FF,$FF,$FF,$FF,$EE,$EE,
$EE,$EE,$DD,$DD,$DD,$CC,$CC,$BB,$BB,$AA,$99,$88,$88,$77,$66,$55,$44,$22,$11,$FF,$DD,
$BB,$88,$00
 331 
 
 332 
mshift:    dc.w 4,4,4,4,4,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,4,4,4,4,4
 333 
 
 334 
 
 335 
 
 336 
    Section ChipRAM,Data_c
 337 
 
 338 
; bitplanes aligned to 32-bit
 339 
    CNOP 0,4
 340 
bpl0:    blk.b 352/8*200,0
 341 
bpl1:    blk.b 352/8*200,0
 342 
bpl2:    blk.b 352/8*200,0
 343 
 
 344 
; datalists aligned to 32-bit
 345 
    CNOP 0,4
 346 
copper1:    
 347 
            dc.l $ffffffe     ; CHIPMEM!
 348 
            blk.l 2047,0     ; CHIPMEM!
 349 
    CNOP 0,4
 350 
copper2:    
 351 
            dc.l $ffffffe     ; CHIPMEM!
 352 
            blk.l 2047,0     ; CHIPMEM!
 353 
 
 354 
    CNOP 0,4
 355 
img_av:    incbin "amigavikke-flowers.raw"

 


Write a Comment
bbcode:
[br]  [b][/b]  [i][/i]  [u][/u]
[img]link image[/img]
[color=colour][/color]
[url]link[/url]
[url=link]title[/url]
 If you don't see Verification Code clearly -> Reload
* Write Verification Code
* Required fields

Published on  April 1st, 2013