All Downloads are FREE. Search and download functionalities are using the official Maven repository.

main.cesium.requestAnimationFrame.kt Maven / Gradle / Ivy

The newest version!
// Automatically generated - do not modify!

@file:JsModule("cesium")

package cesium

/**
 * A browser-independent function to request a new animation frame.  This is used to create
 * an application's draw loop as shown in the example below.
 * ```
 * // Create a draw loop using requestAnimationFrame. The
 * // tick callback function is called for every animation frame.
 * function tick() {
 *   scene.render();
 *   requestAnimationFrame(tick);
 * }
 * tick();
 * ```
 * @param [callback] The function to call when the next frame should be drawn.
 * @return An ID that can be passed to [cancelAnimationFrame] to cancel the request.
 * @see Online Documentation
 */
external fun requestAnimationFrame(callback: requestAnimationFrameCallback): Double




© 2015 - 2024 Weber Informatics LLC | Privacy Policy