mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
Fix for instantiate-test (see core). Also remove dead code from jpegenc (which still needs fixing, but that's lower o...
Original commit message from CVS: 2004-01-07 Ronald Bultje <rbultje@ronald.bitfreak.net> * ext/audiofile/gstafsink.c: (gst_afsink_init), (gst_afsink_chain), (gst_afsink_handle_event): * ext/jpeg/gstjpegenc.c: (gst_jpegenc_init): * gst/avi/gstavimux.c: (gst_avimux_request_new_pad): * sys/dxr3/dxr3audiosink.c: (dxr3audiosink_init): * sys/dxr3/dxr3spusink.c: (dxr3spusink_init): * sys/dxr3/dxr3videosink.c: (dxr3videosink_init): Fix for instantiate-test (see core). Also remove dead code from jpegenc (which still needs fixing, but that's lower on my TODO list...). * sys/v4l2/gstv4l2src.c: (gst_v4l2src_getcaps): Never return NULL as caps.
This commit is contained in:
parent
1120700716
commit
1b63854c1f
6 changed files with 33 additions and 36 deletions
15
ChangeLog
15
ChangeLog
|
@ -1,3 +1,18 @@
|
|||
2004-01-07 Ronald Bultje <rbultje@ronald.bitfreak.net>
|
||||
|
||||
* ext/audiofile/gstafsink.c: (gst_afsink_init), (gst_afsink_chain),
|
||||
(gst_afsink_handle_event):
|
||||
* ext/jpeg/gstjpegenc.c: (gst_jpegenc_init):
|
||||
* gst/avi/gstavimux.c: (gst_avimux_request_new_pad):
|
||||
* sys/dxr3/dxr3audiosink.c: (dxr3audiosink_init):
|
||||
* sys/dxr3/dxr3spusink.c: (dxr3spusink_init):
|
||||
* sys/dxr3/dxr3videosink.c: (dxr3videosink_init):
|
||||
Fix for instantiate-test (see core). Also remove dead code from
|
||||
jpegenc (which still needs fixing, but that's lower on my TODO
|
||||
list...).
|
||||
* sys/v4l2/gstv4l2src.c: (gst_v4l2src_getcaps):
|
||||
Never return NULL as caps.
|
||||
|
||||
2004-01-07 David Schleef <ds@schleef.org>
|
||||
|
||||
* configure.ac:
|
||||
|
|
|
@ -190,7 +190,6 @@ gst_afsink_init (GstAFSink *afsink)
|
|||
gst_element_add_pad (GST_ELEMENT (afsink), afsink->sinkpad);
|
||||
|
||||
gst_pad_set_chain_function (afsink->sinkpad, gst_afsink_chain);
|
||||
gst_pad_set_event_function (afsink->sinkpad, gst_afsink_handle_event);
|
||||
|
||||
afsink->filename = NULL;
|
||||
afsink->file = NULL;
|
||||
|
@ -387,14 +386,19 @@ gst_afsink_close_file (GstAFSink *sink)
|
|||
static void
|
||||
gst_afsink_chain (GstPad *pad, GstData *_data)
|
||||
{
|
||||
GstBuffer *buf = GST_BUFFER (_data);
|
||||
GstBuffer *buf;
|
||||
GstAFSink *afsink;
|
||||
int ret = 0;
|
||||
|
||||
g_return_if_fail (pad != NULL);
|
||||
g_return_if_fail (GST_IS_PAD (pad));
|
||||
g_return_if_fail (buf != NULL);
|
||||
|
||||
if (GST_IS_EVENT (_data)) {
|
||||
gst_afsink_handle_event (pad, GST_EVENT (_data));
|
||||
return;
|
||||
}
|
||||
|
||||
buf = GST_BUFFER (_data);
|
||||
afsink = GST_AFSINK (gst_pad_get_parent (pad));
|
||||
/* we use audiofile now
|
||||
if (GST_FLAG_IS_SET (afsink, GST_AFSINK_OPEN))
|
||||
|
@ -484,7 +488,16 @@ gst_afsink_handle_event (GstPad *pad, GstEvent *event)
|
|||
|
||||
afsink = GST_AFSINK (gst_pad_get_parent (pad));
|
||||
GST_DEBUG ("DEBUG: afsink: got event");
|
||||
gst_afsink_close_file (afsink);
|
||||
|
||||
switch (GST_EVENT_TYPE (event)) {
|
||||
case GST_EVENT_EOS:
|
||||
gst_afsink_close_file (afsink);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
gst_pad_event_default (pad, event);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
|
|
@ -93,13 +93,6 @@ GST_STATIC_PAD_TEMPLATE (
|
|||
);
|
||||
|
||||
|
||||
GST_PAD_EVENT_MASK_FUNCTION(dxr3audiosink_get_event_mask,
|
||||
{ GST_EVENT_FLUSH, 0 },
|
||||
{ GST_EVENT_DISCONTINUOUS, 0 },
|
||||
{ GST_EVENT_EOS, 0 }
|
||||
)
|
||||
|
||||
|
||||
static void dxr3audiosink_class_init (Dxr3AudioSinkClass *klass);
|
||||
static void dxr3audiosink_base_init (Dxr3AudioSinkClass *klass);
|
||||
static void dxr3audiosink_init (Dxr3AudioSink *sink);
|
||||
|
@ -235,12 +228,6 @@ dxr3audiosink_init (Dxr3AudioSink *sink)
|
|||
gst_element_add_pad (GST_ELEMENT (sink), sink->ac3_sinkpad);
|
||||
|
||||
GST_FLAG_SET (GST_ELEMENT(sink), GST_ELEMENT_EVENT_AWARE);
|
||||
gst_pad_set_event_function (sink->pcm_sinkpad, dxr3audiosink_handle_event);
|
||||
gst_pad_set_event_mask_function (sink->pcm_sinkpad,
|
||||
dxr3audiosink_get_event_mask);
|
||||
gst_pad_set_event_function (sink->ac3_sinkpad, dxr3audiosink_handle_event);
|
||||
gst_pad_set_event_mask_function (sink->ac3_sinkpad,
|
||||
dxr3audiosink_get_event_mask);
|
||||
|
||||
sink->card_number = 0;
|
||||
|
||||
|
|
|
@ -70,13 +70,6 @@ GST_STATIC_PAD_TEMPLATE (
|
|||
);
|
||||
|
||||
|
||||
GST_PAD_EVENT_MASK_FUNCTION (dxr3spusink_get_event_mask,
|
||||
{ GST_EVENT_FLUSH, 0 },
|
||||
{ GST_EVENT_DISCONTINUOUS, 0 },
|
||||
{ GST_EVENT_EOS, 0 }
|
||||
)
|
||||
|
||||
|
||||
static void dxr3spusink_class_init (Dxr3SpuSinkClass *klass);
|
||||
static void dxr3spusink_base_init (Dxr3SpuSinkClass *klass);
|
||||
static void dxr3spusink_init (Dxr3SpuSink *dxr3spusink);
|
||||
|
@ -228,8 +221,6 @@ dxr3spusink_init (Dxr3SpuSink *sink)
|
|||
gst_pad_set_chain_function (pad, dxr3spusink_chain);
|
||||
|
||||
GST_FLAG_SET (GST_ELEMENT (sink), GST_ELEMENT_EVENT_AWARE);
|
||||
gst_pad_set_event_function (pad, dxr3spusink_handle_event);
|
||||
gst_pad_set_event_mask_function (pad, dxr3spusink_get_event_mask);
|
||||
|
||||
sink->card_number = 0;
|
||||
|
||||
|
|
|
@ -93,13 +93,6 @@ GST_STATIC_PAD_TEMPLATE (
|
|||
);
|
||||
|
||||
|
||||
GST_PAD_EVENT_MASK_FUNCTION (dxr3videosink_get_event_mask,
|
||||
{ GST_EVENT_FLUSH, 0 },
|
||||
{ GST_EVENT_DISCONTINUOUS, 0 },
|
||||
{ GST_EVENT_EOS, 0 }
|
||||
)
|
||||
|
||||
|
||||
static void dxr3videosink_class_init (Dxr3VideoSinkClass *klass);
|
||||
static void dxr3videosink_base_init (Dxr3VideoSinkClass *klass);
|
||||
static void dxr3videosink_init (Dxr3VideoSink *dxr3videosink);
|
||||
|
@ -219,8 +212,6 @@ dxr3videosink_init (Dxr3VideoSink *sink)
|
|||
gst_pad_set_chain_function (pad, dxr3videosink_chain);
|
||||
|
||||
GST_FLAG_SET (GST_ELEMENT (sink), GST_ELEMENT_EVENT_AWARE);
|
||||
gst_pad_set_event_function (pad, dxr3videosink_handle_event);
|
||||
gst_pad_set_event_mask_function (pad, dxr3videosink_get_event_mask);
|
||||
|
||||
sink->card_number = 0;
|
||||
|
||||
|
|
|
@ -743,7 +743,7 @@ gst_v4l2src_getcaps (GstPad *pad)
|
|||
int min_w, max_w, min_h, max_h;
|
||||
|
||||
if (!GST_V4L2_IS_OPEN(GST_V4L2ELEMENT(v4l2src))) {
|
||||
return NULL;
|
||||
return gst_caps_new_any ();
|
||||
}
|
||||
|
||||
/* build our own capslist */
|
||||
|
|
Loading…
Reference in a new issue