mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-07 16:08:51 +00:00
convertframe: fix docs
Fixup paramter mismatch between func and prototype. Add missing parameter docs.
This commit is contained in:
parent
089fdb7792
commit
8db7c1221e
1 changed files with 17 additions and 17 deletions
|
@ -235,7 +235,7 @@ link_failed:
|
||||||
* @buf: a #GstBuffer
|
* @buf: a #GstBuffer
|
||||||
* @to_caps: the #GstCaps to convert to
|
* @to_caps: the #GstCaps to convert to
|
||||||
* @timeout: the maximum amount of time allowed for the processing.
|
* @timeout: the maximum amount of time allowed for the processing.
|
||||||
* @err: pointer to a #GError. Can be %NULL.
|
* @error: pointer to a #GError. Can be %NULL.
|
||||||
*
|
*
|
||||||
* Converts a raw video buffer into the specified output caps.
|
* Converts a raw video buffer into the specified output caps.
|
||||||
*
|
*
|
||||||
|
@ -251,11 +251,11 @@ link_failed:
|
||||||
*/
|
*/
|
||||||
GstBuffer *
|
GstBuffer *
|
||||||
gst_video_convert_frame (GstBuffer * buf, const GstCaps * to_caps,
|
gst_video_convert_frame (GstBuffer * buf, const GstCaps * to_caps,
|
||||||
GstClockTime timeout, GError ** err)
|
GstClockTime timeout, GError ** error)
|
||||||
{
|
{
|
||||||
GstMessage *msg;
|
GstMessage *msg;
|
||||||
GstBuffer *result = NULL;
|
GstBuffer *result = NULL;
|
||||||
GError *error = NULL;
|
GError *err = NULL;
|
||||||
GstBus *bus;
|
GstBus *bus;
|
||||||
GstCaps *from_caps, *to_caps_copy = NULL;
|
GstCaps *from_caps, *to_caps_copy = NULL;
|
||||||
GstFlowReturn ret;
|
GstFlowReturn ret;
|
||||||
|
@ -279,8 +279,7 @@ gst_video_convert_frame (GstBuffer * buf, const GstCaps * to_caps,
|
||||||
}
|
}
|
||||||
|
|
||||||
pipeline =
|
pipeline =
|
||||||
build_convert_frame_pipeline (&src, &sink, from_caps, to_caps_copy,
|
build_convert_frame_pipeline (&src, &sink, from_caps, to_caps_copy, &err);
|
||||||
&error);
|
|
||||||
if (!pipeline)
|
if (!pipeline)
|
||||||
goto no_pipeline;
|
goto no_pipeline;
|
||||||
|
|
||||||
|
@ -318,14 +317,14 @@ gst_video_convert_frame (GstBuffer * buf, const GstCaps * to_caps,
|
||||||
case GST_MESSAGE_ERROR:{
|
case GST_MESSAGE_ERROR:{
|
||||||
gchar *dbg = NULL;
|
gchar *dbg = NULL;
|
||||||
|
|
||||||
gst_message_parse_error (msg, &error, &dbg);
|
gst_message_parse_error (msg, &err, &dbg);
|
||||||
if (error) {
|
if (err) {
|
||||||
GST_ERROR ("Could not convert video frame: %s", error->message);
|
GST_ERROR ("Could not convert video frame: %s", err->message);
|
||||||
GST_DEBUG ("%s [debug: %s]", error->message, GST_STR_NULL (dbg));
|
GST_DEBUG ("%s [debug: %s]", err->message, GST_STR_NULL (dbg));
|
||||||
if (err)
|
if (error)
|
||||||
*err = error;
|
*error = err;
|
||||||
else
|
else
|
||||||
g_error_free (error);
|
g_error_free (err);
|
||||||
}
|
}
|
||||||
g_free (dbg);
|
g_free (dbg);
|
||||||
break;
|
break;
|
||||||
|
@ -337,8 +336,8 @@ gst_video_convert_frame (GstBuffer * buf, const GstCaps * to_caps,
|
||||||
gst_message_unref (msg);
|
gst_message_unref (msg);
|
||||||
} else {
|
} else {
|
||||||
GST_ERROR ("Could not convert video frame: timeout during conversion");
|
GST_ERROR ("Could not convert video frame: timeout during conversion");
|
||||||
if (err)
|
if (error)
|
||||||
*err = g_error_new (GST_CORE_ERROR, GST_CORE_ERROR_FAILED,
|
*error = g_error_new (GST_CORE_ERROR, GST_CORE_ERROR_FAILED,
|
||||||
"Could not convert video frame: timeout during conversion");
|
"Could not convert video frame: timeout during conversion");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -354,10 +353,10 @@ no_pipeline:
|
||||||
{
|
{
|
||||||
gst_caps_unref (to_caps_copy);
|
gst_caps_unref (to_caps_copy);
|
||||||
|
|
||||||
if (err)
|
if (error)
|
||||||
*err = error;
|
*error = err;
|
||||||
else
|
else
|
||||||
g_error_free (error);
|
g_error_free (err);
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -577,6 +576,7 @@ done:
|
||||||
* @to_caps: the #GstCaps to convert to
|
* @to_caps: the #GstCaps to convert to
|
||||||
* @timeout: the maximum amount of time allowed for the processing.
|
* @timeout: the maximum amount of time allowed for the processing.
|
||||||
* @callback: %GstVideoConvertFrameCallback that will be called after conversion.
|
* @callback: %GstVideoConvertFrameCallback that will be called after conversion.
|
||||||
|
* @user_data: extra data that will be passed to the @callback
|
||||||
* @destroy_notify: %GDestroyNotify to be called after @user_data is not needed anymore
|
* @destroy_notify: %GDestroyNotify to be called after @user_data is not needed anymore
|
||||||
*
|
*
|
||||||
* Converts a raw video buffer into the specified output caps.
|
* Converts a raw video buffer into the specified output caps.
|
||||||
|
|
Loading…
Reference in a new issue