# Question about 2D Visibility

 Classic List Threaded
5 messages
Reply | Threaded
Open this post in threaded view
|

## Question about 2D Visibility

 Hi there， The example file of "Visibility_2/general_polygon_example.cpp " shows the visibility of a vertex which is on the polygon. Could you please give me an example of how to judge visibility of a vertex which is in the polygon area? Best regards, Andy Li. -- Sent from: http://cgal-discuss.949826.n4.nabble.com/-- You are currently subscribed to cgal-discuss. To unsubscribe or access the archives, go to https://sympa.inria.fr/sympa/info/cgal-discuss
Reply | Threaded
Open this post in threaded view
|

## Re: Question about 2D Visibility

 In this example: https://doc.cgal.org/latest/Visibility_2/Visibility_2_2simple_polygon_visibility_2_8cpp-example.htmlthe query is q a user given point. Sebastien. On 5/21/19 12:03 PM, Andy Li wrote: > Hi there， > > The example file of "Visibility_2/general_polygon_example.cpp " shows the > visibility of a vertex which is on the polygon. Could you please give me an > example of how to judge visibility of a vertex which is in the polygon area? > > Best regards, > Andy Li. > > > > -- > Sent from: http://cgal-discuss.949826.n4.nabble.com/> -- You are currently subscribed to cgal-discuss. To unsubscribe or access the archives, go to https://sympa.inria.fr/sympa/info/cgal-discuss
Reply | Threaded
Open this post in threaded view
|

## Re: Question about 2D Visibility

 Thanks for your reply. I noticed the example which you gave. But this example applies to simple polygon, not for the polygon with holes. The following example shows the 2D visibility of the boundary point of the polygon with holes, not for the inside point. Could you show me how to use this code to do that, please? Thank you. https://doc.cgal.org/latest/Visibility_2/Visibility_2_2general_polygon_example_8cpp-example.htmlBest regards, Andy Li -- Sent from: http://cgal-discuss.949826.n4.nabble.com/-- You are currently subscribed to cgal-discuss. To unsubscribe or access the archives, go to https://sympa.inria.fr/sympa/info/cgal-discuss
Reply | Threaded
Open this post in threaded view
|

## Re: Question about 2D Visibility

 In reply to this post by Sebastien Loriot (GeometryFactory) Thanks for your reply. I noticed the example which you gave. But this example applies to simple polygon, not for the polygon with holes. The following example shows the 2D visibility of the boundary point of the polygon with holes, not for the inside point. Could you show me how to use this code to do that, please? Thank you. https://doc.cgal.org/latest/Visibility_2/Visibility_2_2general_polygon_example_8cpp-example.htmlBest regards, Andy Li -- Sent from: http://cgal-discuss.949826.n4.nabble.com/-- You are currently subscribed to cgal-discuss. To unsubscribe or access the archives, go to https://sympa.inria.fr/sympa/info/cgal-discuss
Reply | Threaded
Open this post in threaded view
|

## Re: Question about 2D Visibility

 You can use the same function as from the other example, each example is using different functions documented here: https://doc.cgal.org/latest/Visibility_2/classVisibility__2.htmlWhat you have to do also is the locate part to get the face of the arrangement containing your query point, like in the other example. Sebastien. On 5/24/19 9:35 AM, Andy Li wrote: > Thanks for your reply. > > I noticed the example which you gave. But this example applies to simple > polygon, not for the polygon with holes. The following example shows the 2D > visibility of the boundary point of the polygon with holes, not for the > inside point. Could you show me how to use this code to do that, please? > Thank you. > > https://doc.cgal.org/latest/Visibility_2/Visibility_2_2general_polygon_example_8cpp-example.html> > Best regards, > Andy Li > > > > -- > Sent from: http://cgal-discuss.949826.n4.nabble.com/> -- You are currently subscribed to cgal-discuss. To unsubscribe or access the archives, go to https://sympa.inria.fr/sympa/info/cgal-discuss