summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Schleef <ds@schleef.org>2003-12-21 23:24:38 +0000
committerDavid Schleef <ds@schleef.org>2003-12-21 23:24:38 +0000
commit8284d0d3a2911a9ef9667aa52f0fd42e4c93405f (patch)
tree5fa53a115231b29afd0bc832f9c32afdd8dd51c7
parent26da56b423a834192f5edf413c3cb1be257f845a (diff)
Global change from "caps2" to "caps"CAPS-ENDCAPS
Original commit message from CVS: Global change from "caps2" to "caps"
-rw-r--r--examples/seeking/vorbisfile.c14
-rw-r--r--ext/artsd/gstartsdsink.c6
-rw-r--r--ext/audiofile/gstafparse.c2
-rw-r--r--ext/audiofile/gstafsink.c4
-rw-r--r--ext/audiofile/gstafsrc.c2
-rw-r--r--ext/gsm/gstgsmdec.c8
-rw-r--r--ext/gsm/gstgsmenc.c8
-rw-r--r--ext/hermes/gstcolorspace.c32
-rw-r--r--ext/hermes/gstcolorspace.h4
-rw-r--r--ext/hermes/yuv2rgb.c6
-rw-r--r--ext/hermes/yuv2rgb.h2
-rw-r--r--ext/jack/gstjack.c18
-rw-r--r--ext/ladspa/gstladspa.c12
-rw-r--r--ext/libfame/gstlibfame.c4
-rw-r--r--ext/mas/massink.c4
-rw-r--r--ext/mplex/gstmplex.cc6
-rw-r--r--ext/sdl/sdlvideosink.c12
-rw-r--r--ext/snapshot/gstsnapshot.c10
-rw-r--r--ext/sndfile/gstsf.c12
-rw-r--r--ext/swfdec/gstswfdec.c8
-rw-r--r--ext/xvid/gstxviddec.c12
-rw-r--r--ext/xvid/gstxvidenc.c12
-rw-r--r--gst-libs/gst/audio/audio.c16
-rw-r--r--gst-libs/gst/audio/gstaudiofilter.c20
-rw-r--r--gst-libs/gst/audio/gstaudiofilter.h4
-rw-r--r--gst-libs/gst/media-info/media-info-priv.c16
-rw-r--r--gst-libs/gst/media-info/media-info-priv.h8
-rw-r--r--gst-libs/gst/media-info/media-info-test.c6
-rw-r--r--gst-libs/gst/media-info/media-info.c4
-rw-r--r--gst-libs/gst/media-info/media-info.h14
-rw-r--r--gst-libs/gst/play/gstplay.c4
-rw-r--r--gst-libs/gst/play/play.c4
-rw-r--r--gst-libs/gst/play/play.old.c2
-rw-r--r--gst-libs/gst/riff/riff-media.c96
-rw-r--r--gst-libs/gst/riff/riff-media.h12
-rw-r--r--gst-libs/gst/riff/riff-read.c12
-rw-r--r--gst-libs/gst/riff/riff-read.h2
-rw-r--r--gst-libs/gst/video/video.c8
-rw-r--r--gst/chart/gstchart.c12
-rw-r--r--gst/deinterlace/gstdeinterlace.c4
-rw-r--r--gst/filter/gstbpwsinc.c4
-rw-r--r--gst/filter/gstiir.c4
-rw-r--r--gst/filter/gstlpwsinc.c4
-rw-r--r--gst/flx/gstflxdec.c6
-rw-r--r--gst/mixmatrix/mixmatrix.c8
-rw-r--r--gst/modplug/gstmodplug.cc16
-rw-r--r--gst/mpeg1videoparse/gstmp1videoparse.c4
-rw-r--r--gst/mpegaudioparse/gstmpegaudioparse.c8
-rw-r--r--gst/overlay/gstoverlay.c8
-rw-r--r--gst/passthrough/gstpassthrough.c6
-rw-r--r--gst/playondemand/gstplayondemand.c6
-rw-r--r--gst/qtdemux/qtdemux.c94
-rw-r--r--gst/smooth/gstsmooth.c4
-rw-r--r--gst/smpte/gstsmpte.c10
-rw-r--r--gst/speed/gstspeed.c8
-rw-r--r--gst/switch/gstswitch.c2
-rw-r--r--gst/vbidec/gstvbidec.c2
-rw-r--r--gst/videocrop/gstvideocrop.c6
-rw-r--r--gst/videodrop/gstvideodrop.c4
-rw-r--r--gst/y4m/gsty4mencode.c4
-rw-r--r--sys/qcam/gstqcamsrc.c2
-rw-r--r--sys/v4l2/gstv4l2src.c16
62 files changed, 334 insertions, 334 deletions
diff --git a/examples/seeking/vorbisfile.c b/examples/seeking/vorbisfile.c
index f191aa7b8..acaa60c9d 100644
--- a/examples/seeking/vorbisfile.c
+++ b/examples/seeking/vorbisfile.c
@@ -12,25 +12,25 @@ struct probe_context {
gint total_ls;
- GstCaps2 *metadata;
- GstCaps2 *streaminfo;
- GstCaps2 *caps;
+ GstCaps *metadata;
+ GstCaps *streaminfo;
+ GstCaps *caps;
};
static void
-print_caps (GstCaps2 *caps)
+print_caps (GstCaps *caps)
{
char *s;
- s = gst_caps2_to_string (caps);
+ s = gst_caps_to_string (caps);
g_print(" %s\n", s);
g_free (s);
}
static void
-print_format (GstCaps2 *caps)
+print_format (GstCaps *caps)
{
char *s;
- s = gst_caps2_to_string (caps);
+ s = gst_caps_to_string (caps);
g_print(" format: %s\n", s);
g_free (s);
}
diff --git a/ext/artsd/gstartsdsink.c b/ext/artsd/gstartsdsink.c
index 6012f9337..25ff80c4e 100644
--- a/ext/artsd/gstartsdsink.c
+++ b/ext/artsd/gstartsdsink.c
@@ -62,7 +62,7 @@ static gboolean gst_artsdsink_open_audio (GstArtsdsink *sink);
static void gst_artsdsink_close_audio (GstArtsdsink *sink);
static GstElementStateReturn gst_artsdsink_change_state (GstElement *element);
static gboolean gst_artsdsink_sync_parms (GstArtsdsink *artsdsink);
-static GstPadLinkReturn gst_artsdsink_link (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_artsdsink_link (GstPad *pad, const GstCaps *caps);
static void gst_artsdsink_chain (GstPad *pad, GstData *_data);
static void gst_artsdsink_set_property (GObject *object, guint prop_id,
@@ -158,12 +158,12 @@ gst_artsdsink_sync_parms (GstArtsdsink *artsdsink)
}
static GstPadLinkReturn
-gst_artsdsink_link (GstPad *pad, const GstCaps2 *caps)
+gst_artsdsink_link (GstPad *pad, const GstCaps *caps)
{
GstArtsdsink *artsdsink = GST_ARTSDSINK (gst_pad_get_parent (pad));
GstStructure *structure;
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &artsdsink->frequency);
gst_structure_get_int (structure, "depth", &artsdsink->depth);
gst_structure_get_int (structure, "signed", &artsdsink->signd);
diff --git a/ext/audiofile/gstafparse.c b/ext/audiofile/gstafparse.c
index bb37687b7..f61d64f43 100644
--- a/ext/audiofile/gstafparse.c
+++ b/ext/audiofile/gstafparse.c
@@ -382,7 +382,7 @@ gst_afparse_open_file (GstAFParse *afparse)
/* set caps on src */
/*FIXME: add all the possible formats, especially float ! */
gst_pad_try_set_caps (afparse->srcpad,
- gst_caps2_new_simple (
+ gst_caps_new_simple (
"audio/x-raw-int",
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"signed", G_TYPE_BOOLEAN, afparse->is_signed,
diff --git a/ext/audiofile/gstafsink.c b/ext/audiofile/gstafsink.c
index 8dad9ede2..5b6b702ea 100644
--- a/ext/audiofile/gstafsink.c
+++ b/ext/audiofile/gstafsink.c
@@ -282,7 +282,7 @@ static gboolean
gst_afsink_open_file (GstAFSink *sink)
{
AFfilesetup outfilesetup;
- const GstCaps2 *caps;
+ const GstCaps *caps;
GstStructure *structure;
int sample_format; /* audiofile's sample format, look in audiofile.h */
int byte_order = 0; /* audiofile's byte order defines */
@@ -306,7 +306,7 @@ gst_afsink_open_file (GstAFSink *sink)
if (caps == NULL) {
g_critical ("gstafsink chain : Could not get caps of pad !\n");
} else {
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "channels", &sink->channels);
gst_structure_get_int (structure, "width", &sink->width);
gst_structure_get_int (structure, "rate", &sink->rate);
diff --git a/ext/audiofile/gstafsrc.c b/ext/audiofile/gstafsrc.c
index a569f8bf8..0520463d0 100644
--- a/ext/audiofile/gstafsrc.c
+++ b/ext/audiofile/gstafsrc.c
@@ -341,7 +341,7 @@ gst_afsrc_open_file (GstAFSrc *src)
/* set caps on src */
/*FIXME: add all the possible formats, especially float ! */
gst_pad_try_set_caps (src->srcpad,
- gst_caps2_new_simple ("audio/x-raw-int",
+ gst_caps_new_simple ("audio/x-raw-int",
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"signed", G_TYPE_BOOLEAN, src->is_signed,
"width", G_TYPE_INT, src->width,
diff --git a/ext/gsm/gstgsmdec.c b/ext/gsm/gstgsmdec.c
index 7a35b1552..1359ce97c 100644
--- a/ext/gsm/gstgsmdec.c
+++ b/ext/gsm/gstgsmdec.c
@@ -49,7 +49,7 @@ static void gst_gsmdec_class_init (GstGSMDec *klass);
static void gst_gsmdec_init (GstGSMDec *gsmdec);
static void gst_gsmdec_chain (GstPad *pad, GstData *_data);
-static GstPadLinkReturn gst_gsmdec_sinkconnect (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_gsmdec_sinkconnect (GstPad *pad, const GstCaps *caps);
static GstElementClass *parent_class = NULL;
/*static guint gst_gsmdec_signals[LAST_SIGNAL] = { 0 }; */
@@ -146,7 +146,7 @@ gst_gsmdec_init (GstGSMDec *gsmdec)
}
static GstPadLinkReturn
-gst_gsmdec_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_gsmdec_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstGSMDec *gsmdec;
gint rate;
@@ -154,11 +154,11 @@ gst_gsmdec_sinkconnect (GstPad *pad, const GstCaps2 *caps)
gsmdec = GST_GSMDEC (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &rate);
if (gst_pad_try_set_caps (gsmdec->srcpad,
- gst_caps2_new_simple ("audio/x-raw-int",
+ gst_caps_new_simple ("audio/x-raw-int",
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"signed", G_TYPE_BOOLEAN, TRUE,
"width", G_TYPE_INT, 16,
diff --git a/ext/gsm/gstgsmenc.c b/ext/gsm/gstgsmenc.c
index 7158630c5..a608fea03 100644
--- a/ext/gsm/gstgsmenc.c
+++ b/ext/gsm/gstgsmenc.c
@@ -50,7 +50,7 @@ static void gst_gsmenc_class_init (GstGSMEnc *klass);
static void gst_gsmenc_init (GstGSMEnc *gsmenc);
static void gst_gsmenc_chain (GstPad *pad,GstData *_data);
-static GstPadLinkReturn gst_gsmenc_sinkconnect (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_gsmenc_sinkconnect (GstPad *pad, const GstCaps *caps);
static GstElementClass *parent_class = NULL;
static guint gst_gsmenc_signals[LAST_SIGNAL] = { 0 };
@@ -156,17 +156,17 @@ gst_gsmenc_init (GstGSMEnc *gsmenc)
}
static GstPadLinkReturn
-gst_gsmenc_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_gsmenc_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstGSMEnc *gsmenc;
GstStructure *structure;
gsmenc = GST_GSMENC (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &gsmenc->rate);
if (gst_pad_try_set_caps (gsmenc->srcpad,
- gst_caps2_new_simple("audio/x-gsm",
+ gst_caps_new_simple("audio/x-gsm",
"rate", G_TYPE_INT, gsmenc->rate,
"channels", G_TYPE_INT, 1,
NULL)) > 0)
diff --git a/ext/hermes/gstcolorspace.c b/ext/hermes/gstcolorspace.c
index aa4edb595..7a42e905a 100644
--- a/ext/hermes/gstcolorspace.c
+++ b/ext/hermes/gstcolorspace.c
@@ -58,7 +58,7 @@ static void gst_colorspace_get_property (GObject *object, guint prop_id,
GValue *value, GParamSpec *pspec);
static GstPadLinkReturn
- gst_colorspace_link (GstPad *pad, const GstCaps2 *caps);
+ gst_colorspace_link (GstPad *pad, const GstCaps *caps);
static void gst_colorspace_chain (GstPad *pad, GstData *_data);
static GstElementStateReturn
gst_colorspace_change_state (GstElement *element);
@@ -74,7 +74,7 @@ static GstElementClass *parent_class = NULL;
/*static guint gst_colorspace_signals[LAST_SIGNAL] = { 0 }; */
static gboolean
-colorspace_setup_converter (GstColorspace *space, GstCaps2 *from_caps, GstCaps2 *to_caps)
+colorspace_setup_converter (GstColorspace *space, GstCaps *from_caps, GstCaps *to_caps)
{
guint32 from_space, to_space;
GstStructure *from_struct;
@@ -83,8 +83,8 @@ colorspace_setup_converter (GstColorspace *space, GstCaps2 *from_caps, GstCaps2
g_return_val_if_fail (to_caps != NULL, FALSE);
g_return_val_if_fail (from_caps != NULL, FALSE);
- from_struct = gst_caps2_get_nth_cap (from_caps, 0);
- to_struct = gst_caps2_get_nth_cap (to_caps, 0);
+ from_struct = gst_caps_get_structure (from_caps, 0);
+ to_struct = gst_caps_get_structure (to_caps, 0);
from_space = GST_MAKE_FOURCC ('R','G','B',' ');
gst_structure_get_fourcc (from_struct, "format", &from_space);
@@ -226,12 +226,12 @@ colorspace_setup_converter (GstColorspace *space, GstCaps2 *from_caps, GstCaps2
return FALSE;
}
-static GstCaps2*
+static GstCaps*
gst_colorspace_getcaps (GstPad *pad)
{
GstColorspace *space;
- GstCaps2 *peercaps;
- GstCaps2 *ourcaps;
+ GstCaps *peercaps;
+ GstCaps *ourcaps;
space = GST_COLORSPACE (gst_pad_get_parent (pad));
@@ -239,16 +239,16 @@ gst_colorspace_getcaps (GstPad *pad)
peercaps = gst_pad_get_allowed_caps (space->srcpad);
/* and our own template of course */
- ourcaps = gst_caps2_copy (gst_pad_get_pad_template_caps (pad));
+ ourcaps = gst_caps_copy (gst_pad_get_pad_template_caps (pad));
/* merge them together, we prefer the peercaps first */
- gst_caps2_append (peercaps, ourcaps);
+ gst_caps_append (peercaps, ourcaps);
return peercaps;
}
static GstPadLinkReturn
-gst_colorspace_link (GstPad *pad, const GstCaps2 *caps)
+gst_colorspace_link (GstPad *pad, const GstCaps *caps)
{
GstColorspace *space;
GstPad *otherpad;
@@ -257,7 +257,7 @@ gst_colorspace_link (GstPad *pad, const GstCaps2 *caps)
space = GST_COLORSPACE (gst_pad_get_parent (pad));
otherpad = (pad == space->sinkpad) ? space->srcpad : space->sinkpad;
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &space->width);
gst_structure_get_int (structure, "height", &space->height);
@@ -266,9 +266,9 @@ gst_colorspace_link (GstPad *pad, const GstCaps2 *caps)
GST_INFO ( "size: %dx%d", space->width, space->height);
if (pad == space->sinkpad) {
- gst_caps2_replace (&space->sinkcaps, gst_caps2_copy(caps));
+ gst_caps_replace (&space->sinkcaps, gst_caps_copy(caps));
} else {
- gst_caps2_replace (&space->srccaps, gst_caps2_copy(caps));
+ gst_caps_replace (&space->srccaps, gst_caps_copy(caps));
}
#if 0
@@ -317,10 +317,10 @@ static void
gst_colorspace_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
- GstCaps2 *caps;
+ GstCaps *caps;
/* create caps for templates */
- caps = gst_caps2_from_string (
+ caps = gst_caps_from_string (
GST_VIDEO_YUV_PAD_TEMPLATE_CAPS ("{ I420, YV12, YUY2 }") "; "
GST_VIDEO_RGB_PAD_TEMPLATE_CAPS_24_32_REVERSE "; "
GST_VIDEO_RGB_PAD_TEMPLATE_CAPS_24_32 "; "
@@ -464,7 +464,7 @@ gst_colorspace_change_state (GstElement *element)
gst_colorspace_converter_destroy (space->converter);
space->converter = NULL;
space->type = GST_COLORSPACE_NONE;
- gst_caps2_replace (&space->sinkcaps, NULL);
+ gst_caps_replace (&space->sinkcaps, NULL);
break;
}
diff --git a/ext/hermes/gstcolorspace.h b/ext/hermes/gstcolorspace.h
index 5a5450670..0cf6f2d78 100644
--- a/ext/hermes/gstcolorspace.h
+++ b/ext/hermes/gstcolorspace.h
@@ -79,8 +79,8 @@ struct _GstColorspace {
gint srcbpp, destbpp;
gboolean passthru;
- GstCaps2 *sinkcaps;
- GstCaps2 *srccaps;
+ GstCaps *sinkcaps;
+ GstCaps *srccaps;
};
struct _GstColorspaceClass {
diff --git a/ext/hermes/yuv2rgb.c b/ext/hermes/yuv2rgb.c
index 512eb046b..b3b1b4945 100644
--- a/ext/hermes/yuv2rgb.c
+++ b/ext/hermes/yuv2rgb.c
@@ -105,7 +105,7 @@ static GstColorSpaceYUVTables * gst_colorspace_init_yuv(long depth,
long red_mask, long green_mask, long blue_mask);
GstColorSpaceConverter*
-gst_colorspace_yuv2rgb_get_converter (const GstCaps2 *from, const GstCaps2 *to)
+gst_colorspace_yuv2rgb_get_converter (const GstCaps *from, const GstCaps *to)
{
guint32 from_space;
GstColorSpaceConverter *new;
@@ -116,8 +116,8 @@ gst_colorspace_yuv2rgb_get_converter (const GstCaps2 *from, const GstCaps2 *to)
new = g_malloc (sizeof (GstColorSpaceConverter));
- struct_from = gst_caps2_get_nth_cap (from, 0);
- struct_to = gst_caps2_get_nth_cap (to, 0);
+ struct_from = gst_caps_get_structure (from, 0);
+ struct_to = gst_caps_get_structure (to, 0);
gst_structure_get_int (struct_from, "width", &new->width);
gst_structure_get_int (struct_from, "height", &new->height);
diff --git a/ext/hermes/yuv2rgb.h b/ext/hermes/yuv2rgb.h
index 8abb41cf0..7edfa3779 100644
--- a/ext/hermes/yuv2rgb.h
+++ b/ext/hermes/yuv2rgb.h
@@ -59,7 +59,7 @@ struct _GstColorSpaceConverter {
};
-GstColorSpaceConverter* gst_colorspace_yuv2rgb_get_converter (const GstCaps2 *from, const GstCaps2 *to);
+GstColorSpaceConverter* gst_colorspace_yuv2rgb_get_converter (const GstCaps *from, const GstCaps *to);
#define gst_colorspace_convert(converter, src, dest) \
(converter)->convert((converter), (src), (dest))
void gst_colorspace_converter_destroy (GstColorSpaceConverter *space);
diff --git a/ext/jack/gstjack.c b/ext/jack/gstjack.c
index 4ebeded2b..4a987ae17 100644
--- a/ext/jack/gstjack.c
+++ b/ext/jack/gstjack.c
@@ -77,7 +77,7 @@ static GstPadTemplate* gst_jack_sink_request_pad_factory();
static GstPad* gst_jack_request_new_pad (GstElement *element, GstPadTemplate *templ,
const gchar *name);
static GstElementStateReturn gst_jack_change_state (GstElement *element);
-static GstPadLinkReturn gst_jack_link (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_jack_link (GstPad *pad, const GstCaps *caps);
static void gst_jack_loop (GstElement *element);
@@ -263,8 +263,8 @@ gst_jack_src_request_pad_factory (void)
static GstPadTemplate *template = NULL;
if (!template) {
- GstCaps2 *caps;
- caps = gst_caps2_from_string (GST_AUDIO_FLOAT_STANDARD_PAD_TEMPLATE_CAPS);
+ GstCaps *caps;
+ caps = gst_caps_from_string (GST_AUDIO_FLOAT_STANDARD_PAD_TEMPLATE_CAPS);
template = gst_pad_template_new ("%s", GST_PAD_SRC,
GST_PAD_REQUEST, caps);
}
@@ -278,8 +278,8 @@ gst_jack_sink_request_pad_factory (void)
static GstPadTemplate *template = NULL;
if (!template) {
- GstCaps2 *caps;
- caps = gst_caps2_from_string (GST_AUDIO_FLOAT_STANDARD_PAD_TEMPLATE_CAPS);
+ GstCaps *caps;
+ caps = gst_caps_from_string (GST_AUDIO_FLOAT_STANDARD_PAD_TEMPLATE_CAPS);
template = gst_pad_template_new ("%s", GST_PAD_SINK,
GST_PAD_REQUEST, caps);
}
@@ -349,7 +349,7 @@ gst_jack_change_state (GstElement *element)
GstJack *this;
GList *l = NULL, **pads;
GstJackPad *pad;
- GstCaps2 *caps;
+ GstCaps *caps;
g_return_val_if_fail (element != NULL, FALSE);
this = GST_JACK (element);
@@ -393,7 +393,7 @@ gst_jack_change_state (GstElement *element)
while (l) {
pad = GST_JACK_PAD (l);
caps = gst_pad_get_caps (pad->pad);
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"rate", G_TYPE_INT, (int)this->bin->rate,
"buffer-frames", G_TYPE_INT, (gint)this->bin->nframes,
NULL);
@@ -417,7 +417,7 @@ gst_jack_change_state (GstElement *element)
}
static GstPadLinkReturn
-gst_jack_link (GstPad *pad, const GstCaps2 *caps)
+gst_jack_link (GstPad *pad, const GstCaps *caps)
{
GstJack *this;
gint rate, buffer_frames;
@@ -425,7 +425,7 @@ gst_jack_link (GstPad *pad, const GstCaps2 *caps)
this = GST_JACK (GST_OBJECT_PARENT (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &rate);
gst_structure_get_int (structure, "buffer-frames", &buffer_frames);
if (this->bin && (rate != this->bin->rate ||
diff --git a/ext/ladspa/gstladspa.c b/ext/ladspa/gstladspa.c
index b6e97120d..ff2711fce 100644
--- a/ext/ladspa/gstladspa.c
+++ b/ext/ladspa/gstladspa.c
@@ -37,7 +37,7 @@
#define LADSPA_VERSION "1.0"
#endif
-static GstStaticCaps2 ladspa_pad_caps =
+static GstStaticCaps ladspa_pad_caps =
GST_STATIC_CAPS (GST_AUDIO_FLOAT_STANDARD_PAD_TEMPLATE_CAPS);
static void gst_ladspa_class_init (GstLADSPAClass *klass);
@@ -45,7 +45,7 @@ static void gst_ladspa_base_init (GstLADSPAClass *klass);
static void gst_ladspa_init (GstLADSPA *ladspa);
static void gst_ladspa_update_int (const GValue *value, gpointer data);
-static GstPadLinkReturn gst_ladspa_link (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_ladspa_link (GstPad *pad, const GstCaps *caps);
static void gst_ladspa_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
static void gst_ladspa_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
@@ -112,11 +112,11 @@ gst_ladspa_base_init (GstLADSPAClass *klass)
/* the factories take ownership of the name */
if (LADSPA_IS_PORT_INPUT(desc->PortDescriptors[j])) {
templ = gst_pad_template_new (name, GST_PAD_SINK, GST_PAD_ALWAYS,
- gst_caps2_copy (gst_static_caps2_get (&ladspa_pad_caps)));
+ gst_caps_copy (gst_static_caps_get (&ladspa_pad_caps)));
klass->numsinkpads++;
} else {
templ = gst_pad_template_new (name, GST_PAD_SRC, GST_PAD_ALWAYS,
- gst_caps2_copy (gst_static_caps2_get (&ladspa_pad_caps)));
+ gst_caps_copy (gst_static_caps_get (&ladspa_pad_caps)));
klass->numsrcpads++;
}
@@ -463,7 +463,7 @@ gst_ladspa_update_int(const GValue *value, gpointer data)
}
static GstPadLinkReturn
-gst_ladspa_link (GstPad *pad, const GstCaps2 *caps)
+gst_ladspa_link (GstPad *pad, const GstCaps *caps)
{
GstElement *element = (GstElement*)GST_PAD_PARENT (pad);
GstLADSPA *ladspa = (GstLADSPA*)element;
@@ -480,7 +480,7 @@ gst_ladspa_link (GstPad *pad, const GstCaps2 *caps)
/* we assume that the ladspa plugin can handle any sample rate, so this
check gets put last */
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &rate);
/* have to instantiate ladspa plugin when samplerate changes (groan) */
if (ladspa->samplerate != rate) {
diff --git a/ext/libfame/gstlibfame.c b/ext/libfame/gstlibfame.c
index 6b8d30534..c68ff36be 100644
--- a/ext/libfame/gstlibfame.c
+++ b/ext/libfame/gstlibfame.c
@@ -298,7 +298,7 @@ gst_fameenc_class_init (GstFameEncClass *klass)
}
static GstPadLinkReturn
-gst_fameenc_sink_link (GstPad *pad, const GstCaps2 *caps)
+gst_fameenc_sink_link (GstPad *pad, const GstCaps *caps)
{
gint width, height, fps_idx;
gdouble fps;
@@ -312,7 +312,7 @@ gst_fameenc_sink_link (GstPad *pad, const GstCaps2 *caps)
return GST_PAD_LINK_REFUSED;
}
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &width);
gst_structure_get_int (structure, "height", &height);
gst_structure_get_double (structure, "framerate", &fps);
diff --git a/ext/mas/massink.c b/ext/mas/massink.c
index 0a87c9c86..01eed9e6d 100644
--- a/ext/mas/massink.c
+++ b/ext/mas/massink.c
@@ -65,7 +65,7 @@ static gboolean gst_massink_open_audio (GstMassink *sink);
//static void gst_massink_close_audio (GstMassink *sink);
static GstElementStateReturn gst_massink_change_state (GstElement *element);
static gboolean gst_massink_sync_parms (GstMassink *massink);
-static GstPadLinkReturn gst_massink_sinkconnect (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_massink_sinkconnect (GstPad *pad, const GstCaps *caps);
static void gst_massink_chain (GstPad *pad, GstData *_data);
@@ -201,7 +201,7 @@ gst_massink_sync_parms (GstMassink *massink)
}
static GstPadLinkReturn
-gst_massink_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_massink_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstMassink *massink;
diff --git a/ext/mplex/gstmplex.cc b/ext/mplex/gstmplex.cc
index 535b058fd..2fda444c7 100644
--- a/ext/mplex/gstmplex.cc
+++ b/ext/mplex/gstmplex.cc
@@ -101,7 +101,7 @@ GST_STATIC_PAD_TEMPLATE (
"private_stream_2",
GST_PAD_SINK,
GST_PAD_REQUEST,
- GST_STATIC_CAPS2_ANY
+ GST_STATIC_CAPS_ANY
);
#define GST_TYPE_MPLEX_MUX_FORMAT (gst_mplex_mux_format_get_type())
@@ -253,7 +253,7 @@ gst_mplex_init (GstMPlex *mplex)
}
static GstPadLinkReturn
-gst_mplex_video_link (GstPad *pad, const GstCaps2 *caps)
+gst_mplex_video_link (GstPad *pad, const GstCaps *caps)
{
GstMPlex *mplex;
gint version;
@@ -264,7 +264,7 @@ gst_mplex_video_link (GstPad *pad, const GstCaps2 *caps)
stream = (GstMPlexStream *) gst_pad_get_element_private (pad);
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
if (!gst_structure_get_int (structure, "mpegversion", &version)){
return GST_PAD_LINK_REFUSED;
diff --git a/ext/sdl/sdlvideosink.c b/ext/sdl/sdlvideosink.c
index 1628057ad..887b37f85 100644
--- a/ext/sdl/sdlvideosink.c
+++ b/ext/sdl/sdlvideosink.c
@@ -64,7 +64,7 @@ static void gst_sdlvideosink_destroy (GstSDLVideoSink *sdl);
static GstPadLinkReturn
gst_sdlvideosink_sinkconnect (GstPad *pad,
- const GstCaps2 *caps);
+ const GstCaps *caps);
static void gst_sdlvideosink_chain (GstPad *pad,
GstData *data);
@@ -128,7 +128,7 @@ static void
gst_sdlvideosink_base_init (gpointer g_class)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
- GstCaps2 *capslist;
+ GstCaps *capslist;
gint i;
gulong format[6] = { GST_MAKE_FOURCC('I','4','2','0'),
GST_MAKE_FOURCC('Y','V','1','2'),
@@ -138,9 +138,9 @@ gst_sdlvideosink_base_init (gpointer g_class)
};
/* make a list of all available caps */
- capslist = gst_caps2_new_empty();
+ capslist = gst_caps_new_empty();
for (i = 0; i < 5; i++) {
- gst_caps2_append_cap (capslist,
+ gst_caps_append_structure (capslist,
gst_structure_new ("video/x-raw-yuv",
"format", GST_TYPE_FOURCC, format[i],
"width", GST_TYPE_INT_RANGE, 1, G_MAXINT,
@@ -509,7 +509,7 @@ gst_sdlvideosink_create (GstSDLVideoSink *sdlvideosink)
static GstPadLinkReturn
gst_sdlvideosink_sinkconnect (GstPad *pad,
- const GstCaps2 *vscapslist)
+ const GstCaps *vscapslist)
{
GstSDLVideoSink *sdlvideosink;
guint32 format;
@@ -517,7 +517,7 @@ gst_sdlvideosink_sinkconnect (GstPad *pad,
sdlvideosink = GST_SDLVIDEOSINK (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (vscapslist, 0);
+ structure = gst_caps_get_structure (vscapslist, 0);
gst_structure_get_fourcc (structure, "format", &format);
sdlvideosink->format =
gst_sdlvideosink_get_sdl_from_fourcc (sdlvideosink, format);
diff --git a/ext/snapshot/gstsnapshot.c b/ext/snapshot/gstsnapshot.c
index eac0cdf86..eff6567af 100644
--- a/ext/snapshot/gstsnapshot.c
+++ b/ext/snapshot/gstsnapshot.c
@@ -164,16 +164,16 @@ snapshot_handler(GstElement *element)
static gboolean
-gst_snapshot_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_snapshot_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstSnapshot *filter;
- GstCaps2 *from_caps, *to_caps;
+ GstCaps *from_caps, *to_caps;
gdouble fps;
GstStructure *structure;
filter = GST_SNAPSHOT (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &filter->width);
gst_structure_get_int (structure, "height", &filter->height);
gst_structure_get_double (structure, "framerate", &fps);
@@ -181,7 +181,7 @@ gst_snapshot_sinkconnect (GstPad *pad, const GstCaps2 *caps)
filter->to_bpp = 24;
- to_caps = gst_caps2_new_simple ("video/x-raw-rgb",
+ to_caps = gst_caps_new_simple ("video/x-raw-rgb",
"width", G_TYPE_INT, filter->width,
"height", G_TYPE_INT, filter->height,
"red_mask", G_TYPE_INT, 0x0000FF,
@@ -195,7 +195,7 @@ gst_snapshot_sinkconnect (GstPad *pad, const GstCaps2 *caps)
{
case GST_MAKE_FOURCC('Y','U','Y','2'):
case GST_MAKE_FOURCC('I','4','2','0'):
- from_caps = gst_caps2_new_simple ("video/x-raw-yuv",
+ from_caps = gst_caps_new_simple ("video/x-raw-yuv",
"format", GST_TYPE_FOURCC, GST_STR_FOURCC ("I420"),
"width", G_TYPE_INT, filter->width,
"height", G_TYPE_INT, filter->height,
diff --git a/ext/sndfile/gstsf.c b/ext/sndfile/gstsf.c
index c3a69265d..b9c630c91 100644
--- a/ext/sndfile/gstsf.c
+++ b/ext/sndfile/gstsf.c
@@ -156,7 +156,7 @@ static GstPad* gst_sf_request_new_pad (GstElement *element, GstPadTemplate *tem
static void gst_sf_release_request_pad (GstElement *element, GstPad *pad);
static GstElementStateReturn gst_sf_change_state (GstElement *element);
-static GstPadLinkReturn gst_sf_link (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_sf_link (GstPad *pad, const GstCaps *caps);
static void gst_sf_loop (GstElement *element);
@@ -524,12 +524,12 @@ gst_sf_release_request_pad (GstElement *element, GstPad *pad)
}
static GstPadLinkReturn
-gst_sf_link (GstPad *pad, const GstCaps2 *caps)
+gst_sf_link (GstPad *pad, const GstCaps *caps)
{
GstSF *this = (GstSF*)GST_OBJECT_PARENT (pad);
GstStructure *structure;
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &this->rate);
gst_structure_get_int (structure, "buffer-frames", &this->buffer_frames);
@@ -695,11 +695,11 @@ gst_sf_loop (GstElement *element)
continue;
if (!channel->caps_set) {
- GstCaps2 *caps = GST_PAD_CAPS (GST_SF_CHANNEL (l)->pad);
+ GstCaps *caps = GST_PAD_CAPS (GST_SF_CHANNEL (l)->pad);
if (!caps)
- caps = gst_caps2_copy
+ caps = gst_caps_copy
(GST_PAD_TEMPLATE_CAPS (GST_PAD_PAD_TEMPLATE (GST_SF_CHANNEL (l)->pad)));
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"rate", G_TYPE_INT, this->rate,
"buffer-frames", G_TYPE_INT, this->buffer_frames,
NULL);
diff --git a/ext/swfdec/gstswfdec.c b/ext/swfdec/gstswfdec.c
index da222e342..6e42c4fa7 100644
--- a/ext/swfdec/gstswfdec.c
+++ b/ext/swfdec/gstswfdec.c
@@ -158,18 +158,18 @@ gst_swfdec_class_init(GstSwfdecClass *klass)
gstelement_class->change_state = gst_swfdec_change_state;
}
-static GstCaps2 *gst_swfdec_videosrc_getcaps(GstPad *pad)
+static GstCaps *gst_swfdec_videosrc_getcaps(GstPad *pad)
{
GstSwfdec *swfdec;
- GstCaps2 *caps;
+ GstCaps *caps;
swfdec = GST_SWFDEC (gst_pad_get_parent (pad));
- caps = gst_caps2_copy (gst_pad_template_get_caps (
+ caps = gst_caps_copy (gst_pad_template_get_caps (
gst_static_pad_template_get (&video_template_factory)));
if (swfdec->height) {
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"framerate", G_TYPE_DOUBLE, swfdec->frame_rate,
"height",G_TYPE_INT,swfdec->height,
"width",G_TYPE_INT,swfdec->width,
diff --git a/ext/xvid/gstxviddec.c b/ext/xvid/gstxviddec.c
index afc123431..84af838d5 100644
--- a/ext/xvid/gstxviddec.c
+++ b/ext/xvid/gstxviddec.c
@@ -77,7 +77,7 @@ static void gst_xviddec_dispose (GObject *object);
static void gst_xviddec_chain (GstPad *pad,
GstData *data);
static GstPadLinkReturn gst_xviddec_link (GstPad *pad,
- const GstCaps2 *vscapslist);
+ const GstCaps *vscapslist);
static GstPadLinkReturn gst_xviddec_negotiate (GstXvidDec *xviddec);
static GstElementClass *parent_class = NULL;
@@ -263,7 +263,7 @@ static GstPadLinkReturn
gst_xviddec_negotiate (GstXvidDec *xviddec)
{
GstPadLinkReturn ret;
- GstCaps2 *caps;
+ GstCaps *caps;
struct {
guint32 fourcc;
gint depth, bpp;
@@ -307,7 +307,7 @@ gst_xviddec_negotiate (GstXvidDec *xviddec)
r_mask = R_MASK_32_INT; g_mask = G_MASK_32_INT; b_mask = B_MASK_32_INT;
break;
}
- caps = gst_caps2_new_simple (
+ caps = gst_caps_new_simple (
"video/x-raw-rgb",
"width", G_TYPE_INT, xviddec->width,
"height", G_TYPE_INT, xviddec->height,
@@ -320,7 +320,7 @@ gst_xviddec_negotiate (GstXvidDec *xviddec)
"framerate", G_TYPE_DOUBLE, xviddec->fps,
NULL);
} else {
- caps = gst_caps2_new_simple (
+ caps = gst_caps_new_simple (
"video/x-raw-yuv",
"width", G_TYPE_INT, xviddec->width,
"height", G_TYPE_INT, xviddec->height,
@@ -346,7 +346,7 @@ gst_xviddec_negotiate (GstXvidDec *xviddec)
static GstPadLinkReturn
gst_xviddec_link (GstPad *pad,
- const GstCaps2 *vscaps)
+ const GstCaps *vscaps)
{
GstXvidDec *xviddec;
GstStructure *structure;
@@ -360,7 +360,7 @@ gst_xviddec_link (GstPad *pad,
/* if we get here, we know the input is xvid. we
* only need to bother with the output colorspace */
- structure = gst_caps2_get_nth_cap (vscaps, 0);
+ structure = gst_caps_get_structure (vscaps, 0);
gst_structure_get_int(structure, "width", &xviddec->width);
gst_structure_get_int(structure, "height", &xviddec->height);
gst_structure_get_double(structure, "framerate", &xviddec->fps);
diff --git a/ext/xvid/gstxvidenc.c b/ext/xvid/gstxvidenc.c
index e3cad2940..ce2e71e9e 100644
--- a/ext/xvid/gstxvidenc.c
+++ b/ext/xvid/gstxvidenc.c
@@ -79,7 +79,7 @@ static void gst_xvidenc_init (GstXvidEnc *xvidenc);
static void gst_xvidenc_chain (GstPad *pad,
GstData *data);
static GstPadLinkReturn gst_xvidenc_link (GstPad *pad,
- const GstCaps2 *vscapslist);
+ const GstCaps *vscapslist);
/* properties */
static void gst_xvidenc_set_property (GObject *object,
@@ -298,7 +298,7 @@ gst_xvidenc_chain (GstPad *pad,
static GstPadLinkReturn
gst_xvidenc_link (GstPad *pad,
- const GstCaps2 *vscaps)
+ const GstCaps *vscaps)
{
GstXvidEnc *xvidenc;
GstStructure *structure;
@@ -315,8 +315,8 @@ gst_xvidenc_link (GstPad *pad,
xvidenc->handle = NULL;
}
- g_return_val_if_fail (gst_caps2_get_n_structures (vscaps) == 1, GST_PAD_LINK_REFUSED);
- structure = gst_caps2_get_nth_cap (vscaps, 0);
+ g_return_val_if_fail (gst_caps_get_size (vscaps) == 1, GST_PAD_LINK_REFUSED);
+ structure = gst_caps_get_structure (vscaps, 0);
gst_structure_get_int (structure, "width", &w);
gst_structure_get_int (structure, "height", &h);
@@ -372,9 +372,9 @@ gst_xvidenc_link (GstPad *pad,
if (gst_xvidenc_setup(xvidenc)) {
GstPadLinkReturn ret;
- GstCaps2 *new_caps;
+ GstCaps *new_caps;
- new_caps = gst_caps2_new_simple(
+ new_caps = gst_caps_new_simple(
"video/x-xvid",
"width", G_TYPE_INT, w,
"height", G_TYPE_INT, h,
diff --git a/gst-libs/gst/audio/audio.c b/gst-libs/gst/audio/audio.c
index f3c85a59f..bec298e93 100644
--- a/gst-libs/gst/audio/audio.c
+++ b/gst-libs/gst/audio/audio.c
@@ -35,7 +35,7 @@ gst_audio_frame_byte_size (GstPad* pad)
int width = 0;
int channels = 0;
- GstCaps2 *caps;
+ GstCaps *caps;
GstStructure *structure;
/* get caps of pad */
@@ -48,7 +48,7 @@ gst_audio_frame_byte_size (GstPad* pad)
return 0;
}
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &width);
gst_structure_get_int (structure, "channels", &channels);
@@ -82,7 +82,7 @@ gst_audio_frame_rate (GstPad *pad)
* returns 0 if failed, rate if success
*/
{
- GstCaps2 *caps = NULL;
+ GstCaps *caps = NULL;
gint rate;
GstStructure *structure;
@@ -96,7 +96,7 @@ gst_audio_frame_rate (GstPad *pad)
return 0;
}
else {
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &rate);
return rate;
}
@@ -117,7 +117,7 @@ gst_audio_length (GstPad* pad, GstBuffer* buf)
double length;
- GstCaps2 *caps = NULL;
+ GstCaps *caps = NULL;
GstStructure *structure;
g_assert (GST_IS_BUFFER (buf));
@@ -132,7 +132,7 @@ gst_audio_length (GstPad* pad, GstBuffer* buf)
}
else
{
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
bytes = GST_BUFFER_SIZE (buf);
gst_structure_get_int (structure, "width", &width);
gst_structure_get_int (structure, "channels", &channels);
@@ -156,7 +156,7 @@ gst_audio_highest_sample_value (GstPad* pad)
{
gboolean is_signed = FALSE;
gint width = 0;
- GstCaps2 *caps = NULL;
+ GstCaps *caps = NULL;
GstStructure *structure;
caps = GST_PAD_CAPS (pad);
@@ -166,7 +166,7 @@ gst_audio_highest_sample_value (GstPad* pad)
GST_ELEMENT_NAME (gst_pad_get_parent (pad)), GST_PAD_NAME (pad));
}
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &width);
gst_structure_get_boolean (structure, "signed", &is_signed);
diff --git a/gst-libs/gst/audio/gstaudiofilter.c b/gst-libs/gst/audio/gstaudiofilter.c
index adbb97485..46e7c7de6 100644
--- a/gst-libs/gst/audio/gstaudiofilter.c
+++ b/gst-libs/gst/audio/gstaudiofilter.c
@@ -48,7 +48,7 @@ static void gst_audiofilter_set_property (GObject *object, guint prop_id, const
static void gst_audiofilter_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
static void gst_audiofilter_chain (GstPad *pad, GstData *_data);
-GstCaps2 * gst_audiofilter_class_get_capslist(GstAudiofilterClass *klass);
+GstCaps * gst_audiofilter_class_get_capslist(GstAudiofilterClass *klass);
static GstElementClass *parent_class = NULL;
@@ -105,11 +105,11 @@ static void gst_audiofilter_class_init (gpointer g_class, gpointer class_data)
gobject_class->get_property = gst_audiofilter_get_property;
}
-static GstCaps2 *
+static GstCaps *
gst_audiofilter_getcaps (GstPad *pad)
{
GstAudiofilter *audiofilter;
- GstCaps2 *othercaps;
+ GstCaps *othercaps;
GstAudiofilterClass *audiofilter_class;
GST_DEBUG("gst_audiofilter_sink_getcaps");
@@ -124,11 +124,11 @@ gst_audiofilter_getcaps (GstPad *pad)
othercaps = gst_pad_get_allowed_caps (audiofilter->srcpad);
}
- return gst_caps2_intersect (othercaps, audiofilter_class->caps);
+ return gst_caps_intersect (othercaps, audiofilter_class->caps);
}
static GstPadLinkReturn
-gst_audiofilter_link (GstPad *pad, const GstCaps2 *caps)
+gst_audiofilter_link (GstPad *pad, const GstCaps *caps)
{
GstAudiofilter *audiofilter;
GstPadLinkReturn ret;
@@ -150,7 +150,7 @@ gst_audiofilter_link (GstPad *pad, const GstCaps2 *caps)
if (link_ret != GST_PAD_LINK_OK) return link_ret;
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
if (strcmp (gst_structure_get_name (structure), "audio/x-raw-int") == 0) {
ret = gst_structure_get_int (structure, "depth", &audiofilter->depth);
@@ -287,19 +287,19 @@ gst_audiofilter_get_property (GObject *object, guint prop_id, GValue *value, GPa
}
void gst_audiofilter_class_add_pad_templates (
- GstAudiofilterClass *audiofilter_class, const GstCaps2 *caps)
+ GstAudiofilterClass *audiofilter_class, const GstCaps *caps)
{
GstElementClass *element_class = GST_ELEMENT_CLASS (audiofilter_class);
- audiofilter_class->caps = gst_caps2_copy(caps);
+ audiofilter_class->caps = gst_caps_copy(caps);
gst_element_class_add_pad_template (element_class,
gst_pad_template_new("src", GST_PAD_SRC, GST_PAD_ALWAYS,
- gst_caps2_copy(caps)));
+ gst_caps_copy(caps)));
gst_element_class_add_pad_template (element_class,
gst_pad_template_new("sink", GST_PAD_SINK, GST_PAD_ALWAYS,
- gst_caps2_copy(caps)));
+ gst_caps_copy(caps)));
}
static gboolean
diff --git a/gst-libs/gst/audio/gstaudiofilter.h b/gst-libs/gst/audio/gstaudiofilter.h
index f5bb7eaa4..4723c329a 100644
--- a/gst-libs/gst/audio/gstaudiofilter.h
+++ b/gst-libs/gst/audio/gstaudiofilter.h
@@ -68,7 +68,7 @@ struct _GstAudiofilter {
struct _GstAudiofilterClass {
GstElementClass parent_class;
- GstCaps2 *caps;
+ GstCaps *caps;
GstAudiofilterSetupFunc setup;
GstAudiofilterInplaceFilterFunc filter_inplace;
GstAudiofilterFilterFunc filter;
@@ -76,7 +76,7 @@ struct _GstAudiofilterClass {
GType gst_audiofilter_get_type(void);
-void gst_audiofilter_class_add_pad_templates (GstAudiofilterClass *audiofilterclass, const GstCaps2 *caps);
+void gst_audiofilter_class_add_pad_templates (GstAudiofilterClass *audiofilterclass, const GstCaps *caps);
G_END_DECLS
diff --git a/gst-libs/gst/media-info/media-info-priv.c b/gst-libs/gst/media-info/media-info-priv.c
index b613ab86c..c7f470eaa 100644
--- a/gst-libs/gst/media-info/media-info-priv.c
+++ b/gst-libs/gst/media-info/media-info-priv.c
@@ -78,7 +78,7 @@ gmi_track_new (void)
/* callbacks */
static void
-have_type_callback (GstElement *typefind, GstCaps2 *type, GstMediaInfoPriv *priv)
+have_type_callback (GstElement *typefind, GstCaps *type, GstMediaInfoPriv *priv)
{
priv->type = type;
}
@@ -136,13 +136,13 @@ gmi_reset (GstMediaInfo *info)
if (priv->format)
{
GMI_DEBUG ("unreffing priv->format, error before this ?\n");
- gst_caps2_free (priv->format);
+ gst_caps_free (priv->format);
priv->format = NULL;
}
if (priv->metadata)
{
GMI_DEBUG ("unreffing priv->metadata, error before this ?\n");
- gst_caps2_free (priv->metadata);
+ gst_caps_free (priv->metadata);
priv->metadata = NULL;
}
if (priv->stream)
@@ -193,12 +193,12 @@ gmi_seek_to_track (GstMediaInfo *info, long track)
/* clear structs because of the seek */
if (priv->metadata)
{
- gst_caps2_free (priv->metadata);
+ gst_caps_free (priv->metadata);
priv->metadata = NULL;
}
if (priv->streaminfo)
{
- gst_caps2_free (priv->streaminfo);
+ gst_caps_free (priv->streaminfo);
priv->streaminfo = NULL;
}
return TRUE;
@@ -293,7 +293,7 @@ gmi_clear_decoder (GstMediaInfo *info)
/****
* typefind functions
* find the type of a file and store it in the caps of the info
- * FIXME: we might better return GstCaps2 instead of storing them
+ * FIXME: we might better return GstCaps instead of storing them
* internally */
/* prepare for typefind, move from NULL to TYPEFIND */
@@ -304,7 +304,7 @@ gmip_find_type_pre (GstMediaInfoPriv *priv)
if (priv->type)
{
/* we don't need to unref, this is done inside gsttypefind.c
- gst_caps2_free (priv->type);
+ gst_caps_free (priv->type);
*/
priv->type = NULL;
}
@@ -578,7 +578,7 @@ gmip_find_track_streaminfo_post (GstMediaInfoPriv *priv)
value_end -= value_start;
/* FIXME: check units; this is in seconds */
- gst_caps2_set_simple (priv->streaminfo,
+ gst_caps_set_simple (priv->streaminfo,
"length", G_TYPE_INT, (int) (value_end / 1E6), NULL);
}
}
diff --git a/gst-libs/gst/media-info/media-info-priv.h b/gst-libs/gst/media-info/media-info-priv.h
index 24da73332..0a7aa5009 100644
--- a/gst-libs/gst/media-info/media-info-priv.h
+++ b/gst-libs/gst/media-info/media-info-priv.h
@@ -64,14 +64,14 @@ struct GstMediaInfoPriv
GstElement *typefind;
- GstCaps2 *type;
+ GstCaps *type;
GstPad *decoder_pad; /* pad for querying decoded caps */
GstPad *source_pad; /* pad for querying encoded caps */
- GstCaps2 *format;
- GstCaps2 *metadata;
+ GstCaps *format;
+ GstCaps *metadata;
gint metadata_iters;
- GstCaps2 *streaminfo;
+ GstCaps *streaminfo;
GstElement *decoder; /* will be != NULL during collection */
gchar *source_element; /* type of element used as source */
diff --git a/gst-libs/gst/media-info/media-info-test.c b/gst-libs/gst/media-info/media-info-test.c
index 8e0c1f72e..5a73c8bd7 100644
--- a/gst-libs/gst/media-info/media-info-test.c
+++ b/gst-libs/gst/media-info/media-info-test.c
@@ -27,11 +27,11 @@ info_print (GstMediaInfoStream *stream)
g_print ("- track %d\n", i);
track = (GstMediaInfoTrack *) p->data;
g_print (" - metadata:\n");
- g_print ("%s\n", gst_caps2_to_string (track->metadata));
+ g_print ("%s\n", gst_caps_to_string (track->metadata));
g_print (" - streaminfo:\n");
- g_print ("%s\n", gst_caps2_to_string (track->streaminfo));
+ g_print ("%s\n", gst_caps_to_string (track->streaminfo));
g_print (" - format:\n");
- g_print ("%s\n", gst_caps2_to_string (track->format));
+ g_print ("%s\n", gst_caps_to_string (track->format));
p = p->next;
}
}
diff --git a/gst-libs/gst/media-info/media-info.c b/gst-libs/gst/media-info/media-info.c
index d22bdbb46..e214e8e10 100644
--- a/gst-libs/gst/media-info/media-info.c
+++ b/gst-libs/gst/media-info/media-info.c
@@ -295,7 +295,7 @@ gst_media_info_read_idler (GstMediaInfo *info, GstMediaInfoStream **streamp)
gmip_find_type_post (priv);
GMI_DEBUG("finding out mime type\n");
mime = g_strdup (gst_structure_get_name (
- gst_caps2_get_nth_cap(priv->type, 0)));
+ gst_caps_get_structure(priv->type, 0)));
GMI_DEBUG("found out mime type: %s\n", mime);
decoder = gmi_get_decoder (info, mime);
if (decoder == NULL)
@@ -445,7 +445,7 @@ gst_media_info_read (GstMediaInfo *info, const char *location, guint16 flags)
if (!gmip_find_type (priv)) return NULL;
mime = g_strdup (gst_structure_get_name (
- gst_caps2_get_nth_cap(priv->type, 0)));
+ gst_caps_get_structure(priv->type, 0)));
GMI_DEBUG("mime type: %s\n", mime);
/* c) figure out decoder */
diff --git a/gst-libs/gst/media-info/media-info.h b/gst-libs/gst/media-info/media-info.h
index 069bfd7c0..d42a4af7b 100644
--- a/gst-libs/gst/media-info/media-info.h
+++ b/gst-libs/gst/media-info/media-info.h
@@ -55,7 +55,7 @@ typedef struct
gboolean seekable;
gchar *mime;
gchar *path;
- GstCaps2 *caps; /* properties of the complete bitstream */
+ GstCaps *caps; /* properties of the complete bitstream */
guint64 length_time;
glong length_tracks;
@@ -68,9 +68,9 @@ typedef struct
* or one of a set of sequentially muxed streams */
typedef struct
{
- GstCaps2 *metadata; /* changeable metadata or tags */
- GstCaps2 *streaminfo; /* codec property stuff */
- GstCaps2 *format; /* properties of the logical stream */
+ GstCaps *metadata; /* changeable metadata or tags */
+ GstCaps *streaminfo; /* codec property stuff */
+ GstCaps *format; /* properties of the logical stream */
guint64 length_time;
@@ -80,7 +80,7 @@ typedef struct
typedef struct
{
- GstCaps2 *caps; /* properties of the muxed concurrent stream */
+ GstCaps *caps; /* properties of the muxed concurrent stream */
} GstMediaInfoConcurrent;
#define GST_MEDIA_INFO_ERROR gst_media_info_error_quark ()
@@ -116,13 +116,13 @@ gboolean gst_media_info_read_many (GstMediaInfo *media_info,
GList *locations,
guint16 GST_MEDIA_INFO_FLAGS,
GError **error);
-GstCaps2 * gst_media_info_get_next (GstMediaInfo *media_info,
+GstCaps * gst_media_info_get_next (GstMediaInfo *media_info,
GError **error);
/*
* FIXME: reset ?
gboolean gst_media_info_write (GstMediaInfo *media_info,
const char *location,
- GstCaps2 *media_info);
+ GstCaps *media_info);
*/
G_END_DECLS
diff --git a/gst-libs/gst/play/gstplay.c b/gst-libs/gst/play/gstplay.c
index e4c652a54..061f125c7 100644
--- a/gst-libs/gst/play/gstplay.c
+++ b/gst-libs/gst/play/gstplay.c
@@ -909,13 +909,13 @@ gst_play_get_sink_element (GstPlay *play,
}
else {
/* If not a src pad checking caps */
- const GstCaps2 *caps;
+ const GstCaps *caps;
GstStructure *structure;
gboolean has_video_cap = FALSE;
gboolean has_audio_cap = FALSE;
caps = gst_pad_get_caps (GST_PAD (pads->data));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
if (strcmp (gst_structure_get_name (structure),
"audio/x-raw-int") == 0) {
diff --git a/gst-libs/gst/play/play.c b/gst-libs/gst/play/play.c
index e4c652a54..061f125c7 100644
--- a/gst-libs/gst/play/play.c
+++ b/gst-libs/gst/play/play.c
@@ -909,13 +909,13 @@ gst_play_get_sink_element (GstPlay *play,
}
else {
/* If not a src pad checking caps */
- const GstCaps2 *caps;
+ const GstCaps *caps;
GstStructure *structure;
gboolean has_video_cap = FALSE;
gboolean has_audio_cap = FALSE;
caps = gst_pad_get_caps (GST_PAD (pads->data));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
if (strcmp (gst_structure_get_name (structure),
"audio/x-raw-int") == 0) {
diff --git a/gst-libs/gst/play/play.old.c b/gst-libs/gst/play/play.old.c
index dd787001b..513a3e12d 100644
--- a/gst-libs/gst/play/play.old.c
+++ b/gst-libs/gst/play/play.old.c
@@ -910,7 +910,7 @@ gst_play_get_sink_element (GstPlay * play,
gboolean has_video_cap = FALSE, has_audio_cap = FALSE;
const char *media_type;
- media_type = gst_structure_get_name (gst_caps2_get_nth_cap (
+ media_type = gst_structure_get_name (gst_caps_get_structure (
gst_pad_get_caps (GST_PAD (pads->data)), 0));
if (strcmp (media_type, "audio/x-raw-int") == 0)
{
diff --git a/gst-libs/gst/riff/riff-media.c b/gst-libs/gst/riff/riff-media.c
index 79db94202..7c200896c 100644
--- a/gst-libs/gst/riff/riff-media.c
+++ b/gst-libs/gst/riff/riff-media.c
@@ -26,17 +26,17 @@
#include "riff-ids.h"
#include "riff-media.h"
-GstCaps2 *
+GstCaps *
gst_riff_create_video_caps (guint32 codec_fcc,
gst_riff_strh *strh,
gst_riff_strf_vids *strf)
{
- GstCaps2 *caps = NULL;
+ GstCaps *caps = NULL;
switch (codec_fcc) {
case GST_MAKE_FOURCC('I','4','2','0'):
case GST_MAKE_FOURCC('Y','U','Y','2'):
- caps = gst_caps2_new_simple ("video/x-raw-yuv",
+ caps = gst_caps_new_simple ("video/x-raw-yuv",
"format", GST_TYPE_FOURCC, codec_fcc,
NULL);
break;
@@ -45,16 +45,16 @@ gst_riff_create_video_caps (guint32 codec_fcc,
case GST_MAKE_FOURCC('J','P','E','G'): /* generic (mostly RGB) MJPEG */
case GST_MAKE_FOURCC('P','I','X','L'): /* Miro/Pinnacle fourccs */
case GST_MAKE_FOURCC('V','I','X','L'): /* Miro/Pinnacle fourccs */
- caps = gst_caps2_new_simple ("video/x-jpeg", NULL);
+ caps = gst_caps_new_simple ("video/x-jpeg", NULL);
break;
case GST_MAKE_FOURCC('H','F','Y','U'):
- caps = gst_caps2_new_simple ( "video/x-huffyuv", NULL);
+ caps = gst_caps_new_simple ( "video/x-huffyuv", NULL);
break;
case GST_MAKE_FOURCC('M','P','E','G'):
case GST_MAKE_FOURCC('M','P','G','I'):
- caps = gst_caps2_new_simple ("video/mpeg",
+ caps = gst_caps_new_simple ("video/mpeg",
"systemstream", G_TYPE_BOOLEAN, FALSE,
"mpegversion", G_TYPE_BOOLEAN, 1,
NULL);
@@ -67,13 +67,13 @@ gst_riff_create_video_caps (guint32 codec_fcc,
case GST_MAKE_FOURCC('V','D','O','W'):
case GST_MAKE_FOURCC('V','I','V','O'):
case GST_MAKE_FOURCC('x','2','6','3'):
- caps = gst_caps2_new_simple ("video/x-h263", NULL);
+ caps = gst_caps_new_simple ("video/x-h263", NULL);
break;
case GST_MAKE_FOURCC('D','I','V','3'):
case GST_MAKE_FOURCC('D','I','V','4'):
case GST_MAKE_FOURCC('D','I','V','5'):
- caps = gst_caps2_new_simple ("video/x-divx",
+ caps = gst_caps_new_simple ("video/x-divx",
"divxversion", G_TYPE_INT, 3,
NULL);
break;
@@ -81,54 +81,54 @@ gst_riff_create_video_caps (guint32 codec_fcc,
case GST_MAKE_FOURCC('d','i','v','x'):
case GST_MAKE_FOURCC('D','I','V','X'):
case GST_MAKE_FOURCC('D','X','5','0'):
- caps = gst_caps2_new_simple ("video/x-divx",
+ caps = gst_caps_new_simple ("video/x-divx",
"divxversion", G_TYPE_INT, 5,
NULL);
break;
case GST_MAKE_FOURCC('X','V','I','D'):
case GST_MAKE_FOURCC('x','v','i','d'):
- caps = gst_caps2_new_simple ("video/x-xvid", NULL);
+ caps = gst_caps_new_simple ("video/x-xvid", NULL);
break;
case GST_MAKE_FOURCC('M','P','G','4'):
- caps = gst_caps2_new_simple ("video/x-msmpeg",
+ caps = gst_caps_new_simple ("video/x-msmpeg",
"msmpegversion", G_TYPE_INT, 41,
NULL);
break;
case GST_MAKE_FOURCC('M','P','4','2'):
- caps = gst_caps2_new_simple ("video/x-msmpeg",
+ caps = gst_caps_new_simple ("video/x-msmpeg",
"msmpegversion", G_TYPE_INT, 42,
NULL);
break;
case GST_MAKE_FOURCC('M','P','4','3'):
- caps = gst_caps2_new_simple ("video/x-msmpeg",
+ caps = gst_caps_new_simple ("video/x-msmpeg",
"msmpegversion", G_TYPE_INT, 43,
NULL);
break;
case GST_MAKE_FOURCC('3','I','V','1'):
case GST_MAKE_FOURCC('3','I','V','2'):
- caps = gst_caps2_new_simple ( "video/x-3ivx", NULL);
+ caps = gst_caps_new_simple ( "video/x-3ivx", NULL);
break;
case GST_MAKE_FOURCC('D','V','S','D'):
case GST_MAKE_FOURCC('d','v','s','d'):
- caps = gst_caps2_new_simple ("video/x-dv",
+ caps = gst_caps_new_simple ("video/x-dv",
"systemstream", G_TYPE_BOOLEAN, FALSE,
NULL);
break;
case GST_MAKE_FOURCC('W','M','V','1'):
- caps = gst_caps2_new_simple ("video/x-wmv",
+ caps = gst_caps_new_simple ("video/x-wmv",
"wmvversion", G_TYPE_INT, 1,
NULL);
break;
case GST_MAKE_FOURCC('W','M','V','2'):
- caps = gst_caps2_new_simple ("video/x-wmv",
+ caps = gst_caps_new_simple ("video/x-wmv",
"wmvversion", G_TYPE_INT, 2,
NULL);
break;
@@ -142,20 +142,20 @@ gst_riff_create_video_caps (guint32 codec_fcc,
if (strh != NULL) {
gfloat fps = 1. * strh->rate / strh->scale;
- gst_caps2_set_simple (caps, "framerate", G_TYPE_DOUBLE, fps, NULL);
+ gst_caps_set_simple (caps, "framerate", G_TYPE_DOUBLE, fps, NULL);
} else {
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"framerate", GST_TYPE_DOUBLE_RANGE, 0., G_MAXDOUBLE,
NULL);
}
if (strf != NULL) {
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"width", G_TYPE_INT, strf->width,
"height", G_TYPE_INT, strf->height,
NULL);
} else {
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"width", GST_TYPE_INT_RANGE, 16, 4096,
"height", GST_TYPE_INT_RANGE, 16, 4096,
NULL);
@@ -164,23 +164,23 @@ gst_riff_create_video_caps (guint32 codec_fcc,
return caps;
}
-GstCaps2 *
+GstCaps *
gst_riff_create_audio_caps (guint16 codec_id,
gst_riff_strh *strh,
gst_riff_strf_auds *strf)
{
- GstCaps2 *caps = NULL;
+ GstCaps *caps = NULL;
switch (codec_id) {
case GST_RIFF_WAVE_FORMAT_MPEGL3: /* mp3 */
- caps = gst_caps2_new_simple ("audio/mpeg",
+ caps = gst_caps_new_simple ("audio/mpeg",
"mpegversion", G_TYPE_INT, 1,
"layer", G_TYPE_INT, 3,
NULL);
break;
case GST_RIFF_WAVE_FORMAT_MPEGL12: /* mp1 or mp2 */
- caps = gst_caps2_new_simple ("audio/mpeg",
+ caps = gst_caps_new_simple ("audio/mpeg",
"layer", G_TYPE_INT, 2,
NULL);
break;
@@ -191,14 +191,14 @@ gst_riff_create_audio_caps (guint16 codec_id,
gint ch = GUINT16_FROM_LE (strf->channels);
gint ws = GUINT16_FROM_LE (strf->size);
- caps = gst_caps2_new_simple ("audio/x-raw-int",
+ caps = gst_caps_new_simple ("audio/x-raw-int",
"endianness", G_TYPE_INT, G_LITTLE_ENDIAN,
"width", G_TYPE_INT, (int)(ba * 8 / ch),
"depth", G_TYPE_INT, ws,
"signed", G_TYPE_BOOLEAN, ws != 8,
NULL);
} else {
- caps = gst_caps2_from_string ("audio/x-raw-int, "
+ caps = gst_caps_from_string ("audio/x-raw-int, "
"endianness = (int) LITTLE_ENDIAN, "
"signed = (boolean) { true, false }, "
"width = (int) { 8, 16 }, "
@@ -211,7 +211,7 @@ gst_riff_create_audio_caps (guint16 codec_id,
GST_WARNING ("invalid depth (%d) of mulaw audio, overwriting.",
strf->size);
}
- caps = gst_caps2_new_simple ("audio/x-mulaw", NULL);
+ caps = gst_caps_new_simple ("audio/x-mulaw", NULL);
break;
case GST_RIFF_WAVE_FORMAT_ALAW:
@@ -219,7 +219,7 @@ gst_riff_create_audio_caps (guint16 codec_id,
GST_WARNING ("invalid depth (%d) of alaw audio, overwriting.",
strf->size);
}
- caps = gst_caps2_new_simple ("audio/x-alaw", NULL);
+ caps = gst_caps_new_simple ("audio/x-alaw", NULL);
break;
case GST_RIFF_WAVE_FORMAT_VORBIS1: /* ogg/vorbis mode 1 */
@@ -228,11 +228,11 @@ gst_riff_create_audio_caps (guint16 codec_id,
case GST_RIFF_WAVE_FORMAT_VORBIS1PLUS: /* ogg/vorbis mode 1+ */
case GST_RIFF_WAVE_FORMAT_VORBIS2PLUS: /* ogg/vorbis mode 2+ */
case GST_RIFF_WAVE_FORMAT_VORBIS3PLUS: /* ogg/vorbis mode 3+ */
- caps = gst_caps2_new_simple ("audio/x-vorbis", NULL);
+ caps = gst_caps_new_simple ("audio/x-vorbis", NULL);
break;
case GST_RIFF_WAVE_FORMAT_A52:
- caps = gst_caps2_new_simple ("audio/x-ac3", NULL);
+ caps = gst_caps_new_simple ("audio/x-ac3", NULL);
break;
default:
@@ -242,12 +242,12 @@ gst_riff_create_audio_caps (guint16 codec_id,
}
if (strf != NULL) {
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"rate", G_TYPE_INT, strf->rate,
"channels", G_TYPE_INT, strf->channels,
NULL);
} else {
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"rate", GST_TYPE_INT_RANGE, 8000, 96000,
"channels", GST_TYPE_INT_RANGE, 1, 2,
NULL);
@@ -256,18 +256,18 @@ gst_riff_create_audio_caps (guint16 codec_id,
return caps;
}
-GstCaps2 *
+GstCaps *
gst_riff_create_iavs_caps (guint32 codec_fcc,
gst_riff_strh *strh,
gst_riff_strf_iavs *strf)
{
- GstCaps2 *caps = NULL;
+ GstCaps *caps = NULL;
switch (codec_fcc) {
/* is this correct? */
case GST_MAKE_FOURCC ('D','V','S','D'):
case GST_MAKE_FOURCC ('d','v','s','d'):
- caps = gst_caps2_new_simple ("video/x-dv",
+ caps = gst_caps_new_simple ("video/x-dv",
"systemstream", G_TYPE_BOOLEAN, TRUE, NULL);
default:
@@ -283,7 +283,7 @@ gst_riff_create_iavs_caps (guint32 codec_fcc,
* Functions below are for template caps. All is variable.
*/
-GstCaps2 *
+GstCaps *
gst_riff_create_video_template_caps (void)
{
guint32 tags[] = {
@@ -307,19 +307,19 @@ gst_riff_create_video_template_caps (void)
0
};
guint i;
- GstCaps2 *caps, *one;
+ GstCaps *caps, *one;
- caps = gst_caps2_new_empty ();
+ caps = gst_caps_new_empty ();
for (i = 0; tags[i] != 0; i++) {
one = gst_riff_create_video_caps (tags[i], NULL, NULL);
if (one)
- gst_caps2_append (caps, one);
+ gst_caps_append (caps, one);
}
return caps;
}
-GstCaps2 *
+GstCaps *
gst_riff_create_audio_template_caps (void)
{
guint16 tags[] = {
@@ -334,19 +334,19 @@ gst_riff_create_audio_template_caps (void)
0
};
guint i;
- GstCaps2 *caps, *one;
+ GstCaps *caps, *one;
- caps = gst_caps2_new_empty ();
+ caps = gst_caps_new_empty ();
for (i = 0; tags[i] != 0; i++) {
one = gst_riff_create_audio_caps (tags[i], NULL, NULL);
if (one)
- gst_caps2_append (caps, one);
+ gst_caps_append (caps, one);
}
return caps;
}
-GstCaps2 *
+GstCaps *
gst_riff_create_iavs_template_caps (void)
{
guint32 tags[] = {
@@ -355,13 +355,13 @@ gst_riff_create_iavs_template_caps (void)
0
};
guint i;
- GstCaps2 *caps, *one;
+ GstCaps *caps, *one;
- caps = gst_caps2_new_empty ();
+ caps = gst_caps_new_empty ();
for (i = 0; tags[i] != 0; i++) {
one = gst_riff_create_iavs_caps (tags[i], NULL, NULL);
if (one)
- gst_caps2_append (caps, one);
+ gst_caps_append (caps, one);
}
return caps;
diff --git a/gst-libs/gst/riff/riff-media.h b/gst-libs/gst/riff/riff-media.h
index 1607fc3a3..256ed9479 100644
--- a/gst-libs/gst/riff/riff-media.h
+++ b/gst-libs/gst/riff/riff-media.h
@@ -32,13 +32,13 @@ G_BEGIN_DECLS
* Create one caps. strh/strf can be NULL (for non-fixed caps).
*/
-GstCaps2 *gst_riff_create_video_caps (guint32 codec_fcc,
+GstCaps *gst_riff_create_video_caps (guint32 codec_fcc,
gst_riff_strh *strh,
gst_riff_strf_vids *strf);
-GstCaps2 *gst_riff_create_audio_caps (guint16 codec_id,
+GstCaps *gst_riff_create_audio_caps (guint16 codec_id,
gst_riff_strh *strh,
gst_riff_strf_auds *strf);
-GstCaps2 *gst_riff_create_iavs_caps (guint32 codec_fcc,
+GstCaps *gst_riff_create_iavs_caps (guint32 codec_fcc,
gst_riff_strh *strh,
gst_riff_strf_iavs *strf);
@@ -46,9 +46,9 @@ GstCaps2 *gst_riff_create_iavs_caps (guint32 codec_fcc,
* Create template caps (includes all known types).
*/
-GstCaps2 *gst_riff_create_video_template_caps (void);
-GstCaps2 *gst_riff_create_audio_template_caps (void);
-GstCaps2 *gst_riff_create_iavs_template_caps (void);
+GstCaps *gst_riff_create_video_template_caps (void);
+GstCaps *gst_riff_create_audio_template_caps (void);
+GstCaps *gst_riff_create_iavs_template_caps (void);
G_END_DECLS
diff --git a/gst-libs/gst/riff/riff-read.c b/gst-libs/gst/riff/riff-read.c
index 17daf0241..815b3a7b6 100644
--- a/gst-libs/gst/riff/riff-read.c
+++ b/gst-libs/gst/riff/riff-read.c
@@ -80,7 +80,7 @@ gst_riff_read_class_init (GstRiffReadClass *klass)
g_object_class_install_property (gobject_class, ARG_METADATA,
g_param_spec_boxed ("metadata", "Metadata", "Metadata",
- GST_TYPE_CAPS2, G_PARAM_READABLE));
+ GST_TYPE_CAPS, G_PARAM_READABLE));
parent_class = g_type_class_ref (GST_TYPE_ELEMENT);
@@ -128,7 +128,7 @@ gst_riff_read_change_state (GstElement *element)
riff->bs = gst_bytestream_new (riff->sinkpad);
break;
case GST_STATE_PAUSED_TO_READY:
- gst_caps2_replace (&riff->metadata, NULL);
+ gst_caps_replace (&riff->metadata, NULL);
gst_bytestream_destroy (riff->bs);
while (riff->level) {
GstRiffLevel *level = riff->level->data;
@@ -714,7 +714,7 @@ gst_riff_read_info (GstRiffRead *riff)
GstRiffLevel *level;
GList *last;
gchar *name, *type;
- GstCaps2 *caps;
+ GstCaps *caps;
/* What we're doing here is ugly (oh no!); we look
* at our LIST tag size and assure that we do not
@@ -726,7 +726,7 @@ gst_riff_read_info (GstRiffRead *riff)
end = level->start + level->length;
g_free (level);
- caps = gst_caps2_new_simple ("application/x-gst-metadata", NULL);
+ caps = gst_caps_new_simple ("application/x-gst-metadata", NULL);
while (gst_bytestream_tell (riff->bs) < end) {
if (!gst_riff_peek_head (riff, &tag, NULL, NULL)) {
@@ -816,14 +816,14 @@ gst_riff_read_info (GstRiffRead *riff)
return FALSE;
}
- gst_caps2_set_simple (caps, type, G_TYPE_STRING, name, NULL);
+ gst_caps_set_simple (caps, type, G_TYPE_STRING, name, NULL);
} else {
gst_riff_read_skip (riff);
}
}
/* let the world know about this wonderful thing */
- gst_caps2_replace (&riff->metadata, caps);
+ gst_caps_replace (&riff->metadata, caps);
g_object_notify (G_OBJECT (riff), "metadata");
return TRUE;
diff --git a/gst-libs/gst/riff/riff-read.h b/gst-libs/gst/riff/riff-read.h
index cf8c379bc..a0f92e3e0 100644
--- a/gst-libs/gst/riff/riff-read.h
+++ b/gst-libs/gst/riff/riff-read.h
@@ -55,7 +55,7 @@ typedef struct _GstRiffRead {
GList *level;
/* metadata */
- GstCaps2 *metadata;
+ GstCaps *metadata;
} GstRiffRead;
typedef struct _GstRiffReadClass {
diff --git a/gst-libs/gst/video/video.c b/gst-libs/gst/video/video.c
index 2fc54003a..6d804a4d4 100644
--- a/gst-libs/gst/video/video.c
+++ b/gst-libs/gst/video/video.c
@@ -30,7 +30,7 @@ gdouble
gst_video_frame_rate (GstPad *pad)
{
gdouble fps = 0.;
- GstCaps2 *caps;
+ GstCaps *caps;
GstStructure *structure;
/* get pad caps */
@@ -42,7 +42,7 @@ gst_video_frame_rate (GstPad *pad)
return 0.;
}
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
if (!gst_structure_get_double (structure, "framerate", &fps)){
g_warning ("gstvideo: failed to get framerate property of pad %s:%s",
GST_ELEMENT_NAME (gst_pad_get_parent (pad)),
@@ -62,7 +62,7 @@ gst_video_get_size (GstPad *pad,
gint *width,
gint *height)
{
- GstCaps2 *caps;
+ GstCaps *caps;
GstStructure *structure;
gboolean ret;
@@ -79,7 +79,7 @@ gst_video_get_size (GstPad *pad,
return FALSE;
}
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
ret = gst_structure_get_int (structure, "width", width);
ret &= gst_structure_get_int (structure, "height", height);
diff --git a/gst/chart/gstchart.c b/gst/chart/gstchart.c
index 8bdb8d2a8..329b672ea 100644
--- a/gst/chart/gstchart.c
+++ b/gst/chart/gstchart.c
@@ -112,9 +112,9 @@ static void gst_chart_get_property (GObject *object, guint prop_id, GValue *valu
static void gst_chart_chain (GstPad *pad, GstData *_data);
static GstPadLinkReturn
- gst_chart_sinkconnect (GstPad *pad, const GstCaps2 *caps);
+ gst_chart_sinkconnect (GstPad *pad, const GstCaps *caps);
static GstPadLinkReturn
- gst_chart_srcconnect (GstPad *pad, const GstCaps2 *caps);
+ gst_chart_srcconnect (GstPad *pad, const GstCaps *caps);
static GstElementClass *parent_class = NULL;
@@ -197,14 +197,14 @@ gst_chart_init (GstChart *chart)
}
static GstPadLinkReturn
-gst_chart_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_chart_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstChart *chart;
GstStructure *structure;
chart = GST_CHART (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "rate", &chart->samplerate);
chart->samples_between_frames = chart->samplerate / chart->framerate;
@@ -217,14 +217,14 @@ gst_chart_sinkconnect (GstPad *pad, const GstCaps2 *caps)
}
static GstPadLinkReturn
-gst_chart_srcconnect (GstPad *pad, const GstCaps2*caps)
+gst_chart_srcconnect (GstPad *pad, const GstCaps*caps)
{
GstChart *chart;
GstStructure *structure;
chart = GST_CHART (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
if (gst_structure_get_double (structure, "framerate", &chart->framerate)) {
chart->samples_between_frames = chart->samplerate / chart->framerate;
diff --git a/gst/deinterlace/gstdeinterlace.c b/gst/deinterlace/gstdeinterlace.c
index 2a73ab01e..7b2c3ee37 100644
--- a/gst/deinterlace/gstdeinterlace.c
+++ b/gst/deinterlace/gstdeinterlace.c
@@ -145,14 +145,14 @@ gst_deinterlace_class_init (GstDeInterlaceClass *klass)
}
static GstPadLinkReturn
-gst_deinterlace_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_deinterlace_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstDeInterlace *filter;
GstStructure *structure;
filter = GST_DEINTERLACE(gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &filter->width);
gst_structure_get_int (structure, "height", &filter->height);
diff --git a/gst/filter/gstbpwsinc.c b/gst/filter/gstbpwsinc.c
index d9d608d71..775290530 100644
--- a/gst/filter/gstbpwsinc.c
+++ b/gst/filter/gstbpwsinc.c
@@ -105,7 +105,7 @@ static void gst_bpwsinc_get_property (GObject * object, guint prop_id,
static void gst_bpwsinc_chain (GstPad * pad, GstData *_data);
static GstPadLinkReturn
- gst_bpwsinc_sink_connect (GstPad * pad, const GstCaps2 * caps);
+ gst_bpwsinc_sink_connect (GstPad * pad, const GstCaps * caps);
static GstElementClass *parent_class = NULL;
/*static guint gst_bpwsinc_signals[LAST_SIGNAL] = { 0 }; */
@@ -195,7 +195,7 @@ gst_bpwsinc_init (GstBPWSinc * filter)
}
static GstPadLinkReturn
-gst_bpwsinc_sink_connect (GstPad * pad, const GstCaps2 * caps)
+gst_bpwsinc_sink_connect (GstPad * pad, const GstCaps * caps)
{
int i = 0;
double sum = 0.0;
diff --git a/gst/filter/gstiir.c b/gst/filter/gstiir.c
index 60c5c6372..4ccf9f094 100644
--- a/gst/filter/gstiir.c
+++ b/gst/filter/gstiir.c
@@ -89,7 +89,7 @@ static void gst_iir_get_property (GObject * object, guint prop_id,
static void gst_iir_chain (GstPad * pad, GstData *_data);
static GstPadLinkReturn
- gst_iir_sink_connect (GstPad * pad, const GstCaps2 * caps);
+ gst_iir_sink_connect (GstPad * pad, const GstCaps * caps);
static GstElementClass *parent_class = NULL;
/*static guint gst_iir_signals[LAST_SIGNAL] = { 0 }; */
@@ -181,7 +181,7 @@ gst_iir_init (GstIIR * filter)
}
static GstPadLinkReturn
-gst_iir_sink_connect (GstPad * pad, const GstCaps2 * caps)
+gst_iir_sink_connect (GstPad * pad, const GstCaps * caps)
{
GstIIR *filter;
GstPadLinkReturn set_retval;
diff --git a/gst/filter/gstlpwsinc.c b/gst/filter/gstlpwsinc.c
index d549db525..603d8775e 100644
--- a/gst/filter/gstlpwsinc.c
+++ b/gst/filter/gstlpwsinc.c
@@ -102,7 +102,7 @@ static void gst_lpwsinc_get_property (GObject * object, guint prop_id,
static void gst_lpwsinc_chain (GstPad * pad, GstData *_data);
static GstPadLinkReturn
- gst_lpwsinc_sink_connect (GstPad * pad, const GstCaps2 * caps);
+ gst_lpwsinc_sink_connect (GstPad * pad, const GstCaps * caps);
static GstElementClass *parent_class = NULL;
/*static guint gst_lpwsinc_signals[LAST_SIGNAL] = { 0 }; */
@@ -186,7 +186,7 @@ gst_lpwsinc_init (GstLPWSinc * filter)
}
static GstPadLinkReturn
-gst_lpwsinc_sink_connect (GstPad * pad, const GstCaps2 * caps)
+gst_lpwsinc_sink_connect (GstPad * pad, const GstCaps * caps)
{
int i = 0;
double sum = 0.0;
diff --git a/gst/flx/gstflxdec.c b/gst/flx/gstflxdec.c
index 3fb0598c8..ca8933944 100644
--- a/gst/flx/gstflxdec.c
+++ b/gst/flx/gstflxdec.c
@@ -430,7 +430,7 @@ gst_flxdec_loop (GstElement *element)
GstBuffer *buf;
GstBuffer *databuf;
guchar *data, *chunk;
- GstCaps2 *caps;
+ GstCaps *caps;
GstFlxDec *flxdec;
FlxHeader *flxh;
@@ -484,8 +484,8 @@ gst_flxdec_loop (GstElement *element)
flxdec->frame_time = flxh->speed * GST_MSECOND;
}
- caps = gst_caps2_from_string (GST_VIDEO_RGB_PAD_TEMPLATE_CAPS_32);
- gst_caps2_set_simple (caps,
+ caps = gst_caps_from_string (GST_VIDEO_RGB_PAD_TEMPLATE_CAPS_32);
+ gst_caps_set_simple (caps,
"width", G_TYPE_INT, flxh->width,
"height", G_TYPE_INT, flxh->height,
"framerate", G_TYPE_DOUBLE, GST_SECOND/flxdec->frame_time, NULL);
diff --git a/gst/mixmatrix/mixmatrix.c b/gst/mixmatrix/mixmatrix.c
index 726f9e020..0551cac02 100644
--- a/gst/mixmatrix/mixmatrix.c
+++ b/gst/mixmatrix/mixmatrix.c
@@ -43,7 +43,7 @@ typedef struct _GstMixMatrixClass GstMixMatrixClass;
struct _GstMixMatrix {
GstElement element;
- GstCaps2 *caps;
+ GstCaps *caps;
gint samplerate;
gint grpsize;
@@ -112,7 +112,7 @@ static void gst_mixmatrix_set_property (GObject *object, guint prop_id, const GV
static void gst_mixmatrix_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
static GstPad * gst_mixmatrix_request_new_pad (GstElement *element, GstPadTemplate *temp, const gchar *name);
-static GstPadLinkReturn gst_mixmatrix_connect (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn gst_mixmatrix_connect (GstPad *pad, const GstCaps *caps);
static void gst_mixmatrix_loop (GstElement *element);
@@ -319,7 +319,7 @@ gst_mixmatrix_set_all_caps (GstMixMatrix *mix)
*/
static GstPadLinkReturn
-gst_mixmatrix_connect (GstPad *pad, const GstCaps2 *caps)
+gst_mixmatrix_connect (GstPad *pad, const GstCaps *caps)
{
GstMixMatrix *mix = GST_MIXMATRIX(GST_PAD_PARENT(pad));
gint i;
@@ -334,7 +334,7 @@ gst_mixmatrix_connect (GstPad *pad, const GstCaps2 *caps)
}
}
- mix->caps = gst_caps2_copy(caps);
+ mix->caps = gst_caps_copy(caps);
return GST_PAD_LINK_OK;
}
diff --git a/gst/modplug/gstmodplug.cc b/gst/modplug/gstmodplug.cc
index 75acae236..ab603cd3a 100644
--- a/gst/modplug/gstmodplug.cc
+++ b/gst/modplug/gstmodplug.cc
@@ -103,7 +103,7 @@ static void gst_modplug_get_property (GObject *object,
GValue *value,
GParamSpec *pspec );
static GstPadLinkReturn
- gst_modplug_srclink (GstPad *pad, const GstCaps2 *caps);
+ gst_modplug_srclink (GstPad *pad, const GstCaps *caps);
static void gst_modplug_loop (GstElement *element);
static void gst_modplug_setup (GstModPlug *modplug);
static const GstFormat *
@@ -380,17 +380,17 @@ gst_modplug_src_event (GstPad *pad, GstEvent *event)
}
#if 0
-static GstCaps2*
+static GstCaps*
gst_modplug_get_streaminfo (GstModPlug *modplug)
{
- GstCaps2 *caps;
+ GstCaps *caps;
props = gst_props_empty_new ();
entry = gst_props_entry_new ("Patterns", G_TYPE_INT ((gint)modplug->mSoundFile->GetNumPatterns()));
gst_props_add_entry (props, (GstPropsEntry *) entry);
- caps = gst_caps2_new_simple ("application/x-gst-streaminfo", NULL);
+ caps = gst_caps_new_simple ("application/x-gst-streaminfo", NULL);
return caps;
}
@@ -419,7 +419,7 @@ gst_modplug_update_metadata (GstModPlug *modplug)
entry = gst_props_entry_new ("Title", G_TYPE_STRING (title));
gst_props_add_entry (props, entry);
- modplug->metadata = gst_caps2_new_simple ("application/x-gst-metadata",
+ modplug->metadata = gst_caps_new_simple ("application/x-gst-metadata",
NULL);
g_object_notify (G_OBJECT (modplug), "metadata");
@@ -446,7 +446,7 @@ modplug_negotiate (GstModPlug *modplug)
}
if ((ret = gst_pad_try_set_caps (modplug->srcpad,
- gst_caps2_new_simple ("audio/x-raw-int",
+ gst_caps_new_simple ("audio/x-raw-int",
"endianness", G_TYPE_INT, G_BYTE_ORDER,
"signed", G_TYPE_BOOLEAN, sign,
"width", G_TYPE_INT, modplug->bitsPerSample,
@@ -464,7 +464,7 @@ modplug_negotiate (GstModPlug *modplug)
static GstPadLinkReturn
-gst_modplug_srclink (GstPad *pad, const GstCaps2 *caps)
+gst_modplug_srclink (GstPad *pad, const GstCaps *caps)
{
GstModPlug *modplug;
GstStructure *structure;
@@ -472,7 +472,7 @@ gst_modplug_srclink (GstPad *pad, const GstCaps2 *caps)
modplug = GST_MODPLUG (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "depth", &depth);
modplug->_16bit = (depth == 16);
diff --git a/gst/mpeg1videoparse/gstmp1videoparse.c b/gst/mpeg1videoparse/gstmp1videoparse.c
index 51a29a4e5..1cdefbb1e 100644
--- a/gst/mpeg1videoparse/gstmp1videoparse.c
+++ b/gst/mpeg1videoparse/gstmp1videoparse.c
@@ -187,7 +187,7 @@ mp1videoparse_parse_seq (Mp1VideoParse *mp1videoparse, GstBuffer *buf)
fps_table[fps_idx] != mp1videoparse->fps ||
width != mp1videoparse->width ||
height != mp1videoparse->height) {
- GstCaps2 *caps;
+ GstCaps *caps;
gint p_w, p_h;
mp1videoparse->asr = asr_table[asr_idx];
@@ -198,7 +198,7 @@ mp1videoparse_parse_seq (Mp1VideoParse *mp1videoparse, GstBuffer *buf)
p_w = (asr_table[asr_idx] < 1.0) ? (100 / asr_table[asr_idx]) : 1;
p_h = (asr_table[asr_idx] > 1.0) ? (100 * asr_table[asr_idx]) : 1;
- caps = gst_caps2_new_simple ("video/mpeg",
+ caps = gst_caps_new_simple ("video/mpeg",
"systemstream", G_TYPE_BOOLEAN, FALSE,
"mpegversion", G_TYPE_INT, 1,
"width", G_TYPE_INT, width,
diff --git a/gst/mpegaudioparse/gstmpegaudioparse.c b/gst/mpegaudioparse/gstmpegaudioparse.c
index cc56bb013..e06919160 100644
--- a/gst/mpegaudioparse/gstmpegaudioparse.c
+++ b/gst/mpegaudioparse/gstmpegaudioparse.c
@@ -219,18 +219,18 @@ mp3_type_frame_length_from_header (guint32 header, guint *put_layer,
#define GST_MP3_TYPEFIND_MIN_HEADERS 3
#define GST_MP3_TYPEFIND_MIN_DATA (1440 * (GST_MP3_TYPEFIND_MIN_HEADERS + 1) - 1 + 3)
-static GstCaps2 *
+static GstCaps *
mp3_caps_create (guint layer, guint channels,
guint bitrate, guint samplerate)
{
- GstCaps2 *new;
+ GstCaps *new;
g_assert (layer);
g_assert (samplerate);
g_assert (bitrate);
g_assert (channels);
- new = gst_caps2_new_simple ("audio/mpeg",
+ new = gst_caps_new_simple ("audio/mpeg",
"mpegversion", G_TYPE_INT, 1,
"layer", G_TYPE_INT, layer,
"rate", G_TYPE_INT, samplerate,
@@ -461,7 +461,7 @@ bpf_from_header (GstMPEGAudioParse *parse, unsigned long header)
rate != parse->rate ||
layer != parse->layer ||
bitrate != parse->bit_rate) {
- GstCaps2 *caps = mp3_caps_create (layer, channels, bitrate, rate);
+ GstCaps *caps = mp3_caps_create (layer, channels, bitrate, rate);
if (gst_pad_try_set_caps(parse->srcpad, caps) <= 0) {
gst_element_error (GST_ELEMENT (parse),
diff --git a/gst/overlay/gstoverlay.c b/gst/overlay/gstoverlay.c
index a027ab89b..f2c01b3f8 100644
--- a/gst/overlay/gstoverlay.c
+++ b/gst/overlay/gstoverlay.c
@@ -144,9 +144,9 @@ gst_overlay_class_init (GstOverlayClass *klass)
}
#if 0
-static GstCaps2 *gst_overlay_getcaps(GstPad *pad)
+static GstCaps *gst_overlay_getcaps(GstPad *pad)
{
- GstCaps2 *caps;
+ GstCaps *caps;
GstOverlay *overlay;
overlay = GST_OVERLAY (gst_pad_get_parent (pad));
@@ -174,14 +174,14 @@ static GstCaps2 *gst_overlay_getcaps(GstPad *pad)
#endif
static gboolean
-gst_overlay_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_overlay_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstOverlay *overlay;
GstStructure *structure;
overlay = GST_OVERLAY (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &overlay->width);
gst_structure_get_int (structure, "height", &overlay->height);
diff --git a/gst/passthrough/gstpassthrough.c b/gst/passthrough/gstpassthrough.c
index 2bcb5d0ec..5bf97f161 100644
--- a/gst/passthrough/gstpassthrough.c
+++ b/gst/passthrough/gstpassthrough.c
@@ -79,7 +79,7 @@ static void passthrough_init (GstPassthrough *filter);
static void passthrough_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
static void passthrough_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
-static GstPadLinkReturn passthrough_connect_sink (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn passthrough_connect_sink (GstPad *pad, const GstCaps *caps);
static void passthrough_chain (GstPad *pad, GstData *_data);
static void inline passthrough_fast_float_chain (gfloat* data, guint numsamples);
@@ -89,7 +89,7 @@ static void inline passthrough_fast_8bit_chain (gint8* data, guint numsamples);
static GstElementClass *parent_class = NULL;
static GstPadLinkReturn
-passthrough_connect_sink (GstPad *pad, const GstCaps2 *caps)
+passthrough_connect_sink (GstPad *pad, const GstCaps *caps)
{
const gchar *mimetype;
GstPassthrough *filter;
@@ -102,7 +102,7 @@ passthrough_connect_sink (GstPad *pad, const GstCaps2 *caps)
g_return_val_if_fail (filter != NULL, GST_PAD_LINK_REFUSED);
g_return_val_if_fail (GST_IS_PASSTHROUGH (filter), GST_PAD_LINK_REFUSED);
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
mimetype = gst_structure_get_name (structure);
gst_structure_get_int (structure, "rate", &filter->rate);
diff --git a/gst/playondemand/gstplayondemand.c b/gst/playondemand/gstplayondemand.c
index 0dec38355..3313599ca 100644
--- a/gst/playondemand/gstplayondemand.c
+++ b/gst/playondemand/gstplayondemand.c
@@ -81,7 +81,7 @@ static void play_on_demand_get_property (GObject *object, guint prop_id, GValue
static void play_on_demand_dispose (GObject *object);
/* GStreamer functionality */
-static GstPadLinkReturn play_on_demand_pad_link (GstPad *pad, const GstCaps2 *caps);
+static GstPadLinkReturn play_on_demand_pad_link (GstPad *pad, const GstCaps *caps);
static void play_on_demand_loop (GstElement *elem);
static void play_on_demand_set_clock (GstElement *elem, GstClock *clock);
@@ -365,7 +365,7 @@ play_on_demand_dispose (GObject *object)
}
static GstPadLinkReturn
-play_on_demand_pad_link (GstPad *pad, const GstCaps2 *caps)
+play_on_demand_pad_link (GstPad *pad, const GstCaps *caps)
{
const gchar *mimetype;
GstPlayOnDemand *filter;
@@ -376,7 +376,7 @@ play_on_demand_pad_link (GstPad *pad, const GstCaps2 *caps)
filter = GST_PLAYONDEMAND(GST_PAD_PARENT(pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
mimetype = gst_structure_get_name (structure);
gst_structure_get_int (structure, "rate", &filter->rate);
diff --git a/gst/qtdemux/qtdemux.c b/gst/qtdemux/qtdemux.c
index 2bbe5819c..78ac6cd31 100644
--- a/gst/qtdemux/qtdemux.c
+++ b/gst/qtdemux/qtdemux.c
@@ -64,7 +64,7 @@ struct _QtDemuxSample {
struct _QtDemuxStream {
guint32 subtype;
- GstCaps2 *caps;
+ GstCaps *caps;
GstPad *pad;
int n_samples;
QtDemuxSample *samples;
@@ -114,7 +114,7 @@ GST_STATIC_PAD_TEMPLATE (
"sink",
GST_PAD_SINK,
GST_PAD_SOMETIMES,
- GST_STATIC_CAPS2_ANY
+ GST_STATIC_CAPS_ANY
);
static GstStaticPadTemplate gst_qtdemux_videosrc_template =
@@ -122,7 +122,7 @@ GST_STATIC_PAD_TEMPLATE (
"audio_%02d",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
- GST_STATIC_CAPS2_ANY
+ GST_STATIC_CAPS_ANY
);
static GstStaticPadTemplate gst_qtdemux_audiosrc_template =
@@ -130,7 +130,7 @@ GST_STATIC_PAD_TEMPLATE (
"video_%02d",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
- GST_STATIC_CAPS2_ANY
+ GST_STATIC_CAPS_ANY
);
static GstElementClass *parent_class = NULL;
@@ -147,8 +147,8 @@ static void qtdemux_parse(GstQTDemux *qtdemux, GNode *node, void *buffer, int le
static QtNodeType *qtdemux_type_get(guint32 fourcc);
static void qtdemux_node_dump(GstQTDemux *qtdemux, GNode *node);
static void qtdemux_parse_tree(GstQTDemux *qtdemux);
-static GstCaps2 *qtdemux_video_caps(GstQTDemux *qtdemux, guint32 fourcc);
-static GstCaps2 *qtdemux_audio_caps(GstQTDemux *qtdemux, guint32 fourcc);
+static GstCaps *qtdemux_video_caps(GstQTDemux *qtdemux, guint32 fourcc);
+static GstCaps *qtdemux_audio_caps(GstQTDemux *qtdemux, guint32 fourcc);
static GType gst_qtdemux_get_type (void)
{
@@ -208,7 +208,7 @@ static gboolean
plugin_init (GstPlugin *plugin)
{
#if 0
- GstCaps2 *audiocaps = NULL, *videocaps = NULL, *temp;
+ GstCaps *audiocaps = NULL, *videocaps = NULL, *temp;
const guint32 audio_fcc[] = {
/* FILLME */
0,
@@ -496,7 +496,7 @@ static void gst_qtdemux_loop_header (GstElement *element)
if(stream->subtype == GST_MAKE_FOURCC('v','i','d','e')){
float fps = 1. * GST_SECOND / stream->samples[stream->sample_index].duration;
if (fps != stream->fps) {
- gst_caps2_set_simple (stream->caps, "framerate", G_TYPE_DOUBLE, fps,
+ gst_caps_set_simple (stream->caps, "framerate", G_TYPE_DOUBLE, fps,
NULL);
stream->fps = fps;
gst_pad_try_set_caps(stream->pad, stream->caps);
@@ -517,7 +517,7 @@ static void gst_qtdemux_loop_header (GstElement *element)
}
-static GstCaps2 *gst_qtdemux_src_getcaps(GstPad *pad)
+static GstCaps *gst_qtdemux_src_getcaps(GstPad *pad)
{
GstQTDemux *qtdemux;
QtDemuxStream *stream;
@@ -529,13 +529,13 @@ static GstCaps2 *gst_qtdemux_src_getcaps(GstPad *pad)
g_return_val_if_fail(GST_IS_QTDEMUX(qtdemux), NULL);
stream = GST_PAD_ELEMENT_PRIVATE (pad);
- return gst_caps2_copy(stream->caps);
+ return gst_caps_copy(stream->caps);
}
#if 0
/* This function doesn't do anything useful, but might be useful later */
static GstPadLinkReturn
-gst_qtdemux_src_link(GstPad *pad, GstCaps2 *caps)
+gst_qtdemux_src_link(GstPad *pad, GstCaps *caps)
{
GstQTDemux *qtdemux;
QtDemuxStream *stream;
@@ -571,7 +571,7 @@ void gst_qtdemux_add_stream(GstQTDemux *qtdemux, QtDemuxStream *stream)
g_strdup_printf ("video_%02d", qtdemux->n_video_streams));
stream->fps = 1. * GST_SECOND / stream->samples[0].duration;
if(stream->caps){
- gst_caps2_set_simple(stream->caps,
+ gst_caps_set_simple(stream->caps,
"width", G_TYPE_INT, stream->width,
"height", G_TYPE_INT, stream->height,
"framerate", G_TYPE_DOUBLE, stream->fps, NULL);
@@ -582,7 +582,7 @@ void gst_qtdemux_add_stream(GstQTDemux *qtdemux, QtDemuxStream *stream)
gst_static_pad_template_get(&gst_qtdemux_audiosrc_template),
g_strdup_printf ("audio_%02d", qtdemux->n_audio_streams));
if(stream->caps){
- gst_caps2_set_simple(stream->caps,
+ gst_caps_set_simple(stream->caps,
"rate", G_TYPE_INT, (int)stream->rate,
"channels", G_TYPE_INT, stream->n_channels, NULL);
}
@@ -1324,7 +1324,7 @@ static void qtdemux_parse_trak(GstQTDemux *qtdemux, GNode *trak)
stream->caps = qtdemux_video_caps(qtdemux,
QTDEMUX_FOURCC_GET(stsd->data+offset+4));
- g_print("caps %s\n",gst_caps2_to_string(stream->caps));
+ g_print("caps %s\n",gst_caps_to_string(stream->caps));
}else if(stream->subtype == FOURCC_soun){
int version;
@@ -1352,7 +1352,7 @@ static void qtdemux_parse_trak(GstQTDemux *qtdemux, GNode *trak)
stream->caps = qtdemux_audio_caps(qtdemux,
QTDEMUX_FOURCC_GET(stsd->data+16+4));
- g_print("caps %s\n",gst_caps2_to_string(stream->caps));
+ g_print("caps %s\n",gst_caps_to_string(stream->caps));
}else{
g_print("unknown subtype\n");
return;
@@ -1518,28 +1518,28 @@ done2:
}
-static GstCaps2 *qtdemux_video_caps(GstQTDemux *qtdemux, guint32 fourcc)
+static GstCaps *qtdemux_video_caps(GstQTDemux *qtdemux, guint32 fourcc)
{
switch(fourcc){
case GST_MAKE_FOURCC('j','p','e','g'):
/* JPEG */
- return gst_caps2_from_string ("image/jpeg");
+ return gst_caps_from_string ("image/jpeg");
case GST_MAKE_FOURCC('m','j','p','a'):
/* Motion-JPEG (format A) */
- return gst_caps2_from_string ("image/jpeg");
+ return gst_caps_from_string ("image/jpeg");
case GST_MAKE_FOURCC('m','j','p','b'):
/* Motion-JPEG (format B) */
- return gst_caps2_from_string ("image/jpeg");
+ return gst_caps_from_string ("image/jpeg");
case GST_MAKE_FOURCC('S','V','Q','3'):
- return gst_caps2_from_string ("video/x-svq, "
+ return gst_caps_from_string ("video/x-svq, "
"svqversion = (int) 3");
case GST_MAKE_FOURCC('s','v','q','i'):
case GST_MAKE_FOURCC('S','V','Q','1'):
- return gst_caps2_from_string ("video/x-svq, "
+ return gst_caps_from_string ("video/x-svq, "
"svqversion = (int) 1");
case GST_MAKE_FOURCC('r','a','w',' '):
/* uncompressed RGB */
- return gst_caps2_from_string ("video/x-raw-rgb, "
+ return gst_caps_from_string ("video/x-raw-rgb, "
"endianness = (int) BIG_ENDIAN");
/*"bpp", GST_PROPS_INT(x),
"depth", GST_PROPS_INT(x),
@@ -1548,26 +1548,26 @@ static GstCaps2 *qtdemux_video_caps(GstQTDemux *qtdemux, guint32 fourcc)
"blue_mask", GST_PROPS_INT(x), FIXME! */
case GST_MAKE_FOURCC('Y','u','v','2'):
/* uncompressed YUV2 */
- return gst_caps2_from_string ("video/x-raw-yuv, "
+ return gst_caps_from_string ("video/x-raw-yuv, "
"format = (fourcc) YUY2");
case GST_MAKE_FOURCC('m','p','e','g'):
/* MPEG */
- return gst_caps2_from_string ("video/mpeg, "
+ return gst_caps_from_string ("video/mpeg, "
"systemstream = (boolean) false, "
"mpegversion = (int) 1");
case GST_MAKE_FOURCC('g','i','f',' '):
- return gst_caps2_from_string ("image/gif");
+ return gst_caps_from_string ("image/gif");
case GST_MAKE_FOURCC('h','2','6','3'):
/* H.263 */
/* ffmpeg uses the height/width props, don't know why */
- return gst_caps2_from_string ("video/x-h263");
+ return gst_caps_from_string ("video/x-h263");
case GST_MAKE_FOURCC('m','p','4','v'):
/* MPEG-4 */
- return gst_caps2_from_string ("video/mpeg, "
+ return gst_caps_from_string ("video/mpeg, "
"mpegversion = (int) 4, "
"systemstream = (boolean) false");
case GST_MAKE_FOURCC('3','I','V','1'):
- return gst_caps2_from_string ("video/x-3ivx");
+ return gst_caps_from_string ("video/x-3ivx");
case GST_MAKE_FOURCC('r','p','z','a'):
case GST_MAKE_FOURCC('c','v','i','d'):
/* Cinepak */
@@ -1582,91 +1582,91 @@ static GstCaps2 *qtdemux_video_caps(GstQTDemux *qtdemux, guint32 fourcc)
}
}
-static GstCaps2 *qtdemux_audio_caps(GstQTDemux *qtdemux, guint32 fourcc)
+static GstCaps *qtdemux_audio_caps(GstQTDemux *qtdemux, guint32 fourcc)
{
switch(fourcc){
case GST_MAKE_FOURCC('N','O','N','E'):
- return NULL; /*gst_caps2_from_string ("audio/raw");*/
+ return NULL; /*gst_caps_from_string ("audio/raw");*/
case GST_MAKE_FOURCC('r','a','w',' '):
/* FIXME */
- return gst_caps2_from_string ("audio/x-raw-int, "
+ return gst_caps_from_string ("audio/x-raw-int, "
"width = (int) 8, "
"depth = (int) 8, "
"signed = (boolean) true");
case GST_MAKE_FOURCC('t','w','o','s'):
/* FIXME */
- return gst_caps2_from_string ("audio/x-raw-int, "
+ return gst_caps_from_string ("audio/x-raw-int, "
"width = (int) 16, "
"depth = (int) 16, "
"endianness = (int) G_BIG_ENDIAN, "
"signed = (boolean) true");
case GST_MAKE_FOURCC('s','o','w','t'):
/* FIXME */
- return gst_caps2_from_string ("audio/x-raw-int, "
+ return gst_caps_from_string ("audio/x-raw-int, "
"width = (int) 16, "
"depth = (int) 16, "
"endianness = (int) G_LITTLE_ENDIAN, "
"signed = (boolean) true");
case GST_MAKE_FOURCC('f','l','6','4'):
- return gst_caps2_from_string ("audio/x-raw-float, "
+ return gst_caps_from_string ("audio/x-raw-float, "
"width = (int) 64, "
"endianness = (int) G_BIG_ENDIAN");
case GST_MAKE_FOURCC('f','l','3','2'):
- return gst_caps2_from_string ("audio/x-raw-float, "
+ return gst_caps_from_string ("audio/x-raw-float, "
"width = (int) 32, "
"endianness = (int) G_BIG_ENDIAN");
case GST_MAKE_FOURCC('i','n','2','4'):
/* FIXME */
- return gst_caps2_from_string ("audio/x-raw-int, "
+ return gst_caps_from_string ("audio/x-raw-int, "
"width = (int) 24, "
"depth = (int) 32, "
"endianness = (int) G_BIG_ENDIAN, "
"signed = (boolean) true");
case GST_MAKE_FOURCC('i','n','3','2'):
/* FIXME */
- return gst_caps2_from_string ("audio/x-raw-int, "
+ return gst_caps_from_string ("audio/x-raw-int, "
"width = (int) 32, "
"depth = (int) 32, "
"endianness = (int) G_BIG_ENDIAN, "
"signed = (boolean) true");
case GST_MAKE_FOURCC('u','l','a','w'):
/* FIXME */
- return gst_caps2_from_string ("audio/x-mulaw");
+ return gst_caps_from_string ("audio/x-mulaw");
case GST_MAKE_FOURCC('a','l','a','w'):
/* FIXME */
- return gst_caps2_from_string ("audio/x-alaw");
+ return gst_caps_from_string ("audio/x-alaw");
case 0x6d730002:
/* Microsoft ADPCM-ACM code 2 */
- return gst_caps2_from_string ("audio/x-adpcm, "
+ return gst_caps_from_string ("audio/x-adpcm, "
"layout = (string) microsoft");
case 0x6d730011:
/* FIXME DVI/Intel IMA ADPCM/ACM code 17 */
- return gst_caps2_from_string ("audio/x-adpcm, "
+ return gst_caps_from_string ("audio/x-adpcm, "
"layout = (string) quicktime");
case 0x6d730055:
/* MPEG layer 3, CBR only (pre QT4.1) */
case 0x5500736d:
case GST_MAKE_FOURCC('.','m','p','3'):
/* MPEG layer 3, CBR & VBR (QT4.1 and later) */
- return gst_caps2_from_string ("audio/mpeg, "
+ return gst_caps_from_string ("audio/mpeg, "
"layer = (int) 3");
case GST_MAKE_FOURCC('M','A','C','3'):
/* MACE 3:1 */
- return gst_caps2_from_string ("audio/x-mace, "
+ return gst_caps_from_string ("audio/x-mace, "
"maceversion = (int) 3");
case GST_MAKE_FOURCC('M','A','C','6'):
/* MACE 6:1 */
- return gst_caps2_from_string ("audio/x-mace, "
+ return gst_caps_from_string ("audio/x-mace, "
"maceversion = (int) 6");
case GST_MAKE_FOURCC('O','g','g','V'):
/* Ogg Vorbis */
- return gst_caps2_from_string ("application/ogg");
+ return gst_caps_from_string ("application/ogg");
case GST_MAKE_FOURCC('d','v','c','a'):
/* DV audio */
- return gst_caps2_from_string ("audio/x-dv");
+ return gst_caps_from_string ("audio/x-dv");
case GST_MAKE_FOURCC('m','p','4','a'):
/* MPEG-4 AAC */
- return gst_caps2_from_string ("audio/mpeg, "
+ return gst_caps_from_string ("audio/mpeg, "
"mpegversion = (int) 4");
case GST_MAKE_FOURCC('q','t','v','r'):
/* ? */
diff --git a/gst/smooth/gstsmooth.c b/gst/smooth/gstsmooth.c
index c30507d62..6e38fe86e 100644
--- a/gst/smooth/gstsmooth.c
+++ b/gst/smooth/gstsmooth.c
@@ -142,7 +142,7 @@ gst_smooth_class_init (GstSmoothClass *klass)
}
static GstPadLinkReturn
-gst_smooth_link (GstPad *pad, const GstCaps2 *caps)
+gst_smooth_link (GstPad *pad, const GstCaps *caps)
{
GstSmooth *filter;
GstStructure *structure;
@@ -150,7 +150,7 @@ gst_smooth_link (GstPad *pad, const GstCaps2 *caps)
filter = GST_SMOOTH (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
ret = gst_structure_get_int (structure, "width", &filter->width);
ret &= gst_structure_get_int (structure, "height", &filter->height);
diff --git a/gst/smpte/gstsmpte.c b/gst/smpte/gstsmpte.c
index ebd5d3f12..fffc4caa4 100644
--- a/gst/smpte/gstsmpte.c
+++ b/gst/smpte/gstsmpte.c
@@ -230,7 +230,7 @@ gst_smpte_update_mask (GstSMPTE *smpte, gint type, gint depth, gint width, gint
}
static gboolean
-gst_smpte_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_smpte_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstSMPTE *smpte;
GstStructure *structure;
@@ -238,7 +238,7 @@ gst_smpte_sinkconnect (GstPad *pad, const GstCaps2 *caps)
smpte = GST_SMPTE (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
ret = gst_structure_get_int (structure, "width", &smpte->width);
ret &= gst_structure_get_int (structure, "height", &smpte->height);
@@ -362,10 +362,10 @@ gst_smpte_loop (GstElement *element)
outbuf = gst_buffer_new_and_alloc (smpte->width * smpte->height * 3);
if (!GST_PAD_CAPS (smpte->srcpad)) {
- GstCaps2 *caps;
- caps = gst_caps2_copy (gst_static_caps2_get (
+ GstCaps *caps;
+ caps = gst_caps_copy (gst_static_caps_get (
&gst_smpte_src_template.static_caps));
- gst_caps2_set_simple (caps,
+ gst_caps_set_simple (caps,
"width", G_TYPE_INT, smpte->width,
"height", G_TYPE_INT, smpte->height,
"framerate", G_TYPE_DOUBLE, smpte->fps, NULL);
diff --git a/gst/speed/gstspeed.c b/gst/speed/gstspeed.c
index c3d4d7b71..ec094156f 100644
--- a/gst/speed/gstspeed.c
+++ b/gst/speed/gstspeed.c
@@ -84,7 +84,7 @@ static void speed_init (GstSpeed *filter);
static void speed_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
static void speed_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
-static gboolean speed_parse_caps (GstSpeed *filter, const GstCaps2 *caps);
+static gboolean speed_parse_caps (GstSpeed *filter, const GstCaps *caps);
static void speed_loop (GstElement *element);
@@ -92,7 +92,7 @@ static GstElementClass *parent_class = NULL;
/*static guint gst_filter_signals[LAST_SIGNAL] = { 0 }; */
static GstPadLinkReturn
-speed_link (GstPad *pad, const GstCaps2 *caps)
+speed_link (GstPad *pad, const GstCaps *caps)
{
GstSpeed *filter;
GstPad *otherpad;
@@ -108,7 +108,7 @@ speed_link (GstPad *pad, const GstCaps2 *caps)
}
static gboolean
-speed_parse_caps (GstSpeed *filter, const GstCaps2 *caps)
+speed_parse_caps (GstSpeed *filter, const GstCaps *caps)
{
const gchar *mimetype;
GstStructure *structure;
@@ -117,7 +117,7 @@ speed_parse_caps (GstSpeed *filter, const GstCaps2 *caps)
g_return_val_if_fail(filter != NULL, FALSE);
g_return_val_if_fail(caps != NULL, FALSE);
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
ret = gst_structure_get_int (structure, "rate", &filter->rate);
ret &= gst_structure_get_int (structure, "channels", &filter->channels);
diff --git a/gst/switch/gstswitch.c b/gst/switch/gstswitch.c
index 6b6ad06ca..625eba29c 100644
--- a/gst/switch/gstswitch.c
+++ b/gst/switch/gstswitch.c
@@ -43,7 +43,7 @@ GST_STATIC_PAD_TEMPLATE (
"sink%d",
GST_PAD_SINK,
GST_PAD_REQUEST,
- GST_STATIC_CAPS2_ANY
+ GST_STATIC_CAPS_ANY
);
static GstElementClass *parent_class = NULL;
diff --git a/gst/vbidec/gstvbidec.c b/gst/vbidec/gstvbidec.c
index 8ceaee5b5..1670142f6 100644
--- a/gst/vbidec/gstvbidec.c
+++ b/gst/vbidec/gstvbidec.c
@@ -87,7 +87,7 @@ GST_STATIC_PAD_TEMPLATE (
"sink",
GST_PAD_SINK,
GST_PAD_ALWAYS,
- GST_STATIC_CAPS2_ANY
+ GST_STATIC_CAPS_ANY
);
static GstStaticPadTemplate gst_vbidec_src_template =
diff --git a/gst/videocrop/gstvideocrop.c b/gst/videocrop/gstvideocrop.c
index b8bece149..ab975a238 100644
--- a/gst/videocrop/gstvideocrop.c
+++ b/gst/videocrop/gstvideocrop.c
@@ -107,7 +107,7 @@ static void gst_video_crop_get_property (GObject *object, guint prop_id,
GValue *value, GParamSpec *pspec);
static GstPadLinkReturn
- gst_video_crop_sink_link (GstPad *pad, const GstCaps2 *caps);
+ gst_video_crop_sink_link (GstPad *pad, const GstCaps *caps);
static void gst_video_crop_chain (GstPad *pad, GstData *_data);
static GstElementStateReturn
@@ -262,14 +262,14 @@ gst_video_crop_get_property (GObject *object, guint prop_id, GValue *value, GPar
}
static GstPadLinkReturn
-gst_video_crop_sink_link (GstPad *pad, const GstCaps2 *caps)
+gst_video_crop_sink_link (GstPad *pad, const GstCaps *caps)
{
GstVideoCrop *video_crop;
GstStructure *structure;
gboolean ret;
video_crop = GST_VIDEO_CROP (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
ret = gst_structure_get_int (structure, "width", &video_crop->width);
ret &= gst_structure_get_int (structure, "height", &video_crop->height);
diff --git a/gst/videodrop/gstvideodrop.c b/gst/videodrop/gstvideodrop.c
index 481e535fd..05c232209 100644
--- a/gst/videodrop/gstvideodrop.c
+++ b/gst/videodrop/gstvideodrop.c
@@ -147,7 +147,7 @@ gst_videodrop_class_init (GstVideodropClass *klass)
min, max)
static GstPadLinkReturn
-gst_videodrop_link (GstPad *pad, const GstCaps2 *caps)
+gst_videodrop_link (GstPad *pad, const GstCaps *caps)
{
GstVideodrop *videodrop;
GstStructure *structure;
@@ -156,7 +156,7 @@ gst_videodrop_link (GstPad *pad, const GstCaps2 *caps)
videodrop = GST_VIDEODROP (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
ret = gst_structure_get_double (structure, "framerate", &fps);
if (!ret) return GST_PAD_LINK_REFUSED;
diff --git a/gst/y4m/gsty4mencode.c b/gst/y4m/gsty4mencode.c
index 2c0cb5989..f45cf109d 100644
--- a/gst/y4m/gsty4mencode.c
+++ b/gst/y4m/gsty4mencode.c
@@ -137,7 +137,7 @@ gst_y4mencode_class_init (GstY4mEncodeClass *klass)
}
static GstPadLinkReturn
-gst_y4mencode_sinkconnect (GstPad *pad, const GstCaps2 *caps)
+gst_y4mencode_sinkconnect (GstPad *pad, const GstCaps *caps)
{
GstY4mEncode *filter;
gint idx = -1, i;
@@ -154,7 +154,7 @@ gst_y4mencode_sinkconnect (GstPad *pad, const GstCaps2 *caps)
filter = GST_Y4MENCODE (gst_pad_get_parent (pad));
- structure = gst_caps2_get_nth_cap (caps, 0);
+ structure = gst_caps_get_structure (caps, 0);
gst_structure_get_int (structure, "width", &filter->width);
gst_structure_get_int (structure, "height", &filter->height);
diff --git a/sys/qcam/gstqcamsrc.c b/sys/qcam/gstqcamsrc.c
index 4f213f531..1312bb43d 100644
--- a/sys/qcam/gstqcamsrc.c
+++ b/sys/qcam/gstqcamsrc.c
@@ -249,7 +249,7 @@ gst_qcamsrc_get (GstPad *pad)
qc_set (qcamsrc->qcam);
if (!GST_PAD_CAPS (pad)) {
- gst_pad_try_set_caps (pad, gst_caps2_new_simple("video/x-raw-yuv",
+ gst_pad_try_set_caps (pad, gst_caps_new_simple("video/x-raw-yuv",
"format", GST_TYPE_FOURCC, "I420",
"width", G_TYPE_INT, qcamsrc->qcam->width / scale,
"height", G_TYPE_INT, qcamsrc->qcam->height / scale,
diff --git a/sys/v4l2/gstv4l2src.c b/sys/v4l2/gstv4l2src.c
index 35da20782..c560e00e6 100644
--- a/sys/v4l2/gstv4l2src.c
+++ b/sys/v4l2/gstv4l2src.c
@@ -70,8 +70,8 @@ static gboolean gst_v4l2src_srcconvert (GstPad *pad,
GstFormat *dest_format,
gint64 *dest_value);
static GstPadLinkReturn gst_v4l2src_srcconnect (GstPad *pad,
- const GstCaps2 *caps);
-static GstCaps2 * gst_v4l2src_getcaps (GstPad *pad);
+ const GstCaps *caps);
+static GstCaps * gst_v4l2src_getcaps (GstPad *pad);
static GstData * gst_v4l2src_get (GstPad *pad);
/* get/set params */
@@ -644,7 +644,7 @@ gst_v4l2_caps_to_v4l2fourcc (GstV4l2Src *v4l2src,
static GstPadLinkReturn
gst_v4l2src_srcconnect (GstPad *pad,
- const GstCaps2 *vscapslist)
+ const GstCaps *vscapslist)
{
GstV4l2Src *v4l2src;
GstV4l2Element *v4l2element;
@@ -655,7 +655,7 @@ gst_v4l2src_srcconnect (GstPad *pad,
v4l2src = GST_V4L2SRC(gst_pad_get_parent (pad));
v4l2element = GST_V4L2ELEMENT(v4l2src);
- structure = gst_caps2_get_nth_cap (vscapslist, 0);
+ structure = gst_caps_get_structure (vscapslist, 0);
/* clean up if we still haven't cleaned up our previous
* capture session */
@@ -685,11 +685,11 @@ gst_v4l2src_srcconnect (GstPad *pad,
}
-static GstCaps2 *
+static GstCaps *
gst_v4l2src_getcaps (GstPad *pad)
{
GstV4l2Src *v4l2src = GST_V4L2SRC(gst_pad_get_parent (pad));
- GstCaps2 *caps;
+ GstCaps *caps;
gint i;
struct v4l2_fmtdesc *format;
int min_w, max_w, min_h, max_h;
@@ -699,7 +699,7 @@ gst_v4l2src_getcaps (GstPad *pad)
}
/* build our own capslist */
- caps = gst_caps2_new_empty();
+ caps = gst_caps_new_empty();
for (i=0;i<g_list_length(v4l2src->formats);i++) {
GstStructure *structure;
@@ -722,7 +722,7 @@ gst_v4l2src_getcaps (GstPad *pad)
"framerate", GST_TYPE_DOUBLE_RANGE, 0, G_MAXDOUBLE,
NULL);
- gst_caps2_append_cap (caps, structure);
+ gst_caps_append_structure (caps, structure);
}
return caps;