Skip to content

Commit

Permalink
qa
Browse files Browse the repository at this point in the history
  • Loading branch information
tomadamatkinson committed Jun 24, 2024
1 parent 7afbca4 commit 1e16cb9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 13 deletions.
21 changes: 9 additions & 12 deletions components/core/include/core/util/profiling.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,25 +25,22 @@
#include "core/util/error.hpp"

#ifdef TRACY_ENABLE
#include <tracy/Tracy.hpp>
# include <tracy/Tracy.hpp>
#endif




#ifdef TRACY_ENABLE
// malloc and free are used by Tracy to provide memory profiling
void *operator new(size_t count);
void operator delete(void *ptr) noexcept;

// Tracy a scope
#define PROFILE_SCOPE(name) ZoneScopedN(name)
# define PROFILE_SCOPE(name) ZoneScopedN(name)

// Trace a function
#define PROFILE_FUNCTION() ZoneScoped
# define PROFILE_FUNCTION() ZoneScoped
#else
#define PROFILE_SCOPE(name)
#define PROFILE_FUNCTION()
# define PROFILE_SCOPE(name)
# define PROFILE_FUNCTION()
#endif

// The type of plot to use
Expand Down Expand Up @@ -116,10 +113,10 @@ class Plot
private:
static void update_tracy_plot(const char *name, T value)
{
#ifdef TRACY_ENABLE
TracyPlot(name, value);
TracyPlotConfig(name, TO_TRACY_PLOT_FORMAT(PT), true, true, 0);
#endif
#ifdef TRACY_ENABLE
TracyPlot(name, value);
TracyPlotConfig(name, TO_TRACY_PLOT_FORMAT(PT), true, true, 0);
#endif
}

static Plot *get_instance()
Expand Down
2 changes: 1 addition & 1 deletion framework/hpp_gui.h
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ struct HPPFont
}

std::vector<uint8_t> data;
ImFont *handle = nullptr;
ImFont *handle = nullptr;
std::string name;
float size = 0.0f;
};
Expand Down

0 comments on commit 1e16cb9

Please sign in to comment.