diff --git a/libs/maps/include/mrpt/maps/CPointsMap.h b/libs/maps/include/mrpt/maps/CPointsMap.h index 177bca53fa..c813306f01 100644 --- a/libs/maps/include/mrpt/maps/CPointsMap.h +++ b/libs/maps/include/mrpt/maps/CPointsMap.h @@ -533,7 +533,7 @@ class CPointsMap : /// Gets the point weight, which is ignored in all classes (defaults to 1) /// but in those which actually store that field (Note: No checks are done /// for out-of-bounds index). \sa setPointWeight - virtual unsigned int getPointWeight([[maybe_unused]] size_t index) const { return 1; } + virtual unsigned long getPointWeight([[maybe_unused]] size_t index) const { return 1; } /** Provides a direct access to points buffer, or nullptr if there is no * points in the map. diff --git a/libs/maps/include/mrpt/maps/CWeightedPointsMap.h b/libs/maps/include/mrpt/maps/CWeightedPointsMap.h index 2fd4f93152..345ebfacf4 100644 --- a/libs/maps/include/mrpt/maps/CWeightedPointsMap.h +++ b/libs/maps/include/mrpt/maps/CWeightedPointsMap.h @@ -119,7 +119,7 @@ class CWeightedPointsMap : public CPointsMap /// Gets the point weight, which is ignored in all classes (defaults to 1) /// but in those which actually store that field (Note: No checks are done /// for out-of-bounds index). \sa setPointWeight - unsigned int getPointWeight(size_t index) const override { return pointWeight[index]; } + unsigned long getPointWeight(size_t index) const override { return pointWeight[index]; } protected: /** The points weights */ diff --git a/python/patch-013.diff b/python/patch-013.diff index 54839a5aa7..84bfbb7b0a 100644 --- a/python/patch-013.diff +++ b/python/patch-013.diff @@ -32,15 +32,6 @@ diff --git a/python/src/mrpt/maps/CPointsMap.cpp b/python/src/mrpt/maps/CPointsM index 6f4e1c86d..769c2e52c 100644 --- a/python/src/mrpt/maps/CPointsMap.cpp +++ b/python/src/mrpt/maps/CPointsMap.cpp -@@ -214,7 +214,7 @@ void bind_mrpt_maps_CPointsMap(std::function< pybind11::module &(std::string con - cl.def("setPoint", (void (mrpt::maps::CPointsMap::*)(size_t, const struct mrpt::math::TPoint3D_ &)) &mrpt::maps::CPointsMap::setPoint, "C++: mrpt::maps::CPointsMap::setPoint(size_t, const struct mrpt::math::TPoint3D_ &) --> void", pybind11::arg("index"), pybind11::arg("p")); - cl.def("setPoint", (void (mrpt::maps::CPointsMap::*)(size_t, float, float)) &mrpt::maps::CPointsMap::setPoint, "C++: mrpt::maps::CPointsMap::setPoint(size_t, float, float) --> void", pybind11::arg("index"), pybind11::arg("x"), pybind11::arg("y")); - cl.def("setPointRGB", (void (mrpt::maps::CPointsMap::*)(size_t, float, float, float, float, float, float)) &mrpt::maps::CPointsMap::setPointRGB, "overload (RGB data is ignored in classes without color information)\n\nC++: mrpt::maps::CPointsMap::setPointRGB(size_t, float, float, float, float, float, float) --> void", pybind11::arg("index"), pybind11::arg("x"), pybind11::arg("y"), pybind11::arg("z"), pybind11::arg("R"), pybind11::arg("G"), pybind11::arg("B")); -- cl.def("setPointWeight", (void (mrpt::maps::CPointsMap::*)(size_t, unsigned long)) &mrpt::maps::CPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CPointsMap::setPointWeight(size_t, unsigned long) --> void", pybind11::arg("index"), pybind11::arg("w")); -+ cl.def("setPointWeight", (void (mrpt::maps::CPointsMap::*)(size_t, uint64_t)) &mrpt::maps::CPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CPointsMap::setPointWeight(size_t, uint64_t) --> void", pybind11::arg("index"), pybind11::arg("w")); - cl.def("getPointWeight", (unsigned int (mrpt::maps::CPointsMap::*)(size_t) const) &mrpt::maps::CPointsMap::getPointWeight, "Gets the point weight, which is ignored in all classes (defaults to 1)\n but in those which actually store that field (Note: No checks are done\n for out-of-bounds index). \n\n setPointWeight\n\nC++: mrpt::maps::CPointsMap::getPointWeight(size_t) const --> unsigned int", pybind11::arg("index")); - cl.def("hasField_Intensity", (bool (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::hasField_Intensity, "C++: mrpt::maps::CPointsMap::hasField_Intensity() const --> bool"); - cl.def("hasField_Ring", (bool (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::hasField_Ring, "C++: mrpt::maps::CPointsMap::hasField_Ring() const --> bool"); @@ -259,7 +259,7 @@ void bind_mrpt_maps_CPointsMap(std::function< pybind11::module &(std::string con cl.def("setHeightFilterLevels", (void (mrpt::maps::CPointsMap::*)(const double, const double)) &mrpt::maps::CPointsMap::setHeightFilterLevels, "Set the min/max Z levels for points to be actually inserted in the map\n (only if was called before). \n\nC++: mrpt::maps::CPointsMap::setHeightFilterLevels(const double, const double) --> void", pybind11::arg("_z_min"), pybind11::arg("_z_max")); cl.def("getHeightFilterLevels", (void (mrpt::maps::CPointsMap::*)(double &, double &) const) &mrpt::maps::CPointsMap::getHeightFilterLevels, "Get the min/max Z levels for points to be actually inserted in the map\n \n\n enableFilterByHeight, setHeightFilterLevels \n\nC++: mrpt::maps::CPointsMap::getHeightFilterLevels(double &, double &) const --> void", pybind11::arg("_z_min"), pybind11::arg("_z_max")); @@ -50,25 +41,3 @@ index 6f4e1c86d..769c2e52c 100644 cl.def("kdtree_get_point_count", (size_t (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::kdtree_get_point_count, "Must return the number of data points\n\nC++: mrpt::maps::CPointsMap::kdtree_get_point_count() const --> size_t"); cl.def("kdtree_get_pt", (float (mrpt::maps::CPointsMap::*)(size_t, int) const) &mrpt::maps::CPointsMap::kdtree_get_pt, "Returns the dim'th component of the idx'th point in the class:\n\nC++: mrpt::maps::CPointsMap::kdtree_get_pt(size_t, int) const --> float", pybind11::arg("idx"), pybind11::arg("dim")); cl.def("kdtree_distance", (float (mrpt::maps::CPointsMap::*)(const float *, size_t, size_t) const) &mrpt::maps::CPointsMap::kdtree_distance, "Returns the distance between the vector \"p1[0:size-1]\" and the data\n point with index \"idx_p2\" stored in the class:\n\nC++: mrpt::maps::CPointsMap::kdtree_distance(const float *, size_t, size_t) const --> float", pybind11::arg("p1"), pybind11::arg("idx_p2"), pybind11::arg("size")); -diff --git a/python/src/mrpt/maps/CReflectivityGridMap2D.cpp b/python/src/mrpt/maps/CReflectivityGridMap2D.cpp -index c786c92ec..23fb62762 100644 ---- a/python/src/mrpt/maps/CReflectivityGridMap2D.cpp -+++ b/python/src/mrpt/maps/CReflectivityGridMap2D.cpp -@@ -589,7 +589,7 @@ struct PyCallBack_mrpt_maps_CWeightedPointsMap : public mrpt::maps::CWeightedPoi - } - return CWeightedPointsMap::addFrom_classSpecific(a0, a1, a2); - } -- void setPointWeight(size_t a0, unsigned long a1) override { -+ void setPointWeight(size_t a0, uint64_t a1) override { - pybind11::gil_scoped_acquire gil; - pybind11::function overload = pybind11::get_overload(static_cast(this), "setPointWeight"); - if (overload) { -@@ -1207,7 +1207,7 @@ void bind_mrpt_maps_CReflectivityGridMap2D(std::function< pybind11::module &(std - cl.def("setSize", (void (mrpt::maps::CWeightedPointsMap::*)(size_t)) &mrpt::maps::CWeightedPointsMap::setSize, "C++: mrpt::maps::CWeightedPointsMap::setSize(size_t) --> void", pybind11::arg("newLength")); - cl.def("insertPointFast", [](mrpt::maps::CWeightedPointsMap &o, float const & a0, float const & a1) -> void { return o.insertPointFast(a0, a1); }, "", pybind11::arg("x"), pybind11::arg("y")); - cl.def("insertPointFast", (void (mrpt::maps::CWeightedPointsMap::*)(float, float, float)) &mrpt::maps::CWeightedPointsMap::insertPointFast, "The virtual method for *without* calling\n mark_as_modified() \n\nC++: mrpt::maps::CWeightedPointsMap::insertPointFast(float, float, float) --> void", pybind11::arg("x"), pybind11::arg("y"), pybind11::arg("z")); -- cl.def("setPointWeight", (void (mrpt::maps::CWeightedPointsMap::*)(size_t, unsigned long)) &mrpt::maps::CWeightedPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::setPointWeight(size_t, unsigned long) --> void", pybind11::arg("index"), pybind11::arg("w")); -+ cl.def("setPointWeight", (void (mrpt::maps::CWeightedPointsMap::*)(size_t, uint64_t)) &mrpt::maps::CWeightedPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::setPointWeight(size_t, uint64_t) --> void", pybind11::arg("index"), pybind11::arg("w")); - cl.def("getPointWeight", (unsigned int (mrpt::maps::CWeightedPointsMap::*)(size_t) const) &mrpt::maps::CWeightedPointsMap::getPointWeight, "Gets the point weight, which is ignored in all classes (defaults to 1)\n but in those which actually store that field (Note: No checks are done\n for out-of-bounds index). \n\n setPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::getPointWeight(size_t) const --> unsigned int", pybind11::arg("index")); - - { // mrpt::maps::CWeightedPointsMap::TMapDefinitionBase file: line:74 diff --git a/python/patch-015.diff b/python/patch-015.diff deleted file mode 100644 index 0ba3e4757d..0000000000 --- a/python/patch-015.diff +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/python/src/mrpt/maps/CPointsMap.cpp b/python/src/mrpt/maps/CPointsMap.cpp -index c620355f8..3a240d9bb 100644 ---- a/python/src/mrpt/maps/CPointsMap.cpp -+++ b/python/src/mrpt/maps/CPointsMap.cpp -@@ -269,8 +269,8 @@ void bind_mrpt_maps_CPointsMap(std::function< pybind11::module &(std::string con - cl.def("nn_prepare_for_3d_queries", (void (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::nn_prepare_for_3d_queries, "C++: mrpt::maps::CPointsMap::nn_prepare_for_3d_queries() const --> void"); - cl.def("nn_has_indices_or_ids", (bool (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::nn_has_indices_or_ids, "C++: mrpt::maps::CPointsMap::nn_has_indices_or_ids() const --> bool"); - cl.def("nn_index_count", (size_t (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::nn_index_count, "C++: mrpt::maps::CPointsMap::nn_index_count() const --> size_t"); -- cl.def("nn_single_search", (bool (mrpt::maps::CPointsMap::*)(const struct mrpt::math::TPoint3D_ &, struct mrpt::math::TPoint3D_ &, float &, unsigned long &) const) &mrpt::maps::CPointsMap::nn_single_search, "C++: mrpt::maps::CPointsMap::nn_single_search(const struct mrpt::math::TPoint3D_ &, struct mrpt::math::TPoint3D_ &, float &, unsigned long &) const --> bool", pybind11::arg("query"), pybind11::arg("result"), pybind11::arg("out_dist_sqr"), pybind11::arg("resultIndexOrID")); -- cl.def("nn_single_search", (bool (mrpt::maps::CPointsMap::*)(const struct mrpt::math::TPoint2D_ &, struct mrpt::math::TPoint2D_ &, float &, unsigned long &) const) &mrpt::maps::CPointsMap::nn_single_search, "C++: mrpt::maps::CPointsMap::nn_single_search(const struct mrpt::math::TPoint2D_ &, struct mrpt::math::TPoint2D_ &, float &, unsigned long &) const --> bool", pybind11::arg("query"), pybind11::arg("result"), pybind11::arg("out_dist_sqr"), pybind11::arg("resultIndexOrID")); -+ cl.def("nn_single_search", (bool (mrpt::maps::CPointsMap::*)(const struct mrpt::math::TPoint3D_ &, struct mrpt::math::TPoint3D_ &, float &, uint64_t &) const) &mrpt::maps::CPointsMap::nn_single_search, "C++: mrpt::maps::CPointsMap::nn_single_search(const struct mrpt::math::TPoint3D_ &, struct mrpt::math::TPoint3D_ &, float &, uint64_t &) const --> bool", pybind11::arg("query"), pybind11::arg("result"), pybind11::arg("out_dist_sqr"), pybind11::arg("resultIndexOrID")); -+ cl.def("nn_single_search", (bool (mrpt::maps::CPointsMap::*)(const struct mrpt::math::TPoint2D_ &, struct mrpt::math::TPoint2D_ &, float &, uint64_t &) const) &mrpt::maps::CPointsMap::nn_single_search, "C++: mrpt::maps::CPointsMap::nn_single_search(const struct mrpt::math::TPoint2D_ &, struct mrpt::math::TPoint2D_ &, float &, uint64_t &) const --> bool", pybind11::arg("query"), pybind11::arg("result"), pybind11::arg("out_dist_sqr"), pybind11::arg("resultIndexOrID")); - - { // mrpt::maps::CPointsMap::TInsertionOptions file:mrpt/maps/CPointsMap.h line:228 - auto & enclosing_class = cl; diff --git a/python/src/mrpt/maps/CColouredOctoMap.cpp b/python/src/mrpt/maps/CColouredOctoMap.cpp index 63e24b1b15..8b1ca2e3fd 100644 --- a/python/src/mrpt/maps/CColouredOctoMap.cpp +++ b/python/src/mrpt/maps/CColouredOctoMap.cpp @@ -920,16 +920,16 @@ struct PyCallBack_mrpt_maps_CColouredPointsMap : public mrpt::maps::CColouredPoi } return CPointsMap::setPointWeight(a0, a1); } - unsigned int getPointWeight(size_t a0) const override { + unsigned long getPointWeight(size_t a0) const override { pybind11::gil_scoped_acquire gil; pybind11::function overload = pybind11::get_overload(static_cast(this), "getPointWeight"); if (overload) { auto o = overload.operator()(a0); - if (pybind11::detail::cast_is_temporary_value_reference::value) { - static pybind11::detail::override_caster_t caster; - return pybind11::detail::cast_ref(std::move(o), caster); + if (pybind11::detail::cast_is_temporary_value_reference::value) { + static pybind11::detail::override_caster_t caster; + return pybind11::detail::cast_ref(std::move(o), caster); } - else return pybind11::detail::cast_safe(std::move(o)); + else return pybind11::detail::cast_safe(std::move(o)); } return CPointsMap::getPointWeight(a0); } diff --git a/python/src/mrpt/maps/COctoMap.cpp b/python/src/mrpt/maps/COctoMap.cpp index eba933a784..246d2f7e50 100644 --- a/python/src/mrpt/maps/COctoMap.cpp +++ b/python/src/mrpt/maps/COctoMap.cpp @@ -860,16 +860,16 @@ struct PyCallBack_mrpt_maps_CSimplePointsMap : public mrpt::maps::CSimplePointsM } return CPointsMap::setPointWeight(a0, a1); } - unsigned int getPointWeight(size_t a0) const override { + unsigned long getPointWeight(size_t a0) const override { pybind11::gil_scoped_acquire gil; pybind11::function overload = pybind11::get_overload(static_cast(this), "getPointWeight"); if (overload) { auto o = overload.operator()(a0); - if (pybind11::detail::cast_is_temporary_value_reference::value) { - static pybind11::detail::override_caster_t caster; - return pybind11::detail::cast_ref(std::move(o), caster); + if (pybind11::detail::cast_is_temporary_value_reference::value) { + static pybind11::detail::override_caster_t caster; + return pybind11::detail::cast_ref(std::move(o), caster); } - else return pybind11::detail::cast_safe(std::move(o)); + else return pybind11::detail::cast_safe(std::move(o)); } return CPointsMap::getPointWeight(a0); } diff --git a/python/src/mrpt/maps/CPointCloudFilterByDistance.cpp b/python/src/mrpt/maps/CPointCloudFilterByDistance.cpp index 276a0578e4..bca8eb7298 100644 --- a/python/src/mrpt/maps/CPointCloudFilterByDistance.cpp +++ b/python/src/mrpt/maps/CPointCloudFilterByDistance.cpp @@ -463,16 +463,16 @@ struct PyCallBack_mrpt_maps_CPointsMapXYZI : public mrpt::maps::CPointsMapXYZI { } return CPointsMap::setPointWeight(a0, a1); } - unsigned int getPointWeight(size_t a0) const override { + unsigned long getPointWeight(size_t a0) const override { pybind11::gil_scoped_acquire gil; pybind11::function overload = pybind11::get_overload(static_cast(this), "getPointWeight"); if (overload) { auto o = overload.operator()(a0); - if (pybind11::detail::cast_is_temporary_value_reference::value) { - static pybind11::detail::override_caster_t caster; - return pybind11::detail::cast_ref(std::move(o), caster); + if (pybind11::detail::cast_is_temporary_value_reference::value) { + static pybind11::detail::override_caster_t caster; + return pybind11::detail::cast_ref(std::move(o), caster); } - else return pybind11::detail::cast_safe(std::move(o)); + else return pybind11::detail::cast_safe(std::move(o)); } return CPointsMap::getPointWeight(a0); } diff --git a/python/src/mrpt/maps/CPointsMap.cpp b/python/src/mrpt/maps/CPointsMap.cpp index 3a240d9bbe..19115641f4 100644 --- a/python/src/mrpt/maps/CPointsMap.cpp +++ b/python/src/mrpt/maps/CPointsMap.cpp @@ -214,8 +214,8 @@ void bind_mrpt_maps_CPointsMap(std::function< pybind11::module &(std::string con cl.def("setPoint", (void (mrpt::maps::CPointsMap::*)(size_t, const struct mrpt::math::TPoint3D_ &)) &mrpt::maps::CPointsMap::setPoint, "C++: mrpt::maps::CPointsMap::setPoint(size_t, const struct mrpt::math::TPoint3D_ &) --> void", pybind11::arg("index"), pybind11::arg("p")); cl.def("setPoint", (void (mrpt::maps::CPointsMap::*)(size_t, float, float)) &mrpt::maps::CPointsMap::setPoint, "C++: mrpt::maps::CPointsMap::setPoint(size_t, float, float) --> void", pybind11::arg("index"), pybind11::arg("x"), pybind11::arg("y")); cl.def("setPointRGB", (void (mrpt::maps::CPointsMap::*)(size_t, float, float, float, float, float, float)) &mrpt::maps::CPointsMap::setPointRGB, "overload (RGB data is ignored in classes without color information)\n\nC++: mrpt::maps::CPointsMap::setPointRGB(size_t, float, float, float, float, float, float) --> void", pybind11::arg("index"), pybind11::arg("x"), pybind11::arg("y"), pybind11::arg("z"), pybind11::arg("R"), pybind11::arg("G"), pybind11::arg("B")); - cl.def("setPointWeight", (void (mrpt::maps::CPointsMap::*)(size_t, uint64_t)) &mrpt::maps::CPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CPointsMap::setPointWeight(size_t, uint64_t) --> void", pybind11::arg("index"), pybind11::arg("w")); - cl.def("getPointWeight", (unsigned int (mrpt::maps::CPointsMap::*)(size_t) const) &mrpt::maps::CPointsMap::getPointWeight, "Gets the point weight, which is ignored in all classes (defaults to 1)\n but in those which actually store that field (Note: No checks are done\n for out-of-bounds index). \n\n setPointWeight\n\nC++: mrpt::maps::CPointsMap::getPointWeight(size_t) const --> unsigned int", pybind11::arg("index")); + cl.def("setPointWeight", (void (mrpt::maps::CPointsMap::*)(size_t, unsigned long)) &mrpt::maps::CPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CPointsMap::setPointWeight(size_t, unsigned long) --> void", pybind11::arg("index"), pybind11::arg("w")); + cl.def("getPointWeight", (unsigned long (mrpt::maps::CPointsMap::*)(size_t) const) &mrpt::maps::CPointsMap::getPointWeight, "Gets the point weight, which is ignored in all classes (defaults to 1)\n but in those which actually store that field (Note: No checks are done\n for out-of-bounds index). \n\n setPointWeight\n\nC++: mrpt::maps::CPointsMap::getPointWeight(size_t) const --> unsigned long", pybind11::arg("index")); cl.def("hasField_Intensity", (bool (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::hasField_Intensity, "C++: mrpt::maps::CPointsMap::hasField_Intensity() const --> bool"); cl.def("hasField_Ring", (bool (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::hasField_Ring, "C++: mrpt::maps::CPointsMap::hasField_Ring() const --> bool"); cl.def("hasField_Timestamp", (bool (mrpt::maps::CPointsMap::*)() const) &mrpt::maps::CPointsMap::hasField_Timestamp, "C++: mrpt::maps::CPointsMap::hasField_Timestamp() const --> bool"); diff --git a/python/src/mrpt/maps/CReflectivityGridMap2D.cpp b/python/src/mrpt/maps/CReflectivityGridMap2D.cpp index 4fc7df69e9..6902eb5512 100644 --- a/python/src/mrpt/maps/CReflectivityGridMap2D.cpp +++ b/python/src/mrpt/maps/CReflectivityGridMap2D.cpp @@ -576,7 +576,7 @@ struct PyCallBack_mrpt_maps_CWeightedPointsMap : public mrpt::maps::CWeightedPoi } return CWeightedPointsMap::addFrom_classSpecific(a0, a1, a2); } - void setPointWeight(size_t a0, uint64_t a1) override { + void setPointWeight(size_t a0, unsigned long a1) override { pybind11::gil_scoped_acquire gil; pybind11::function overload = pybind11::get_overload(static_cast(this), "setPointWeight"); if (overload) { @@ -589,16 +589,16 @@ struct PyCallBack_mrpt_maps_CWeightedPointsMap : public mrpt::maps::CWeightedPoi } return CWeightedPointsMap::setPointWeight(a0, a1); } - unsigned int getPointWeight(size_t a0) const override { + unsigned long getPointWeight(size_t a0) const override { pybind11::gil_scoped_acquire gil; pybind11::function overload = pybind11::get_overload(static_cast(this), "getPointWeight"); if (overload) { auto o = overload.operator()(a0); - if (pybind11::detail::cast_is_temporary_value_reference::value) { - static pybind11::detail::override_caster_t caster; - return pybind11::detail::cast_ref(std::move(o), caster); + if (pybind11::detail::cast_is_temporary_value_reference::value) { + static pybind11::detail::override_caster_t caster; + return pybind11::detail::cast_ref(std::move(o), caster); } - else return pybind11::detail::cast_safe(std::move(o)); + else return pybind11::detail::cast_safe(std::move(o)); } return CWeightedPointsMap::getPointWeight(a0); } @@ -1194,8 +1194,8 @@ void bind_mrpt_maps_CReflectivityGridMap2D(std::function< pybind11::module &(std cl.def("setSize", (void (mrpt::maps::CWeightedPointsMap::*)(size_t)) &mrpt::maps::CWeightedPointsMap::setSize, "C++: mrpt::maps::CWeightedPointsMap::setSize(size_t) --> void", pybind11::arg("newLength")); cl.def("insertPointFast", [](mrpt::maps::CWeightedPointsMap &o, float const & a0, float const & a1) -> void { return o.insertPointFast(a0, a1); }, "", pybind11::arg("x"), pybind11::arg("y")); cl.def("insertPointFast", (void (mrpt::maps::CWeightedPointsMap::*)(float, float, float)) &mrpt::maps::CWeightedPointsMap::insertPointFast, "The virtual method for *without* calling\n mark_as_modified() \n\nC++: mrpt::maps::CWeightedPointsMap::insertPointFast(float, float, float) --> void", pybind11::arg("x"), pybind11::arg("y"), pybind11::arg("z")); - cl.def("setPointWeight", (void (mrpt::maps::CWeightedPointsMap::*)(size_t, uint64_t)) &mrpt::maps::CWeightedPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::setPointWeight(size_t, uint64_t) --> void", pybind11::arg("index"), pybind11::arg("w")); - cl.def("getPointWeight", (unsigned int (mrpt::maps::CWeightedPointsMap::*)(size_t) const) &mrpt::maps::CWeightedPointsMap::getPointWeight, "Gets the point weight, which is ignored in all classes (defaults to 1)\n but in those which actually store that field (Note: No checks are done\n for out-of-bounds index). \n\n setPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::getPointWeight(size_t) const --> unsigned int", pybind11::arg("index")); + cl.def("setPointWeight", (void (mrpt::maps::CWeightedPointsMap::*)(size_t, unsigned long)) &mrpt::maps::CWeightedPointsMap::setPointWeight, "Sets the point weight, which is ignored in all classes but those which\n actually store that field (Note: No checks are done for out-of-bounds\n index). \n\n getPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::setPointWeight(size_t, unsigned long) --> void", pybind11::arg("index"), pybind11::arg("w")); + cl.def("getPointWeight", (unsigned long (mrpt::maps::CWeightedPointsMap::*)(size_t) const) &mrpt::maps::CWeightedPointsMap::getPointWeight, "Gets the point weight, which is ignored in all classes (defaults to 1)\n but in those which actually store that field (Note: No checks are done\n for out-of-bounds index). \n\n setPointWeight\n\nC++: mrpt::maps::CWeightedPointsMap::getPointWeight(size_t) const --> unsigned long", pybind11::arg("index")); { // mrpt::maps::CWeightedPointsMap::TMapDefinitionBase file: line:74 auto & enclosing_class = cl; diff --git a/python/stubs-out/mrpt/pymrpt/mrpt/maps.pyi b/python/stubs-out/mrpt/pymrpt/mrpt/maps.pyi index afb17efe5e..b57b5ea8d0 100644 --- a/python/stubs-out/mrpt/pymrpt/mrpt/maps.pyi +++ b/python/stubs-out/mrpt/pymrpt/mrpt/maps.pyi @@ -2873,7 +2873,7 @@ class CPointsMap(CMetricMap, mrpt.pymrpt.mrpt.opengl.PLY_Importer, mrpt.pymrpt.m @overload def getPointWeight(self, index: int) -> int: ... @overload - def getPointWeight(size_t) -> unsignedint: ... + def getPointWeight(size_t) -> unsignedlong: ... @overload def getVisualizationInto(self, outObj) -> None: ... @overload @@ -3041,7 +3041,7 @@ class CPointsMap(CMetricMap, mrpt.pymrpt.mrpt.opengl.PLY_Importer, mrpt.pymrpt.m @overload def setPointWeight(self, index: int, w: int) -> None: ... @overload - def setPointWeight(size_t, uint64_t) -> void: ... + def setPointWeight(size_t, unsignedlong) -> void: ... @overload def setSize(self, newLength: int) -> None: ... @overload @@ -4159,7 +4159,7 @@ class CWeightedPointsMap(CPointsMap): @overload def getPointWeight(self, index: int) -> int: ... @overload - def getPointWeight(size_t) -> unsignedint: ... + def getPointWeight(size_t) -> unsignedlong: ... @overload def insertPointFast(self, x: float, y: float) -> None: ... @overload @@ -4172,7 +4172,7 @@ class CWeightedPointsMap(CPointsMap): @overload def setPointWeight(self, index: int, w: int) -> None: ... @overload - def setPointWeight(size_t, uint64_t) -> void: ... + def setPointWeight(size_t, unsignedlong) -> void: ... @overload def setSize(self, newLength: int) -> None: ... @overload