|
OpenTTD Source
14.0-beta1
|
Go to the documentation of this file.
10 #ifndef NEWGRF_PROFILING_H
11 #define NEWGRF_PROFILING_H
38 static uint32_t FinishAll();
59 extern std::vector<NewGRFProfiler> _newgrf_profilers;
std::vector< Call > calls
All calls collected so far.
uint32_t item
Local ID of item being resolved for.
uint64_t start_tick
Tick number this profiler was started on.
const GRFFile * grffile
Which GRF is being profiled.
static void AbortTimer()
Abort the timeout timer, so the timer callback is never called.
Measurement of a single sprite group resolution.
Interface for SpriteGroup-s to access the gamestate.
void RecursiveResolve()
Capture a recursive sprite group resolution.
CallbackID
List of implemented NewGRF callbacks.
NewGRFProfiler(const GRFFile *grffile)
Create profiler object and begin profiling session.
void EndResolve(const SpriteGroup *result)
Capture the completion of a sprite group resolution.
void BeginResolve(const ResolverObject &resolver)
Capture the start of a sprite group resolution.
static void StartTimer(uint64_t ticks)
Start the timeout timer that will finish all profiling sessions.
~NewGRFProfiler()
Complete profiling session and write data to file.
GrfSpecFeature feat
GRF feature being resolved for.
std::string GetOutputFilename() const
Get name of the file that will be written.
bool active
Is this profiler collecting data.
Call cur_call
Data for current call in progress.
uint32_t time
Time taken for resolution (microseconds)
Callback profiler for NewGRF development.
uint32_t result
Result of callback.
uint32_t subs
Sub-calls to other sprite groups.
CallbackID cb
Callback ID.
Dynamic data of a loaded NewGRF.
uint32_t root_sprite
Pseudo-sprite index in GRF file.