English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Asm / Hardware

 
 
Thread Tools
Old Today, 00:25   #1
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,458
help me fix this copper "effect"

What I'm trying to do is to change one color, taking advantage of the fact that there are 8-pixel blocks that hide it.


I know that there's a delay when you change a color but I can't seem to tune it properly. The changing color (line which is red/blue/green/yellow...) starts too late/ends too soon at places, and sometimes it's perfect.



Click image for larger version

Name:	copper_change.png
Views:	65
Size:	751 Bytes
ID:	83003


Here's the code (copperlist) I found by a lot of trial and error but it's still not okay. Can you help me fix it? or what I'm asking is not possible? (using AGA + fmode=3)



Code:
    .word    0x4441,0xFFFE
    .word    color,0xF0
    .word    0x4453,0xFFFE
    .word    color,0xF00
    .word    0x4461,0xFFFE
    .word    color,0xF0
    .word    0x4469,0xFFFE
    .word    color,0xF4F
    .word    0x4477,0xFFFE
    .word    color,0xF
    .word    0x4495,0xFFFE
    .word    color,0xFF0
    .word    0x449B,0xFFFE
    .word    color,0xF0F
    .word    0x44B1,0xFFFE
    .word    color,0x0
jotd is offline  
Old Today, 00:56   #2
a/b
Registered User
 
Join Date: Jun 2016
Location: europe
Posts: 1,097
1. How many bitplanes, more than 4? Even with fetch=1/2/3 the copper can be slowed down.
2. Copper's horizontal resolution is lower than lores (320), writes to color registers can't be pixel perfect. You can select every fourth pixel: 50% lower resolution, waits can only select every other position, bit0=0 means it's a move, so that's another 50% reduction.
a/b is offline  
Old Today, 01:52   #3
chb
Registered User
 
Join Date: Dec 2014
Location: germany
Posts: 449
AFAIR, in higher fetch modes the display DMA is not uniformly distributed; e.g in eight planes lores with fmode=3 for eight consecutive memory cycles (16pix) bitplane data will be fetched, leaving no free cycles for copper or CPU, then afterwards bitplane DMA is inactive for 24 mem cycles. Does that explain the observed behavior?
chb is offline  
Old Today, 09:00   #4
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 54
Posts: 4,536
To add to what a/b and chb rightly said.

This may or may not be possible, it depends on several factors, the data you provided is not enough for a precise or definitive answer.
We also need the values of BPLCON0, BPLCON1, DDFSTRT and possibly also the bitmap (basically a test executable..).

However from your Copper list it is very clear that the bitplane DMA fetches are interfering, the wait positions values are too erratic.
ross is offline  
Old Today, 10:50   #5
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,458
right, it's best with a test exe.

Find "elevator_action_aga.zip" in the zone. It has a whdload starter too, and crashes when click on LMB
jotd is offline  
Old Today, 11:19   #6
ross
Defendit numerus
 
ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 54
Posts: 4,536


Fix:
Code:
    .word    0x4435,0xFFFE
    .word    color,0xF0
    .word    0x4455,0xFFFE
    .word    color,0xF00
    .word    0x01fe,0xFFFE
    .word    color,0xF0
    .word    0x4475,0xFFFE
    .word    color,0xF4F
    .word    0x01fe,0xFFFE
    .word    color,0xF
    .word    0x4495,0xFFFE
    .word    color,0xFF0
    .word    0x01fe,0xFFFE
    .word    color,0xF0F
    .word    0x44B5,0xFFFE
    .word    color,0x0
Uses the fact that a simple CNOP is sufficient for waiting (due to bitplane fetches in certain areas) and evenly distributes the CWAITs.
Attached Thumbnails
Click image for larger version

Name:	Copper_08-24-2024_01.jpg
Views:	63
Size:	11.3 KB
ID:	83011  
ross is offline  
Old Today, 11:27   #7
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,458
I don't think I could have found that! thanks. Works a treat.
jotd is offline  
 


Currently Active Users Viewing This Thread: 2 (1 members and 1 guests)
Axxy
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
"Voices8" 8 Channel Soundtracker "DemoSongI" song - "This is the Amiga with 8 Voices" DemosongIHunter request.Music 45 23 May 2022 20:07
"Screech!! v2.41" & "Screech!! [AGA] v2.51" - "HD install" --> "ADFs" DamienD request.Old Rare Games 45 15 June 2020 12:42
WHDload games with "HD" Resolution/Widescreen fix Paulthetall project.WHDLoad 1 28 August 2019 11:15
Help for code an effect called "Blitter Tornado" Powergoo Coders. Asm / Hardware 9 21 September 2015 04:16
Copper coin "Danger Thus Reveals Its Face" - which game? ALL collectors pls read this andreas HOL data problems 1 10 July 2006 19:16

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 17:17.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.09041 seconds with 16 queries