Cogl.OnscreenResizeCallback
function onOnscreenResizeCallback(onscreen: Cogl.Onscreen, width: Number(gint), height: Number(gint)): void {
}
Is a callback type used with the Cogl.Onscreen.prototype.add_resize_callback allowing applications to be notified whenever an onscreen framebuffer is resized.
<note>Cogl automatically updates the viewport of an onscreen framebuffer that is resized so this callback is also an indication that the viewport has been modified too</note>
<note>A resize callback will only ever be called while dispatching Cogl events from the system mainloop; so for example during Cogl.poll_renderer_dispatch. This is so that callbacks shouldn't occur while an application might have arbitrary locks held for example.</note>
Since 2.0
- onscreen
A Cogl.Onscreen framebuffer that was resized
- width
The new width of onscreen
- height
The new height of onscreen