Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Center of a polygon

This topic is 6928 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I''m trying to find the center of a convex 3d polygon with n sides. How can I do this? One idea I had is to take every triangle in the polygon and find the center of each triangle by taking the intersection of the medians. Once I have the center of each triangle, I sum up all the centers and divide by the number of triangles to get the average, and that point is the center. My first question is, will this approach work? My second question is, how do I find the intersection of the medians? I know that I make two lines going from one vertex to the median of the opposite side, but how do I find the intersection of two 3d lines? Thanks in advance!! ----Blah

Share this post

Link to post
Share on other sites
Nevermind! I found this page:


Man, whoever wrote that is a life saver! The source code
is in fortran, which I have never used, but it is still
pretty easy to see what is going on.

I haven''t tested the code yet, but I bet it will work.
Sorry for posting the question guys, I guess I should have
looked around some more first. Well, back to


Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!