mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2024-12-29 03:19:44 +00:00
Report loading screens to osg stats
This commit is contained in:
parent
739ff70a82
commit
a920ca9070
@ -343,7 +343,12 @@ namespace MWGui
|
||||
|
||||
MWBase::Environment::get().getInputManager()->update(0, true, true);
|
||||
|
||||
mResourceSystem->reportStats(mViewer->getFrameStamp()->getFrameNumber(), mViewer->getViewerStats());
|
||||
osg::Stats* const stats = mViewer->getViewerStats();
|
||||
const unsigned frameNumber = mViewer->getFrameStamp()->getFrameNumber();
|
||||
|
||||
stats->setAttribute(frameNumber, "Loading", 1);
|
||||
|
||||
mResourceSystem->reportStats(frameNumber, stats);
|
||||
if (osgUtil::IncrementalCompileOperation* ico = mViewer->getIncrementalCompileOperation())
|
||||
{
|
||||
ico->setMinimumTimeAvailableForGLCompileAndDeletePerFrame(1.f / getTargetFrameRate());
|
||||
|
@ -54,6 +54,7 @@ namespace Resource
|
||||
constexpr std::string_view firstPage[] = {
|
||||
"FrameNumber",
|
||||
"",
|
||||
"Loading",
|
||||
"Compiling",
|
||||
"WorkQueue",
|
||||
"WorkThread",
|
||||
@ -75,7 +76,6 @@ namespace Resource
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
};
|
||||
|
||||
static_assert(std::size(firstPage) == itemsPerPage);
|
||||
|
Loading…
Reference in New Issue
Block a user