Skip to content
Snippets Groups Projects
Commit c64934c3 authored by Arch de Noé's avatar Arch de Noé
Browse files

feat: add timing statistics

parent da1d3b32
Branches
No related merge requests found
......@@ -3,6 +3,7 @@
#include "marching_cubes.h"
#include <filesystem>
#include <chrono>
#include <imgui.h>
#include <pmp/surface_mesh.h>
#include <pmp/io/io.h>
......@@ -66,8 +67,15 @@ void MorphistViewer::process_imgui()
// Bake the meshes
if (this->is_baking)
{
auto start = std::chrono::high_resolution_clock::now();
morpher.load_mesh(mesh1_path, mesh2_path);
morpher.compute_sdf(this->bake_resolution);
auto end = std::chrono::high_resolution_clock::now();
const std::chrono::duration<double> duration = end - start;
std::cout << "SDF baking took " << duration << "" << std::endl;
this->is_baking = false;
this->is_mesh_baked = true;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment