MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / enableMarker

Method enableMarker

Engine/source/platform/profiler.cpp:637–657  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

635}
636
637void Profiler::enableMarker(const char *marker, bool enable)
638{
639 reset();
640 U32 markerLen = dStrlen(marker);
641 if(markerLen == 0)
642 return;
643 bool sn = marker[markerLen - 1] == '*';
644 for(ProfilerRootData *data = ProfilerRootData::sRootList; data; data = data->mNextRoot)
645 {
646 if(sn)
647 {
648 if(!dStrncmp(marker, data->mName, markerLen - 1))
649 data->mEnabled = enable;
650 }
651 else
652 {
653 if(!String::compare(marker, data->mName))
654 data->mEnabled = enable;
655 }
656 }
657}
658
659//=============================================================================
660// Console Functions.

Callers 1

profiler.cppFile · 0.80

Calls 4

resetFunction · 0.85
dStrncmpFunction · 0.85
compareFunction · 0.85
dStrlenFunction · 0.50

Tested by

no test coverage detected