13,358,079 members (58,034 online)
alternative version

#### Stats

180.5K views
23 bookmarked
Posted 6 Feb 2002

# Tesselation of Mono Connected Non Convex Polygon

, 6 Feb 2002
 Rate this:
Tesselation of mono connected non convex polygon

## Introduction

A simple alternative to OpenGL polygon tesselation callback. You can focus on file triangle.h that contain the class to evaluate convexity of polygon and tesselate the polygon. No extra points are inserted. You can work only with planar polygon also in 3D.

Every suggestion in order to speed up the class and create better tesselation ('better' triangles) is appreciated.

## History

• 6th February, 2002: Initial post

## About the Author

 United States
No Biography provided

## Comments and Discussions

 First PrevNext
 cut object in slicing joy_nim24-Feb-06 7:01 joy_nim 24-Feb-06 7:01
 Possible error and fix GregDude21-Jul-05 16:34 GregDude 21-Jul-05 16:34
 Robust tesselation Skavenger1-Jul-05 23:04 Skavenger 1-Jul-05 23:04
 Re: Robust tesselation [modified] Liu Guoping9-Aug-06 16:51 Liu Guoping 9-Aug-06 16:51
 Re: Robust tesselation Skavenger310-Aug-06 2:42 Skavenger3 10-Aug-06 2:42
 Problem in CPolyTri::ComputeNormal Torsten B8-Jun-04 2:43 Torsten B 8-Jun-04 2:43
 Re: Problem in CPolyTri::ComputeNormal Sebastien Maraux13-Dec-04 4:52 Sebastien Maraux 13-Dec-04 4:52
 It could be better for performance issue to exclude the case of last j from the for loop, in order not to compute the modulo each time. I would do : normal[0]=normal[1]=normal[2]=0.0f; for( register int i=0 , j=1 ; j < nPoints ; i++ , j++ ){ normal[0]+= ( points[i][1] - points[j][1] ) * ( points[i][2] + points[j][2] ) ; normal[1]+= ( points[i][2] - points[j][2] ) * ( points[i][0] + points[j][0] ) ; normal[2]+= ( points[i][0] - points[j][0] ) * ( points[i][1] + points[j][1] ) ; } // last case : normal[0]+= ( points[i][1] - points[0][1] ) * ( points[i][2] + points[0][2] ) ; normal[1]+= ( points[i][2] - points[0][2] ) * ( points[i][0] + points[0][0] ) ; normal[2]+= ( points[i][0] - points[0][0] ) * ( points[i][1] + points[0][1] ) ; -------------------------------------------------- It would also be a good idea to delete Vector3F array in CPolyTryView::OnDraw(CDC* pDC) after call to triangulate() to avoid memory leaks !
 Re: Problem in CPolyTri::ComputeNormal Sébastien Maraux14-Dec-04 0:45 Sébastien Maraux 14-Dec-04 0:45
 Good Article mchapman123422-May-04 12:50 mchapman1234 22-May-04 12:50
 Found an index range error in code TruePyroman23-Feb-03 15:38 TruePyroman 23-Feb-03 15:38
 Re: Found an index range error in code topus10-Apr-03 3:46 topus 10-Apr-03 3:46
 Better tesselation jeckle8-Feb-02 10:00 jeckle 8-Feb-02 10:00
 Re: Better tesselation pepito10-Feb-02 23:05 pepito 10-Feb-02 23:05
 Re: Better tesselation jeckle11-Feb-02 11:46 jeckle 11-Feb-02 11:46
 Re: Better tesselation Rick York11-Feb-02 11:53 Rick York 11-Feb-02 11:53
 Better tesselation Tim Aidley8-Feb-02 3:45 Tim Aidley 8-Feb-02 3:45
 Re: Better tesselation kilowatt8-Feb-02 9:21 kilowatt 8-Feb-02 9:21
 Re: Better tesselation pepito sbarzeguti10-Feb-02 23:03 pepito sbarzeguti 10-Feb-02 23:03
 Guareschiano anche tu? Anonymous7-Feb-02 22:19 Anonymous 7-Feb-02 22:19
 Re: Guareschiano anche tu? Dieter Hammer8-Feb-02 1:04 Dieter Hammer 8-Feb-02 1:04
 Re: Guareschiano anche tu? pepito8-Feb-02 2:38 pepito 8-Feb-02 2:38
 Re: Guareschiano anche tu? Anonymous10-Feb-02 23:37 Anonymous 10-Feb-02 23:37
 Very poor article on very interesting subject... George7-Feb-02 15:25 George 7-Feb-02 15:25
 Re: Very poor article on very interesting subject... Pepito Sbarzeguti7-Feb-02 22:46 Pepito Sbarzeguti 7-Feb-02 22:46
 Re: Very poor article on very interesting subject... Anonymous7-Feb-02 22:47 Anonymous 7-Feb-02 22:47
 Last Visit: 31-Dec-99 19:00     Last Update: 24-Jan-18 1:59 Refresh 12 Next »

General    News    Suggestion    Question    Bug    Answer    Joke    Praise    Rant    Admin

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.