Top | ![]() |
![]() |
![]() |
![]() |
GstVaapiDisplay *
gst_vaapi_display_new_with_display (VADisplay va_display
);
Creates a new GstVaapiDisplay, using va_display
as the VA
display.
GstVaapiDisplay *
gst_vaapi_display_ref (GstVaapiDisplay *display
);
Atomically increases the reference count of the given display
by one.
void
gst_vaapi_display_unref (GstVaapiDisplay *display
);
Atomically decreases the reference count of the display
by one. If
the reference count reaches zero, the display will be free'd.
void gst_vaapi_display_replace (GstVaapiDisplay **old_display_ptr
,GstVaapiDisplay *new_display
);
Atomically replaces the display display held in old_display_ptr
with new_display
. This means that old_display_ptr
shall reference
a valid display. However, new_display
can be NULL.
void
gst_vaapi_display_lock (GstVaapiDisplay *display
);
Locks display
. If display
is already locked by another thread,
the current thread will block until display
is unlocked by the
other thread.
void
gst_vaapi_display_unlock (GstVaapiDisplay *display
);
Unlocks display
. If another thread is blocked in a
gst_vaapi_display_lock()
call for display
, it will be woken and
can lock display
itself.
void
gst_vaapi_display_sync (GstVaapiDisplay *display
);
Flushes any requests queued for the windowing system and waits until all requests have been handled. This is often used for making sure that the display is synchronized with the current state of the program.
This is most useful for X11. On windowing systems where requests are handled synchronously, this function will do nothing.
void
gst_vaapi_display_flush (GstVaapiDisplay *display
);
Flushes any requests queued for the windowing system.
This is most useful for X11. On windowing systems where requests are handled synchronously, this function will do nothing.
GstVaapiDisplayType
gst_vaapi_display_get_class_type (GstVaapiDisplay *display
);
Returns the GstVaapiDisplayType of display
. This is the type of
the object, thus the associated class, not the type of the VA
display.
GstVaapiDisplayType
gst_vaapi_display_get_display_type (GstVaapiDisplay *display
);
Returns the display
name.
const gchar *
gst_vaapi_display_get_display_name (GstVaapiDisplay *display
);
VADisplay
gst_vaapi_display_get_display (GstVaapiDisplay *display
);
Returns the VADisplay bound to display
.
guint
gst_vaapi_display_get_width (GstVaapiDisplay *display
);
Retrieves the width of a GstVaapiDisplay.
guint
gst_vaapi_display_get_height (GstVaapiDisplay *display
);
Retrieves the height of a GstVaapiDisplay
void gst_vaapi_display_get_size (GstVaapiDisplay *display
,guint *pwidth
,guint *pheight
);
Retrieves the dimensions of a GstVaapiDisplay.
void gst_vaapi_display_get_pixel_aspect_ratio (GstVaapiDisplay *display
,guint *par_n
,guint *par_d
);
Retrieves the pixel aspect ratio of a GstVaapiDisplay.
gboolean
gst_vaapi_display_has_video_processing
(GstVaapiDisplay *display
);
Checks whether the underlying VA driver implementation supports video processing (VPP) acceleration.
GArray *
gst_vaapi_display_get_decode_profiles (GstVaapiDisplay *display
);
Gets the supported profiles for decoding. The caller owns an extra
reference to the resulting array of GstVaapiProfile elements, so
it shall be released with g_array_unref()
after usage.
gboolean gst_vaapi_display_has_decoder (GstVaapiDisplay *display
,GstVaapiProfile profile
,GstVaapiEntrypoint entrypoint
);
Returns whether VA display
supports profile
for decoding at the
specified entrypoint
.
GArray *
gst_vaapi_display_get_encode_profiles (GstVaapiDisplay *display
);
Gets the supported profiles for encoding. The caller owns an extra
reference to the resulting array of GstVaapiProfile elements, so
it shall be released with g_array_unref()
after usage.
gboolean gst_vaapi_display_has_encoder (GstVaapiDisplay *display
,GstVaapiProfile profile
,GstVaapiEntrypoint entrypoint
);
Returns whether VA display
supports profile
for encoding at the
specified entrypoint
.
GArray *
gst_vaapi_display_get_image_formats (GstVaapiDisplay *display
);
Gets the supported image formats for gst_vaapi_surface_get_image()
or gst_vaapi_surface_put_image()
.
Note that this method does not necessarily map image formats
returned by vaQueryImageFormats()
. The set of capabilities can be
stripped down, if gstreamer-vaapi does not support the format, or
expanded to cover compatible formats not exposed by the underlying
driver. e.g. I420 can be supported even if the driver only exposes
YV12.
Note: the caller owns an extra reference to the resulting array of
GstVideoFormat elements, so it shall be released with
g_array_unref()
after usage.
gboolean gst_vaapi_display_has_image_format (GstVaapiDisplay *display
,GstVideoFormat format
);
Returns whether VA display
supports format
image format.
GArray *
gst_vaapi_display_get_subpicture_formats
(GstVaapiDisplay *display
);
Gets the supported subpicture formats.
Note that this method does not necessarily map subpicture formats
returned by vaQuerySubpictureFormats()
. The set of capabilities can
be stripped down if gstreamer-vaapi does not support the
format. e.g. this is the case for paletted formats like IA44.
Note: the caller owns an extra reference to the resulting array of
GstVideoFormat elements, so it shall be released with
g_array_unref()
after usage.
gboolean gst_vaapi_display_has_subpicture_format (GstVaapiDisplay *display
,GstVideoFormat format
,guint *flags_ptr
);
Returns whether VA display
supports format
subpicture format with
the supplied flags
.
gboolean gst_vaapi_display_has_property (GstVaapiDisplay *display
,const gchar *name
);
Returns whether VA display
supports the requested property. The
check is performed against the property name
. So, the client
application may perform this check only once and cache this
information.
gboolean gst_vaapi_display_get_property (GstVaapiDisplay *display
,const gchar *name
,GValue *out_value
);
gboolean gst_vaapi_display_set_property (GstVaapiDisplay *display
,const gchar *name
,const GValue *value
);
gboolean gst_vaapi_display_get_render_mode (GstVaapiDisplay *display
,GstVaapiRenderMode *pmode
);
Returns the current VA display
rendering mode.
gboolean gst_vaapi_display_set_render_mode (GstVaapiDisplay *display
,GstVaapiRenderMode mode
);
Sets the VA display
rendering mode to the supplied mode
. This
function returns FALSE
if the rendering mode could not be set,
e.g. run-time switching rendering mode is not supported.
GstVaapiRotation
gst_vaapi_display_get_rotation (GstVaapiDisplay *display
);
Returns the current VA display
rotation angle. If the VA driver
does not support "rotation" display attribute, then the display is
assumed to be un-rotated.
gboolean gst_vaapi_display_set_rotation (GstVaapiDisplay *display
,GstVaapiRotation rotation
);
Sets the VA display
rotation angle to the supplied rotation
value. This function returns FALSE
if the rotation angle could not
be set, e.g. the VA driver does not allow to change the display
rotation angle.
const gchar *
gst_vaapi_display_get_vendor_string (GstVaapiDisplay *display
);
Returns the VA driver vendor string attached to the supplied VA display
.
The display
owns the vendor string, do *not* de-allocate it.
This function is thread safe.
gboolean
gst_vaapi_display_has_opengl (GstVaapiDisplay *display
);
Returns wether the display
that was created does support OpenGL
context to be attached.
This function is thread safe.