28 April 2010, 12:13 | #1 |
68k
Join Date: Sep 2005
Location: Somewhere
Posts: 829
|
ASM: VERTB int and 16 colored sprites.
Hello,
I need some explanation about VERTB int + 16 colored sprites. I uploaded into zone two examples ( four files: 2 source + 2 binary ). the main difference between sources is hidden in two lines inside the VERTB routine. Code:
bsr fill_sprites bsr sprites_on Code:
bsr sprites_on bsr fill_sprites I tested on my A1200 blizzIV 030/50 32mb fast and on WinUae ( beta 20 or something ) I choosen a1200 configuration + cycle exact option. edit: vertb-spr16-bad.asm ( binary:vertb-spr16-bad ) - there is no sprites on screen vertb-spr16-ok.asm ( binary: vertb-spr16-ok )- blinking and moving sprites on screen Regards Last edited by Asman; 28 April 2010 at 12:18. Reason: added some info about files |
28 April 2010, 12:37 | #2 |
gone
Join Date: Apr 2007
Location: completely gone
Posts: 1,596
|
Asman - I only quickly scanned the souce code but didn't run the .exe's
You have a vblank interrupt to keep things sync'd with the display but you are also waiting for vb in your main loop - I don't think you need to do both - in fact, I'm fairly sure when I've messed around with doing this in the past that it caused display problems... Edit: Also - it looks like each interrupt you write the pointers to the sprite data into the copper list. Is this needed? If your sprites are animated then most likely yes but if not and you just want to move the sprites you shouldn't need to rewrite the sprite pointers into the copper list each frame. Obviously this won't cause any harm though... Last edited by pmc; 28 April 2010 at 12:55. Reason: read the source better, it's a vblank interrupt - not copper interrupt! |
28 April 2010, 13:21 | #3 | |||
68k
Join Date: Sep 2005
Location: Somewhere
Posts: 829
|
Quote:
Quote:
Quote:
problem. I just simplify to minimum the problem. cheers. |
|||
28 April 2010, 13:27 | #4 | ||
gone
Join Date: Apr 2007
Location: completely gone
Posts: 1,596
|
Quote:
Quote:
Anyways, I'll shut up now - I don't think I've been too much help to you. No surprise really - you know what you're doing better than I do! |
||
28 April 2010, 13:36 | #5 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,574
|
Working case runs sprite_on early enough, before copper has processed sprite pointer update moves, bad case updates them too late -> previous frame's sprite data is shown on screen (which is always sprite_off sprite data because sprite_off always runs early enough)
|
28 April 2010, 14:18 | #6 |
68k
Join Date: Sep 2005
Location: Somewhere
Posts: 829
|
@Toni Wilen - now its so obvious. many thanks.
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Some sprites | Frog | project.Sprites | 6 | 22 August 2022 20:01 |
asm game - how implement exit to OS via PORTS int | Asman | Coders. General | 4 | 28 June 2011 11:07 |
ASM: false int vector ($60) | Asman | Coders. General | 2 | 13 September 2010 09:22 |
Where are all the sprites? | Gambit37 | project.Sprites | 8 | 14 October 2005 14:49 |
INT-2 modification on Cyberstorm boards? | astuermer | support.Hardware | 2 | 06 October 2005 15:23 |
|
|