Commit graph

23 commits

Author SHA1 Message Date
Guillaume Desmottes
d29ec01b8a camerabinpreview: fix bus leak
We were never removing the watch introduced in
gst_camerabin_create_preview_pipeline() so its extra ref on the bus was
never released.

https://bugzilla.gnome.org/show_bug.cgi?id=768838
2016-07-15 13:41:48 -03:00
Tim-Philipp Müller
34c9c86ab7 basecamerabinsrc: don't use private GMutex implementation details
Don't use private GMutex implementation details to check
whether it has been freed already or not. Just clear mutex
and GCond unconditionally in free function, they are always
inited anyway, and the free function can't be called multiple
times either.
2015-02-17 09:56:55 +00:00
Tim-Philipp Müller
9e1b75fda3 Fix FSF address
https://bugzilla.gnome.org/show_bug.cgi?id=687520
2012-11-04 00:09:59 +00:00
Thiago Santos
0a831613a8 camerabin: update preview buffer pushing
need to pass a GstSample to the utilitary preview buffer post functions
as a GstBuffer doesn't have caps anymore. The GstSample has the GstCaps
and it is used to inform the preview's pipeline about the format of the
input, before it gets converted to the user's requested output format.
2012-07-29 00:53:29 -03:00
Thiago Santos
89a20eb63e basecamerabinsrc: updating property to new name
enable-last-buffer is now enable-last-sample
2012-05-01 15:10:54 -03:00
Thiago Santos
79d3cc533f camerabin: Replacing ffmpegcolorspace with videoconvert 2012-05-01 15:10:51 -03:00
Wim Taymans
1119f6ee41 Merge branch 'master' into 0.11
Conflicts:
	ext/chromaprint/gstchromaprint.c
	ext/mpeg2enc/Makefile.am
	ext/voaacenc/gstvoaacenc.c
	gst/dvbsuboverlay/gstdvbsuboverlay.c
	gst/mpegtsdemux/mpegtsbase.c
	gst/sdp/gstsdpdemux.c
	gst/videoparsers/gsth264parse.c
	sys/d3dvideosink/d3dvideosink.c
	tests/examples/camerabin/gst-camera-perf.c
	tests/examples/camerabin/gst-camerabin-test.c
	tests/examples/camerabin2/gst-camerabin2-test.c
	tests/examples/mxf/mxfdemux-structure.c
	tests/examples/scaletempo/demo-main.c
2012-02-10 16:46:50 +01:00
Vincent Penquerc'h
8147669971 plenty: fixup glib deprecations 2012-01-27 15:47:07 +00:00
Wim Taymans
27ee60a27b port to new gthread API 2012-01-19 11:34:26 +01:00
Wim Taymans
cacdd29b5c camerabin: use GstSample for the preview 2011-12-01 16:59:14 +01:00
Tommi Myöhänen
de138dbc57 basecamerasrc: optimize state changing speed
Create preview pipeline already in initialization phase. This speeds
up NULL_TO_READY state change. Also implement a separate function for
setting the preview filter element.

This also restricts the preview filter property to work only on
NULL state.
2011-10-31 07:14:36 -03:00
Thiago Santos
21653a793a camerabin2: Initialize camerabin2 preview pipeline data with 0
Use g_new0 to initialize all fields with 0 to only cleanup what has been
initialized. This makes cleanup work correctly when some initialization
fails and pointers are left in some inconsistent state.
2011-10-03 16:16:23 -03:00
Thiago Santos
b03c7478d4 camerabin2: removing capsfilter from preview pipeline
appsink already has a caps property, so we don't need the
capsfilter here
2011-09-29 11:50:04 -03:00
Thiago Santos
43ec4f46b8 basecamerasrc: Fail state change if preview pipeline fails creation
If the preview pipeline fails creation, for any reason, we should
fail basecamerasrc state change.

Also adds a missing g_return_if_fail check to preview pipeline
functions
2011-09-20 13:02:17 -03:00
Thiago Santos
12f77b27e2 camerabin2: preview: No need for appsink to store the last buffer
There is no need for preview's appsink to keep a reference to the last buffer,
so disable the property to make it unref the buffers sooner.
2011-09-06 23:03:40 -03:00
Thiago Santos
8a56a7de6d camerabin2: preview: Appsink doesn't need to sync
Set sync to false on preview's pipeline appsink
2011-09-05 14:39:20 -03:00
Thiago Santos
d41af4e2f8 camerabin2: preview: Remove one of the two colorspace converters
The preview pipeline doesn't need 2 colorspace converters, remove
one to speed up caps negotiation and reduce the delay on getting
the first preview buffer out of the preview pipeline.

It shouldn't cause problems as videoscale and ffmpegcolorspace seems
to handle the same caps, so no conversion should be needed for
videoscale. Additionally, camerabin1 has been working with a similar
pipeline with a single ffmpegcolorspace and no bugs have been open about it
so far.
2011-09-05 09:59:53 -03:00
Thiago Santos
0bdde84f3b camerabin2: preview: Disable appsrc signals emission
Camerabin2 doesn't check appsrc's signals, so disable them
2011-09-05 09:33:45 -03:00
Thiago Santos
e17d99c4c4 basecamerabinsrc: Optimize preview pipeline startup
Use gst_element_link_pads_full to optimize preview pipeline startup,
leading to a faster camerabin2 startup as well.
2011-08-31 15:45:18 -03:00
Raluca Elena Podiuc
c189ba3496 basecamerabinsrc: preview: remove unused new_preroll callback 2011-08-02 13:39:17 -03:00
Lauri Lehtinen
c86d662b23 basecamerabinsrc: Handle errors from preview pipeline
Implements a message handling function to preview pipeline bus.
If GST_MESSAGE_ERROR is seen, considers preview pipeline unable
to do its job and posts an error message to application.

Sets pipeline element to NULL so that subsequent calls to post_preview
and set_caps functions just returns without pushing anything to the
disposed preview pipeline. Leaves further actions to the application.
2011-05-16 18:08:39 -03:00
Lauri Lehtinen
802028081c basecamerabinsrc: Protection for previewpipeline when setting new preview caps
Implements a state indicating flag to preview pipeline,
so that new caps are not set if the pipeline is processing a
preview. The caps are set as pending and applied when the
next preview post is called.

In this case a wait was implemented in the post_preview function,
so that new preview image buffer will wait until the other previews
have been posted to the application and the new caps can be used
safely.
2011-05-16 18:08:39 -03:00
Thiago Santos
0255584d90 camerabin2: Move preview helper functions to basecamerabinsrc
Move preview helper functions to baseacamerabinsrc so they can
be reused by multiple camerabin2 sources.
2011-03-10 08:42:00 -03:00