Class of android.view · Choreographer.java · Android's reference
public final class Choreographer
Frames: input, animation, traversal and commit callbacks, in that order, once for each vsync. The vsync is the window's present pace (snx.android.ui.Window drives frames); without a window, a 60 Hz timer.
public static final int CALLBACK_INPUT = 0 sourcepublic static final int CALLBACK_ANIMATION = 1 sourcepublic static final int CALLBACK_INSETS_ANIMATION = 2 sourcepublic static final int CALLBACK_TRAVERSAL = 3 sourcepublic static final int CALLBACK_COMMIT = 4 sourcepublic static Choreographer getInstance() sourcepublic static Choreographer getMainThreadInstance() sourcepublic static long getFrameDelay() sourcepublic static void setFrameDelay(long frameDelay) empty body sourcepublic static void setVsyncSource(Runnable request) sourceHow the window asks for the next vsync: it calls doFrame then. Null for the timer.
public long getFrameTime() sourcepublic long getFrameTimeNanos() sourcepublic long getLastFrameTimeNanos() sourcepublic long getFrameIntervalNanos() sourcepublic void postFrameCallback(FrameCallback callback) sourcepublic void postFrameCallbackDelayed(FrameCallback callback, long delayMillis) sourcepublic void removeFrameCallback(FrameCallback callback) sourcepublic void postCallback(int callbackType, Runnable action, Object token) sourcepublic void postCallbackDelayed(int callbackType, Runnable action, Object token, long delayMillis) sourcepublic void removeCallbacks(int callbackType, Runnable action, Object token) sourcepublic void postVsyncCallback(VsyncCallback callback) sourcepublic void removeVsyncCallback(VsyncCallback callback) empty body sourcepublic void doFrame(long frameTimeNanos) sourceA frame: the callbacks due now, by type. The window calls it at each vsync it was asked for.
Made from ScarletNX's Sail at 166ad3910f80. The framework is ScarletNX's (GPL-3.0-or-later); the parts that follow the Android Open Source Project's sources (Apache-2.0) say so in their files.