| |
Dr. Jay Account closed
Registered: Jan 2003 Posts: 32 |
FPP - Flexible Pixel Position
I was trying to dissect the code on Crest and the best I could figure was some short of bank switching, maybe this confuses the chip and delays the read at a pixel level? Anyway, to make a short story boring, has anyone document this feature of the VIC chip (i.e. used in Krestage, the Spirits demo, etc.) or is it back to the ML monitor?
|
|
| |
Stryyker
Registered: Dec 2001 Posts: 468 |
It all depends on method used. VIC bank switching simple enables more than 16KB of graphics to be used. I can also be used cleverly, like: lda #$xx, sta $d018, sta $dd00. $d018 doesn't use bit 0. Depending on mode used, maybe some hardware stretching could be used. Maybe FLI mode can be used too. To tell you the truth I've been thinking about making some FPP myself. I have a few ideas like switching charsets but not screen then you have many more cycles for the line. |
| |
Puterman Account closed
Registered: Jan 2002 Posts: 188 |
You use $d018 to choose which line to display (and you need the graphics to be structured appropriately) but you also need to bash $d011 to get the VIC to start over and read in screen data. So it's actually pretty similar to FLI. |
| |
Dr. Jay Account closed
Registered: Jan 2003 Posts: 32 |
I'm wondering if it is similar to FLD, then, using $d018? I see on several demos the effects of either stretching the pixel over multiple lines, or crunching it. In the Spirits demo, however, I'm curious because they actually reverse the scroll upside down. I haven't delved into the code but I'm assuming some trickery isn't actually manipulating memory, but is forcing later pixels to draw sooner, etc? At any rate, I know FLD is simply delaying the bad line and forcing the VIC to redraw later on. With FPP, though, I'm wondering how the VIC keeps redrawing the same pixel? Is it "stunned" by the switches in $d018 and gets confused, or is there something deeper?
Dr. Jay
|
| |
Puterman Account closed
Registered: Jan 2002 Posts: 188 |
FLD + $d018 would be an FPD (Flexible Pixel Distance).
With FPP you "stun" the VIC by clever usage of $d011, which gives you the free choice of which line to display on every line on the screen, ie. you can turn things upside down if you want to.
A good starting point is to think "this must be $d011" whenever something funny is going on. :-)
|
| |
Dr. Jay Account closed
Registered: Jan 2003 Posts: 32 |
Cool. I'll have to dive into it. I'm familiar with flexible pixel distance but I haven't delved into getting it to draw a line, i.e. flexible pixel position. Guess it's time to start examining some code!
|
| |
Cybernator
Registered: Jun 2002 Posts: 154 |
The main difference between FPP and FLI (from aspect of generating the badlines) is that with FLI, you generate the badline at cycle 14. With FPP, you need to do it before cycle 14. The VIC article would help a lot.
Btw, can you name some demos containing the FPD effect? I'm not sure what it looks like.
FLD + $D018? With FLD the sequencer goes into IDLE state, and can't use $D018 for anything here. When it turns into DISPLAY state, $D018 can only be used to change the charset (and screen-mem, but not until the next badline). |
| |
HCL
Registered: Feb 2003 Posts: 727 |
Ok, let's just make this clear.
FLD: (Flexible Line Distance). You can have have variable distance between the lines, which is referred to as charlines (= 8 pixel lines). So this means top-down: 8 lines of graphics, some empty lines, another 8 lines of graphics, more empty lines, and so on... Example: The good old 'Starion Intro'. Note, the 'empty lines' may of course be *empty* themselves ;) which then gives us 16 (or more) lines of grapics.
FPD: (Flexible Pixel Distance). You can have have variable distance between each pixel lines, Top-down: 1 line of gfx, some empty space, another line of gfx, empty space, etc.. Example: The remake of the good old 'Starion Intro' by Booze Design.
FPP: (Flexible Pixel Position). Completely different. The two proir effects are just able to 'stretch' the graphics by putting empty space inbetween. With FPP you can put *any* line of the graphics *anywhere* on the screen (vertically). Example: Yes, the crest-logo in Krestage.
There are various ways to implement all of these 3 effects. It's not that one *type* of code is called FPD or whatever.
Hope i didn't mess it all up even more for you ;) |
| |
Dr. Jay Account closed
Registered: Jan 2003 Posts: 32 |
Doesn't mess it up at all for me, since I have no clue how to code anything other than FLD. I'm being too lazy, and trying to learn ground-breaking techniques without sitting down and taking the effort to actually LEARN it .. like, FPP for Dummies instead of, look at the code, sit down, understand the cycles, the raster timing, the video fetches, analyze how the code is dorking with the VIC registers and then code the damn thing myself!
-Doc |