polygon demo

Discussion of hardware and software development for Super NES and Super Famicom.

Moderator: Moderators

Forum rules
  • For making cartridges of your Super NES games, see Reproduction.
psycopathicteen
Posts: 3001
Joined: Wed May 19, 2010 6:12 pm

polygon demo

Post by psycopathicteen »

This demo shows a rotating triangle. This is entirely done with the CPU. No cheating involved.
Attachments
polygon demo.zip
(2.19 KiB) Downloaded 183 times
tepples
Posts: 22345
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: polygon demo

Post by tepples »

Good job so far. Now try adding a couple more triangles, having them spin around a few times, and then drawing them together in the first iteration of the Sierpinski triangle:
  ▲
▲ ▲
(Bet you noobs can't do that.)

Then all you need to do is draw some elfin-looking pretty boy and make a bunch of dungeons for him to run around and murder* in.


* I was disappointed that after having stealthed through the upper levels of the first castle in ALTTP, I had to kill someone in the basement to proceed.
User avatar
Bregalad
Posts: 8036
Joined: Fri Nov 12, 2004 2:49 pm
Location: Caen, France

Re: polygon demo

Post by Bregalad »

Mmh, no offense, but that's nothing special or ground breaking. A lot of SNES games (such as Tales of Phantasia) does effects like that during gameplay.
psycopathicteen
Posts: 3001
Joined: Wed May 19, 2010 6:12 pm

Re: polygon demo

Post by psycopathicteen »

I forgot about window effects, but my polygon engine can eventually be able to do 3d.
magno
Posts: 193
Joined: Tue Aug 15, 2006 5:23 am
Location: Spain
Contact:

Re: polygon demo

Post by magno »

Really nice! It could be a good start to calculate how many flat polygons can draw the SNES per second!
User avatar
tokumaru
Posts: 12106
Joined: Sat Feb 12, 2005 9:43 pm
Location: Rio de Janeiro - Brazil

Re: polygon demo

Post by tokumaru »

Bregalad wrote:Mmh, no offense, but that's nothing special or ground breaking.
IMO what makes this not so interesting is that there's a much more impressive demo running on a less capable console!
psycopathicteen
Posts: 3001
Joined: Wed May 19, 2010 6:12 pm

Re: polygon demo

Post by psycopathicteen »

How does he even transfer the image at 30 or 60 fps full screen?
User avatar
Bregalad
Posts: 8036
Joined: Fri Nov 12, 2004 2:49 pm
Location: Caen, France

Re: polygon demo

Post by Bregalad »

I forgot about window effects, but my polygon engine can eventually be able to do 3d.
Yeah that's pretty much what I was expecting to see when I downloaded it, so sorry if I was a bit disappointed by seeing only a simple triangle, that's just that my expectations were too high from the start, e.g. "polygon" usually means 3d while "triangle" or whathever usually means 2d, even if technically (in math terms) it's wrong and both refer to either a 2D shape or a 2D shape in a 3D space.

Well long story short, the only additional difficulty if you're not using window clipping is that you have to somehow cheat the tilemap/tiles screen in order to show this, which I think is the point of your demo, so yeah nice work.

I can't say for this particular demo (I mean the NES one tokumaru talked about), but for me the key point in simulating bitmaps on NES is to cheat and don't use the tilemap as a bitmap (this is impossible, since the NES doesn't have enough tiles, not even talking about the extremely low transfer bandwith....). Instead you keep solid tiles for solid colored areas, and makes only border tiles using actually pseudo-bitmapped tiles. This not only reduces the VRAM usage, but also the bandwith for typical cases (but don't work in an arbirtary case where you fill the screen with details, of course, when it runs out of drawable tiles it simply can't show anything more).
User avatar
benjaminsantiago
Posts: 84
Joined: Mon Jan 20, 2014 9:40 pm
Location: Astoria, NY
Contact:

Re: polygon demo

Post by benjaminsantiago »

Hey this demo as well as the other NES are quite nice.

I'm curious, have you tried to run this on real hardware, or at least BSNES?

Also what is your end goal with these, are you trying to do some pure 3D stuff ala Star Fox, a 2D game with something triforce like as tepples mentioned, just demos, some kind of 3D "engine" for other folks to use?
psycopathicteen
Posts: 3001
Joined: Wed May 19, 2010 6:12 pm

Re: polygon demo

Post by psycopathicteen »

Possibly an engine somebody else will use, since I have am busy with other projects.

It appears that using his "XOR-filling" method is faster at rendering several polys than mine is at rendering one, but it has the limitation that polys can't overlap. Maybe if I use a second buffer, one for edges, another for the actual screen, I would be able to do the "XOR-filling" method but be able to do overlapping.
Optiroc
Posts: 129
Joined: Thu Feb 07, 2013 1:15 am
Location: Sweden

Re: polygon demo

Post by Optiroc »

"No cheating" is not really a good trait when dealing with quirky slow machines like these... :twisted:
Kannagi
Posts: 100
Joined: Sun May 11, 2014 8:36 am
Location: France

Re: polygon demo

Post by Kannagi »

I think it's a good job.

After a game, make 3D CPU is slow, it's already slow to 3D software(cpu) is a recent engine is not very fast.
tepples
Posts: 22345
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: polygon demo

Post by tepples »

Ian Bell's tank demo for NES dynamically allocates tiles to non-solid areas.
psycopathicteen
Posts: 3001
Joined: Wed May 19, 2010 6:12 pm

Re: polygon demo

Post by psycopathicteen »

Added Z-axis, and optimized the code a bit.
Attachments
polygon demo 2.zip
(2.3 KiB) Downloaded 123 times
User avatar
Bregalad
Posts: 8036
Joined: Fri Nov 12, 2004 2:49 pm
Location: Caen, France

Re: polygon demo

Post by Bregalad »

Well it's an improvement, but still doesn't loook very 3D, you could easily do something like that in Mode-7 or using window clipping, so it's not too impressive.
Will you end up displaying Star-Fox like graphics ? (without the FX chip, that is) ? That'd be very cool.
Post Reply