summaryrefslogtreecommitdiffstats
path: root/sys/v4l2/v4l2src_calls.h
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2007-05-30 14:40:53 +0000
committerAndy Wingo <wingo@pobox.com>2007-05-30 14:40:53 +0000
commit3b5f9882390c4c8a65072a9375100c57c8002ac3 (patch)
tree8dab1f05bde0d69ca6d2a60794146f2381901581 /sys/v4l2/v4l2src_calls.h
parent3127a32c1c734681bfc6fcdcd23e06ff1db8f266 (diff)
sys/v4l2/v4l2src_calls.*: Store the format list in the order that the driver gives it to us.
Original commit message from CVS: 2007-05-30 Andy Wingo <wingo@pobox.com> * sys/v4l2/v4l2src_calls.h: * sys/v4l2/v4l2src_calls.c (gst_v4l2src_fill_format_list): Store the format list in the order that the driver gives it to us. (gst_v4l2src_probe_caps_for_format_and_size) (gst_v4l2src_probe_caps_for_format): New functions, fill GstCaps based on the capabilities of the device. (gst_v4l2src_grab_frame): Update for object variable renaming. (gst_v4l2src_set_capture): Update to be strict in its parameters, as in the set_caps below. (gst_v4l2src_capture_init): Update for object variable renaming, and reflow. (gst_v4l2src_capture_start, gst_v4l2src_capture_stop) (gst_v4l2src_capture_deinit): Update for object variable renaming. (gst_v4l2src_update_fps, gst_v4l2src_set_fps) (gst_v4l2src_get_fps): Remove; these functions don't have much meaning outside of an atomic set_caps method. (gst_v4l2src_buffer_new): Don't set buffer duration, it is not known. * sys/v4l2/gstv4l2tuner.c (gst_v4l2_tuner_set_channel): Remove call to update_fps; not sure about this change. (gst_v4l2_tuner_set_norm): Work around the fact that for the moment we don't have an update_fps_func. * sys/v4l2/gstv4l2src.h (struct _GstV4l2Src): Don't put v4l2 structures in the object, just store what we need. Do store the probed caps of the device. Don't store the current frame rate. * sys/v4l2/gstv4l2src.c (gst_v4l2src_init): Remove the update_fps_function, for now. Update for new object variable naming. (gst_v4l2src_set_property, gst_v4l2src_get_property): Update for new object variable naming. (gst_v4l2src_v4l2fourcc_to_structure): Rename from ..._to_caps. (gst_v4l2_structure_to_v4l2fourcc): Rename from ...caps_to_.... (gst_v4l2src_get_caps): Rework to probe the device for supported frame sizes and frame rates. (gst_v4l2src_set_caps): Rework to be strict in the given parameters: if someone asks us to have a certain size and rate, that is what we configure. (gst_v4l2src_get_read): Update for object variable naming. Don't leak buffers on short reads. (gst_v4l2src_get_mmap): Update for object variable naming, and add comments. (gst_v4l2src_create): Update for object variable naming.
Diffstat (limited to 'sys/v4l2/v4l2src_calls.h')
-rw-r--r--sys/v4l2/v4l2src_calls.h17
1 files changed, 6 insertions, 11 deletions
diff --git a/sys/v4l2/v4l2src_calls.h b/sys/v4l2/v4l2src_calls.h
index ea752ae7..ea294815 100644
--- a/sys/v4l2/v4l2src_calls.h
+++ b/sys/v4l2/v4l2src_calls.h
@@ -29,9 +29,9 @@
gboolean gst_v4l2src_get_capture (GstV4l2Src * v4l2src);
gboolean gst_v4l2src_set_capture (GstV4l2Src * v4l2src,
- struct v4l2_fmtdesc *fmt,
- gint * width, gint * height,
- guint *fps_n, guint * fps_d);
+ guint32 pixelformat,
+ guint32 width, guint32 height,
+ guint32 fps_n, guint32 fps_d);
gboolean gst_v4l2src_capture_init (GstV4l2Src * v4l2src);
gboolean gst_v4l2src_capture_start (GstV4l2Src * v4l2src);
@@ -45,6 +45,9 @@ gboolean gst_v4l2src_capture_deinit (GstV4l2Src * v4l2src);
gboolean gst_v4l2src_fill_format_list (GstV4l2Src * v4l2src);
gboolean gst_v4l2src_clear_format_list (GstV4l2Src * v4l2src);
+GstCaps* gst_v4l2src_probe_caps_for_format (GstV4l2Src * v4l2src, guint32 pixelformat,
+ const GstStructure *template);
+
gboolean gst_v4l2src_get_size_limits (GstV4l2Src * v4l2src,
struct v4l2_fmtdesc *fmt,
gint * min_w, gint * max_w,
@@ -55,13 +58,5 @@ GstBuffer* gst_v4l2src_buffer_new (GstV4l2Src * v4l2src,
GstV4l2Buffer * srcbuf);
void gst_v4l2src_free_buffer (GstBuffer * buffer);
-/* FPS stuff */
-gboolean gst_v4l2src_update_fps (GstV4l2Object * v4l2object);
-gboolean gst_v4l2src_get_fps (GstV4l2Src * v4l2src,
- guint * fps_n, guint * fps_d);
-gboolean gst_v4l2src_set_fps (GstV4l2Src * v4l2src,
- guint * fps_n, guint * fps_d);
-GValue* gst_v4l2src_get_fps_list (GstV4l2Src * v4l2src);
-
#endif /* __V4L2SRC_CALLS_H__ */