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

Method Resume

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

Resumes ticking the application.

Source from the content-addressed store, hash-verified

106
107 /// Resumes ticking the application.
108 void Resume() {
109 // This is called whenever the activity is resumed (brought into the
110 // foreground). When that happens, we schedule our next update tick with
111 // Choreographer. Choreographer is the Android system that paces app render
112 // loops. If you instead render new frames in a loop without frame pacing,
113 // you risk rendering more quickly than the display pipeline is able to
114 // present new frames. This will increase the latency between frame
115 // submission and presentation.
116 // https://developer.android.com/ndk/reference/group/choreographer
117
118 // Checked to make sure we don't double schedule Choreographer.
119 if (!running_) {
120 running_ = true;
121 ScheduleNextTick();
122 }
123 }
124
125 /// Pauses ticking the application.
126 ///

Callers 1

engine_handle_cmdFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected