English Amiga Board


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

 
 
Thread Tools
Old 18 May 2021, 21:26   #1
roondar
Registered User

 
Join Date: Jul 2015
Location: The Netherlands
Posts: 2,977
Copper Chunky example + source

Ever since starting my Amiga development adventures, I've been wanting to create a Copper Chunky screen. Some time ago, I thought it might be nice to turn that into one of my video's & articles. And with that, the next episode in my Amiga Tech series was created.

Naturally, I've included the full source code and a download of the program itself on my website. I had a lot of fun experimenting with this one. Note that my example uses the startup code by Photon of Scoopex and requires at least 1MB of RAM (of which 512KB Chip RAM).

The article/source can be found here:
http://powerprograms.nl/amiga/copper-chunky.html

Here's the YouTube video:
[ Show youtube player ]

Note that emulating this using an AGA configuration requires the 'Subpixel Display Emulation' setting to be activated.

Last edited by roondar; 18 May 2021 at 21:33. Reason: Fixed the link to my website :S
roondar is offline  
Old 18 May 2021, 21:53   #2
ross
Defendit numerus

ross's Avatar
 
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 51
Posts: 3,374
Excellent and complete article!
ross is offline  
Old 18 May 2021, 22:10   #3
StingRay
move.l #$c0ff33,throat

StingRay's Avatar
 
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,662
Good stuff indeed, great effort!
StingRay is offline  
Old 18 May 2021, 22:27   #4
mcgeezer
Registered User

 
Join Date: Oct 2017
Location: Sunderland, England
Posts: 2,377
Indeed fabulous stuff!
mcgeezer is offline  
Old 18 May 2021, 23:12   #5
roondar
Registered User

 
Join Date: Jul 2015
Location: The Netherlands
Posts: 2,977
Thanks all. Experimenting with the Copper is always fun
roondar is offline  
Old 18 May 2021, 23:17   #6
saimon69
J.M.D - Bedroom Musician

 
Join Date: Apr 2014
Location: los angeles,ca
Posts: 2,013
Was this done on AGA? (no, wasn't) What about a 3d floor effect?

Listening to the tutorial you say will need a LUT for every degree of rotation, but i think that you take a limited amount, like 16 or 32 you can still have a decent approximation depending on what you want to do

Last edited by saimon69; 18 May 2021 at 23:34.
saimon69 is online now  
Old 18 May 2021, 23:41   #7
roondar
Registered User

 
Join Date: Jul 2015
Location: The Netherlands
Posts: 2,977
Quote:
Originally Posted by saimon69 View Post
Was this done on AGA? (no, wasn't) What about a 3d floor effect?
Haven't thought about that type of effect yet. Who knows though, I'm always looking for inspiration for these videos
Quote:
Listening to the tutorial you say will need a LUT for every degree of rotation, but i think that you take a limited amount, like 16 or 32 you can still have a decent approximation depending on what you want to do
The problem I ran into was simply one of raster time. I don't really have the time to make any decisions during the inner loop of the drawing phase. I suppose you can make it work by making multiple different routines that do mirroring for you and picking and choosing which one to select. However, I did try something like that originally with the rotation and it ended up not being so easy because the calculation changed as well.

It may be worth trying something different here for a 'real' release/demo, but for an introduction/example I think this is good enough
roondar is offline  
Old 19 May 2021, 01:12   #8
arcanist
Registered User
 
Join Date: Dec 2017
Location: Austin, TX
Age: 38
Posts: 326
Nice! I played with copper chunky a while back but didn't get beyond 8 pixel resolution.
arcanist is offline  
Old 19 May 2021, 08:11   #9
LaBodilsen
Registered User

 
Join Date: Dec 2017
Location: Gandrup / Denmark
Posts: 134
Looks sweet.

With this you could easily do per line zooming, with different zoom values for every X or Y line, to make a wobble/wave like effect.

Guess the tables could also make a ring-ripple effect from center.
LaBodilsen is offline  
Old 19 May 2021, 10:27   #10
khph_re
Registered User
 
Join Date: Feb 2008
Location: Northampton/UK
Posts: 364
Beautifully explained. Behind the smoke and mirrors of Demo effects. Loved it!
khph_re is offline  
Old 19 May 2021, 10:34   #11
Antiriad_UK
OCS forever!

Antiriad_UK's Avatar
 
Join Date: Mar 2019
Location: Birmingham, UK
Posts: 395
Awesome. I need to go through this in detail because on first glance I'm like "wtf how what"
Antiriad_UK is offline  
Old 19 May 2021, 11:05   #12
roondar
Registered User

 
Join Date: Jul 2015
Location: The Netherlands
Posts: 2,977
Quote:
Originally Posted by LaBodilsen View Post
Looks sweet.

With this you could easily do per line zooming, with different zoom values for every X or Y line, to make a wobble/wave like effect.

Guess the tables could also make a ring-ripple effect from center.
Yup, all those should be doable. In fact, clever use of table entries can make effects that last much longer and are much more varied than the ones I've shown
Quote:
Originally Posted by khph_re View Post
Beautifully explained. Behind the smoke and mirrors of Demo effects. Loved it!
Quote:
Originally Posted by Antiriad_UK View Post
Awesome. I need to go through this in detail because on first glance I'm like "wtf how what"
Thanks, it was a lot of fun to do as well
roondar is offline  
Old 19 May 2021, 12:24   #13
no9
Registered User

no9's Avatar
 
Join Date: Feb 2018
Location: Poland
Posts: 209
As always great finding Roondar, and also explained smoothly!
no9 is offline  
Old 19 May 2021, 12:47   #14
Steril707
Tigerskunk!

Steril707's Avatar
 
Join Date: Sep 2016
Location: Amiga Island
Posts: 2,117
Always something new to learn from Amiga coding guru Roony.
Steril707 is offline  
Old 19 May 2021, 12:58   #15
WayneK
Registered User
 
Join Date: May 2004
Location: Somewhere secret
Age: 47
Posts: 334
Really good explanation of everything, thanks!
I always thought that rotozoomers precalced 90 degrees of rotation and just used 4 pre-rotated versions of the source image (pre-rotated during startup/init) to avoid having so many tables? But that is possibly a false economy depending on the source image size :P
WayneK is offline  
Old 19 May 2021, 13:03   #16
DanScott
Lemon. / Core Design

DanScott's Avatar
 
Join Date: Mar 2016
Location: Tier 5
Posts: 1,002
Quote:
Originally Posted by WayneK View Post
Really good explanation of everything, thanks!
I always thought that rotozoomers precalced 90 degrees of rotation and just used 4 pre-rotated versions of the source image (pre-rotated during startup/init) to avoid having so many tables? But that is possibly a false economy depending on the source image size :P
For efficiency, most rotozoomers will precalculate the code for generating a line worth of copper data using unrolled moves:

eg.

move.w XX(a0),YY(a1)
move.w XX(a0),YY(a1)
move.w XX(a0),YY(a1)
move.w XX(a0),YY(a1)
......
......
......
......
rts


with XX being the text source offset, and YY being the copper list address offset
DanScott is offline  
Old 19 May 2021, 14:16   #17
roondar
Registered User

 
Join Date: Jul 2015
Location: The Netherlands
Posts: 2,977
To be clear, this is my take on the rotozoomer - it's certainly possible other or better ways exist. It seemed to be the best option to me at the time. I did try to make use of the symmetry in rotation by only creating 90 degrees of pre-calculated table, but I couldn't make it work in time for this to be released so I gave up (it was either too slow or just didn't draw the correct images).

I'm interested in knowing how that code-precalculation is supposed to work though, any info on what exactly is being done?
roondar is offline  
Old 19 May 2021, 17:21   #18
modrobert
old bearded fool

modrobert's Avatar
 
Join Date: Jan 2010
Location: Bangkok
Age: 54
Posts: 586
roondar,

Thanks for the lesson, learned something again, and subscribed.

I had no idea these chunky tricks were done in precalculated copper tables, although was aware of the cosinus/sinus tables for integer speed.
modrobert is offline  
Old 19 May 2021, 17:54   #19
jotd
This cat is no more
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 49
Posts: 5,583
roondar I like the video, and also the humility you put in that video.

Why can't we change 1 color per 1 pixel line damnit ?

I wonder what was used in the "Brian the lion" title screen with Brian letters wobbling all over.

Isn't it possible to "pipeline" the changes and create 1 pixel color with enough colors? say 8 colors? (possibly what I'm saying is stoopid)
jotd is offline  
Old 19 May 2021, 22:17   #20
redblade
Zone Friend

redblade's Avatar
 
Join Date: Mar 2004
Location: Middle Earth
Age: 37
Posts: 1,771
Great tutorial, Also thumbs up for mentioning dr dobbs, I love looking at the articles in that and byte magazine, so much code from the golden days

Good on you for giving love to Amanita Muscaria, I haven't eaten those in years, I prefer psilocybin
redblade 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
Combining copper scrolling with copper background phx Coders. Asm / Hardware 16 13 February 2021 12:41
Requested: Chunky Copper Tutorial sandruzzo Coders. General 27 16 August 2020 19:35
Copper Chunky Calvin & Hobbes rotozoom? ReadOnlyCat support.Demos 5 10 July 2018 10:47
Best way to mix blitting with copper and copper effects roondar Coders. Asm / Hardware 3 12 September 2016 13:12
Copper source wanted. Six Coders. General 4 24 November 2004 16:08

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 06:27.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, vBulletin Solutions Inc.
Page generated in 0.09959 seconds with 13 queries