English Amiga Board


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

 
 
Thread Tools
Old 19 May 2021, 00:29   #1
KONEY
OctaMED Music Composer
 
KONEY's Avatar
 
Join Date: Jan 2009
Location: Venice - Italy
Age: 49
Posts: 666
Horizontal Copper WAIT on multiple lines

Hello,

I'm building a copperlist which is basically two gradients: vertical and horizontal.

So now I'm adding the horizontal waits but it turns out I would need hundreds of them, if I have to repeat them for every line... So I'm asking if a trick or technique exists so that the instruction after a horizontal wait spans for multiple lines.

my decoded copperlist: (I know colors are wrong, I'll fix it
Code:
0180 0bbb          	;  COLOR00 := 0x0bbb
da45 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x44
0180 0ddd          	;  COLOR00 := 0x0ddd
da49 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x48
180 0fff          	;  COLOR00 := 0x0fff
da4d dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x4c
0180 1221          	;  COLOR00 := 0x1221
da51 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x50
180 1443          	;  COLOR00 := 0x1443
da55 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x54
0180 1665          	;  COLOR00 := 0x1665
da59 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x58
180 1887          	;  COLOR00 := 0x1887
da61 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x60
0180 1665          	;  COLOR00 := 0x1665
da65 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x64
180 1443          	;  COLOR00 := 0x1443
da69 dafe          	;  Wait for vpos & 0x5a >= 0xda and hpos >= 0x68
Here it can be seen how gradients after Horizontal waits are only 1px:



thanks for any help!
Attached Thumbnails
Click image for larger version

Name:	077.png
Views:	558
Size:	4.0 KB
ID:	71987  
KONEY is offline  
Old 19 May 2021, 00:44   #2
DanScott
Lemon. / Core Design
 
DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,211
Yes, you can use a combination of SKIP's and copper jumps to "repeat" a horizontal line on the next line.

Have a look at Roondar's post today about copper screen, he uses that technique (with some probably well documented code available too)
DanScott is online now  
Old 19 May 2021, 00:56   #3
KONEY
OctaMED Music Composer
 
KONEY's Avatar
 
Join Date: Jan 2009
Location: Venice - Italy
Age: 49
Posts: 666
thanks!
KONEY is offline  
Old 19 May 2021, 08:00   #4
KONEY
OctaMED Music Composer
 
KONEY's Avatar
 
Join Date: Jan 2009
Location: Venice - Italy
Age: 49
Posts: 666
Roondar's post describes a much more complex technique and trying to extract what I need is a bit confusing. Knowing it's possible is already a good thing, hope to find some other examples.
KONEY is offline  
Old 19 May 2021, 08:26   #5
LaBodilsen
Registered User
 
Join Date: Dec 2017
Location: Denmark
Posts: 179
i've played with this sometime ago, and thought there was a bug in winuae (which there was not).

But in the post is a very small example on how to repeat a copper line.
https://eab.abime.net/showthread.php?t=81184


I might have a better example stored some where, if you really want to take a look at it.

EDIT: I found a better example, which I have attached. It makes 3 splits down the screen, and repeat every line between the 3 splits. Also includes Pal workaround.
Attached Files
File Type: s Small Copper Loop Screen.s (4.7 KB, 162 views)

Last edited by LaBodilsen; 20 May 2021 at 08:53.
LaBodilsen is offline  
Old 26 August 2021, 07:58   #6
KONEY
OctaMED Music Composer
 
KONEY's Avatar
 
Join Date: Jan 2009
Location: Venice - Italy
Age: 49
Posts: 666
@LaBodilsen thanks and sorry for the delay but I've been super busy releasing a musicdisk!

So your example works and I'm studying it. As far I understand there are 3 jumps because there's a limit in the height of repeated pattern and 3 jumps are required to fill the entire H of screen.

But I can't figure out how to make them shorter, I'm always ending up with the same height of about 1/3 of total height. Or maybe I'm doing it all wrong

Attached Thumbnails
Click image for larger version

Name:	109.png
Views:	411
Size:	8.0 KB
ID:	72998  
KONEY is offline  
Old 26 August 2021, 17:32   #7
defor
Registered User
 
Join Date: Jun 2020
Location: Brno
Posts: 90
You may also look at this thread:
http://eab.abime.net/showthread.php?t=107705
You can see how to deal with $80/$100 vpos problem (if you encounter it).
defor is offline  
Old 26 August 2021, 18:50   #8
roondar
Registered User
 
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,408
Quote:
Originally Posted by KONEY View Post
@LaBodilsen thanks and sorry for the delay but I've been super busy releasing a musicdisk!

So your example works and I'm studying it. As far I understand there are 3 jumps because there's a limit in the height of repeated pattern and 3 jumps are required to fill the entire H of screen.

But I can't figure out how to make them shorter, I'm always ending up with the same height of about 1/3 of total height. Or maybe I'm doing it all wrong
You can make a Copper loop of any height as long as the vertical position doesn't cross either rasterline $80 or rasterline $100, so it should be possible to have many or just a few loops.

What values are you using for the SKIP & WAIT instructions? That might help fix the issue
roondar is offline  
Old 26 August 2021, 19:13   #9
LaBodilsen
Registered User
 
Join Date: Dec 2017
Location: Denmark
Posts: 179
Floppy disk

Quote:
Originally Posted by KONEY View Post
@LaBodilsen thanks and sorry for the delay but I've been super busy releasing a musicdisk!

So your example works and I'm studying it. As far I understand there are 3 jumps because there's a limit in the height of repeated pattern and 3 jumps are required to fill the entire H of screen.

But I can't figure out how to make them shorter, I'm always ending up with the same height of about 1/3 of total height. Or maybe I'm doing it all wrong
To change the position og Split 2, you need to change both the wait address for skip, and repeat. so change both $7fe1 and $803f below

Code:
	dc.w	$7fe1,$7fff	;<-- Change here
 	dc.w	COPJMP2,$0	; Jump to CopJmp1 as set in COP2LCH

	dc.w	$0084,$0000,$0086,$0000		;Set COP2LCH
CopJmp2:	;split 2
	dc.w	$803f,$80fe	; <-- and change here
LaBodilsen is offline  
 


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

Similar Threads
Thread Thread Starter Forum Replies Last Post
CD32 (with TerribleFire) horizontal lines flickering tripp support.Hardware 5 30 July 2020 16:04
Busy wait for screen lines Quagliarulo Coders. Asm / Hardware 5 18 July 2020 12:17
Copper Horizontal Wait Problems mcgeezer Coders. Asm / Hardware 5 21 May 2020 16:45
Copper wait geldo79 Coders. Asm / Hardware 9 12 November 2019 09:18
Copper Wait Problem sandruzzo support.WinUAE 13 18 May 2016 21:54

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:39.

Top

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