Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

remove empty holes of polygon

35 views
Skip to first unread message

dirk Baumann

unread,
Nov 30, 2011, 11:58:32 AM11/30/11
to
i try to remove holes from a 2d poylgon.

Input is the polygon on the right, an the result is on the left. see
picture: http://www.clevislauzon.qc.ca/arts/DOCXSI50/XSIPortal/cg06e26b.jpg

how do i get started ?

Alexandre Ferrieux

unread,
Nov 30, 2011, 2:18:14 PM11/30/11
to
On Nov 30, 5:58 pm, dirk Baumann <dirk.8.baum...@googlemail.com>
wrote:
Is this an algorithmic or display question ?
On the image, the input "polygon" is tiled with squares. What role do
they play in the model ? Is the input always a union of squares ?
output too ? other/fewer constraints ?
Also, what's the context ? Is this a school assignment ?

In short: wtf ?

-Alex

Harm Olthof

unread,
Nov 30, 2011, 3:41:46 PM11/30/11
to

Donald Arseneau

unread,
Nov 30, 2011, 5:49:25 PM11/30/11
to

dirk Baumann

unread,
Dec 1, 2011, 2:49:18 AM12/1/11
to
On 30 Nov., 20:18, Alexandre Ferrieux <alexandre.ferri...@gmail.com>
wrote:
> On Nov 30, 5:58 pm, dirk Baumann <dirk.8.baum...@googlemail.com>
> wrote:
>
> > i try to remove holes from a 2d poylgon.
>
> > Input is the polygon on the right, an the result is on the left. see
> > picture:http://www.clevislauzon.qc.ca/arts/DOCXSI50/XSIPortal/cg06e26b.jpg
>
> > how do i get started ?
>
> Is this an algorithmic or display question ?
algorithmic

> On the image, the input "polygon" is tiled with squares. What role do
> they play in the model ?
none

Is the input always a union of squares ?
no, any polygon is possible
> output too ?
no, output shoulb be 1 polygon
other/fewer constraints ?
no
> Also, what's the context ?
i want to "simplify" large polygons in cadence encounter
Is this a school assignment ?
no
>
> In short: wtf ?
ttf
>
> -Alex

dirk Baumann

unread,
Dec 1, 2011, 3:08:00 AM12/1/11
to
On 30 Nov., 23:49, Donald Arseneau <a...@triumf.ca> wrote:
> Donald Arseneau                          a...@triumf.ca

thats the opposite , i want to remove, not tu cut

Christian Gollwitzer

unread,
Dec 1, 2011, 5:50:43 AM12/1/11
to
On 30.11.2011 17:58, dirk Baumann wrote:
> i try to remove holes from a 2d poylgon.
>
> Input is the polygon on the right, an the result is on the left. see
> picture: http://www.clevislauzon.qc.ca/arts/DOCXSI50/XSIPortal/cg06e26b.jpg

1) Your picture is confusing, because people expect the direction from
left to right, you want right-to-left

2) You don't have a polygon, but a "polygonal mesh" - vertices connected
by edges

3) One simple hole filling algorithm for meshes goes like this: Assuming
you have identified the inner contour of the hole. Pick 3 adjacent
vertices on the contour, connect them to a triangle and add it to your
mesh. Now you have removed one vertex from the hole boundary. Repeat
until the hole is filled

4) For more sophisticated questions this way, try
comp.graphics.algorithms

Christian

Alexandre Ferrieux

unread,
Dec 1, 2011, 12:42:20 PM12/1/11
to
Do you realize how underspecified and cryptic your request is ?

Since you want an algorithmic solution, give the algorithmic
constraints:

- wanted representation of polygons:

- (simply connected polygon) -> one connected boundary

- (non-simply connected polygon) -> list of connected
boundaries

- (non-simply connected polygon) -> one connected boundary with
reversed paths, as suggested in the wiki page given to you by Harm

- degrees of freedom on the hole:

- completely known

- solves some optimization problem (like "smallest area
containing list-of-points and connected")

- etc.

-Alex


0 new messages