From 5131ff921ef709ef2318c7ef1bda56e6222b5608 Mon Sep 17 00:00:00 2001 From: ManifoldFR Date: Sun, 19 May 2024 18:43:00 +0200 Subject: [PATCH 1/2] Bump minimum version of rerun to 0.16 --- .github/workflows/conda/conda-env.yml | 4 ++-- CMakeLists.txt | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/conda/conda-env.yml b/.github/workflows/conda/conda-env.yml index cef866c..752b9ff 100644 --- a/.github/workflows/conda/conda-env.yml +++ b/.github/workflows/conda/conda-env.yml @@ -11,7 +11,7 @@ dependencies: - gtest - pinocchio - eigen - - rerun-sdk - - librerun-sdk + - rerun-sdk'>=0.16' + - librerun-sdk'>=0.16' - fmt - example-robot-data diff --git a/CMakeLists.txt b/CMakeLists.txt index f815b7f..d3d0e66 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,7 +22,7 @@ add_project_dependency(pinocchio REQUIRED) add_project_dependency(pinocchio_visualizers REQUIRED) add_project_dependency(assimp REQUIRED) add_project_dependency(fmt 10.0 REQUIRED) -add_project_dependency(rerun_sdk REQUIRED) +add_project_dependency(rerun_sdk 0.16.0 REQUIRED) set(INSTALL_DOCUMENTATION OFF) set(CMAKE_VERBOSE_MAKEFILE OFF) From 5f720e6db5b1e4708bf38d493ab13b0ab20707c0 Mon Sep 17 00:00:00 2001 From: ManifoldFR Date: Sun, 19 May 2024 18:45:37 +0200 Subject: [PATCH 2/2] Fix load_mesh.cpp and conda-env.yml --- .github/workflows/conda/conda-env.yml | 4 ++-- src/load_mesh.cpp | 9 +++------ 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/.github/workflows/conda/conda-env.yml b/.github/workflows/conda/conda-env.yml index 752b9ff..ffe2e76 100644 --- a/.github/workflows/conda/conda-env.yml +++ b/.github/workflows/conda/conda-env.yml @@ -11,7 +11,7 @@ dependencies: - gtest - pinocchio - eigen - - rerun-sdk'>=0.16' - - librerun-sdk'>=0.16' + - rerun-sdk>=0.16.0 + - librerun-sdk>=0.16.0 - fmt - example-robot-data diff --git a/src/load_mesh.cpp b/src/load_mesh.cpp index a5fd8be..d6e1e8e 100644 --- a/src/load_mesh.cpp +++ b/src/load_mesh.cpp @@ -112,17 +112,14 @@ MeshDescription loadMesh(const std::string &meshPath, Vector3f scale, rerun::archetypes::Mesh3D meshDescriptionToRerun(MeshDescription &&mesh) { size_t numTris = mesh.faceTriangles.size(); - vector indices; + vector indices; for (size_t i = 0; i < numTris; i++) { Vector3u &tri = mesh.faceTriangles[i]; - indices.push_back(tri[0]); - indices.push_back(tri[1]); - indices.push_back(tri[2]); + indices.emplace_back(tri[0], tri[1], tri[2]); } auto rmesh = rerun::archetypes::Mesh3D(std::move(mesh.vertices)) - .with_mesh_properties( - rerun::components::MeshProperties(std::move(indices))) + .with_triangle_indices(std::move(indices)) .with_vertex_normals(std::move(mesh.normals)) .with_vertex_colors(std::move(mesh.colors)); return rmesh;