Using window/shape mask directly on the background colour . . .

Discussion of hardware and software development for Super NES and Super Famicom. See the SNESdev wiki for more information.

Moderator: Moderators

Forum rules
  • For making cartridges of your Super NES games, see Reproduction.
iNCEPTIONAL

Re: Using window/shape mask directly on the background colour . . .

Post by iNCEPTIONAL »

crabking wrote: Thu Jun 30, 2022 12:01 pm
rainwarrior wrote: Thu Jun 30, 2022 11:45 am
crabking wrote: Thu Jun 30, 2022 11:28 amAs Snes can display 128 simultaneous 64 x 64 sprites, if the screen resolution only support 16 of them?
Yes. You can fit 4 full 64x64 sprites on a line before tiles start dropping out from the 34-tiles-per-line limit. (Tiles are 8x8.)

They didn't intend for you to use all 128 sprites at that size, but a sprite is a sprite to the hardware, if you tell it to draw 128 sprites it will do as many as it can for each scanline and discard the rest. Same way it would have to discard some if you tried to put 128 8x8 sprites on a scanline.
Well yes, but considering that there is no practical application in a game situation, i wouldn't call it an "advantage".
It is when you're just arguing with Genesis fanboys on some YouTube video. LOL
crabking
Posts: 7
Joined: Thu Jun 30, 2022 5:13 am

Re: Using window/shape mask directly on the background colour . . .

Post by crabking »

iNCEPTIONAL wrote: Thu Jun 30, 2022 12:10 pm
crabking wrote: Thu Jun 30, 2022 12:01 pm
rainwarrior wrote: Thu Jun 30, 2022 11:45 am
Yes. You can fit 4 full 64x64 sprites on a line before tiles start dropping out from the 34-tiles-per-line limit. (Tiles are 8x8.)

They didn't intend for you to use all 128 sprites at that size, but a sprite is a sprite to the hardware, if you tell it to draw 128 sprites it will do as many as it can for each scanline and discard the rest. Same way it would have to discard some if you tried to put 128 8x8 sprites on a scanline.
Well yes, but considering that there is no practical application in a game situation, i wouldn't call it an "advantage".
It is when you're just arguing with Genesis fanboys on some YouTube video. LOL
Oh i caught the point! :lol:
Pokun
Posts: 2681
Joined: Tue May 28, 2013 5:49 am
Location: Hokkaido, Japan

Re: Using window/shape mask directly on the background colour . . .

Post by Pokun »

TmEE wrote: Thu Jun 30, 2022 7:54 am
Pokun wrote: Wed Jun 29, 2022 5:07 pmDoes the MD window have its own nametable like the Gameboy one do?
Yes, it has its own fixed size tilemap (32x32 in H256 and 64x32 in H320)
I see, then the Megadrive window is pretty much the same as the Gameboy window and not anything like the SNES/SuperGrafx window. It's a separate layer with more limited functionality.
iNCEPTIONAL

Re: Using window/shape mask directly on the background colour . . .

Post by iNCEPTIONAL »

crabking wrote: Thu Jun 30, 2022 5:45 am El Viento uses a similar effect for in game explosions.
Image
Image
Is that the same technique as this dynamite explosion: https://youtu.be/j_8RYvUSCeU?t=134

Not as impressive as the enemy flying towards the screen in TMNT using the extra background for the effect, at least not imo, but certainly an interesting effect. Although, in both cases of this large pixelated explosion effect, I'd rather just some normal explosion sprites were used there without the huge pixels that just look cheap to me. But that's just my opinion. And, to be fair, it's technically quite an impressive thing to see explosions that big while the rest of the action is happening. The water splashes look terrible though, and they actually have the opposite effect of looking cool or impressive for me personally, and, funnily, come across as some kind of limitation of the system (even though it really isn't), which obviously isn't the intention at all. Sometimes, just because you can, it doesn't mean you should.
Last edited by iNCEPTIONAL on Thu Jun 30, 2022 12:40 pm, edited 1 time in total.
93143
Posts: 1717
Joined: Fri Jul 04, 2014 9:31 pm

Re: Using window/shape mask directly on the background colour . . .

Post by 93143 »

Is that not just a BG layer with solid-coloured tiles, animated via tilemap updates? Kinda like the Jurassic Park raycaster, but without Mode 7?
iNCEPTIONAL

Re: Using window/shape mask directly on the background colour . . .

Post by iNCEPTIONAL »

93143 wrote: Thu Jun 30, 2022 12:37 pm Is that not just a BG layer with solid-coloured tiles, animated via tilemap updates? Kinda like the Jurassic Park raycaster, but without Mode 7?
What are you referring to?
iNCEPTIONAL

Re: Using window/shape mask directly on the background colour . . .

Post by iNCEPTIONAL »

Pokun wrote: Thu Jun 30, 2022 12:26 pm
TmEE wrote: Thu Jun 30, 2022 7:54 am
Pokun wrote: Wed Jun 29, 2022 5:07 pmDoes the MD window have its own nametable like the Gameboy one do?
Yes, it has its own fixed size tilemap (32x32 in H256 and 64x32 in H320)
I see, then the Megadrive window is pretty much the same as the Gameboy window and not anything like the SNES/SuperGrafx window. It's a separate layer with more limited functionality.
It cannot be a "separate layer" when you literally have to sacrifice part of one of the two available background layers to get it, meaning you can only ever have one background layer directly behind the window section on Genesis. Well, it is a "separate layer" . . . from the second layer--because it's part of the first layer. But, my point being, you either have two fully overlapping background layers in a Genesis game (and do the HUD with sprites) or you sacrifice part of one of the two available background layers to do this window effect for the HUD, which can be a fully opaque solid bar or have some parts cut out of it (but still only ever with one background layer behind the places where it appears). The SNES can use layer 3 for a HUD entirely on top of layers 1 and 2 (fully opaque like a big solid bar, cut out with elements that are completely see through, or even semi-transparent), or it can actually just do basically exactly the same thing as Genesis and sacrifice part of one of the two high-colour layers for the HUD if it likes (and have the entire layer 3 free to do whatever the hell it wants with it, and layer 4 too if you use Mode 0). On Genesis, it's not a "separate layer"; it's a chunk of one of the only two available layers.

I know I'm being an ass about this but I just hate how people constantly oversell the Genesis' capabilities ("It has 2 background layers plus a window layer plus a sprite layer", even though the window "layer" comes at the cost of part of one of the two background layers--and no one refers to sprites as one of the "layers") yet undersell the SNES' capabilities at the same time ("It has four background layers"--let's just ignore the sprite "layer" and the window/shape masks, which can technically be used as two simple additional overlaid "layers", entirely on SNES). That's how it seems to go most places I read about these consoles--totally and utterly distorted and lop-sided information about each system's capabilities--and I'm kinda sick of it. The Genesis has up to two [fully overlapping background] layers (no more), and the SNES has up to four [fully overlapping background] layers (no more--although actually technically six if you use the SNES' window/masks particularly creatively). Apologies for getting on my soapbox about it.
Last edited by iNCEPTIONAL on Thu Jun 30, 2022 2:40 pm, edited 2 times in total.
93143
Posts: 1717
Joined: Fri Jul 04, 2014 9:31 pm

Re: Using window/shape mask directly on the background colour . . .

Post by 93143 »

iNCEPTIONAL wrote: Thu Jun 30, 2022 12:41 pm
93143 wrote: Thu Jun 30, 2022 12:37 pm Is that not just a BG layer with solid-coloured tiles, animated via tilemap updates? Kinda like the Jurassic Park raycaster, but without Mode 7?
What are you referring to?
The big pixelated graphics in those gifs.

Super Mario RPG seems to do this too, for some smoothly animated fullscreen additive blend effects during combat. And like I said, Jurassic Park's indoor sequences use it to speed up the 3D rendering, exploiting Mode 7 to zoom out so as to display more and smaller pixels.
iNCEPTIONAL

Re: Using window/shape mask directly on the background colour . . .

Post by iNCEPTIONAL »

93143 wrote: Thu Jun 30, 2022 1:59 pm
iNCEPTIONAL wrote: Thu Jun 30, 2022 12:41 pm
93143 wrote: Thu Jun 30, 2022 12:37 pm Is that not just a BG layer with solid-coloured tiles, animated via tilemap updates? Kinda like the Jurassic Park raycaster, but without Mode 7?
What are you referring to?
The big pixelated graphics in those gifs.

Super Mario RPG seems to do this too, for some smoothly animated fullscreen additive blend effects during combat. And like I said, Jurassic Park's indoor sequences use it to speed up the 3D rendering, exploiting Mode 7 to zoom out so as to display more and smaller pixels.
Ah, okay. Coolio.

The way the fps sections are done in Jurassic Park on SNES is really very cool imo, especially for a console that was never built for such a thing.

Similarly, I'm impressed with however they're doing the flying sections in Lawnmower Man (no idea how it's done):

https://youtu.be/PKZxhsZjI20?t=354
https://youtu.be/PKZxhsZjI20?t=604
https://youtu.be/PKZxhsZjI20?t=1019
https://youtu.be/PKZxhsZjI20?t=1084
https://youtu.be/PKZxhsZjI20?t=1739
https://youtu.be/PKZxhsZjI20?t=1924
https://youtu.be/PKZxhsZjI20?t=2262
https://youtu.be/PKZxhsZjI20?t=2316

Lot's of variation, all move at a nice speed and framerate, and just kinda cool.

I'm gonna go have a look at the Super Mario RPG examples.
iNCEPTIONAL

Re: Using window/shape mask directly on the background colour . . .

Post by iNCEPTIONAL »

Note: I just copied this over from a duplicate topic I made by mistake.

Now that I think about it more after having looked at rainwarrior's first reply/answer in this thread again, in the following video at 2:25 https://youtu.be/zcoU6-9_fDM?t=144, Retro Game Mechanics Explained talks of the SNES having six layers, and none of them seem to be the window/masks either, so, with a bit of expert design and coding, would it technically be possible to show what could actually look like a total of eight overlapping layers on the SNES?

Let's say, for my scrolling shmup, if I created a simple circle over the background colour using the method rainwarrior described previously (representing a planet in the distance), then four regular layers for standard overlapping mountains and other normal level stuff, then sprites faking another layer in the foreground, and lastly two window/mask shapes [silhouettes or something) that look like two objects moving even closer to the camera in front of everything else.

Would that technically be possible?

Edit: Actually, the planet would need to use one of the window/shape masks, so I think it would just be seven overlapping layers, if I have understood everything else correctly.
Last edited by iNCEPTIONAL on Tue Jul 19, 2022 3:22 pm, edited 3 times in total.
TrekkiesUnite118
Posts: 92
Joined: Fri Mar 08, 2013 5:56 pm

Re: Using window/shape mask directly on the background colour . . .

Post by TrekkiesUnite118 »

turboxray wrote: Thu Jun 30, 2022 9:50 am That is definitely not a true statement. I know you've been following my sprite line optimization tweets. I should probably do something similar for the SNES, but overall sprites, to dispel some of the myths about "128 sprites" advantages of the SNES.
Yeah, if you don't care about flickering or drop out isn't the Genesis still gonna come out on top here? There's games like Streets of Rage that just don't care about the limit and just keep drawing enemies at higher difficulty levels, and those still draw way more enemies before flickering than I think I've ever seen in any SNES beat'em up. I know doing 2 player at the hardest difficulty in Streets of Rage 1 draws a ridiculous amount of enemies on screen.
turboxray
Posts: 348
Joined: Thu Oct 31, 2019 12:56 am

Re: Using window/shape mask directly on the background colour . . .

Post by turboxray »

TrekkiesUnite118 wrote: Tue Jul 19, 2022 12:22 pm
turboxray wrote: Thu Jun 30, 2022 9:50 am That is definitely not a true statement. I know you've been following my sprite line optimization tweets. I should probably do something similar for the SNES, but overall sprites, to dispel some of the myths about "128 sprites" advantages of the SNES.
Yeah, if you don't care about flickering or drop out isn't the Genesis still gonna come out on top here? There's games like Streets of Rage that just don't care about the limit and just keep drawing enemies at higher difficulty levels, and those still draw way more enemies before flickering than I think I've ever seen in any SNES beat'em up. I know doing 2 player at the hardest difficulty in Streets of Rage 1 draws a ridiculous amount of enemies on screen.
Given the order of systems coming out: PCE, then MD, and then finally SuperGrafx came out before the SFC.. their approach for sprites is... a little odd. Then again, maybe they did update the sprite capabilities to what we have now. And originally it was worse. Yikes. But hey, no system is superior in all categories/areas. I guess that's what makes them fun to code for - pushing their limits.
User avatar
rainwarrior
Posts: 8732
Joined: Sun Jan 22, 2012 12:03 pm
Location: Canada
Contact:

Re: Using window/shape mask directly on the background colour . . .

Post by rainwarrior »

iNCEPTIONAL wrote: Tue Jul 19, 2022 10:34 amNow that I think about it more after having looked at rainwarrior's first reply/answer in this thread again, in the following video at 2:25 https://youtu.be/zcoU6-9_fDM?t=144, Retro Game Mechanics Explained talks of the SNES having six layers, and none of them seem to be the window/masks either, so, with a bit of expert design and coding, would it technically be possible to show what could actually look like a total of eight overlapping layers on the SNES?
Since you started a second thread, I've answered there:
viewtopic.php?p=281596#p281596
Post Reply