View Single Post
Old 04 January 2023, 01:31   #1
Sucrerat
Registered User
 
Sucrerat's Avatar
 
Join Date: Feb 2022
Location: St-Pierre-et-Miquelon (just below Newfoundland, Canada !), France
Posts: 11
Copperlist with dummy moves ?

Hi,
First of all : happy new year coding on amiga !

Well, I've built a copperlist looking like a "plasma" copperlist with a Wait for each line followed by 40 moves to change color 0. There are 200 lines in my copperlist.
It works perfectly well.

But now, I just want to change colors for about 50% of the 200 lines. The remaining 50% are not used. Of course, the 50% lines used change every vbl.

I could built a new copperlist with only the lines i'm interested in... but for a lot of reasons I want to work with my "full" (i.e my 200 lines) copperlist (in fact, think of an "array" of 40 columns and 200 rows. Classic stuff)

But I want also save dma cycles and don't waste cycles on lines i'm not modifying.

So I tried to initialize my copperlist like this :
After the Wait, instead of doing the 40 "move.w #$180, (a0)+, move.w #$0, (a0)+"

I did this : "move.w #$0, (a0)+, move.w #$0, (a0)+, ..."

(with a0 = copperlist)

with the idea for the lines i'm only interesting in (at each vbl) to simply recreate
the "usual" flow of 40 moves : "move.w #$180, (a0)+, move.w #$mycolor, (a0)+"

But it doesn't work (i only tested on winuae) !
The copper doesn't seem to like dealing with a line having after the Wait, 80 words at $0 and the next line having the Wait followed by "normal" 40 : $180, $mycolor, $180, $mycolor, ...

So my question, is there a easy way to deal with this situation ? by easy, i mean avoiding using Skip instruction or jumping to copper subroutines ?
Just having kind of dummy moves after the Wait in my "array" ?

To illustrate what I would like to do is to initialize my copperlist like this :

$2c41, $fffe, $0, $0, $0, $0, $0, $0, ...
$2d41, $fffe, $0, $0, $0, $0, $0, $0, ...
$2e41, $fffe, $0, $0, $0, $0, $0, $0, ...
...
$ffff, $fffe

and for example filling only the second line like this :
$2c41, $fffe, $0, $0, $0, $0, $0, $0, ...
$2d41, $fffe, $180, $fff, $180, $fff, $180, $fff, ...
$2e41, $fffe, $0, $0, $0, $0, $0, $0, ...
...
$ffff, $fffe

to be complete : i would like to "clear" at each vbl the lines I modified in the copperlist by using the dummy moves. And classically initialize 2 copperlists and swap them at each vbl : one displayed, one where lines previously used are cleared before modifying the lines i want to.

Thanks in advance for your advices !

I didn't try : A skip followed by a (dummy) move. I'm not sure it could achieve what i want to do ? But i plan to try

Quote:
Originally Posted by Toni Wilen View Post
"Skipped" instruction is still processed normally (DMA slot usage won't change, no DMA slots saved). Only difference is that if following instruction is MOVE, MOVE's register write becomes dummy write. If following instruction is WAIT or SKIP: it is executed normally.
Sucrerat is offline  
 
Page generated in 0.04372 seconds with 11 queries