Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > NUFLI Sprite Layer
2011-04-14 09:30
Sabbi

Registered: Jan 2002
Posts: 8
NUFLI Sprite Layer

Hi everybody,

I'm trying to understand what's going on with the sprite layer on NUFLI-Pictures or more precise the NUFLI-Viewer, and something I just don't get.

It's about Y-Position and Y-Expand:

Acording to the Vice-Monitor, Sprite Y-Positions are only written at Raster 43, 45 and 248, while $d017 (Y-Expand) is written at Raster 45 and 46.

So, with no new Y-Positions between 45 and 248, and no $d017-stretcher, how can there be sprites upto 248?

I know I (obviously) oversee something, but I cannot find the missing piece.

Thank a lot for any directions :)

Sabbi

(btw: Observed on 25 Years of Yie Ar Kung-Fu)
 
... 10 posts hidden. Click here to view all posts....
 
2011-04-20 08:38
Sabbi

Registered: Jan 2002
Posts: 8
Thanks :) Now it's all clear about the magic!

But while we're at the VIC-II Text....

3. In the first phases of cycle 55 and 56, the VIC checks for every sprite if the corresponding MxE bit in register $d015 is set and the Y coordinate of the sprite match the lower 8 bits of RASTER. If this is the case and the DMA for the sprite is still off, the DMA is switched on.

4. In the first phase of cycle 58, it is checked if the DMA for the sprite is turned on and the Y coordinate of the sprite matches the lower 8 bits of RASTER. If this is the case, the display of the sprite is turned on.

The Vic checks TWICE if the Y-Coordinate is same as the raster? So if you change SpriteY on cycle 57, the DMA is on, but the sprite will not be visible?
2011-04-20 10:27
tlr

Registered: Sep 2003
Posts: 1790
Yes.

See here: http://vice-emu.svn.sourceforge.net/viewvc/vice-emu/testprogs/V..
(spriteenable[1-5].prg)

The source is in core[1-5].asm.
2011-04-20 11:47
Sabbi

Registered: Jan 2002
Posts: 8
Intresting... Inactive Sprites eating Cycles :)
2011-05-04 23:13
Digger

Registered: Mar 2005
Posts: 437
OK, so 1 extended layer of sprites (42px high) + 3 times wrapped extended sprites (3 *42 = 126px) gives 168 pixels. The NUFLI pic is 200 px high. What about the remaining 32 lines? If the "sprite crunch" trick is only performed once (@ lines 45 and 46) how can this work?

Anyone wants to play with the source, here's what I've got so far...
https://gist.github.com/956683
2011-05-05 08:41
Sabbi

Registered: Jan 2002
Posts: 8
Digger: Not checked, but afaik the sprites are multiplexed once.

At raster 43 is the first Y-Position for the 168 stretched-sprites is set, at raster 45 already the next position (Y + 168) is set to have 42 extra-lines of normal expanded sprites.

Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
St0rmfr0nt/Quantum
MWR/Visdom
LKP/CFN
Chesoner/House Designs
katon/Lepsi De
The Syndrom/TIA/Pret..
Youth
Mike
Lazycow
Alakran_64
TheRyk/MYD!
mutetus/Ald ^ Ons
megasoftargentina
Guests online: 135
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.6)
5 Edge of Disgrace  (9.6)
6 What Is The Matrix 2  (9.6)
7 The Demo Coder  (9.6)
8 Uncensored  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 No Listen  (9.6)
2 Layers  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 Dawnfall V1.1  (9.5)
7 Rainbow Connection  (9.5)
8 Onscreen 5k  (9.5)
9 Morph  (9.5)
10 Libertongo  (9.5)
Top Groups
1 Performers  (9.3)
2 Booze Design  (9.3)
3 Oxyron  (9.3)
4 Censor Design  (9.3)
5 Triad  (9.3)
Top Musicians
1 Rob Hubbard  (9.7)
2 Mutetus  (9.7)
3 Jeroen Tel  (9.7)
4 Linus  (9.6)
5 Stinsen  (9.6)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.057 sec.