| |
Six
Registered: Apr 2002 Posts: 293 |
Sprite + Sprite + Background priority color switching trick.
So, I'm not sure what this technique is called, and I'm sure it's been done to death. I'm hoping to determine if there's a more efficient way to do it.
(Everything is in hires, not multicolor mode)
I put character graphics on screen.
color ram is pink
sprite 0 color is white
sprite 1 color is red
I put sprite 1 with matching bitmap data in front of the character graphics.
I set sprite-background priority to 01
I move sprite 0 partially in front of sprite 1.
In the areas in which sprite 0 has pixels in front of sprite 1, the character graphics show through, giving the appearance that red mixes with white to make pink.
SO...
What is this technique called?
Is there a better way to achieve it so that I'm not limited to a narrow width of graphics on screen? |
|
| |
Krill
Registered: Apr 2002 Posts: 2980 |
I don't know what this technique is called, or if it has a name at all.
But, no, you do require 2 sprites on top of each other, which indeed limits you to 4*48 pixels width with X-expanded sprites. |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
so far it has been called (VICII) priority bug / trick. I wonder what happens inside the VIC dont remember a good explanation to this.
maybe its just: oh sprite 0 should be displayed here, but wait graphich are even higher priority so lets just display that :)
in one of the offence demos there was fullscreen 160x200 2 layers scrolling in opposite directions eoring each other at 50fps, so yes there are better ways if you are tricky enough (anyone knows how that one was done?) |
| |
Six
Registered: Apr 2002 Posts: 293 |
I'm thinking something less linear, like freely moving a sprite over an area of graphics, maybe pre-mapping the graphics into sprite data and "following" the moving object across a larger space. If you figure any one sprite can only ever overlap an area that could be covered by 4 sprites, that'd give you 4 moving objects for this effect, and the appearance of having more overlay sprites would come from manipulation of d8xx data.
A few years back, there was a demo that used this trick a lot, I vaguely recall it being lots of black/white/red/pink and lots of "transparency" tricks. Anyone remember what it was called? |
| |
Mirage
Registered: Jan 2003 Posts: 113 |
Tsunami by Booze
Deekay called it 'cookiecutter', which I kinda like:
Breakpoint 06 c64 Graphics Seminar page 13 |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
Quote:I wonder what happens inside the VIC dont remember a good explanation to this.
maybe its just: oh sprite 0 should be displayed here, but wait graphich are even higher priority so lets just display that :)
its pretty simple, a sideeffect of how the sprites rasterizer works. i tried explaining (a bit simplified) what happens here - i think the VIC article has a more technical explaination. |
| |
BjørnRøstøen
Registered: Oct 2010 Posts: 4 |
As far as I know, I was the first to ever produce this trick on Mentallic from Panoramic Designs. I called it the PRIORITY PARADOX back then. |
| |
Digger
Registered: Mar 2005 Posts: 437 |
I've been always calling it "hardware masking" ;-) |
| |
Graham Account closed
Registered: Dec 2002 Posts: 990 |
It's ofcourse called Bullshitting The Vic-2 Sprite Hardware And Getting Away With It (BTV2SHAGAWI). Silly CSDb users, not knowing the basics of C64 abbreviations. |
| |
Tao
Registered: Aug 2002 Posts: 115 |
Quote: As far as I know, I was the first to ever produce this trick on Mentallic from Panoramic Designs. I called it the PRIORITY PARADOX back then.
Dunno if it was the first one, but it's certainly my favourite. |
| |
Krill
Registered: Apr 2002 Posts: 2980 |
I like "priority paradox" as well. Because no matter what the actual rasterizer implementation did, there'd always be a contradiction. This is also why it cannot be called a bug.
"Cookie cutter" is also not bad, but it has a negative connotation in other contexts, and doesn't sound nearly as nicely philosophic. |
| |
ChristopherJam
Registered: Aug 2004 Posts: 1409 |
I quite like cookiecutter, or priority inversion.
Possibly 'felting' (as you're pulling up colours from the foreground through the lower priority sprites, like the craft technique with layers of fabric), but that might be a little obtuse. |
| |
Martin Piper
Registered: Nov 2007 Posts: 722 |
How well is this emulated compared to real hardware? |
| |
chatGPZ
Registered: Dec 2001 Posts: 11386 |
its perfectly emulated (of course, its trivial). see the test program i linked above. if it would'nt, demos like "tsunami" would look completely broken all over the place :) |
| |
Cruzer
Registered: Dec 2001 Posts: 1048 |
Priority paradox - will call it that from now on. |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
say that after a couple of beers :) |