3D Polygon Rendering Engine!

Showcase your libraries, tools and other projects that help your fellow love users.
arundel
Prole
Posts: 31
Joined: Tue Sep 21, 2010 8:49 pm
Location: The Netherlands

Re: 3D Polygon Rendering Engine!

Post by arundel »

Hundreds of polygons are indeed fine. Around 150 gives 150-200 FPS, but when making a scene you'll always be worried about polygon count limits. Like Jasoco said, converting 3D to 2D is quite easily done, but when you have thousands of triangles you'll seriously have to start worrying about the framerate. Not because of the math (because if done right it has minimal impact), but because of the polygon limit, everything being drawn at once for each frame. I know optimisations sound easy to implement, like:
- not rendering what's outside the screen
- use bounding volumes (and octrees)
- don't render things too far away
etc.

But after all, you need to check each polygon (because it's hard implementing bounding volumes; you'll waste more time looping through tables than finding the bounding box first). So you have to be careful, some optimisations aren't beneficial at all if you do them in the wrong/inneficient way.
User avatar
Jasoco
Inner party member
Posts: 3726
Joined: Mon Jun 22, 2009 9:35 am
Location: Pennsylvania, USA
Contact:

Re: 3D Polygon Rendering Engine!

Post by Jasoco »

slime wrote:I definitely encourage you to use something like Unity3D if you really are interested in making a 3D game though. A few non-rectangular quads drawn with textures are a far cry from a full-fledged game, to put it mildly.
If I could figure out how the heck to use Unity, I wouldn't be using Löve. And I shall take offense to that last part my good sir. You give me the ability to do what your screenshot does and I will show you how much of a cry non-regular quads can be.
arundel wrote:But after all, you need to check each polygon (because it's hard implementing bounding volumes; you'll waste more time looping through tables than finding the bounding box first). So you have to be careful, some optimisations aren't beneficial at all if you do them in the wrong/inneficient way.
You need to break the "world" into sections. Like DOOM. Then you simply need to figure out which sections you can actually see, then render what's in those sections only. Or "sectors" as DOOM calls them. Basically you send your rays out and record which sectors they pass through before they hit something solid. Then run through that table to draw what was in those sectors. Ignoring everything outside your view.

The Star Fox type engine I'm working on does the whole distance thing. And will eventually do the sector thing if I need it.
scutheotaku
Party member
Posts: 235
Joined: Sat Dec 15, 2012 6:54 am

Re: 3D Polygon Rendering Engine!

Post by scutheotaku »

slime wrote: I definitely encourage you to use something like Unity3D if you really are interested in making a 3D game though. A few non-rectangular quads drawn with textures are a far cry from a full-fledged game, to put it mildly.
True, but I don't think most people here are necessarily interested in making a full-fledged, modern 3D game - or even a Quake 1 or Quake 2 era 3D game. Instead, it seems like most people are interested in more of a "retro" direction, e.g. Star Fox, Wolf3D, Doom, etc...

With that in mind, textured, non-rectangular quads would make it VERY easy to make something like this with LOVE:
http://www.regularkid.com/doom-style-renderer/
Jasoco wrote:
slime wrote:I definitely encourage you to use something like Unity3D if you really are interested in making a 3D game though. A few non-rectangular quads drawn with textures are a far cry from a full-fledged game, to put it mildly.
If I could figure out how the heck to use Unity, I wouldn't be using Löve. And I shall take offense to that last part my good sir. You give me the ability to do what your screenshot does and I will show you how much of a cry non-regular quads can be.
arundel wrote:But after all, you need to check each polygon (because it's hard implementing bounding volumes; you'll waste more time looping through tables than finding the bounding box first). So you have to be careful, some optimisations aren't beneficial at all if you do them in the wrong/inneficient way.
You need to break the "world" into sections. Like DOOM. Then you simply need to figure out which sections you can actually see, then render what's in those sections only. Or "sectors" as DOOM calls them. Basically you send your rays out and record which sectors they pass through before they hit something solid. Then run through that table to draw what was in those sectors. Ignoring everything outside your view.

The Star Fox type engine I'm working on does the whole distance thing. And will eventually do the sector thing if I need it.
[off topic]
I don't find Unity that hard to use (though it's not really my style, at least not for smaller projects). There are a lot of great tutorials for it these days - you should check it out again!

Also, it seems like any sort of BSP system would be way overkill for a StarFox style game...I think you'd be better off just using a viewport culling + octree solution (though, depending on your game, you could probably skip out on the octree part).
[/off topic]
User avatar
Jasoco
Inner party member
Posts: 3726
Joined: Mon Jun 22, 2009 9:35 am
Location: Pennsylvania, USA
Contact:

Re: 3D Polygon Rendering Engine!

Post by Jasoco »

scutheotaku wrote: [off topic]
I don't find Unity that hard to use (though it's not really my style, at least not for smaller projects). There are a lot of great tutorials for it these days - you should check it out again!

Also, it seems like any sort of BSP system would be way overkill for a StarFox style game...I think you'd be better off just using a viewport culling + octree solution (though, depending on your game, you could probably skip out on the octree part).
[/off topic]
I wouldn't use that for Star Fox, but I might use the idea in a future project.

Unity was way too confusing to figure the crap out when I tried it last. I might as well have been using 3D Studio Max because it's just as confusing to figure out.

One day I would like to figure it out though if I ever want to make a project of mine serious. I just hate their prices. It's seriously expensive just to release versions for the platforms people want. And all the features I'd want to use are pay only. And it's expensive. For instance iOS and Android support, both of which cost $400 separately. ($1500 if you want to go pro) If you ask me there should be one single Mobile option that encompasses iOS and Android and maybe Windows Phone in the future. It's just going to make people not want to release their games on the Android side because the iOS side is bigger. For $400/$1500 I might as well teach myself Cocoa and make my iPhone/iPad game for FREE using the tools Apple provides out of the box.

But yeah, if and when I want to get into more serious 3D, or even 2.5D, I will probably look at Unity again.

Edit: Also their website does not work properly at all in Chrome. How? How? But it works fine in Safari. Makes no sense that does!
scutheotaku
Party member
Posts: 235
Joined: Sat Dec 15, 2012 6:54 am

Re: 3D Polygon Rendering Engine!

Post by scutheotaku »

EDIT:
On second thought, I don't want to go too off topic...so I'll just message my response to Jasoco directly to him :) Sorry arundel!
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest