mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 05:16:13 +00:00
sys/xvimage/xvimagesink.c: Refuse to create an XvImage if we can't find the format.
Original commit message from CVS: 2005-11-28 Julien MOUTTE <julien@moutte.net> * sys/xvimage/xvimagesink.c: (gst_xvimagesink_xvimage_new): Refuse to create an XvImage if we can't find the format.
This commit is contained in:
parent
b80fd557a2
commit
390aa5ec7c
2 changed files with 7 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2005-11-28 Julien MOUTTE <julien@moutte.net>
|
||||||
|
|
||||||
|
* sys/xvimage/xvimagesink.c: (gst_xvimagesink_xvimage_new):
|
||||||
|
Refuse to create an XvImage if we can't find the format.
|
||||||
|
|
||||||
2005-11-28 Edward Hervey <edward@fluendo.com>
|
2005-11-28 Edward Hervey <edward@fluendo.com>
|
||||||
|
|
||||||
* gst-libs/gst/riff/riff-media.c:
|
* gst-libs/gst/riff/riff-media.c:
|
||||||
|
|
|
@ -456,11 +456,11 @@ gst_xvimagesink_xvimage_new (GstXvImageSink * xvimagesink, GstCaps * caps)
|
||||||
GST_LOG_OBJECT (xvimagesink, "creating %dx%d", xvimage->width,
|
GST_LOG_OBJECT (xvimagesink, "creating %dx%d", xvimage->width,
|
||||||
xvimage->height);
|
xvimage->height);
|
||||||
|
|
||||||
/* We should probably get that from the caps as well */
|
|
||||||
xvimage->im_format = gst_xvimagesink_get_format_from_caps (xvimagesink, caps);
|
xvimage->im_format = gst_xvimagesink_get_format_from_caps (xvimagesink, caps);
|
||||||
if (!xvimage->im_format) {
|
if (!xvimage->im_format) {
|
||||||
GST_WARNING_OBJECT (xvimagesink, "failed to get format from caps %"
|
GST_WARNING_OBJECT (xvimagesink, "failed to get format from caps %"
|
||||||
GST_PTR_FORMAT, caps);
|
GST_PTR_FORMAT, caps);
|
||||||
|
goto beach_unlocked;
|
||||||
}
|
}
|
||||||
xvimage->xvimagesink = gst_object_ref (xvimagesink);
|
xvimage->xvimagesink = gst_object_ref (xvimagesink);
|
||||||
|
|
||||||
|
@ -533,6 +533,7 @@ gst_xvimagesink_xvimage_new (GstXvImageSink * xvimagesink, GstCaps * caps)
|
||||||
beach:
|
beach:
|
||||||
g_mutex_unlock (xvimagesink->x_lock);
|
g_mutex_unlock (xvimagesink->x_lock);
|
||||||
|
|
||||||
|
beach_unlocked:
|
||||||
if (!succeeded) {
|
if (!succeeded) {
|
||||||
gst_xvimage_buffer_free (xvimage);
|
gst_xvimage_buffer_free (xvimage);
|
||||||
xvimage = NULL;
|
xvimage = NULL;
|
||||||
|
|
Loading…
Reference in a new issue