| |
ChristopherJam
Registered: Aug 2004 Posts: 1409 |
Unrestricted hires colour mode! (albeit just a *tiny* bit letterboxed..)
I've been spending a few weeks on and off experimenting with how sequences of hires pixels behave, and as something of a side effect I've reached a startling conclusion.
If you layer seven hires sprites over a multicolour sprite over a multicolour bitmap, with the just that final sprite set to a lower priority than the bitmap foreground colours, I'm pretty sure you can have a 24x1 pixel area of any pixel any colour.
It's easily done for a palette of 11 colours as so:
BBbbbbbbbbbbbbbbbbbbBBbb # background layer: two pixels from $d800 & $d802, rest from $d021
00112233445566778899 # MCM sprite layer. Note odd x-position -> half pixels peek out from under fg
ff ff ff ff ff ff # bitmap fg layer
s s s s s s # hires sprite layer. 's' where layer's always opaque, space where it is optional
So, any of the pixels whose x%4 is 0 or 1 can be any of the 7 hires colours or any of the three MCM sprite colours, or $d021
any pixels where x%4==2 can be any one of the 7 hires sprite colours (so ensure those 7 include the up to six represented here)
any pixels where x%4==3 are unrestricted
For 16 colours it's more complex. I have a algorithm that will deal with any sequence for which all sixteen colours are present in the first 16 pixels (ie the first 16 are just a permutation), which chooses from about 50 different layouts depending on the last 8 colours and where they can be found in the first 16.
I've yet to generalise to all 16^24 possibilities, but have also yet to find a sequence that cannot be represented. lp_solve and gprolog have both failed me, as they grind to a halt if I try to describe the general problem.
Would anyone care to prove me right or wrong about the general case being solvable (preferably with either an algorithm or a counter example)? I'm having trouble concentrating on anything else while this is still an open question.
Not sure whether this belongs in Coding or Pixeling; posting here because it's pretty impractical for artwork. Still, it's trivially stretchable to full screen height, so perhaps it would be good for a narrow area of vertical 'raster bars' :D |
|
| |
ChristopherJam
Registered: Aug 2004 Posts: 1409 |
Oh, and here's an example layout for the 'arbitrary first 16, distinct final eight' case:
|00' ' ' | ' 'dd'ff| ' '33' | # MCM bmp bg layer
| 1'14'45'5 | ' ' ' | ' ' ' | # MCM mob layer
| '33' '77|88'aa' ' |22'55' ' | # MCM bmp fg layer
| '2 ' '6 | 9' b'c 'e |b '6 '9 'ac| # hires mob layer
|01 23 45 67 89 ab cd ef b2 65 93 ac| # displayed colours
|
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
nice find, something for HCL :) |
| |
HCL
Registered: Feb 2003 Posts: 728 |
Me!? :) |
| |
ChristopherJam
Registered: Aug 2004 Posts: 1409 |
Thanks, @Oswald.
Help me, @HCL, you're my only hope :D |
| |
Dane
Registered: May 2002 Posts: 423 |
But when would 16col unrestricted in such a small area be useful?
Fiddling with bitmap, sprites and priority to get unusual graphic modes is usually my cup of tea. :) |
| |
Joe
Registered: Apr 2002 Posts: 229 |
I'd still prefer someone would make editors of the underlay/overlay sprites+bitmap mode Algorithm introduced some years back. Could be really useful in ordinary demos (loading time etc).
But.. I support all and every attempt in breaking the boundaries as long as the final result doesn't become interlaced or too small... |
| |
Oswald
Registered: Apr 2002 Posts: 5094 |
I mean it could make a loaderpart or something if Y stretched :) |
| |
Jammer
Registered: Nov 2002 Posts: 1335 |
This thing loosely reminded me of my idea for Lemmings port for C64, this time without reversed background/sprite use and narrow playfield ;) Mostly about writing more Lemmings into single sprites and distributing sprites wisely around with multiplexing. Maybe even a bitmap background could be possible in this case? :D Of course there would be some flickering on characters, but NES games also suffered similar problems and they passed anyway :D |
| |
ChristopherJam
Registered: Aug 2004 Posts: 1409 |
@Dane - I'm mostly posting here rather than in the pixeling forum because it doesn't seem like a very practical result at all :)
Could perhaps have multiple rows separated by black lines or stretch, but it would still only be three chars wide. |
| |
Ninja
Registered: Jan 2002 Posts: 411 |
This calls for Copyfault as the problem should please his interest in GFX modes and mathmatical problems :) |
... 25 posts hidden. Click here to view all posts.... |
Previous - 1 | 2 | 3 | 4 - Next |