|
| static void | _wlcl_dblbuf_callback_if_ready (wlcl_dblbuf_t *dblbuf_ptr) |
| static void | _wlcl_dblbuf_handle_frame_done (void *data_ptr, struct wl_callback *callback, uint32_t time) |
| static bool | _wlcl_dblbuf_create_buffer (wlcl_buffer_t *buffer_ptr, wlcl_dblbuf_t *dblbuf_ptr, struct wl_shm_pool *wl_shm_pool_ptr, unsigned page, unsigned width, unsigned height) |
| static void | _wlcl_dblbuf_handle_wl_buffer_release (void *data_ptr, struct wl_buffer *wl_buffer_ptr) |
| static int | _wlcl_dblbuf_shm_create (const char *app_id_ptr, size_t size) |
| wlcl_dblbuf_t * | wlcl_dblbuf_create (const char *app_id_ptr, struct wl_surface *wl_surface_ptr, struct wl_shm *wl_shm_ptr, unsigned width, unsigned height) |
| void | wlcl_dblbuf_destroy (wlcl_dblbuf_t *dblbuf_ptr) |
| void | wlcl_dblbuf_register_ready_callback (wlcl_dblbuf_t *dblbuf_ptr, wlcl_dblbuf_ready_callback_t callback, void *callback_ud_ptr) |
- Copyright
- Copyright 2025 Google LLC
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Registers a callback for when a frame can be drawn into the buffer.
The frame can be drawn if (1) it is due, and (2) there is a back buffer available ("released") for drawing into. If these conditions hold true, callback will be called right away. Otherwise, it will be called once these conditions are fulfilled.
The callback will be called only once. If the client wishes further notifications, they must call wlcl_dblbuf_register_ready_callback again.
The callback must be registered only after the surface is ready. Eg. for an XDG toplevel, after it has received & acknowledged configure.
- Parameters
-
| dblbuf_ptr | |
| callback | The callback function, or NULL to clear the callback. |
| callback_ud_ptr | Argument to use for callback. |