Procedural Geometry

Threads related to Google Summer of Code
Post Reply
vhpgomes
Gnoblar
Posts: 8
Joined: Fri Jun 04, 2004 12:27 am
Location: São Paulo / Brazil
Contact:

Procedural Geometry

Post by vhpgomes » Fri Mar 16, 2007 7:26 pm

Hello,

I'm currently working on a project that shows a surface given its parametric equations.

Here are two examples:


Sea Shell:
x(u,v) = a*(1-v/(2*pi))*cos(n*v)*(1+cos(u))+c*cos(n*v)
y(u,v) = a*(1-v/(2*pi))*sin(n*v)*(1+cos(u))+c*sin(n*v)
z(u,v) = b*v/(2*pi)+a*(1-v/(2*pi))*sin(u)
with, u = [0,2*pi] ; v = [0,2*pi]
n = 4;
a = 20;
b = 100;
c = 5
Image


Klein's Bottle:
x(u,v) =
S*(A*cos(u)*(1+sin(u))+(4*(1-cos(u)/2))*cos(u)*cos(v)), if u < pi,
S*(A*cos(u)*(1+sin(u))+(4*(1-cos(u)/2))*cos(v+pi))), if u >= pi

y(u,v) =
S*(B*sin(u)+(4*(1-cos(u)/2))*sin(u)*cos(v)), if u < pi,
S*B*sin(u)), if u >= pi

z(u,v) = S*(4*(1-cos(u)/2))*sin(v)

with, u = [0,2*pi] ; v = [0,2*pi]
A = 6;
B = 16;
S = 5;
Image

I was wondering if I could apply for the Summer of Code with this... I mean, I could add some functionalities, and make an addon or something...

Thanks for any feedback,

Victor
0 x

User avatar
Kencho
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 4011
Joined: Fri Sep 19, 2003 6:28 pm
Location: Burgos, Spain
x 1
Contact:

Post by Kencho » Fri Mar 16, 2007 9:03 pm

Seems interesting, though I think you should offer maybe a little more general kinds of geometry. I might be wrong, but the idea I have of procedural meshes is not only that, but also terrain generation, or even "cities" (at a very large scale).
Procedural textures would be a great plus in my opinion as well.
0 x
Image

vhpgomes
Gnoblar
Posts: 8
Joined: Fri Jun 04, 2004 12:27 am
Location: São Paulo / Brazil
Contact:

Post by vhpgomes » Sat Mar 17, 2007 2:34 am

I agree that I should offer more, and that's one of the main reasons I posted the previous message, to get ideas.

I also have doubts of what procedural geometries, meshes, or textures are. Only used the "procedural" term due to the "Procedural Media" task in the HelpWanted page (http://www.ogre3d.org/wiki/index.php/He ... ural_Media)

Another feature that I think I should be able to add is Constructive Solid Geometry (CSG) http://en.wikipedia.org/wiki/Constructi ... d_geometry
0 x

QuantumG
Kobold
Posts: 36
Joined: Wed Jun 15, 2005 1:57 am

Post by QuantumG » Sat Mar 17, 2007 2:44 am

Very cool stuff. As you are obviously experienced in this sort of thing, do you think you could make something mundate with this system? I mean, like a coffee cup or a door handle.

The great hope of procedural content like this is that you can have a model of the world which is richer than that actually displayed. So you can describe exactly what it is you want and then have an algorithm (even an offline algorithm) take that information and make a mesh that is practical for the current application. For example, a game may require very low poly meshes, whereas a animated film requires as high poly meshes as you can practically render (or even raytracing).

Of course, if all you can generate is exotic shapes, that's not particularly useful for this application.
0 x

User avatar
Kencho
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 4011
Joined: Fri Sep 19, 2003 6:28 pm
Location: Burgos, Spain
x 1
Contact:

Post by Kencho » Sat Mar 17, 2007 5:26 am

vhpgomes wrote:I agree that I should offer more, and that's one of the main reasons I posted the previous message, to get ideas.

I also have doubts of what procedural geometries, meshes, or textures are. Only used the "procedural" term due to the "Procedural Media" task in the HelpWanted page (http://www.ogre3d.org/wiki/index.php/He ... ural_Media)

Another feature that I think I should be able to add is Constructive Solid Geometry (CSG) http://en.wikipedia.org/wiki/Constructi ... d_geometry
CSG is in my opinion far from procedural generated meshes. A procedural mesh or texture is one that can be generated completely using an algorithm and tweaking variables. A typical example of procedural geometry is creating a box on the fly instead of having it stored in a file. Obviously, procedural cubes are pointless, but some people has managed to even create cities (not intensively detailed!) this way.
I've recently read a feature article on Gamasutra from the guys of Darwinia, a game that has a lot of procedural media (indeed, I think they only hand-made a small part of it). Worth reading it if you plan on taking this project ;)
0 x
Image

QuantumG
Kobold
Posts: 36
Joined: Wed Jun 15, 2005 1:57 am

Post by QuantumG » Sat Mar 17, 2007 8:49 am

Doesn't really matter if the object is "stored in a file", the point is that an algorithm created it, not someone sitting at a 3d modelling program placing vertexes.
0 x

User avatar
syedhs
Silver Sponsor
Silver Sponsor
Posts: 2702
Joined: Mon Aug 29, 2005 3:24 pm
Location: Kuala Lumpur, Malaysia
x 3

Post by syedhs » Sat Mar 17, 2007 11:54 am

Procedural terrain along with lakes and roads would be very nice.
0 x

mirlix
Goblin
Posts: 225
Joined: Mon May 01, 2006 12:03 am
Location: Germany

Post by mirlix » Sat Mar 17, 2007 12:54 pm

Intel has a great paper how to great a procedural landscape with trees , lakes and clouds. Maybe this can help

http://www.intel.com/cd/ids/developer/a ... /20247.htm

I think procedural content is a the next step for gamedev to cut down the development time/cost for games and it would be great to have ogre support it.
0 x

User avatar
sinbad
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 19265
Joined: Sun Oct 06, 2002 11:19 pm
Location: Guernsey, Channel Islands
x 2
Contact:

Post by sinbad » Sat Mar 17, 2007 5:38 pm

Yes, rather than just shapes, I personally was thinking about 'procedural content' - so that might be terrain, foliage, cities, cave systems. Clearly that's not just geometry but also textures (although if time were short pre-authored textures could be used, but UVs would have to be generated).

Individual shapes are useful, but to be a significant project I think you'd have to pick some kind of more holistic environment you were trying to make. The ultimate goal of this kind of thing would be to be able to generate a large amount of content which stands on its own merits, not just abstract mathematical shapes. There wouldn't be time to make a completely generic system but I think you could pick one of those types of environments and tackle it in a summer.
0 x

Professor420
Greenskin
Posts: 116
Joined: Fri Jul 28, 2006 9:35 am
Contact:

Post by Professor420 » Sun Mar 18, 2007 7:04 am

I am pretty sure the Darwinia team used procedural content creation quite extensively... I know there is a tool they wrote to procedurally generate cities for one of their games (not sure which one, before or after Darwinia). I'm sure you can find the article somewh... wait, here it is.

http://lostgarden.com/2007/02/content-is-bad.html
This has links at the end as well.

http://www.gamecareerguide.com/features ... php?page=1
0 x

User avatar
Frenetic
Bugbear
Posts: 806
Joined: Fri Feb 03, 2006 7:08 am

Post by Frenetic » Sun Mar 18, 2007 7:28 am

Hey! What about teapots? ;)
0 x

Post Reply