mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-17 11:45:25 +00:00
v4l2object: Rename setup_format() method into acquire_format()
The setup_format() was confusing since it does not set anything, in fact it reads the setup from the driver and save it.
This commit is contained in:
parent
8cf1c330d5
commit
70e7868f18
3 changed files with 10 additions and 8 deletions
|
@ -2657,7 +2657,7 @@ pool_failed:
|
|||
}
|
||||
|
||||
/**
|
||||
* gst_v4l2_object_setup_format:
|
||||
* gst_v4l2_object_acquire_format:
|
||||
* @v4l2object the object
|
||||
* @info a GstVideoInfo to be filled
|
||||
* @align a GstVideoAlignment to be filled
|
||||
|
@ -2665,12 +2665,14 @@ pool_failed:
|
|||
* Setup the format base on the currently configured format. This is useful in
|
||||
* decoder or encoder elements where the output format is dictated by the
|
||||
* input.
|
||||
* Acquire the driver choosen format. This is useful in decoder or encoder elements where
|
||||
* the output format is choosen by the HW.
|
||||
*
|
||||
* Returns: %TRUE on success, %FALSE on failure.
|
||||
*/
|
||||
gboolean
|
||||
gst_v4l2_object_setup_format (GstV4l2Object * v4l2object,
|
||||
GstVideoInfo * info, GstVideoAlignment * align)
|
||||
gst_v4l2_object_acquire_format (GstV4l2Object * v4l2object, GstVideoInfo * info,
|
||||
GstVideoAlignment * align)
|
||||
{
|
||||
struct v4l2_fmtdesc *fmtdesc;
|
||||
struct v4l2_format fmt;
|
||||
|
|
|
@ -253,10 +253,10 @@ gboolean gst_v4l2_object_copy (GstV4l2Object * v4l2object,
|
|||
GstCaps * gst_v4l2_object_get_caps (GstV4l2Object * v4l2object,
|
||||
GstCaps * filter);
|
||||
|
||||
gboolean gst_v4l2_object_setup_format (GstV4l2Object * v4l2object,
|
||||
GstVideoInfo * info,
|
||||
GstVideoAlignment * align);
|
||||
|
||||
gboolean gst_v4l2_object_acquire_format (GstV4l2Object * v4l2object,
|
||||
GstVideoInfo * info,
|
||||
GstVideoAlignment * align);
|
||||
|
||||
gboolean gst_v4l2_object_decide_allocation (GstV4l2Object * v4l2object,
|
||||
GstQuery * query);
|
||||
|
||||
|
|
|
@ -475,7 +475,7 @@ gst_v4l2_video_dec_handle_frame (GstVideoDecoder * decoder,
|
|||
|
||||
gst_buffer_unref (codec_data);
|
||||
|
||||
if (!gst_v4l2_object_setup_format (self->v4l2capture, &info, &self->align))
|
||||
if (!gst_v4l2_object_acquire_format (self->v4l2capture, &info))
|
||||
goto not_negotiated;
|
||||
|
||||
output_state = gst_video_decoder_set_output_state (decoder,
|
||||
|
|
Loading…
Reference in a new issue