diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2024-09-11 12:29:18 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2024-09-11 12:29:18 -0400 |
commit | d5712689d36a1ee1af32242706901fde7229b08d (patch) | |
tree | 745cfe5c67504ea3154626ebc92c72bef0ff09e5 /indra/llrender/llglslshader.h | |
parent | 96e061547d15cb44dbe091e7aec507b2d9c87da2 (diff) |
Make Develop->Render Tests->Frame Profile dump JSON to a file too.
Make `LLGLSLShader::finishProfile()` accept a string pathname instead of a
bool and, in addition to logging statistics to the viewer log, output
statistics to that file as JSON. The calls that used to pass
`emit_report=false` now pass `report_name=std::string()`.
Make llviewerdisplay.cpp's `display()` function synthesize a profile filename
in the viewer's logs directory, and pass that filename to
`LLGLSLShader::finishProfile()`.
Diffstat (limited to 'indra/llrender/llglslshader.h')
-rw-r--r-- | indra/llrender/llglslshader.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/indra/llrender/llglslshader.h b/indra/llrender/llglslshader.h index 27c8f0b7d0..efcbaf42e8 100644 --- a/indra/llrender/llglslshader.h +++ b/indra/llrender/llglslshader.h @@ -30,6 +30,7 @@ #include "llgl.h" #include "llrender.h" #include "llstaticstringtable.h" +#include <boost/json.hpp> #include <unordered_map> class LLShaderFeatures @@ -169,14 +170,14 @@ public: static U32 sMaxGLTFNodes; static void initProfile(); - static void finishProfile(bool emit_report = true); + static void finishProfile(const std::string& report_name={}); static void startProfile(); static void stopProfile(); void unload(); void clearStats(); - void dumpStats(); + void dumpStats(boost::json::object& stats); // place query objects for profiling if profiling is enabled // if for_runtime is true, will place timer query only whether or not profiling is enabled |