GstGLUtils
Functions
gst_gl_element_propagate_display_context
gst_gl_element_propagate_display_context (GstElement * element, GstGLDisplay * display)
Parameters:
element
–
display
–
GstGL.prototype.gl_element_propagate_display_context
function GstGL.prototype.gl_element_propagate_display_context(element: Gst.Element, display: GstGL.GLDisplay): {
// javascript wrapper for 'gst_gl_element_propagate_display_context'
}
Parameters:
GstGL.gl_element_propagate_display_context
def GstGL.gl_element_propagate_display_context (element, display):
#python wrapper for 'gst_gl_element_propagate_display_context'
Parameters:
gst_gl_ensure_element_data
gboolean gst_gl_ensure_element_data (gpointer element, GstGLDisplay ** display_ptr, GstGLContext ** other_context_ptr)
Perform the steps necessary for retrieving a GstGLDisplay and (optionally) an application provided GstGLContext from the surrounding elements or from the application using the GstContext mechanism.
If the contents of display_ptr or other_context_ptr are not NULL, then no GstContext query is necessary for GstGLDisplay or GstGLContext retrieval or is performed.
This performs GstContext queries (if necessary) for a winsys display connection with GST_GL_DISPLAY_CONTEXT_TYPE, "gst.x11.display.handle", and "GstWaylandDisplayHandleContextType" stopping after the first successful retrieval.
This also performs a GstContext query (if necessary) for an optional application provided GstGLContext using the name "gst.gl.app_context". The returned GstGLContext will be shared with a GStreamer created OpenGL context.
Parameters:
element
(
[typeGst.Element])
–
the GstElement running the query
display_ptr
(
[inout])
–
the resulting GstGLDisplay
other_context_ptr
(
[inout])
–
the resulting GstGLContext
whether a GstGLDisplay exists in display_ptr
GstGL.prototype.gl_ensure_element_data
function GstGL.prototype.gl_ensure_element_data(element: Gst.Element, display_ptr: GstGL.GLDisplay, other_context_ptr: GstGL.GLContext): {
// javascript wrapper for 'gst_gl_ensure_element_data'
}
Perform the steps necessary for retrieving a GstGL.GLDisplay and (optionally) an application provided GstGL.GLContext from the surrounding elements or from the application using the Gst.Context mechanism.
If the contents of display_ptr or other_context_ptr are not null, then no Gst.Context query is necessary for GstGL.GLDisplay or GstGL.GLContext retrieval or is performed.
This performs Gst.Context queries (if necessary) for a winsys display connection with GstGL.GL_DISPLAY_CONTEXT_TYPE, "gst.x11.display.handle", and "GstWaylandDisplayHandleContextType" stopping after the first successful retrieval.
This also performs a Gst.Context query (if necessary) for an optional application provided GstGL.GLContext using the name "gst.gl.app_context". The returned GstGL.GLContext will be shared with a GStreamer created OpenGL context.
Parameters:
the Gst.Element running the query
the resulting GstGL.GLDisplay
the resulting GstGL.GLContext
Returns a tuple made of:
whether a GstGL.GLDisplay exists in display_ptr
whether a GstGL.GLDisplay exists in display_ptr
whether a GstGL.GLDisplay exists in display_ptr
GstGL.gl_ensure_element_data
def GstGL.gl_ensure_element_data (element, display_ptr, other_context_ptr):
#python wrapper for 'gst_gl_ensure_element_data'
Perform the steps necessary for retrieving a GstGL.GLDisplay and (optionally) an application provided GstGL.GLContext from the surrounding elements or from the application using the Gst.Context mechanism.
If the contents of display_ptr or other_context_ptr are not None, then no Gst.Context query is necessary for GstGL.GLDisplay or GstGL.GLContext retrieval or is performed.
This performs Gst.Context queries (if necessary) for a winsys display connection with GstGL.GL_DISPLAY_CONTEXT_TYPE, "gst.x11.display.handle", and "GstWaylandDisplayHandleContextType" stopping after the first successful retrieval.
This also performs a Gst.Context query (if necessary) for an optional application provided GstGL.GLContext using the name "gst.gl.app_context". The returned GstGL.GLContext will be shared with a GStreamer created OpenGL context.
Parameters:
the Gst.Element running the query
the resulting GstGL.GLDisplay
the resulting GstGL.GLContext
Returns a tuple made of:
whether a GstGL.GLDisplay exists in display_ptr
whether a GstGL.GLDisplay exists in display_ptr
whether a GstGL.GLDisplay exists in display_ptr
gst_gl_get_affine_transformation_meta_as_ndc
gst_gl_get_affine_transformation_meta_as_ndc (GstVideoAffineTransformationMeta * meta, gfloat * matrix)
Retrieves the stored 4x4 affine transformation matrix stored in meta in NDC coordinates. if meta is NULL, an identity matrix is returned.
NDC is a left-handed coordinate system
- x - [-1, 1] - +ve X moves right
- y - [-1, 1] - +ve Y moves up
- z - [-1, 1] - +ve Z moves into
Parameters:
meta
(
[nullable])
–
matrix
(
[arrayfixed-size=16][out])
–
result of the 4x4 matrix
Since : 1.20
GstGL.prototype.gl_get_affine_transformation_meta_as_ndc
function GstGL.prototype.gl_get_affine_transformation_meta_as_ndc(meta: GstVideo.VideoAffineTransformationMeta): {
// javascript wrapper for 'gst_gl_get_affine_transformation_meta_as_ndc'
}
Retrieves the stored 4x4 affine transformation matrix stored in meta in NDC coordinates. if meta is NULL, an identity matrix is returned.
NDC is a left-handed coordinate system
- x - [-1, 1] - +ve X moves right
- y - [-1, 1] - +ve Y moves up
- z - [-1, 1] - +ve Z moves into
Parameters:
Since : 1.20
GstGL.gl_get_affine_transformation_meta_as_ndc
def GstGL.gl_get_affine_transformation_meta_as_ndc (meta):
#python wrapper for 'gst_gl_get_affine_transformation_meta_as_ndc'
Retrieves the stored 4x4 affine transformation matrix stored in meta in NDC coordinates. if meta is NULL, an identity matrix is returned.
NDC is a left-handed coordinate system
- x - [-1, 1] - +ve X moves right
- y - [-1, 1] - +ve Y moves up
- z - [-1, 1] - +ve Z moves into
Parameters:
Since : 1.20
gst_gl_get_plane_data_size
gsize gst_gl_get_plane_data_size (const GstVideoInfo * info, const GstVideoAlignment * align, guint plane)
Retrieve the size in bytes of a video plane of data with a certain alignment
Parameters:
info
–
align
–
a GstVideoAlignment or NULL
plane
–
plane number in info to retrieve the data size of
GstGL.prototype.gl_get_plane_data_size
function GstGL.prototype.gl_get_plane_data_size(info: GstVideo.VideoInfo, align: GstVideo.VideoAlignment, plane: Number): {
// javascript wrapper for 'gst_gl_get_plane_data_size'
}
Retrieve the size in bytes of a video plane of data with a certain alignment
Parameters:
plane number in info to retrieve the data size of
GstGL.gl_get_plane_data_size
def GstGL.gl_get_plane_data_size (info, align, plane):
#python wrapper for 'gst_gl_get_plane_data_size'
Retrieve the size in bytes of a video plane of data with a certain alignment
Parameters:
plane number in info to retrieve the data size of
gst_gl_get_plane_start
gsize gst_gl_get_plane_start (const GstVideoInfo * info, const GstVideoAlignment * valign, guint plane)
Parameters:
info
–
valign
–
a GstVideoAlignment or NULL
plane
–
plane number in info to retrieve the data size of
difference between the supposed start of the plane from the info and where the data from the previous plane ends.
GstGL.prototype.gl_get_plane_start
function GstGL.prototype.gl_get_plane_start(info: GstVideo.VideoInfo, valign: GstVideo.VideoAlignment, plane: Number): {
// javascript wrapper for 'gst_gl_get_plane_start'
}
Parameters:
plane number in info to retrieve the data size of
difference between the supposed start of the plane from the info and where the data from the previous plane ends.
GstGL.gl_get_plane_start
def GstGL.gl_get_plane_start (info, valign, plane):
#python wrapper for 'gst_gl_get_plane_start'
Parameters:
plane number in info to retrieve the data size of
difference between the supposed start of the plane from the info and where the data from the previous plane ends.
gst_gl_handle_context_query
gboolean gst_gl_handle_context_query (GstElement * element, GstQuery * query, GstGLDisplay * display, GstGLContext * context, GstGLContext * other_context)
Parameters:
element
–
query
–
a GstQuery of type GST_QUERY_CONTEXT
display
(
[transfer: none][nullable])
–
context
(
[transfer: none][nullable])
–
other_context
(
[transfer: none][nullable])
–
application provided GstGLContext
Whether the query was successfully responded to from the passed display, context, and other_context.
GstGL.prototype.gl_handle_context_query
function GstGL.prototype.gl_handle_context_query(element: Gst.Element, query: Gst.Query, display: GstGL.GLDisplay, context: GstGL.GLContext, other_context: GstGL.GLContext): {
// javascript wrapper for 'gst_gl_handle_context_query'
}
Whether the query was successfully responded to from the passed display, context, and other_context.
GstGL.gl_handle_context_query
def GstGL.gl_handle_context_query (element, query, display, context, other_context):
#python wrapper for 'gst_gl_handle_context_query'
Whether the query was successfully responded to from the passed display, context, and other_context.
gst_gl_handle_set_context
gboolean gst_gl_handle_set_context (GstElement * element, GstContext * context, GstGLDisplay ** display, GstGLContext ** other_context)
Helper function for implementing set_context() in OpenGL capable elements.
Retrieve's the GstGLDisplay or GstGLContext in context and places the result in display or other_context respectively.
Parameters:
element
–
context
–
display
(
[out][transfer: full])
–
location of a GstGLDisplay
other_context
(
[out][transfer: full])
–
location of a GstGLContext
whether the display or other_context could be set successfully
GstGL.prototype.gl_handle_set_context
function GstGL.prototype.gl_handle_set_context(element: Gst.Element, context: Gst.Context): {
// javascript wrapper for 'gst_gl_handle_set_context'
}
Helper function for implementing vfunc_set_context() in OpenGL capable elements.
Retrieve's the GstGL.GLDisplay or GstGL.GLContext in context and places the result in display or other_context respectively.
Returns a tuple made of:
whether the display or other_context could be set successfully
whether the display or other_context could be set successfully
whether the display or other_context could be set successfully
GstGL.gl_handle_set_context
def GstGL.gl_handle_set_context (element, context):
#python wrapper for 'gst_gl_handle_set_context'
Helper function for implementing do_set_context() in OpenGL capable elements.
Retrieve's the GstGL.GLDisplay or GstGL.GLContext in context and places the result in display or other_context respectively.
Returns a tuple made of:
whether the display or other_context could be set successfully
whether the display or other_context could be set successfully
whether the display or other_context could be set successfully
gst_gl_multiply_matrix4
gst_gl_multiply_matrix4 (const gfloat * a, const gfloat * b, gfloat * result)
Multiplies two 4x4 matrices, a and b, and stores the result, a 2-dimensional array of gfloat, in result.
Parameters:
a
(
[arrayfixed-size=16])
–
a 2-dimensional 4x4 array of gfloat
b
(
[arrayfixed-size=16])
–
another 2-dimensional 4x4 array of gfloat
result
(
[out][arrayfixed-size=16])
–
the result of the multiplication
Since : 1.20
GstGL.prototype.gl_multiply_matrix4
function GstGL.prototype.gl_multiply_matrix4(a: [ Number ], b: [ Number ]): {
// javascript wrapper for 'gst_gl_multiply_matrix4'
}
Multiplies two 4x4 matrices, a and b, and stores the result, a 2-dimensional array of Number, in result.
Parameters:
Since : 1.20
GstGL.gl_multiply_matrix4
def GstGL.gl_multiply_matrix4 (a, b):
#python wrapper for 'gst_gl_multiply_matrix4'
Multiplies two 4x4 matrices, a and b, and stores the result, a 2-dimensional array of float, in result.
Parameters:
Since : 1.20
gst_gl_set_affine_transformation_meta_from_ndc
gst_gl_set_affine_transformation_meta_from_ndc (GstVideoAffineTransformationMeta * meta, const gfloat * matrix)
Set the 4x4 affine transformation matrix stored in meta from the NDC coordinates in matrix.
Since : 1.20
GstGL.prototype.gl_set_affine_transformation_meta_from_ndc
function GstGL.prototype.gl_set_affine_transformation_meta_from_ndc(meta: GstVideo.VideoAffineTransformationMeta, matrix: [ Number ]): {
// javascript wrapper for 'gst_gl_set_affine_transformation_meta_from_ndc'
}
Set the 4x4 affine transformation matrix stored in meta from the NDC coordinates in matrix.
Parameters:
a 4x4 matrix
Since : 1.20
GstGL.gl_set_affine_transformation_meta_from_ndc
def GstGL.gl_set_affine_transformation_meta_from_ndc (meta, matrix):
#python wrapper for 'gst_gl_set_affine_transformation_meta_from_ndc'
Set the 4x4 affine transformation matrix stored in meta from the NDC coordinates in matrix.
Parameters:
a 4x4 matrix
Since : 1.20
gst_gl_value_get_texture_target_mask
GstGLTextureTarget gst_gl_value_get_texture_target_mask (const GValue * value)
See gst_gl_value_set_texture_target_from_mask for what entails a mask
Parameters:
value
–
an initialized GValue of type G_TYPE_STRING
the mask of GstGLTextureTarget's in value or GST_GL_TEXTURE_TARGET_NONE on failure
GstGL.prototype.gl_value_get_texture_target_mask
function GstGL.prototype.gl_value_get_texture_target_mask(value: GObject.Value): {
// javascript wrapper for 'gst_gl_value_get_texture_target_mask'
}
See GstGL.prototype.gl_value_set_texture_target_from_mask for what entails a mask
Parameters:
an initialized GObject.Value of type G_TYPE_STRING
the mask of GstGL.GLTextureTarget's in value or GstGL.GLTextureTarget.NONE on failure
GstGL.gl_value_get_texture_target_mask
def GstGL.gl_value_get_texture_target_mask (value):
#python wrapper for 'gst_gl_value_get_texture_target_mask'
See GstGL.gl_value_set_texture_target_from_mask for what entails a mask
Parameters:
an initialized GObject.Value of type G_TYPE_STRING
the mask of GstGL.GLTextureTarget's in value or GstGL.GLTextureTarget.NONE on failure
gst_gl_value_set_texture_target
gboolean gst_gl_value_set_texture_target (GValue * value, GstGLTextureTarget target)
whether the target could be set on value
GstGL.prototype.gl_value_set_texture_target
function GstGL.prototype.gl_value_set_texture_target(value: GObject.Value, target: GstGL.GLTextureTarget): {
// javascript wrapper for 'gst_gl_value_set_texture_target'
}
whether the target could be set on value
GstGL.gl_value_set_texture_target
def GstGL.gl_value_set_texture_target (value, target):
#python wrapper for 'gst_gl_value_set_texture_target'
whether the target could be set on value
gst_gl_value_set_texture_target_from_mask
gboolean gst_gl_value_set_texture_target_from_mask (GValue * value, GstGLTextureTarget target_mask)
A mask is a bitwise OR of (1 << target) where target is a valid GstGLTextureTarget
whether the target_mask could be set on value
GstGL.prototype.gl_value_set_texture_target_from_mask
function GstGL.prototype.gl_value_set_texture_target_from_mask(value: GObject.Value, target_mask: GstGL.GLTextureTarget): {
// javascript wrapper for 'gst_gl_value_set_texture_target_from_mask'
}
A mask is a bitwise OR of (1 << target) where target is a valid GstGL.GLTextureTarget
whether the target_mask could be set on value
GstGL.gl_value_set_texture_target_from_mask
def GstGL.gl_value_set_texture_target_from_mask (value, target_mask):
#python wrapper for 'gst_gl_value_set_texture_target_from_mask'
A mask is a bitwise OR of (1 << target) where target is a valid GstGL.GLTextureTarget
whether the target_mask could be set on value
The results of the search are