Rename gst_vaapi_window_put_surface_full() to plain gst_vaapi_window_put_surface().

This commit is contained in:
gb 2010-03-21 08:12:52 +00:00
parent 2b91d81836
commit 27307a6c1b
5 changed files with 4 additions and 46 deletions

View file

@ -164,7 +164,6 @@ gst_vaapi_window_set_width
gst_vaapi_window_set_height gst_vaapi_window_set_height
gst_vaapi_window_set_size gst_vaapi_window_set_size
gst_vaapi_window_put_surface gst_vaapi_window_put_surface
gst_vaapi_window_put_surface_full
<SUBSECTION Standard> <SUBSECTION Standard>
GST_VAAPI_WINDOW GST_VAAPI_WINDOW
GST_VAAPI_IS_WINDOW GST_VAAPI_IS_WINDOW

View file

@ -352,40 +352,6 @@ get_window_rect(GstVaapiWindow *window, GstVideoRectangle *rect)
* gst_vaapi_window_put_surface: * gst_vaapi_window_put_surface:
* @window: a #GstVaapiWindow * @window: a #GstVaapiWindow
* @surface: a #GstVaapiSurface * @surface: a #GstVaapiSurface
* @flags: postprocessing flags
*
* Renders the whole @surface into the @window. The surface will be
* scale to fit the window, while not preserving aspect ratio.
*
* Return value: %TRUE on success
*/
gboolean
gst_vaapi_window_put_surface(
GstVaapiWindow *window,
GstVaapiSurface *surface,
guint flags
)
{
GstVideoRectangle src_rect, dst_rect;
g_return_val_if_fail(GST_VAAPI_IS_WINDOW(window), FALSE);
g_return_val_if_fail(window->priv->is_constructed, FALSE);
g_return_val_if_fail(GST_VAAPI_IS_SURFACE(surface), FALSE);
get_surface_rect(surface, &src_rect);
get_window_rect(window, &dst_rect);
return GST_VAAPI_WINDOW_GET_CLASS(window)->render(window,
surface,
&src_rect,
&dst_rect,
flags);
}
/**
* gst_vaapi_window_put_surface_full:
* @window: a #GstVaapiWindow
* @surface: a #GstVaapiSurface
* @src_rect: (allow-none): the sub-rectangle of the source surface to * @src_rect: (allow-none): the sub-rectangle of the source surface to
* extract and process. If %NULL, the entire surface will be used. * extract and process. If %NULL, the entire surface will be used.
* @dst_rect: (allow-none): the sub-rectangle of the destination * @dst_rect: (allow-none): the sub-rectangle of the destination
@ -401,7 +367,7 @@ gst_vaapi_window_put_surface(
* Return value: %TRUE on success * Return value: %TRUE on success
*/ */
gboolean gboolean
gst_vaapi_window_put_surface_full( gst_vaapi_window_put_surface(
GstVaapiWindow *window, GstVaapiWindow *window,
GstVaapiSurface *surface, GstVaapiSurface *surface,
const GstVideoRectangle *src_rect, const GstVideoRectangle *src_rect,

View file

@ -136,13 +136,6 @@ gst_vaapi_window_set_size(GstVaapiWindow *window, guint width, guint height);
gboolean gboolean
gst_vaapi_window_put_surface( gst_vaapi_window_put_surface(
GstVaapiWindow *window,
GstVaapiSurface *surface,
guint flags
);
gboolean
gst_vaapi_window_put_surface_full(
GstVaapiWindow *window, GstVaapiWindow *window,
GstVaapiSurface *surface, GstVaapiSurface *surface,
const GstVideoRectangle *src_rect, const GstVideoRectangle *src_rect,

View file

@ -176,7 +176,7 @@ gst_vaapisink_show_frame(GstBaseSink *base_sink, GstBuffer *buffer)
return GST_FLOW_UNEXPECTED; return GST_FLOW_UNEXPECTED;
flags = GST_VAAPI_PICTURE_STRUCTURE_FRAME; flags = GST_VAAPI_PICTURE_STRUCTURE_FRAME;
if (!gst_vaapi_window_put_surface(sink->window, surface, flags)) if (!gst_vaapi_window_put_surface(sink->window, surface, NULL, NULL, flags))
return GST_FLOW_UNEXPECTED; return GST_FLOW_UNEXPECTED;
return GST_FLOW_OK; return GST_FLOW_OK;

View file

@ -231,7 +231,7 @@ main(int argc, char *argv[])
gst_vaapi_window_show(window); gst_vaapi_window_show(window);
if (!gst_vaapi_window_put_surface(window, surface, flags)) if (!gst_vaapi_window_put_surface(window, surface, NULL, NULL, flags))
g_error("could not render surface"); g_error("could not render surface");
pause(); pause();
@ -268,7 +268,7 @@ main(int argc, char *argv[])
gst_vaapi_window_show(window); gst_vaapi_window_show(window);
if (!gst_vaapi_window_put_surface(window, surface, flags)) if (!gst_vaapi_window_put_surface(window, surface, NULL, NULL, flags))
g_error("could not render surface"); g_error("could not render surface");
pause(); pause();