@@ -126,7 +126,7 @@ data_to_polygon_with_holes(
126126
127127std::tuple<compas::RowMatrixXd, std::vector<int >, compas::RowMatrixXi, std::vector<int >>
128128pmp_create_interior_straight_skeleton (
129- const compas::RowMatrixXd& vertices)
129+ Eigen::Ref< const compas::RowMatrixXd> vertices)
130130{
131131 Polygon_2 polygon = data_to_polygon (vertices);
132132 SsPtr skeleton = CGAL::create_interior_straight_skeleton_2 (polygon.vertices_begin (), polygon.vertices_end ());
@@ -135,7 +135,7 @@ pmp_create_interior_straight_skeleton(
135135
136136std::tuple<compas::RowMatrixXd, std::vector<int >, compas::RowMatrixXi, std::vector<int >>
137137pmp_create_interior_straight_skeleton_with_holes (
138- const compas::RowMatrixXd& boundary_vertices,
138+ Eigen::Ref< const compas::RowMatrixXd> boundary_vertices,
139139 const std::vector<compas::RowMatrixXd>& hole_vertices)
140140{
141141 Polygon_with_holes polygon = data_to_polygon_with_holes (boundary_vertices, hole_vertices);
@@ -145,7 +145,7 @@ pmp_create_interior_straight_skeleton_with_holes(
145145
146146std::vector<compas::RowMatrixXd>
147147pmp_create_offset_polygons_2_inner (
148- const compas::RowMatrixXd& vertices,
148+ Eigen::Ref< const compas::RowMatrixXd> vertices,
149149 double & offset_distance)
150150{
151151 Polygon_2 polygon = data_to_polygon (vertices);
@@ -161,7 +161,7 @@ pmp_create_offset_polygons_2_inner(
161161
162162std::vector<std::vector<compas::RowMatrixXd>>
163163pmp_create_offset_polygons_2_inner_with_holes (
164- const compas::RowMatrixXd& boundary_vertices,
164+ Eigen::Ref< const compas::RowMatrixXd> boundary_vertices,
165165 const std::vector<compas::RowMatrixXd>& hole_vertices,
166166 double & offset_distance)
167167{
@@ -188,7 +188,7 @@ pmp_create_offset_polygons_2_inner_with_holes(
188188
189189std::vector<compas::RowMatrixXd>
190190pmp_create_offset_polygons_2_outer (
191- const compas::RowMatrixXd& vertices,
191+ Eigen::Ref< const compas::RowMatrixXd> vertices,
192192 double & offset_distance)
193193{
194194 Polygon_2 polygon = data_to_polygon (vertices);
@@ -204,7 +204,7 @@ pmp_create_offset_polygons_2_outer(
204204
205205std::vector<std::vector<compas::RowMatrixXd>>
206206pmp_create_offset_polygons_2_outer_with_holes (
207- const compas::RowMatrixXd& boundary_vertices,
207+ Eigen::Ref< const compas::RowMatrixXd> boundary_vertices,
208208 const std::vector<compas::RowMatrixXd>& hole_vertices,
209209 double & offset_distance)
210210{
@@ -226,9 +226,9 @@ pmp_create_offset_polygons_2_outer_with_holes(
226226
227227std::vector<compas::RowMatrixXd>
228228pmp_create_weighted_offset_polygons_2_inner (
229- const compas::RowMatrixXd& vertices,
229+ Eigen::Ref< const compas::RowMatrixXd> vertices,
230230 double offset_distance,
231- const compas::RowMatrixXd& edge_weights)
231+ Eigen::Ref< const compas::RowMatrixXd> edge_weights)
232232{
233233 if (edge_weights.rows () != vertices.rows ()) {
234234 throw std::invalid_argument (" Number of weights must match number of polygon vertices" );
@@ -264,9 +264,9 @@ pmp_create_weighted_offset_polygons_2_inner(
264264
265265std::vector<compas::RowMatrixXd>
266266pmp_create_weighted_offset_polygons_2_outer (
267- const compas::RowMatrixXd& vertices,
267+ Eigen::Ref< const compas::RowMatrixXd> vertices,
268268 double offset_distance,
269- const compas::RowMatrixXd& edge_weights)
269+ Eigen::Ref< const compas::RowMatrixXd> edge_weights)
270270{
271271 if (edge_weights.rows () != vertices.rows ()) {
272272 throw std::invalid_argument (" Number of weights must match number of polygon vertices" );
0 commit comments