gstgl.glwindow
Module for [GLWindow] class
Types 3
classGLWindow : gst.object.ObjectWrap
GstGLWindow represents a window that elements can render into. A window can either be a user visible window (onscreen) or hidden (offscreen).
Methods
GLWindowGidBuilder builder()Get builder for [gstgl.glwindow.GLWindow] Returns: New builder objectbool controlsViewport()Checks if window controls the GL viewport. Returns: true if window controls the GL viewport, otherwise falsevoid draw()Redraw the window contents. Implementations should invoke the draw callback.size_t getDisplay()void getSurfaceDimensions(out uint width, out uint height)size_t getWindowHandle()void handleEvents(bool handleEvents)Tell a window that it should handle events from the window system. These events are forwarded upstream as navigation events. In some window systems events are not propagated in the window hierarchy...bool hasOutputSurface()Query whether window has output surface or not Returns: true if window has useable output surfacevoid queueResize()Queue resizing of window.void quit()Quit the runloop's execution.void resize(uint width, uint height)Resize window to the given width and height.void run()Start the execution of the runloop.void sendKeyEvent(string eventType, string keyStr)void sendMessage(gstgl.types.GLWindowCB callback)Invoke callback with data on the window thread. callback is guaranteed to have executed when this function returns.void sendMessageAsync(gstgl.types.GLWindowCB callback)Invoke callback with data on the window thread. The callback may not have been executed when this function returns.void sendMouseEvent(string eventType, int button, double posx, double posy)void sendScrollEvent(double posx, double posy, double deltaX, double deltaY)Notify a window about a scroll event. A scroll signal holding the event coordinates will be emitted.void setCloseCallback(gstgl.types.GLWindowCB callback)Sets the callback called when the window is about to close.void setDrawCallback(gstgl.types.GLWindowCB callback)Sets the draw callback called every time [gstgl.glwindow.GLWindow.draw] is calledvoid setPreferredSize(int width, int height)Set the preferred width and height of the window. Implementations are free to ignore this information.bool setRenderRectangle(int x, int y, int width, int height)Tell a window that it should render into a specific region of the window according to the #GstVideoOverlay interface.void setResizeCallback(gstgl.types.GLWindowResizeCB callback)Sets the resize callback called every time a resize of the window occurs.void setWindowHandle(size_t handle)Sets the window that this window should render into. Some implementations require this to be called with a valid handle before drawing can commence.void show()Present the window to the screen.gulong connectKeyEvent(T)(T callback, Flag!"After" after = No.After) if (isCallable!T
&& is(ReturnType!T == void)
&& (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] == string)))
&& (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] == string)))
&& (Parameters!T.length < 3 || (ParameterStorageClassTuple!T[2] == ParameterStorageClass.none && is(Parameters!T[2] : gstgl.glwindow.GLWindow)))
&& Parameters!T.length < 4)Connect to `KeyEvent` signal.gulong connectMouseEvent(T)(T callback, Flag!"After" after = No.After) if (isCallable!T
&& is(ReturnType!T == void)
&& (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] == string)))
&& (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] == int)))
&& (Parameters!T.length < 3 || (ParameterStorageClassTuple!T[2] == ParameterStorageClass.none && is(Parameters!T[2] == double)))
&& (Parameters!T.length < 4 || (ParameterStorageClassTuple!T[3] == ParameterStorageClass.none && is(Parameters!T[3] == double)))
&& (Parameters!T.length < 5 || (ParameterStorageClassTuple!T[4] == ParameterStorageClass.none && is(Parameters!T[4] : gstgl.glwindow.GLWindow)))
&& Parameters!T.length < 6)Connect to `MouseEvent` signal.gulong connectScrollEvent(T)(T callback, Flag!"After" after = No.After) if (isCallable!T
&& is(ReturnType!T == void)
&& (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] == double)))
&& (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] == double)))
&& (Parameters!T.length < 3 || (ParameterStorageClassTuple!T[2] == ParameterStorageClass.none && is(Parameters!T[2] == double)))
&& (Parameters!T.length < 4 || (ParameterStorageClassTuple!T[3] == ParameterStorageClass.none && is(Parameters!T[3] == double)))
&& (Parameters!T.length < 5 || (ParameterStorageClassTuple!T[4] == ParameterStorageClass.none && is(Parameters!T[4] : gstgl.glwindow.GLWindow)))
&& Parameters!T.length < 6)Connect to `ScrollEvent` signal.gulong connectWindowHandleChanged(T)(T callback, Flag!"After" after = No.After) if (isCallable!T
&& is(ReturnType!T == void)
&& (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gstgl.glwindow.GLWindow)))
&& Parameters!T.length < 2)Connect to `WindowHandleChanged` signal.