Commit graph

660 commits

Author SHA1 Message Date
Tim-Philipp Müller
5290b514c8 v4l2: fix unportable printf format 2010-02-01 09:18:53 +00:00
Stefan Kost
21a8cb1e06 v4l2src: don't deref NULL
Error out when the pool gets shutdown.
2010-01-25 17:23:43 +02:00
Stefan Kost
8576a11dae Revert "v4l2src: don't deref NULL"
This reverts commit 3d9d34bd60.
2010-01-25 17:21:13 +02:00
Stefan Kost
3d9d34bd60 v4l2src: don't deref NULL
Error out when the pool gets shutdown.
2010-01-25 14:16:22 +02:00
Stefan Kost
30b2cd42c5 v4l2: move G_END_DECLS to the end 2010-01-18 14:57:42 +02:00
Stefan Kost
e789d2253f v4l2: fix bufferpool file names in header comment 2010-01-18 14:55:38 +02:00
Tim-Philipp Müller
d68689255d v4l2src: fix memory leak in new uri handler code
Don't leak a string everytime get_uri() is called and a device
has been set. There's a limited number of devices, so just
intern the string instead of doing more elaborate housekeeping
and storing it in the instance struct or so.
2010-01-05 09:49:16 +00:00
Edward Hervey
121c001437 v4l2src: Add GstURIHandler interface. Fixes #601143
This allows using v4l2://[<device>]
2009-12-21 13:54:40 +01:00
Sebastian Dröge
7ef43f021b v4l2: Make sure to initialize variables before using them 2009-11-11 10:45:23 +01:00
Michael Smith
8991a713a7 osxvideosink: Create the video NSView in READY->PAUSED rather than NULL->READY 2009-10-23 18:31:14 -07:00
Michael Smith
2da535f56f osxvideo: explicitly link to GST_LIBS 2009-10-23 18:28:22 -07:00
Thiago Santos
72af90ae31 v4l2src: Set duration on buffers
Use framerate to estimate duration of buffers.

Fixes #590362
2009-10-14 08:00:49 -03:00
Josep Torra
3f7aed54f9 osxvideo: fix a warning doing a cast 2009-10-09 12:14:22 +02:00
Josep Torra
b3e5dcc5f7 osxaudio: fix warnings on macosx 2009-10-09 12:11:12 +02:00
Josep Torra
dd8fd4de58 osxaudio: Fixes build on macosx snow leopard. 2009-10-09 11:43:44 +02:00
Pau Garcia i Quiles
f10435580f v4l2: Include sys/ioctl.h for the V4L ioctl requests
Old videodevice2.h kernel headers used ioctl stuff without
including ioctl.h, making compilation fail on older systems.

Note: Including ioctl.h here is only a workaround for old kernel
headers, should be removed once everybody has new enough headers.

Fixes bug #597867.
2009-10-09 11:34:16 +02:00
Sjoerd Simons
8b9799aeb1 oss: Downgrade the rank of osssrc to SECONDARY
which is the same rank as osssink has.

Fixes bug #597730.
2009-10-08 13:16:11 +02:00
David Schleef
19ae44f4e0 osxaudio: link against GST_BASE_LIBS 2009-09-16 13:28:27 -07:00
Stefan Kost
00ffa9c2dd v4l2src: add a function pointer for get_frame function and optimize a bit
Use a function-pointer for mmap/read, as this can't change during capture. Also
sprinkle a few G_LIKELY/UNLIKELY to improve the error-less code path.
2009-09-11 22:24:47 +03:00
Stefan Kost
1a945a32cc v4l2: log buffer copies on queue underrun in perf category
v4l2src has a slow path where it does buffer-copies when it runs out of queued
buffers. Log this to performance category to help monitoring it.
2009-09-11 22:19:23 +03:00
Stefan Kost
0a68003efe docs: fix gtk-doc warnings 2009-09-10 10:26:23 +03:00
Wim Taymans
5580571f8d whitespace fixes 2009-09-09 10:27:55 +02:00
Wim Taymans
796dec5920 v4l2src: add support for mpeg formats 2009-09-07 18:28:51 +02:00
David Schleef
55d2754098 Remove Ronald Bultje from Authors field
Replaced with "GStreamer maintainers
<gstreamer-devel@lists.sourceforge.net>" or just removed,
depending on the number of other authors.
2009-09-05 20:53:10 -07:00
Sebastian Dröge
686f8376a8 v4l2: Define V4L2_FMT_FLAG_EMULATED if it's not defined yet
libv4l2 already uses this flag, even on Linux kernel versions
before 2.6.32.
2009-09-04 09:32:42 +02:00
Sebastian Dröge
0c6fba9506 v4l2: Fix stupid typo in last commit 2009-09-03 20:40:17 +02:00
Sebastian Dröge
4fda384a83 v4l2: Put emulated formats behind native formats
Fixes bug #593764.
2009-09-03 20:39:44 +02:00
Hans de Goede
10d41286d5 v4l2src: fix 'hang' with some cameras caused by bad timestamping if no framerate is available
For cameras/drivers that don't support e.g. VIDIOC_G_PARM we'd end up without
a framerate and would try to divide by 0, causing run-time warnings and all
frames to be timestamped with 0, which makes sinks that sync against the clock
drop them, causing 'hangs' (observed with the pwc driver and a Logitech QuickCam
Pro 4000). So if we do not know the framerate, simply don't adjust the
timestamps. Fixes #591451.
2009-08-14 13:30:31 +01:00
Filippo Argiolas
a3a61f8940 v4l2src: clear format list in READY->NULL
Clear format list and probed caps when going to NULL so if a new device
is set we'll probe the formats again instead of using previously
detected ones. Fixes bug #591747.
2009-08-14 10:15:43 +02:00
Tim-Philipp Müller
9590df3c2e v4l2: fix make distcheck by disting some more headers 2009-08-11 03:08:01 +01:00
Tim-Philipp Müller
8c8e6af45b v4l2src: if max == min width/height put an int in the probed caps, not an int range
Fixes #560033.
2009-08-09 14:19:42 +01:00
Tim-Philipp Müller
6df8fb76ef osxaudiosrc: if max_channels == min_channels, use an int instead of an int range in the caps 2009-08-09 13:58:07 +01:00
Sebastian Dröge
198604c108 v4l2: Directly use GST_PTR_FORMAT for printing caps with the LOG_CAPS macro 2009-08-04 14:45:31 +02:00
Sebastian Dröge
23dbb15ff5 v4l2: Remove some OMAP specific hacks
They require special build flags and are not useful in general.
2009-08-04 09:32:07 +02:00
Rob Clark
99e2ac121d v4l2sink: change where buffers get dequeued
It seems to cause strange occasional high latencies (almost 200ms) when dequeuing buffers from _buffer_alloc().  It is simpler and seems to work much better to dqbuf from the same thread that is queuing the next buffer.
2009-08-04 09:22:29 +02:00
Rob Clark
f19cfbda96 v4l2: Add v4l2sink element
This also does the following changes:
(1) pull the bufferpool code out into gstv4l2bufferpool.c, and make a
    bit more generic so it can be used both for v4l2src and v4l2sink
(2) move some of the device probing/configuration/caps stuff into
    gstv4l2object.c so it does not have to be duplicated between
    v4l2src and v4l2sink

Fixes bug #590280.
2009-08-04 09:16:56 +02:00
Elaine Xiong
085f87d85f v4l2: Fix v4l2src on OpenSolaris
The v4l2 driver for USB webcams on OpenSolaris does not support select()
calls. Detect when select() fails, and skip polling the device afterward,
which restores the pre 0.10.14 behaviour on OpenSolaris.

Signed-off-by: Jan Schmidt <thaytan@noraisin.net>
2009-07-19 11:42:13 +01:00
Filippo Argiolas
946c20a8ba v4l2src: optional support for device probing with gudev
Enumerate v4l2 devices using gudev if available.

Fixes bug #583640.
2009-07-13 16:16:05 +02:00
Tim-Philipp Müller
2e13b85a01 waveformsink: use 'guint8' instead of 'byte' to fix compilation with MSVC8
We need a cast here for pointer arithmetic to work correctly, but some
MSVC versions don't seem to like 'byte', so use guint8 here. Hopefully
fixes #585361.
2009-06-25 18:54:06 +01:00
Stefan Kost
5d256c201f v4l2src: set structs to zero before using them in ioctls
This fixes valgrind warnings.
2009-06-25 19:44:21 +03:00
Stefan Kost
0b475ba774 v4l2: open/close the device in READY
This allows to query the device in READY. Before one need to switch it to PAUSED
and that also starts streaming.
2009-06-22 16:24:46 +03:00
Jan Schmidt
7994f64006 sunaudio: Fix switch setting on some devices. Add debug. Fix a FIXME.
Fix the setting of toggle switches on some broken audio drivers which
report that no audio ports are settable by ignoring the mod_port field
there.

Add some debug statements.

Fix a FIXME now that Good relies on a new enough gst-plugins-base.
2009-06-05 16:54:48 +01:00
Jan Schmidt
0fc43060e5 sunaudio: Support new flags for options and actions
Use new audio mixer flags added in Base 0.10.23 to expose flags and options
on the SunAudio devices.

Fixes: #583593
Patch By: Brian Cameron <brian.cameron@sun.com>
Patch By: Garrett D'Amore <garrett.damore@sun.com>
2009-06-05 10:47:53 +01:00
Stefan Kost
751f7fc5f8 v4l2: cleanup and commenting
Remove newlines inserted by gst-indent once. Remove unused var from instance
struct. Add comments. Add another #define for default property value.
2009-05-26 16:29:46 +03:00
Jan Schmidt
bba3e90768 Moved 'directdraw' from -good to -bad 2009-05-16 01:11:33 +01:00
James Andrewartha
2410cd7a00 Fix compiler warnings
Fixes bug #582715.
2009-05-15 15:14:52 +02:00
Edward Hervey
bd4f8576fe osxringbuffer: Run gst-indent. 2009-04-18 18:51:28 +02:00
Edward Hervey
14f715f978 ximage: Remove dead assignments.
Those variables are not read after that point.
2009-04-18 18:51:28 +02:00
Edward Hervey
0cb5b42d54 Remove trivial unused variables detected by CLang static analyzer. 2009-04-18 18:51:28 +02:00
Edward Hervey
4a9e80720a Remove unused variables in _class_init
Detected by LLVM's CLang static analyzer
2009-04-18 18:51:27 +02:00