mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-08 18:39:54 +00:00
/GstBuffer/GstData/ in the API where you can pass events. Fix the plugins to deal with that. Fixes #113488.
Original commit message from CVS: /GstBuffer/GstData/ in the API where you can pass events. Fix the plugins to deal with that. Fixes #113488.
This commit is contained in:
parent
cc76e12bb9
commit
8603e03fd5
6 changed files with 14 additions and 12 deletions
2
common
2
common
|
@ -1 +1 @@
|
|||
Subproject commit b7abb510aa14e8692df39ea8c2c758e37d8a8d8a
|
||||
Subproject commit e903f88a7388f0b463204ea1f960a4ace840175b
|
|
@ -271,8 +271,9 @@ gst_ffmpegdec_release_buffer (AVCodecContext *context,
|
|||
|
||||
static void
|
||||
gst_ffmpegdec_chain (GstPad *pad,
|
||||
GstBuffer *inbuf)
|
||||
GstData *_data)
|
||||
{
|
||||
GstBuffer *inbuf = GST_BUFFER (_data);
|
||||
GstBuffer *outbuf = NULL;
|
||||
GstFFMpegDec *ffmpegdec = (GstFFMpegDec *)(gst_pad_get_parent (pad));
|
||||
GstFFMpegDecClass *oclass = (GstFFMpegDecClass*)(G_OBJECT_GET_CLASS (ffmpegdec));
|
||||
|
@ -354,7 +355,7 @@ gst_ffmpegdec_chain (GstPad *pad,
|
|||
|
||||
GST_BUFFER_TIMESTAMP (outbuf) = GST_BUFFER_TIMESTAMP (inbuf);
|
||||
|
||||
gst_pad_push (ffmpegdec->srcpad, outbuf);
|
||||
gst_pad_push (ffmpegdec->srcpad, GST_DATA (outbuf));
|
||||
}
|
||||
|
||||
size -= len;
|
||||
|
|
|
@ -246,7 +246,7 @@ gst_ffmpegdemux_loop (GstElement *element)
|
|||
pad = ffmpegdemux->srcpads[i];
|
||||
if (GST_PAD_IS_USABLE (pad)) {
|
||||
gst_data_ref (GST_DATA (event));
|
||||
gst_pad_push (pad, GST_BUFFER (event));
|
||||
gst_pad_push (pad, GST_DATA (event));
|
||||
}
|
||||
gst_data_unref (GST_DATA (event));
|
||||
}
|
||||
|
@ -332,7 +332,7 @@ gst_ffmpegdemux_loop (GstElement *element)
|
|||
GST_BUFFER_FLAG_SET (outbuf, GST_BUFFER_KEY_UNIT);
|
||||
}
|
||||
|
||||
gst_pad_push (pad, outbuf);
|
||||
gst_pad_push (pad, GST_DATA (outbuf));
|
||||
pkt.destruct (&pkt);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -124,7 +124,7 @@ static void gst_ffmpegenc_dispose (GObject *object);
|
|||
|
||||
static GstPadLinkReturn
|
||||
gst_ffmpegenc_connect (GstPad *pad, GstCaps *caps);
|
||||
static void gst_ffmpegenc_chain (GstPad *pad, GstBuffer *buffer);
|
||||
static void gst_ffmpegenc_chain (GstPad *pad, GstData *_data);
|
||||
|
||||
static void gst_ffmpegenc_set_property (GObject *object,
|
||||
guint prop_id,
|
||||
|
@ -339,8 +339,9 @@ gst_ffmpegenc_connect (GstPad *pad,
|
|||
|
||||
static void
|
||||
gst_ffmpegenc_chain (GstPad *pad,
|
||||
GstBuffer *inbuf)
|
||||
GstData *_data)
|
||||
{
|
||||
GstBuffer *inbuf = GST_BUFFER (_data);
|
||||
GstBuffer *outbuf = NULL;
|
||||
GstFFMpegEnc *ffmpegenc = (GstFFMpegEnc *)(gst_pad_get_parent (pad));
|
||||
GstFFMpegEncClass *oclass = (GstFFMpegEncClass*)(G_OBJECT_GET_CLASS(ffmpegenc));
|
||||
|
@ -393,7 +394,7 @@ gst_ffmpegenc_chain (GstPad *pad,
|
|||
GST_BUFFER_SIZE (outbuf) = ret_size;
|
||||
GST_BUFFER_TIMESTAMP (outbuf) = GST_BUFFER_TIMESTAMP (inbuf);
|
||||
GST_BUFFER_DURATION (outbuf) = GST_BUFFER_DURATION (inbuf);
|
||||
gst_pad_push (ffmpegenc->srcpad, outbuf);
|
||||
gst_pad_push (ffmpegenc->srcpad, GST_DATA (outbuf));
|
||||
|
||||
gst_buffer_unref (inbuf);
|
||||
}
|
||||
|
|
|
@ -321,7 +321,7 @@ gst_ffmpegmux_loop (GstElement *element)
|
|||
ffmpegmux->eos[i] == FALSE &&
|
||||
ffmpegmux->bufferqueue[i] == NULL) {
|
||||
/* we can pull a buffer! */
|
||||
buf = gst_pad_pull (pad);
|
||||
buf = GST_BUFFER (gst_pad_pull (pad));
|
||||
if (GST_IS_EVENT (buf)) {
|
||||
if (GST_EVENT_TYPE (GST_EVENT (buf)) == GST_EVENT_EOS) {
|
||||
/* flag EOS on this stream */
|
||||
|
|
|
@ -151,7 +151,7 @@ gst_write (URLContext *h,
|
|||
GST_BUFFER_SIZE (outbuf) = size;
|
||||
memcpy (GST_BUFFER_DATA (outbuf), buf, size);
|
||||
|
||||
gst_pad_push (info->pad, outbuf);
|
||||
gst_pad_push (info->pad, GST_DATA (outbuf));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -188,7 +188,7 @@ gst_seek (URLContext *h,
|
|||
|
||||
case URL_WRONLY: {
|
||||
GstEvent *event = gst_event_new_seek (seek_type, pos);
|
||||
gst_pad_push (info->pad, GST_BUFFER (event));
|
||||
gst_pad_push (info->pad, GST_DATA (event));
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -207,7 +207,7 @@ gst_close (URLContext *h)
|
|||
case URL_WRONLY: {
|
||||
/* send EOS - that closes down the stream */
|
||||
GstEvent *event = gst_event_new (GST_EVENT_EOS);
|
||||
gst_pad_push (info->pad, GST_BUFFER (event));
|
||||
gst_pad_push (info->pad, GST_DATA (event));
|
||||
}
|
||||
break;
|
||||
|
||||
|
|
Loading…
Reference in a new issue