diff options
author | Andy Wingo <wingo@pobox.com> | 2005-12-05 13:03:00 +0000 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2005-12-05 13:03:00 +0000 |
commit | 7fbfd29bbe207f93ce17bf52ba1bc46c78cf25d2 (patch) | |
tree | 2ae397d84724ef6c0646fa4b5def509ba17252fa /ext | |
parent | c28031af5a9306abf320f5b6cf57d4233e137e3c (diff) |
Update for alloc_buffer changes.
Original commit message from CVS:
2005-12-05 Andy Wingo <wingo@pobox.com>
* ext/dv/gstdvdec.c: (gst_dvdec_chain):
* ext/flac/gstflacdec.c: (gst_flacdec_write):
* ext/flac/gstflacenc.c: (gst_flacenc_write_callback):
* ext/gdk_pixbuf/gstgdkpixbuf.c: (gst_gdk_pixbuf_chain):
* ext/gdk_pixbuf/pixbufscale.c: (gst_pixbufscale_chain):
* ext/jpeg/gstjpegdec.c: (gst_jpeg_dec_chain):
* ext/jpeg/gstjpegenc.c: (gst_jpegenc_chain):
* ext/ladspa/gstsignalprocessor.c: (gst_signal_processor_process):
* ext/libpng/gstpngdec.c: (user_info_callback), (gst_pngdec_task):
* ext/speex/gstspeexdec.c: (speex_dec_chain):
* ext/speex/gstspeexenc.c: (gst_speexenc_chain):
* gst/auparse/gstauparse.c: (gst_auparse_chain):
* gst/flx/gstflxdec.c: (gst_flxdec_chain):
* gst/goom/gstgoom.c: (gst_goom_chain):
* gst/matroska/matroska-demux.c:
(gst_matroska_demux_push_vorbis_codec_priv_data),
(gst_matroska_demux_add_wvpk_header):
* gst/multipart/multipartdemux.c: (gst_multipart_demux_chain):
* gst/multipart/multipartmux.c: (gst_multipart_mux_collected):
* gst/videomixer/videomixer.c: (gst_videomixer_collected):
* gst/wavenc/gstwavenc.c: (gst_wavenc_chain): Update for
alloc_buffer changes.
Diffstat (limited to 'ext')
-rw-r--r-- | ext/dv/gstdvdec.c | 2 | ||||
-rw-r--r-- | ext/flac/gstflacdec.c | 7 | ||||
-rw-r--r-- | ext/flac/gstflacenc.c | 4 | ||||
-rw-r--r-- | ext/gdk_pixbuf/gstgdkpixbuf.c | 5 | ||||
-rw-r--r-- | ext/gdk_pixbuf/pixbufscale.c | 2 | ||||
-rw-r--r-- | ext/jpeg/gstjpegdec.c | 2 | ||||
-rw-r--r-- | ext/jpeg/gstjpegenc.c | 6 | ||||
-rw-r--r-- | ext/ladspa/gstsignalprocessor.c | 5 | ||||
-rw-r--r-- | ext/libpng/gstpngdec.c | 6 | ||||
-rw-r--r-- | ext/speex/gstspeexdec.c | 4 | ||||
-rw-r--r-- | ext/speex/gstspeexenc.c | 2 |
11 files changed, 27 insertions, 18 deletions
diff --git a/ext/dv/gstdvdec.c b/ext/dv/gstdvdec.c index 32b75aff..fb355d0e 100644 --- a/ext/dv/gstdvdec.c +++ b/ext/dv/gstdvdec.c @@ -273,7 +273,7 @@ gst_dvdec_chain (GstPad * pad, GstBuffer * buf) goto skip; ret = - gst_pad_alloc_buffer (dvdec->srcpad, 0, + gst_pad_alloc_buffer_and_set_caps (dvdec->srcpad, 0, (720 * dvdec->height) * dvdec->bpp, GST_PAD_CAPS (dvdec->srcpad), &outbuf); if (ret != GST_FLOW_OK) diff --git a/ext/flac/gstflacdec.c b/ext/flac/gstflacdec.c index 5f534253..dc8ed7b2 100644 --- a/ext/flac/gstflacdec.c +++ b/ext/flac/gstflacdec.c @@ -488,9 +488,10 @@ gst_flacdec_write (const FLAC__SeekableStreamDecoder * decoder, flacdec->frequency = frame->header.sample_rate; } - ret = gst_pad_alloc_buffer (flacdec->srcpad, flacdec->total_samples, - samples * channels * ((width + 7) >> 3), GST_PAD_CAPS (flacdec->srcpad), - &outbuf); + ret = + gst_pad_alloc_buffer_and_set_caps (flacdec->srcpad, + flacdec->total_samples, samples * channels * ((width + 7) >> 3), + GST_PAD_CAPS (flacdec->srcpad), &outbuf); if (ret != GST_FLOW_NOT_LINKED && ret != GST_FLOW_OK) { GST_DEBUG ("stopping flac decoder engine (%d)", (gint) ret); return FLAC__STREAM_DECODER_WRITE_STATUS_ABORT; diff --git a/ext/flac/gstflacenc.c b/ext/flac/gstflacenc.c index c90e1192..75c83796 100644 --- a/ext/flac/gstflacenc.c +++ b/ext/flac/gstflacenc.c @@ -538,8 +538,8 @@ gst_flacenc_write_callback (const FLAC__SeekableStreamEncoder * encoder, if (flacenc->stopped) return FLAC__STREAM_ENCODER_WRITE_STATUS_OK; - if (gst_pad_alloc_buffer (flacenc->srcpad, flacenc->offset, bytes, - GST_PAD_CAPS (flacenc->srcpad), &outbuf) != GST_FLOW_OK) { + if (gst_pad_alloc_buffer_and_set_caps (flacenc->srcpad, flacenc->offset, + bytes, GST_PAD_CAPS (flacenc->srcpad), &outbuf) != GST_FLOW_OK) { return FLAC__STREAM_ENCODER_WRITE_STATUS_FATAL_ERROR; } diff --git a/ext/gdk_pixbuf/gstgdkpixbuf.c b/ext/gdk_pixbuf/gstgdkpixbuf.c index 9a602ea8..34a1678e 100644 --- a/ext/gdk_pixbuf/gstgdkpixbuf.c +++ b/ext/gdk_pixbuf/gstgdkpixbuf.c @@ -329,8 +329,9 @@ gst_gdk_pixbuf_chain (GstPad * pad, GstData * _data) gst_pad_set_explicit_caps (filter->srcpad, caps); } - outbuf = gst_pad_alloc_buffer (filter->srcpad, GST_BUFFER_OFFSET_NONE, - filter->image_size); + outbuf = + gst_pad_alloc_buffer_and_set_caps (filter->srcpad, + GST_BUFFER_OFFSET_NONE, filter->image_size); GST_BUFFER_TIMESTAMP (outbuf) = GST_BUFFER_TIMESTAMP (buf); GST_BUFFER_DURATION (outbuf) = GST_BUFFER_DURATION (buf); diff --git a/ext/gdk_pixbuf/pixbufscale.c b/ext/gdk_pixbuf/pixbufscale.c index 9edef400..6b52b426 100644 --- a/ext/gdk_pixbuf/pixbufscale.c +++ b/ext/gdk_pixbuf/pixbufscale.c @@ -409,7 +409,7 @@ gst_pixbufscale_chain (GstPad * pad, GstData * _data) return; } - outbuf = gst_pad_alloc_buffer (pixbufscale->srcpad, + outbuf = gst_pad_alloc_buffer_and_set_caps (pixbufscale->srcpad, GST_BUFFER_OFFSET_NONE, pixbufscale->to_buf_size); gst_buffer_stamp (outbuf, buf); diff --git a/ext/jpeg/gstjpegdec.c b/ext/jpeg/gstjpegdec.c index 8b26c3d3..0ad04c42 100644 --- a/ext/jpeg/gstjpegdec.c +++ b/ext/jpeg/gstjpegdec.c @@ -815,7 +815,7 @@ gst_jpeg_dec_chain (GstPad * pad, GstBuffer * buf) dec->caps_framerate_denominator = dec->framerate_denominator; } - ret = gst_pad_alloc_buffer (dec->srcpad, GST_BUFFER_OFFSET_NONE, + ret = gst_pad_alloc_buffer_and_set_caps (dec->srcpad, GST_BUFFER_OFFSET_NONE, I420_SIZE (width, height), GST_PAD_CAPS (dec->srcpad), &outbuf); if (ret != GST_FLOW_OK) goto alloc_failed; diff --git a/ext/jpeg/gstjpegenc.c b/ext/jpeg/gstjpegenc.c index 490121e9..2485d2f6 100644 --- a/ext/jpeg/gstjpegenc.c +++ b/ext/jpeg/gstjpegenc.c @@ -411,8 +411,10 @@ gst_jpegenc_chain (GstPad * pad, GstBuffer * buf) GST_DEBUG_OBJECT (jpegenc, "got buffer of %u bytes", size); - ret = gst_pad_alloc_buffer (jpegenc->srcpad, GST_BUFFER_OFFSET_NONE, - jpegenc->bufsize, GST_PAD_CAPS (jpegenc->srcpad), &outbuf); + ret = + gst_pad_alloc_buffer_and_set_caps (jpegenc->srcpad, + GST_BUFFER_OFFSET_NONE, jpegenc->bufsize, GST_PAD_CAPS (jpegenc->srcpad), + &outbuf); if (ret != GST_FLOW_OK) goto done; diff --git a/ext/ladspa/gstsignalprocessor.c b/ext/ladspa/gstsignalprocessor.c index 9caf7b7b..375ea839 100644 --- a/ext/ladspa/gstsignalprocessor.c +++ b/ext/ladspa/gstsignalprocessor.c @@ -325,8 +325,9 @@ gst_signal_processor_process (GstSignalProcessor * self) srcpad = (GstSignalProcessorPad *) l2->data; - ret = gst_pad_alloc_buffer (GST_PAD (srcpad), -1, self->buffer_frames, - GST_PAD_CAPS (srcpad), &srcpad->pen); + ret = + gst_pad_alloc_buffer_and_set_caps (GST_PAD (srcpad), -1, + self->buffer_frames, GST_PAD_CAPS (srcpad), &srcpad->pen); if (ret != GST_FLOW_OK) { self->state = ret; diff --git a/ext/libpng/gstpngdec.c b/ext/libpng/gstpngdec.c index 67a19e7e..874114a2 100644 --- a/ext/libpng/gstpngdec.c +++ b/ext/libpng/gstpngdec.c @@ -192,7 +192,8 @@ user_info_callback (png_structp png_ptr, png_infop info) /* Allocate output buffer */ pngdec->rowbytes = png_get_rowbytes (pngdec->png, pngdec->info); buffer_size = pngdec->height * GST_ROUND_UP_4 (pngdec->rowbytes); - ret = gst_pad_alloc_buffer (pngdec->srcpad, GST_BUFFER_OFFSET_NONE, + ret = + gst_pad_alloc_buffer_and_set_caps (pngdec->srcpad, GST_BUFFER_OFFSET_NONE, buffer_size, GST_PAD_CAPS (pngdec->srcpad), &buffer); if (ret != GST_FLOW_OK) { goto beach; @@ -397,7 +398,8 @@ gst_pngdec_task (GstPad * pad) /* Allocate output buffer */ rowbytes = png_get_rowbytes (pngdec->png, pngdec->info); buffer_size = pngdec->height * GST_ROUND_UP_4 (rowbytes); - ret = gst_pad_alloc_buffer (pngdec->srcpad, GST_BUFFER_OFFSET_NONE, + ret = + gst_pad_alloc_buffer_and_set_caps (pngdec->srcpad, GST_BUFFER_OFFSET_NONE, buffer_size, GST_PAD_CAPS (pngdec->srcpad), &buffer); if (ret != GST_FLOW_OK) { goto pause; diff --git a/ext/speex/gstspeexdec.c b/ext/speex/gstspeexdec.c index 6cd8374d..5f68a32b 100644 --- a/ext/speex/gstspeexdec.c +++ b/ext/speex/gstspeexdec.c @@ -478,7 +478,9 @@ speex_dec_chain (GstPad * pad, GstBuffer * buf) if (dec->header->nb_channels == 2) speex_decode_stereo (dec->output, dec->frame_size, &dec->stereo); - if ((res = gst_pad_alloc_buffer (dec->srcpad, GST_BUFFER_OFFSET_NONE, + if ((res = + gst_pad_alloc_buffer_and_set_caps (dec->srcpad, + GST_BUFFER_OFFSET_NONE, dec->frame_size * dec->header->nb_channels * 2, GST_PAD_CAPS (dec->srcpad), &outbuf)) != GST_FLOW_OK) return res; diff --git a/ext/speex/gstspeexenc.c b/ext/speex/gstspeexenc.c index 9b602237..777b75ba 100644 --- a/ext/speex/gstspeexenc.c +++ b/ext/speex/gstspeexenc.c @@ -996,7 +996,7 @@ gst_speexenc_chain (GstPad * pad, GstBuffer * buf) speex_bits_insert_terminator (&speexenc->bits); outsize = speex_bits_nbytes (&speexenc->bits); - ret = gst_pad_alloc_buffer (speexenc->srcpad, + ret = gst_pad_alloc_buffer_and_set_caps (speexenc->srcpad, GST_BUFFER_OFFSET_NONE, outsize, GST_PAD_CAPS (speexenc->srcpad), &outbuf); |