MayaFlux 0.1.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ glfw_framebuffer_size_callback()

void MayaFlux::Core::GlfwWindow::glfw_framebuffer_size_callback ( GLFWwindow *  window,
int  width,
int  height 
)
staticprivate

Definition at line 295 of file GlfwWindow.cpp.

296{
297 auto* win = static_cast<GlfwWindow*>(glfwGetWindowUserPointer(window));
298 if (!win)
299 return;
300
301 WindowEvent event;
303 event.timestamp = glfwGetTime();
304 event.data = WindowEvent::ResizeData {
305 .width = static_cast<uint32_t>(width),
306 .height = static_cast<uint32_t>(height)
307 };
308
309 win->m_event_source.signal(event);
310
311 if (win->m_event_callback) {
312 win->m_event_callback(event);
313 }
314}
GlfwWindow(const WindowCreateInfo &create_info, const GraphicsSurfaceInfo &surface_info, GlobalGraphicsConfig::GraphicsApi api, GlfwPreInitConfig pre_init_config={})
Creates a window with the given configuration.

References MayaFlux::Core::FRAMEBUFFER_RESIZED, MayaFlux::Core::WindowEvent::type, and MayaFlux::Core::WindowEvent::ResizeData::width.

Referenced by setup_callbacks().

+ Here is the caller graph for this function: