MCPcopy Create free account
hub / github.com/android/ndk-samples / Tick

Method Tick

native-activity/app/src/main/cpp/main.cpp:158–162  ·  view source on GitHub ↗

Entry point for Choreographer. The first argument (the frame time) is not used as it is not needed for this sample. If you copy from this sample and make use of that argument, note that there's an API bug: that time is a signed 32-bit nanosecond counter on 32-bit systems, so it will roll over every ~2 seconds. If your minSdkVersion is 29 or higher, use AChoreographer_postFrameCallback64 instead,

Source from the content-addressed store, hash-verified

156 ///
157 /// \param data The Engine being ticked.
158 static void Tick(long, void* data) {
159 CHECK_NOT_NULL(data);
160 auto engine = reinterpret_cast<Engine*>(data);
161 engine->DoTick();
162 }
163
164 void DoTick() {
165 if (!running_) {

Callers

nothing calls this directly

Calls 1

DoTickMethod · 0.80

Tested by

no test coverage detected