* Capture the start of a sprite group resolution. * @param resolver Data about sprite group being resolved */
| 46 | * @param resolver Data about sprite group being resolved |
| 47 | */ |
| 48 | void NewGRFProfiler::BeginResolve(const ResolverObject &resolver) |
| 49 | { |
| 50 | using namespace std::chrono; |
| 51 | this->cur_call.root_sprite = resolver.root_spritegroup->nfo_line; |
| 52 | this->cur_call.subs = 0; |
| 53 | this->cur_call.time = (uint32_t)time_point_cast<microseconds>(high_resolution_clock::now()).time_since_epoch().count(); |
| 54 | this->cur_call.tick = TimerGameTick::counter; |
| 55 | this->cur_call.cb = resolver.callback; |
| 56 | this->cur_call.feat = resolver.GetFeature(); |
| 57 | this->cur_call.item = resolver.GetDebugID(); |
| 58 | } |
| 59 | |
| 60 | /** |
| 61 | * Capture the completion of a sprite group resolution. |
no test coverage detected