Top | ![]() |
![]() |
![]() |
![]() |
#define | GST_VAAPI_IMAGE_FORMAT() |
#define | GST_VAAPI_IMAGE_WIDTH() |
#define | GST_VAAPI_IMAGE_HEIGHT() |
GstVaapiImage * | gst_vaapi_image_new () |
GstVaapiImage * | gst_vaapi_image_new_with_image () |
GstVaapiID | gst_vaapi_image_get_id () |
gboolean | gst_vaapi_image_get_image () |
GstVideoFormat | gst_vaapi_image_get_format () |
guint | gst_vaapi_image_get_width () |
guint | gst_vaapi_image_get_height () |
void | gst_vaapi_image_get_size () |
gboolean | gst_vaapi_image_is_linear () |
gboolean | gst_vaapi_image_is_mapped () |
gboolean | gst_vaapi_image_map () |
gboolean | gst_vaapi_image_unmap () |
guint | gst_vaapi_image_get_plane_count () |
guchar * | gst_vaapi_image_get_plane () |
guint | gst_vaapi_image_get_pitch () |
guint | gst_vaapi_image_get_data_size () |
gboolean | gst_vaapi_image_get_buffer () |
gboolean | gst_vaapi_image_update_from_buffer () |
gboolean | gst_vaapi_image_copy () |
#define GST_VAAPI_IMAGE_FORMAT(image)
Macro that evaluates to the GstVideoFormat of image
.
#define GST_VAAPI_IMAGE_WIDTH(image)
Macro that evaluates to the width of image
.
#define GST_VAAPI_IMAGE_HEIGHT(image)
Macro that evaluates to the height of image
.
GstVaapiImage * gst_vaapi_image_new (GstVaapiDisplay *display
,GstVideoFormat format
,guint width
,guint height
);
Creates a new GstVaapiImage with the specified format and dimensions.
GstVaapiImage * gst_vaapi_image_new_with_image (GstVaapiDisplay *display
,VAImage *va_image
);
Creates a new GstVaapiImage from a foreign VA image. The image
format and dimensions will be extracted from va_image
. This
function is mainly used by gst_vaapi_surface_derive_image()
to bind
a VA image to a GstVaapiImage object.
GstVaapiID
gst_vaapi_image_get_id (GstVaapiImage *image
);
Returns the underlying VAImageID of the image
.
gboolean gst_vaapi_image_get_image (GstVaapiImage *image
,VAImage *va_image
);
Fills va_image
with the VA image used internally.
GstVideoFormat
gst_vaapi_image_get_format (GstVaapiImage *image
);
Returns the GstVideoFormat the image
was created with.
guint
gst_vaapi_image_get_width (GstVaapiImage *image
);
Returns the image
width.
guint
gst_vaapi_image_get_height (GstVaapiImage *image
);
Returns the image
height.
void gst_vaapi_image_get_size (GstVaapiImage *image
,guint *pwidth
,guint *pheight
);
Retrieves the dimensions of a GstVaapiImage.
gboolean
gst_vaapi_image_is_linear (GstVaapiImage *image
);
Checks whether the image
has data planes allocated from a single
buffer and offsets into that buffer are in increasing order with
the number of planes.
gboolean
gst_vaapi_image_is_mapped (GstVaapiImage *image
);
Checks whether the image
is currently mapped or not.
gboolean
gst_vaapi_image_map (GstVaapiImage *image
);
Maps the image data buffer. The actual pixels are returned by the
gst_vaapi_image_get_plane()
function.
gboolean
gst_vaapi_image_unmap (GstVaapiImage *image
);
Unmaps the image data buffer. Pointers to pixels returned by
gst_vaapi_image_get_plane()
are then no longer valid.
guint
gst_vaapi_image_get_plane_count (GstVaapiImage *image
);
Retrieves the number of planes available in the image
. The image
must be mapped for this function to work properly.
guchar * gst_vaapi_image_get_plane (GstVaapiImage *image
,guint plane
);
Retrieves the pixels data to the specified plane
. The image
must
be mapped for this function to work properly.
guint gst_vaapi_image_get_pitch (GstVaapiImage *image
,guint plane
);
Retrieves the line size (stride) of the specified plane
. The
image
must be mapped for this function to work properly.
guint
gst_vaapi_image_get_data_size (GstVaapiImage *image
);
Retrieves the underlying image data size. This function could be used to determine whether the image has a compatible layout with another image structure.
gboolean gst_vaapi_image_get_buffer (GstVaapiImage *image
,GstBuffer *buffer
,GstVaapiRectangle *rect
);
Transfers pixels data contained in the image
into the GstBuffer.
Both image structures shall have the same format.
gboolean gst_vaapi_image_update_from_buffer (GstVaapiImage *image
,GstBuffer *buffer
,GstVaapiRectangle *rect
);
Transfers pixels data contained in the GstBuffer into the
image
. Both image structures shall have the same format.
gboolean gst_vaapi_image_copy (GstVaapiImage *dst_image
,GstVaapiImage *src_image
);
Copies pixels data from src_image
to dst_image
. Both images shall
have the same format and size.