File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
8000
path> Open diff view settings Original file line number Diff line number Diff line change @@ -277,7 +277,7 @@ void Triangulation::calculate_edges()
277277 }
278278
279279 // Convert to python _edges array.
280- npy_intp dims[2 ] = {edge_set.size (), 2 };
280+ npy_intp dims[2 ] = {static_cast <npy_intp>( edge_set.size () ), 2 };
281281 _edges = (PyArrayObject*)PyArray_SimpleNew (2 , dims, PyArray_INT);
282282 int * edges_ptr = (int *)PyArray_DATA (_edges);
283283 for (EdgeSet::const_iterator it = edge_set.begin (); it != edge_set.end (); ++it) {
@@ -571,7 +571,7 @@ Py::Object TriContourGenerator::contour_to_segs(const Contour& contour)
571571 Py::List segs (contour.size ());
572572 for (Contour::size_type i = 0 ; i < contour.size (); ++i) {
573573 const ContourLine& line = contour[i];
574- npy_intp dims[2 ] = {line.size (),2 };
574+ npy_intp dims[2 ] = {static_cast <npy_intp>( line.size () ),2 };
575575 PyArrayObject* py_line = (PyArrayObject*)PyArray_SimpleNew (
576576 2 , dims, PyArray_DOUBLE);
577577 double * p = (double *)PyArray_DATA (py_line);
Original file line number Diff line number Diff line change @@ -1353,7 +1353,7 @@ _add_polygon(Py::List& polygons, const std::vector<double>& polygon)
13531353 {
13541354 return ;
13551355 }
1356- npy_intp polygon_dims[] = { polygon.size () / 2 , 2 , 0 };
1356+ npy_intp polygon_dims[] = { static_cast <npy_intp>( polygon.size () / 2 ) , 2 , 0 };
13571357 PyArrayObject* polygon_array = NULL ;
13581358 polygon_array = (PyArrayObject*)PyArray_SimpleNew
13591359 (2 , polygon_dims, PyArray_DOUBLE);
You can’t perform that action at this time.
D23
0 commit comments