04 July 2023, 01:08 | #1 |
Registered User
Join Date: May 2022
Location: Canada
Posts: 139
|
cop2lc modified by the system
Hi Amiga coders,
Today I noticed that if I enable System to perform some file I/O, and then disable System, the value I had in COP2LC is stomped. This is causing a visual glitch in my game since I need a CopJump to copper list 2 at a specific scanline. While I can restore cop2lc after disabling back the system, the visual glitch will still be visible during the I/O part. I tested both KS 1.3 and KS 2.0, and in both cases the same thing happen. Could I perhaps "counter" this by setting cop2lc at the start of my copperlist (instead of being set by cpu)? |
04 July 2023, 07:59 | #2 |
Registered User
Join Date: Sep 2019
Location: Finland
Posts: 363
|
This is done in the system VERTB interrupt. One way to prevent this is to set up a high priority VERTB interrupt that prevents running the lower priority interrupt servers in the chain by clearing the Z flag at the end.
|
04 July 2023, 13:11 | #3 |
Defendit numerus
Join Date: Mar 2017
Location: Crossing the Rubicon
Age: 53
Posts: 4,474
|
Or the opposite, ie a very low priority VERTB, last in the chain, where you rewrite your COP2LC.
This way you are transparent to the existing chain and don't affect it. Or set it to your copper list slightly before the COP2JMP call. |
04 July 2023, 13:32 | #4 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,516
|
Doing file io without vblank can cause problems for example if some 3rd party HD driver uses vblank mode CIA timers. Don't do that, please.
|
15 February 2024, 23:35 | #5 |
OctaMED Music Composer
Join Date: Jan 2009
Location: Venice - Italy
Age: 49
Posts: 667
|
Sorry guys if I resume this but it looks like my problem...
MainCopper won't jump to Copper2 because COP2LC value written by the CPU changes! Setting it from MainCopper would work but I can't do it because I'm building a series of frames and each Copper2 would update COP2LC with next Copper2 so that MainCopper would always jumps to the following Copper2. So how to fix it? Obviously I have no idea what "setting up a VERTB interrupt" means Thanks |
16 February 2024, 08:58 | #6 |
Moderator
Join Date: Nov 2001
Location: Germany
Posts: 866
|
Either use the OS or switch it off. Don't mix.
|
16 February 2024, 10:13 | #7 |
OctaMED Music Composer
Join Date: Jan 2009
Location: Venice - Italy
Age: 49
Posts: 667
|
Well it turned out a VERTB interrupt was already in place since I'm using Photon's MiniWrapper. But I disabled it long ago because it would crash with some combinations of CPU/KS.
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Games modified by crackers | Hewitson | Retrogaming General Discussion | 26 | 01 September 2018 12:40 |
Modified Audio Filter | CHRIS-F | support.Hardware | 11 | 29 January 2017 23:42 |
The Chaos Engine, modified | Exl | Amiga scene | 25 | 23 June 2010 08:02 |
Terrorliner (Modified) | aubergine | request.Old Rare Games | 3 | 30 January 2006 14:26 |
Terrorpods (not modified) | sborat | request.Old Rare Games | 6 | 25 July 2001 11:06 |
|
|