Skip to content

Commit

Permalink
add version method to bindings
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanhhughes committed Dec 12, 2024
1 parent 9743cc9 commit de79f15
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions python/bindings/spark_dsg_bindings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
#include <spark_dsg/scene_graph_utilities.h>
#include <spark_dsg/serialization/file_io.h>
#include <spark_dsg/serialization/graph_binary_serialization.h>
#include <spark_dsg/serialization/versioning.h>

#include <iomanip>
#include <iostream>
Expand Down Expand Up @@ -828,5 +829,8 @@ PYBIND11_MODULE(_dsg_bindings, module) {
"child_layer"_a = DsgLayers::PLACES,
"bbox_type"_a = BoundingBox::Type::AABB);

module.def("version",
[]() { return spark_dsg::io::FileHeader::current().version.toString(); });

py::implicitly_convertible<char, LayerPrefix>();
}

0 comments on commit de79f15

Please sign in to comment.