ext/jpeg/: move format setting to inner loop
authorThomas Vander Stichele <thomas@apestaart.org>
Thu, 29 Apr 2004 17:37:01 +0000 (17:37 +0000)
committerThomas Vander Stichele <thomas@apestaart.org>
Thu, 29 Apr 2004 17:37:01 +0000 (17:37 +0000)
Original commit message from CVS:
* ext/jpeg/gstjpegdec.c: (gst_jpegdec_get_type):
* ext/jpeg/gstjpegenc.c: (gst_jpegenc_get_type),
(gst_jpegenc_getcaps):
move format setting to inner loop
* gst/ffmpegcolorspace/gstffmpegcolorspace.c:
(gst_ffmpegcolorspace_getcaps):
use GST_PAD_CAPS if available so that we use already negotiated
caps
* gst/qtdemux/qtdemux.c: (gst_qtdemux_loop_header),
(qtdemux_parse_moov), (qtdemux_parse):
extra debugging
* sys/qcam/qcam-Linux.c: (qc_lock_wait), (qc_unlock):
* sys/qcam/qcam-os.c: (qc_lock_wait), (qc_unlock):
move hardcoded path to DEFINE

ChangeLog
gst/ffmpegcolorspace/gstffmpegcolorspace.c

index b916d0b..caa45e2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,20 @@
+2004-04-29  Thomas Vander Stichele  <thomas at apestaart dot org>
+
+       * ext/jpeg/gstjpegdec.c: (gst_jpegdec_get_type):
+       * ext/jpeg/gstjpegenc.c: (gst_jpegenc_get_type),
+       (gst_jpegenc_getcaps):
+          move format setting to inner loop
+       * gst/ffmpegcolorspace/gstffmpegcolorspace.c:
+       (gst_ffmpegcolorspace_getcaps):
+          use GST_PAD_CAPS if available so that we use already negotiated
+          caps
+       * gst/qtdemux/qtdemux.c: (gst_qtdemux_loop_header),
+       (qtdemux_parse_moov), (qtdemux_parse):
+          extra debugging
+       * sys/qcam/qcam-Linux.c: (qc_lock_wait), (qc_unlock):
+       * sys/qcam/qcam-os.c: (qc_lock_wait), (qc_unlock):
+          move hardcoded path to DEFINE
+
 2004-04-28  David Schleef  <ds@schleef.org>
 
        * gst/speed/gstspeed.c: (speed_parse_caps):  Fix caps parsing.
index ce0f337..922b26c 100644 (file)
@@ -62,7 +62,7 @@ struct _GstFFMpegColorspaceClass
 
 /* elementfactory information */
 static GstElementDetails ffmpegcolorspace_details = {
-  "FFMPEG Colorspace converter",
+  "FFMPEG-based colorspace converter in gst-plugins",
   "Filter/Converter/Video",
   "Converts video from one colorspace to another",
   "Ronald Bultje <rbultje@ronald.bitfreak.net>",
@@ -143,7 +143,7 @@ static GstCaps *
 gst_ffmpegcolorspace_getcaps (GstPad * pad)
 {
   GstFFMpegColorspace *space;
-  GstCaps *othercaps;
+  GstCaps *othercaps = NULL;
   GstCaps *caps;
   GstPad *otherpad;
 
@@ -151,7 +151,11 @@ gst_ffmpegcolorspace_getcaps (GstPad * pad)
 
   otherpad = (pad == space->srcpad) ? space->sinkpad : space->srcpad;
 
-  othercaps = gst_pad_get_allowed_caps (otherpad);
+  /* use already negotiated caps if they exist */
+  if (GST_PAD_CAPS (otherpad))
+    othercaps = gst_caps_copy (GST_PAD_CAPS (otherpad));
+  if (!othercaps)
+    othercaps = gst_pad_get_allowed_caps (otherpad);
 
   othercaps = gst_ffmpegcolorspace_caps_remove_format_info (othercaps);