Java-Gaming.org Hi !
 Featured games (90) games approved by the League of Dukes Games in Showcase (773) Games in Android Showcase (230) games submitted by our members Games in WIP (856) games currently in development
 News: Read the Java Gaming Resources, or peek at the official Java tutorials
Pages: [1]
 ignore  |  Print
 3D polygon triangulation algorithm  (Read 5896 times) 0 Members and 1 Guest are viewing this topic.
RobinB

JGO Ninja

Medals: 45
Projects: 1
Exp: 3 years

Spacegame in progress

 « Posted 2013-04-22 20:56:45 »

Hello,

For an simple experiment im trying to generate random 3D meshes.
Now im having multiple points in 3d space that needs to be connected with triangles.
Does anyone have some known algorith names or any point toward the correct direction?
The only stuff i can find is about 2d polygons.

Robin
gouessej
 « Reply #1 - Posted 2013-04-22 23:13:57 »

What do you mean by "3D polygon"? A polygon is in a plane, isn't it?

Julien Gouesse | Personal blog | Website | Jogamp
HeroesGraveDev

JGO Kernel

Medals: 382
Projects: 11
Exp: 4 years

┬─┬ノ(ಠ_ಠノ)(╯°□°)╯︵ ┻━┻

 « Reply #2 - Posted 2013-04-22 23:20:59 »

I think 3D polygon is supposed to mean a 2D polygon in 3D space.

Otherwise we would be talking about polyhedra, and that wouldn't make sense.

Anyway, the solution to the problem: Add a z-coordinate.

Agro
 « Reply #3 - Posted 2013-04-22 23:22:56 »

Well, there is a problem. It depends on if you want it to be concave or convex, and if you randomly generate completely random points, it won't work. You'll have to make sure that chosen points don't already intersect the polygon.

Same for polyhedrons, so it doesn't really matter in 2D or 3D, just the overlaying problem of it being a shape at all.

HeroesGraveDev

JGO Kernel

Medals: 382
Projects: 11
Exp: 4 years

┬─┬ノ(ಠ_ಠノ)(╯°□°)╯︵ ┻━┻

 « Reply #4 - Posted 2013-04-22 23:24:39 »

Same for polyhedrons, so it doesn't really matter in 2D or 3D, just the overlaying problem of it being a shape at all.

What the heck is a 2D polyhedron?

Agro
 « Reply #5 - Posted 2013-04-22 23:25:07 »

Sorry, I meant it doesn't matter if its a 2D polygon or a 3D polyhedron.

HeroesGraveDev

JGO Kernel

Medals: 382
Projects: 11
Exp: 4 years

┬─┬ノ(ಠ_ಠノ)(╯°□°)╯︵ ┻━┻

 « Reply #6 - Posted 2013-04-22 23:26:42 »

Sorry, I meant it doesn't matter if its a 2D polygon or a 3D polyhedron.

Okay.

You'll have to make sure that chosen points don't already intersect the polygon.

But the 2D tutorials will surely show how to avoid that?

Agro
 « Reply #7 - Posted 2013-04-22 23:27:09 »

Well, then, it really isn't a problem anymore then

RobinB

JGO Ninja

Medals: 45
Projects: 1
Exp: 3 years

Spacegame in progress

 « Reply #8 - Posted 2013-04-23 07:52:04 »

I guess i did not explain myself very well.
My apologies, i may have used the wrong terms.

I want to achive this:

But then in 3d space (around a point cloud).
There is very little info about it, so i dont rally know how to call it.
RobinB

JGO Ninja

Medals: 45
Projects: 1
Exp: 3 years

Spacegame in progress

 « Reply #9 - Posted 2013-04-23 10:52:49 »

With some googling with more energy i found something what seems like what i would need:
Pages: [1]
 ignore  |  Print

 EgonOlsen (1855 views) 2018-06-10 19:43:48 EgonOlsen (1882 views) 2018-06-10 19:43:44 EgonOlsen (1250 views) 2018-06-10 19:43:20 DesertCoockie (1682 views) 2018-05-13 18:23:11 nelsongames (1348 views) 2018-04-24 18:15:36 nelsongames (1967 views) 2018-04-24 18:14:32 ivj94 (2737 views) 2018-03-24 14:47:39 ivj94 (1940 views) 2018-03-24 14:46:31 ivj94 (3030 views) 2018-03-24 14:43:53 Solater (1081 views) 2018-03-17 05:04:08
 Deployment and Packagingby mudlee2018-08-22 18:09:50Java Gaming Resourcesby gouessej2018-08-22 08:19:41Deployment and Packagingby gouessej2018-08-22 08:04:08Deployment and Packagingby gouessej2018-08-22 08:03:45Deployment and Packagingby philfrei2018-08-20 02:33:38Deployment and Packagingby philfrei2018-08-20 02:29:55Deployment and Packagingby philfrei2018-08-19 23:56:20Deployment and Packagingby philfrei2018-08-19 23:54:46
 java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org