How to keep the order of input points in Efficient RANSAC?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

How to keep the order of input points in Efficient RANSAC?

nilram
Hi guys,

I'm new to CGAL, I follow the example to run a RANSAC on samples of a mesh (https://doc.cgal.org/latest/Point_set_shape_detection_3/Point_set_shape_detection_3_2efficient_RANSAC_point_access_8cpp-example.html), but I found the order of input points changed after that. Is there a way to keep the order of input points or like add an extra index property map to the points?

Thanks!

Best,
Lin
Reply | Threaded
Open this post in threaded view
|

Re: How to keep the order of input points in Efficient RANSAC?

Sebastien Loriot (GeometryFactory)
Note that if the input order of your points is important, you can store
you point in a vector for example and a range of ids as points.

Something similar to this example, CGAL::make_property_map(points) being
the points property map.
https://doc.cgal.org/latest/Spatial_sorting/Spatial_sorting_2sp_sort_using_property_map_3_8cpp-example.html


Sebastien.

On 12/28/2018 04:17 PM, Lin M wrote:

> Hi guys,
>
> I'm new to CGAL, I follow the example to run a RANSAC on samples of a
> mesh
> (https://doc.cgal.org/latest/Point_set_shape_detection_3/Point_set_shape_detection_3_2efficient_RANSAC_point_access_8cpp-example.html),
> but I found the order of input points changed after that. Is there a way
> to keep the order of input points or like add an extra index property
> map to the points?
>
> Thanks!
>
> Best,
> Lin

--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://sympa.inria.fr/sympa/info/cgal-discuss