From 086b25d40a8fc3606d70c32af7f6af178e2d804d Mon Sep 17 00:00:00 2001
From: Christian Schaller <uraeus@gnome.org>
Date: Fri, 6 May 2005 11:41:28 +0000
Subject: remove gst-libs from gst-plugins module as it is in gst-plugins-base
 now

Original commit message from CVS:
remove gst-libs from gst-plugins module as it is in gst-plugins-base now
---
 gst-libs/gst/riff/Makefile.am  |   16 -
 gst-libs/gst/riff/riff-ids.h   |  335 -------------
 gst-libs/gst/riff/riff-media.c |  713 ----------------------------
 gst-libs/gst/riff/riff-media.h |   77 ---
 gst-libs/gst/riff/riff-read.c  | 1016 ----------------------------------------
 gst-libs/gst/riff/riff-read.h  |  114 -----
 gst-libs/gst/riff/riff.c       |   38 --
 gst-libs/gst/riff/riff.def     |   27 --
 gst-libs/gst/riff/riff.vcproj  |  158 -------
 9 files changed, 2494 deletions(-)
 delete mode 100644 gst-libs/gst/riff/Makefile.am
 delete mode 100644 gst-libs/gst/riff/riff-ids.h
 delete mode 100644 gst-libs/gst/riff/riff-media.c
 delete mode 100644 gst-libs/gst/riff/riff-media.h
 delete mode 100644 gst-libs/gst/riff/riff-read.c
 delete mode 100644 gst-libs/gst/riff/riff-read.h
 delete mode 100644 gst-libs/gst/riff/riff.c
 delete mode 100644 gst-libs/gst/riff/riff.def
 delete mode 100644 gst-libs/gst/riff/riff.vcproj

(limited to 'gst-libs/gst/riff')

diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
deleted file mode 100644
index 03cd8d54..00000000
--- a/gst-libs/gst/riff/Makefile.am
+++ /dev/null
@@ -1,16 +0,0 @@
-plugin_LTLIBRARIES = libgstriff.la
-
-libgstriff_la_SOURCES = \
-	riff.c \
-	riff-media.c \
-	riff-read.c
-
-libgstriffincludedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst/riff
-libgstriffinclude_HEADERS = \
-	riff-ids.h \
-	riff-media.h \
-	riff-read.h
-
-libgstriff_la_LIBADD =
-libgstriff_la_CFLAGS = $(GST_CFLAGS)
-libgstriff_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
diff --git a/gst-libs/gst/riff/riff-ids.h b/gst-libs/gst/riff/riff-ids.h
deleted file mode 100644
index e311f9e0..00000000
--- a/gst-libs/gst/riff/riff-ids.h
+++ /dev/null
@@ -1,335 +0,0 @@
-/* GStreamer RIFF I/O
- * Copyright (C) 2003 Ronald Bultje <rbultje@ronald.bitfreak.net>
- *
- * riff-ids.h: RIFF IDs and structs
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#ifndef __GST_RIFF_IDS_H__
-#define __GST_RIFF_IDS_H__
-
-#include <gst/gst.h>
-
-G_BEGIN_DECLS
-
-/* RIFF types */
-#define GST_RIFF_RIFF_WAVE GST_MAKE_FOURCC ('W','A','V','E')
-#define GST_RIFF_RIFF_AVI  GST_MAKE_FOURCC ('A','V','I',' ')
-#define GST_RIFF_RIFF_CDXA GST_MAKE_FOURCC ('C','D','X','A')
-
-/* tags */
-#define GST_RIFF_TAG_RIFF GST_MAKE_FOURCC ('R','I','F','F')
-#define GST_RIFF_TAG_RIFX GST_MAKE_FOURCC ('R','I','F','X')
-#define GST_RIFF_TAG_LIST GST_MAKE_FOURCC ('L','I','S','T')
-#define GST_RIFF_TAG_avih GST_MAKE_FOURCC ('a','v','i','h')
-#define GST_RIFF_TAG_strd GST_MAKE_FOURCC ('s','t','r','d')
-#define GST_RIFF_TAG_strn GST_MAKE_FOURCC ('s','t','r','n')
-#define GST_RIFF_TAG_strh GST_MAKE_FOURCC ('s','t','r','h')
-#define GST_RIFF_TAG_strf GST_MAKE_FOURCC ('s','t','r','f')
-#define GST_RIFF_TAG_vedt GST_MAKE_FOURCC ('v','e','d','t')
-#define GST_RIFF_TAG_JUNK GST_MAKE_FOURCC ('J','U','N','K')
-#define GST_RIFF_TAG_idx1 GST_MAKE_FOURCC ('i','d','x','1')
-#define GST_RIFF_TAG_dmlh GST_MAKE_FOURCC ('d','m','l','h')
-/* WAV stuff */
-#define GST_RIFF_TAG_fmt  GST_MAKE_FOURCC ('f','m','t',' ')
-#define GST_RIFF_TAG_data GST_MAKE_FOURCC ('d','a','t','a')
-#define GST_RIFF_TAG_plst GST_MAKE_FOURCC ('p','l','s','t')
-#define GST_RIFF_TAG_cue  GST_MAKE_FOURCC ('c','u','e',' ')
-/* LIST types */
-#define GST_RIFF_LIST_movi GST_MAKE_FOURCC ('m','o','v','i')
-#define GST_RIFF_LIST_hdrl GST_MAKE_FOURCC ('h','d','r','l')
-#define GST_RIFF_LIST_odml GST_MAKE_FOURCC ('o','d','m','l')
-#define GST_RIFF_LIST_strl GST_MAKE_FOURCC ('s','t','r','l')
-#define GST_RIFF_LIST_INFO GST_MAKE_FOURCC ('I','N','F','O')
-#define GST_RIFF_LIST_AVIX GST_MAKE_FOURCC ('A','V','I','X')
-#define GST_RIFF_LIST_adtl GST_MAKE_FOURCC ('a','d','t','l')
-
-/* fcc types */
-#define GST_RIFF_FCC_vids GST_MAKE_FOURCC ('v','i','d','s')
-#define GST_RIFF_FCC_auds GST_MAKE_FOURCC ('a','u','d','s')
-#define GST_RIFF_FCC_pads GST_MAKE_FOURCC ('p','a','d','s')
-#define GST_RIFF_FCC_txts GST_MAKE_FOURCC ('t','x','t','s')
-#define GST_RIFF_FCC_vidc GST_MAKE_FOURCC ('v','i','d','c')
-#define GST_RIFF_FCC_iavs GST_MAKE_FOURCC ('i','a','v','s')
-/* fcc handlers */
-#define GST_RIFF_FCCH_RLE  GST_MAKE_FOURCC ('R','L','E',' ')
-#define GST_RIFF_FCCH_msvc GST_MAKE_FOURCC ('m','s','v','c')
-#define GST_RIFF_FCCH_MSVC GST_MAKE_FOURCC ('M','S','V','C')
-
-/* INFO types - see http://www.saettler.com/RIFFMCI/riffmci.html */
-#define GST_RIFF_INFO_IARL GST_MAKE_FOURCC ('I','A','R','L') /* location */
-#define GST_RIFF_INFO_IART GST_MAKE_FOURCC ('I','A','R','T') /* artist */
-#define GST_RIFF_INFO_ICMS GST_MAKE_FOURCC ('I','C','M','S') /* commissioned */
-#define GST_RIFF_INFO_ICMT GST_MAKE_FOURCC ('I','C','M','T') /* comment */
-#define GST_RIFF_INFO_ICOP GST_MAKE_FOURCC ('I','C','O','P') /* copyright */
-#define GST_RIFF_INFO_ICRD GST_MAKE_FOURCC ('I','C','R','D') /* creation date */
-#define GST_RIFF_INFO_ICRP GST_MAKE_FOURCC ('I','C','R','P') /* cropped */
-#define GST_RIFF_INFO_IDIM GST_MAKE_FOURCC ('I','D','I','M') /* dimensions */
-#define GST_RIFF_INFO_IDPI GST_MAKE_FOURCC ('I','D','P','I') /* dots-per-inch */
-#define GST_RIFF_INFO_IENG GST_MAKE_FOURCC ('I','E','N','G') /* engineer(s) */
-#define GST_RIFF_INFO_IGNR GST_MAKE_FOURCC ('I','G','N','R') /* genre */
-#define GST_RIFF_INFO_IKEY GST_MAKE_FOURCC ('I','K','E','Y') /* keywords */
-#define GST_RIFF_INFO_ILGT GST_MAKE_FOURCC ('I','L','G','T') /* lightness */
-#define GST_RIFF_INFO_IMED GST_MAKE_FOURCC ('I','M','E','D') /* medium */
-#define GST_RIFF_INFO_INAM GST_MAKE_FOURCC ('I','N','A','M') /* name */
-#define GST_RIFF_INFO_IPLT GST_MAKE_FOURCC ('I','P','L','T') /* palette setting */
-#define GST_RIFF_INFO_IPRD GST_MAKE_FOURCC ('I','P','R','D') /* product */
-#define GST_RIFF_INFO_ISBJ GST_MAKE_FOURCC ('I','S','B','J') /* subject */
-#define GST_RIFF_INFO_ISFT GST_MAKE_FOURCC ('I','S','F','T') /* software */
-#define GST_RIFF_INFO_ISHP GST_MAKE_FOURCC ('I','S','H','P') /* sharpness */
-#define GST_RIFF_INFO_ISRC GST_MAKE_FOURCC ('I','S','R','C') /* source */
-#define GST_RIFF_INFO_ISRF GST_MAKE_FOURCC ('I','S','R','F') /* source form */
-#define GST_RIFF_INFO_ITCH GST_MAKE_FOURCC ('I','T','C','H') /* technician(s) */
-
-/*********Chunk Names***************/
-#define GST_RIFF_FF00 GST_MAKE_FOURCC (0xFF,0xFF,0x00,0x00)
-#define GST_RIFF_00   GST_MAKE_FOURCC ('0', '0',0x00,0x00)
-#define GST_RIFF_01   GST_MAKE_FOURCC ('0', '1',0x00,0x00)
-#define GST_RIFF_02   GST_MAKE_FOURCC ('0', '2',0x00,0x00)
-#define GST_RIFF_03   GST_MAKE_FOURCC ('0', '3',0x00,0x00)
-#define GST_RIFF_04   GST_MAKE_FOURCC ('0', '4',0x00,0x00)
-#define GST_RIFF_05   GST_MAKE_FOURCC ('0', '5',0x00,0x00)
-#define GST_RIFF_06   GST_MAKE_FOURCC ('0', '6',0x00,0x00)
-#define GST_RIFF_07   GST_MAKE_FOURCC ('0', '7',0x00,0x00)
-#define GST_RIFF_00pc GST_MAKE_FOURCC ('0', '0', 'p', 'c')
-#define GST_RIFF_01pc GST_MAKE_FOURCC ('0', '1', 'p', 'c')
-#define GST_RIFF_00dc GST_MAKE_FOURCC ('0', '0', 'd', 'c')
-#define GST_RIFF_00dx GST_MAKE_FOURCC ('0', '0', 'd', 'x')
-#define GST_RIFF_00db GST_MAKE_FOURCC ('0', '0', 'd', 'b')
-#define GST_RIFF_00xx GST_MAKE_FOURCC ('0', '0', 'x', 'x')
-#define GST_RIFF_00id GST_MAKE_FOURCC ('0', '0', 'i', 'd')
-#define GST_RIFF_00rt GST_MAKE_FOURCC ('0', '0', 'r', 't')
-#define GST_RIFF_0021 GST_MAKE_FOURCC ('0', '0', '2', '1')
-#define GST_RIFF_00iv GST_MAKE_FOURCC ('0', '0', 'i', 'v')
-#define GST_RIFF_0031 GST_MAKE_FOURCC ('0', '0', '3', '1')
-#define GST_RIFF_0032 GST_MAKE_FOURCC ('0', '0', '3', '2')
-#define GST_RIFF_00vc GST_MAKE_FOURCC ('0', '0', 'v', 'c')
-#define GST_RIFF_00xm GST_MAKE_FOURCC ('0', '0', 'x', 'm')
-#define GST_RIFF_01wb GST_MAKE_FOURCC ('0', '1', 'w', 'b')
-#define GST_RIFF_01dc GST_MAKE_FOURCC ('0', '1', 'd', 'c')
-#define GST_RIFF_00__ GST_MAKE_FOURCC ('0', '0', '_', '_')
-
-/*********VIDEO CODECS**************/
-#define GST_RIFF_cram GST_MAKE_FOURCC ('c', 'r', 'a', 'm')
-#define GST_RIFF_CRAM GST_MAKE_FOURCC ('C', 'R', 'A', 'M')
-#define GST_RIFF_wham GST_MAKE_FOURCC ('w', 'h', 'a', 'm')
-#define GST_RIFF_WHAM GST_MAKE_FOURCC ('W', 'H', 'A', 'M')
-#define GST_RIFF_rgb  GST_MAKE_FOURCC (0x00,0x00,0x00,0x00)
-#define GST_RIFF_RGB  GST_MAKE_FOURCC ('R', 'G', 'B', ' ')
-#define GST_RIFF_rle8 GST_MAKE_FOURCC (0x01,0x00,0x00,0x00)
-#define GST_RIFF_RLE8 GST_MAKE_FOURCC ('R', 'L', 'E', '8')
-#define GST_RIFF_rle4 GST_MAKE_FOURCC (0x02,0x00,0x00,0x00)
-#define GST_RIFF_RLE4 GST_MAKE_FOURCC ('R', 'L', 'E', '4')
-#define GST_RIFF_none GST_MAKE_FOURCC (0x00,0x00,0xFF,0xFF)
-#define GST_RIFF_NONE GST_MAKE_FOURCC ('N', 'O', 'N', 'E')
-#define GST_RIFF_pack GST_MAKE_FOURCC (0x01,0x00,0xFF,0xFF)
-#define GST_RIFF_PACK GST_MAKE_FOURCC ('P', 'A', 'C', 'K')
-#define GST_RIFF_tran GST_MAKE_FOURCC (0x02,0x00,0xFF,0xFF)
-#define GST_RIFF_TRAN GST_MAKE_FOURCC ('T', 'R', 'A', 'N')
-#define GST_RIFF_ccc  GST_MAKE_FOURCC (0x03,0x00,0xFF,0xFF)
-#define GST_RIFF_CCC  GST_MAKE_FOURCC ('C', 'C', 'C', ' ')
-#define GST_RIFF_cyuv GST_MAKE_FOURCC ('c', 'y', 'u', 'v')
-#define GST_RIFF_CYUV GST_MAKE_FOURCC ('C', 'Y', 'U', 'V')
-#define GST_RIFF_jpeg GST_MAKE_FOURCC (0x04,0x00,0xFF,0xFF)
-#define GST_RIFF_JPEG GST_MAKE_FOURCC ('J', 'P', 'E', 'G')
-#define GST_RIFF_MJPG GST_MAKE_FOURCC ('M', 'J', 'P', 'G')
-#define GST_RIFF_mJPG GST_MAKE_FOURCC ('m', 'J', 'P', 'G')
-#define GST_RIFF_IJPG GST_MAKE_FOURCC ('I', 'J', 'P', 'G')
-#define GST_RIFF_rt21 GST_MAKE_FOURCC ('r', 't', '2', '1')
-#define GST_RIFF_RT21 GST_MAKE_FOURCC ('R', 'T', '2', '1')
-#define GST_RIFF_iv31 GST_MAKE_FOURCC ('i', 'v', '3', '1')
-#define GST_RIFF_IV31 GST_MAKE_FOURCC ('I', 'V', '3', '1')
-#define GST_RIFF_iv32 GST_MAKE_FOURCC ('i', 'v', '3', '2')
-#define GST_RIFF_IV32 GST_MAKE_FOURCC ('I', 'V', '3', '2')
-#define GST_RIFF_iv41 GST_MAKE_FOURCC ('i', 'v', '4', '1')
-#define GST_RIFF_IV41 GST_MAKE_FOURCC ('I', 'V', '4', '1')
-#define GST_RIFF_iv50 GST_MAKE_FOURCC ('i', 'v', '5', '0')
-#define GST_RIFF_IV50 GST_MAKE_FOURCC ('I', 'V', '5', '0')
-#define GST_RIFF_cvid GST_MAKE_FOURCC ('c', 'v', 'i', 'd')
-#define GST_RIFF_CVID GST_MAKE_FOURCC ('C', 'V', 'I', 'D')
-#define GST_RIFF_ULTI GST_MAKE_FOURCC ('U', 'L', 'T', 'I')
-#define GST_RIFF_ulti GST_MAKE_FOURCC ('u', 'l', 't', 'i')
-#define GST_RIFF_YUV9 GST_MAKE_FOURCC ('Y', 'V', 'U', '9')
-#define GST_RIFF_YVU9 GST_MAKE_FOURCC ('Y', 'U', 'V', '9')
-#define GST_RIFF_XMPG GST_MAKE_FOURCC ('X', 'M', 'P', 'G')
-#define GST_RIFF_xmpg GST_MAKE_FOURCC ('x', 'm', 'p', 'g')
-#define GST_RIFF_VDOW GST_MAKE_FOURCC ('V', 'D', 'O', 'W')
-#define GST_RIFF_MVI1 GST_MAKE_FOURCC ('M', 'V', 'I', '1')
-#define GST_RIFF_v422 GST_MAKE_FOURCC ('v', '4', '2', '2')
-#define GST_RIFF_V422 GST_MAKE_FOURCC ('V', '4', '2', '2')
-#define GST_RIFF_mvi1 GST_MAKE_FOURCC ('m', 'v', 'i', '1')
-#define GST_RIFF_MPIX GST_MAKE_FOURCC (0x04,0x00, 'i', '1')     /* MotionPixels munged their id */
-#define GST_RIFF_AURA GST_MAKE_FOURCC ('A', 'U', 'R', 'A')
-#define GST_RIFF_DMB1 GST_MAKE_FOURCC ('D', 'M', 'B', '1')
-#define GST_RIFF_dmb1 GST_MAKE_FOURCC ('d', 'm', 'b', '1')
-
-#define GST_RIFF_BW10 GST_MAKE_FOURCC ('B', 'W', '1', '0')
-#define GST_RIFF_bw10 GST_MAKE_FOURCC ('b', 'w', '1', '0')
-
-#define GST_RIFF_yuy2 GST_MAKE_FOURCC ('y', 'u', 'y', '2')
-#define GST_RIFF_YUY2 GST_MAKE_FOURCC ('Y', 'U', 'Y', '2')
-#define GST_RIFF_YUV8 GST_MAKE_FOURCC ('Y', 'U', 'V', '8')
-#define GST_RIFF_WINX GST_MAKE_FOURCC ('W', 'I', 'N', 'X')
-#define GST_RIFF_WPY2 GST_MAKE_FOURCC ('W', 'P', 'Y', '2')
-#define GST_RIFF_m263 GST_MAKE_FOURCC ('m', '2', '6', '3')
-#define GST_RIFF_M263 GST_MAKE_FOURCC ('M', '2', '6', '3')
-#define GST_RIFF_H263 GST_MAKE_FOURCC ('H', '2', '6', '3')
-#define GST_RIFF_i263 GST_MAKE_FOURCC ('i', '2', '6', '3')
-#define GST_RIFF_L263 GST_MAKE_FOURCC ('L', '2', '6', '3')
-#define GST_RIFF_x263 GST_MAKE_FOURCC ('x', '2', '6', '3')
-#define GST_RIFF_VSSH GST_MAKE_FOURCC ( 'V', 'S', 'S', 'H') /* H2.64 */
-
-#define GST_RIFF_Q1_0 GST_MAKE_FOURCC ('Q', '1',0x2e, '0')
-#define GST_RIFF_SFMC GST_MAKE_FOURCC ('S', 'F', 'M', 'C')
-
-#define GST_RIFF_y41p GST_MAKE_FOURCC ('y', '4', '1', 'p')
-#define GST_RIFF_Y41P GST_MAKE_FOURCC ('Y', '4', '1', 'P')
-#define GST_RIFF_yv12 GST_MAKE_FOURCC ('y', 'v', '1', '2')
-#define GST_RIFF_YV12 GST_MAKE_FOURCC ('Y', 'V', '1', '2')
-#define GST_RIFF_vixl GST_MAKE_FOURCC ('v', 'i', 'x', 'l')
-#define GST_RIFF_VIXL GST_MAKE_FOURCC ('V', 'I', 'X', 'L')
-#define GST_RIFF_iyuv GST_MAKE_FOURCC ('i', 'y', 'u', 'v')
-#define GST_RIFF_IYUV GST_MAKE_FOURCC ('I', 'Y', 'U', 'V')
-#define GST_RIFF_i420 GST_MAKE_FOURCC ('i', '4', '2', '0')
-#define GST_RIFF_I420 GST_MAKE_FOURCC ('I', '4', '2', '0')
-#define GST_RIFF_vyuy GST_MAKE_FOURCC ('v', 'y', 'u', 'y')
-#define GST_RIFF_VYUY GST_MAKE_FOURCC ('V', 'Y', 'U', 'Y')
-
-#define GST_RIFF_DIV3 GST_MAKE_FOURCC ('D', 'I', 'V', '3')
-
-#define GST_RIFF_rpza GST_MAKE_FOURCC ('r', 'p', 'z', 'a')
-/* And this here's the mistakes that need to be supported */
-#define GST_RIFF_azpr GST_MAKE_FOURCC ('a', 'z', 'p', 'r')  /* recognize Apple's rpza mangled? */
-
-/*********** FND in MJPG **********/
-#define GST_RIFF_ISFT GST_MAKE_FOURCC ('I', 'S', 'F', 'T')
-#define GST_RIFF_IDIT GST_MAKE_FOURCC ('I', 'D', 'I', 'T')
-
-#define GST_RIFF_00AM GST_MAKE_FOURCC ('0', '0', 'A', 'M')
-#define GST_RIFF_DISP GST_MAKE_FOURCC ('D', 'I', 'S', 'P')
-#define GST_RIFF_ISBJ GST_MAKE_FOURCC ('I', 'S', 'B', 'J')
-
-#define GST_RIFF_rec  GST_MAKE_FOURCC ('r', 'e', 'c', ' ')
-
-/* common data structures */
-typedef struct _gst_riff_strh {
-  guint32 type;             /* stream type */
-  guint32 fcc_handler;       /* fcc_handler */
-  guint32 flags;
-/* flags values */
-#define GST_RIFF_STRH_DISABLED        0x000000001
-#define GST_RIFF_STRH_VIDEOPALCHANGES 0x000010000
-  guint32 priority;
-  guint32 init_frames;       /* initial frames (???) */
-  guint32 scale;
-  guint32 rate;
-  guint32 start;
-  guint32 length;
-  guint32 bufsize;           /* suggested buffer size */
-  guint32 quality;
-  guint32 samplesize;
-  /* XXX 16 bytes ? */
-} gst_riff_strh;
-
-typedef struct _gst_riff_strf_vids {       /* == BitMapInfoHeader */
-  guint32 size;
-  guint32 width;
-  guint32 height;
-  guint16 planes;
-  guint16 bit_cnt;
-  guint32 compression;
-  guint32 image_size;
-  guint32 xpels_meter;
-  guint32 ypels_meter;
-  guint32 num_colors;        /* used colors */
-  guint32 imp_colors;        /* important colors */
-  /* may be more for some codecs */
-} gst_riff_strf_vids;
-
-
-typedef struct _gst_riff_strf_auds {       /* == WaveHeader (?) */
-  guint16 format;
-/**** from public Microsoft RIFF docs ******/
-#define GST_RIFF_WAVE_FORMAT_UNKNOWN        (0x0000)
-#define GST_RIFF_WAVE_FORMAT_PCM            (0x0001)
-#define GST_RIFF_WAVE_FORMAT_ADPCM          (0x0002)
-#define GST_RIFF_WAVE_FORMAT_IBM_CVSD       (0x0005)
-#define GST_RIFF_WAVE_FORMAT_ALAW           (0x0006)
-#define GST_RIFF_WAVE_FORMAT_MULAW          (0x0007)
-#define GST_RIFF_WAVE_FORMAT_OKI_ADPCM      (0x0010)
-#define GST_RIFF_WAVE_FORMAT_DVI_ADPCM      (0x0011)
-#define GST_RIFF_WAVE_FORMAT_DIGISTD        (0x0015)
-#define GST_RIFF_WAVE_FORMAT_DIGIFIX        (0x0016)
-#define GST_RIFF_WAVE_FORMAT_YAMAHA_ADPCM   (0x0020)
-#define GST_RIFF_WAVE_FORMAT_DSP_TRUESPEECH (0x0022)
-#define GST_RIFF_WAVE_FORMAT_GSM610         (0x0031)
-#define GST_RIFF_WAVE_FORMAT_MSN            (0x0032)
-#define GST_RIFF_WAVE_FORMAT_ITU_G721_ADPCM (0x0040)
-#define GST_RIFF_WAVE_FORMAT_MPEGL12        (0x0050)
-#define GST_RIFF_WAVE_FORMAT_MPEGL3         (0x0055)
-#define GST_RIFF_IBM_FORMAT_MULAW           (0x0101)
-#define GST_RIFF_IBM_FORMAT_ALAW            (0x0102)
-#define GST_RIFF_IBM_FORMAT_ADPCM           (0x0103)
-#define GST_RIFF_WAVE_FORMAT_WMAV1          (0x0160)
-#define GST_RIFF_WAVE_FORMAT_WMAV2          (0x0161)
-#define GST_RIFF_WAVE_FORMAT_WMAV3          (0x0162)
-#define GST_RIFF_WAVE_FORMAT_SONY_ATRAC3    (0x0270)
-#define GST_RIFF_WAVE_FORMAT_A52            (0x2000)
-#define GST_RIFF_WAVE_FORMAT_VORBIS1        (0x674f)
-#define GST_RIFF_WAVE_FORMAT_VORBIS2        (0x6750)
-#define GST_RIFF_WAVE_FORMAT_VORBIS3        (0x6751)
-#define GST_RIFF_WAVE_FORMAT_VORBIS1PLUS    (0x676f)
-#define GST_RIFF_WAVE_FORMAT_VORBIS2PLUS    (0x6770)
-#define GST_RIFF_WAVE_FORMAT_VORBIS3PLUS    (0x6771)
-#define GST_RIFF_WAVE_FORMAT_GSM_AMR_CBR    (0x7A21)
-#define GST_RIFF_WAVE_FORMAT_GSM_AMR_VBR    (0x7A22)
-  guint16 channels;
-  guint32 rate;
-  guint32 av_bps;
-  guint16 blockalign;
-  guint16 size;
-} gst_riff_strf_auds;
-
-typedef struct _gst_riff_strf_iavs {    
-  guint32 DVAAuxSrc;
-  guint32 DVAAuxCtl;
-  guint32 DVAAuxSrc1;
-  guint32 DVAAuxCtl1;
-  guint32 DVVAuxSrc;
-  guint32 DVVAuxCtl;
-  guint32 DVReserved1;
-  guint32 DVReserved2;
-} gst_riff_strf_iavs;
-
-typedef struct _gst_riff_index_entry {  
-  guint32 id;
-  guint32 flags;
-#define GST_RIFF_IF_LIST		(0x00000001L)
-#define GST_RIFF_IF_KEYFRAME		(0x00000010L)
-#define GST_RIFF_IF_NO_TIME		(0x00000100L)
-#define GST_RIFF_IF_COMPUSE		(0x0FFF0000L)
-  guint32 offset;
-  guint32 size;
-} gst_riff_index_entry;
-
-typedef struct _gst_riff_dmlh {
-  guint32 totalframes;
-} gst_riff_dmlh;
-
-G_END_DECLS
-
-#endif /* __GST_RIFF_IDS_H__ */
diff --git a/gst-libs/gst/riff/riff-media.c b/gst-libs/gst/riff/riff-media.c
deleted file mode 100644
index 2d3ac28e..00000000
--- a/gst-libs/gst/riff/riff-media.c
+++ /dev/null
@@ -1,713 +0,0 @@
-/* GStreamer RIFF I/O
- * Copyright (C) 2003 Ronald Bultje <rbultje@ronald.bitfreak.net>
- *
- * riff-media.h: RIFF-id to/from caps routines
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include "riff-ids.h"
-#include "riff-media.h"
-
-/**
- * gst_riff_create_video_caps_with_data:
- * @codec_fcc: fourCC codec for this codec.
- * @strh: pointer to the strh stream header structure.
- * @strf: pointer to the strf stream header structure, including any
- *        data that is within the range of strf.size, but excluding any
- *        additional data withint this chunk but outside strf.size.
- * @strf_data: a #GstBuffer containing the additional data in the strf
- *             chunk outside reach of strf.size. Ususally a palette.
- * @strd_data: a #GstBuffer containing the data in the strd stream header
- *             chunk. Usually codec initialization data.
- * @codec_name: if given, will be filled with a human-readable codec name.
- */
-
-GstCaps *
-gst_riff_create_video_caps_with_data (guint32 codec_fcc,
-    gst_riff_strh * strh, gst_riff_strf_vids * strf,
-    GstBuffer * strf_data, GstBuffer * strd_data, char **codec_name)
-{
-  GstCaps *caps = NULL;
-  GstBuffer *palette = NULL;
-
-  switch (codec_fcc) {
-    case GST_MAKE_FOURCC ('D', 'I', 'B', ' '):
-      caps = gst_caps_new_simple ("video/x-raw-rgb",
-          "bpp", G_TYPE_INT, 8,
-          "depth", G_TYPE_INT, 8, "endianness", G_TYPE_INT, G_BYTE_ORDER, NULL);
-      palette = strf_data;
-      strf_data = NULL;
-      if (codec_name)
-        *codec_name = g_strdup ("Palettized 8-bit RGB");
-      break;
-
-    case GST_MAKE_FOURCC ('I', '4', '2', '0'):
-      caps = gst_caps_new_simple ("video/x-raw-yuv",
-          "format", GST_TYPE_FOURCC, codec_fcc, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Uncompressed planar YUV 4:2:0");
-      break;
-
-    case GST_MAKE_FOURCC ('Y', 'U', 'Y', '2'):
-      caps = gst_caps_new_simple ("video/x-raw-yuv",
-          "format", GST_TYPE_FOURCC, codec_fcc, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Uncompressed packed YUV 4:2:2");
-      break;
-
-    case GST_MAKE_FOURCC ('M', 'J', 'P', 'G'): /* YUY2 MJPEG */
-      caps = gst_caps_new_simple ("image/jpeg", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Motion JPEG");
-      break;
-
-    case GST_MAKE_FOURCC ('J', 'P', 'E', 'G'): /* generic (mostly RGB) MJPEG */
-      caps = gst_caps_new_simple ("image/jpeg", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("JPEG Still Image");
-      break;
-
-    case GST_MAKE_FOURCC ('P', 'I', 'X', 'L'): /* Miro/Pinnacle fourccs */
-    case GST_MAKE_FOURCC ('V', 'I', 'X', 'L'): /* Miro/Pinnacle fourccs */
-      caps = gst_caps_new_simple ("image/jpeg", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Miro/Pinnacle Motion JPEG Video");
-      break;
-
-    case GST_MAKE_FOURCC ('H', 'F', 'Y', 'U'):
-      caps = gst_caps_new_simple ("video/x-huffyuv", NULL);
-      if (strf) {
-        gst_caps_set_simple (caps, "bpp",
-            G_TYPE_INT, (int) strf->bit_cnt, NULL);
-      }
-      if (codec_name)
-        *codec_name = g_strdup ("Huffman Lossless Codec");
-      break;
-
-    case GST_MAKE_FOURCC ('M', 'P', 'E', 'G'):
-    case GST_MAKE_FOURCC ('M', 'P', 'G', 'I'):
-    case GST_MAKE_FOURCC ('m', 'p', 'g', '1'):
-    case GST_MAKE_FOURCC ('M', 'P', 'G', '1'):
-      caps = gst_caps_new_simple ("video/mpeg",
-          "systemstream", G_TYPE_BOOLEAN, FALSE,
-          "mpegversion", G_TYPE_INT, 1, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("MPEG video");
-      break;
-    case GST_MAKE_FOURCC ('M', 'P', 'G', '2'):
-    case GST_MAKE_FOURCC ('m', 'p', 'g', '2'):
-      caps = gst_caps_new_simple ("video/mpeg",
-          "systemstream", G_TYPE_BOOLEAN, FALSE,
-          "mpegversion", G_TYPE_INT, 2, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("MPEG 2 video");
-      break;
-
-    case GST_MAKE_FOURCC ('H', '2', '6', '3'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("ITU H.26n");
-      break;
-
-    case GST_MAKE_FOURCC ('i', '2', '6', '3'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("ITU H.263");
-      break;
-
-    case GST_MAKE_FOURCC ('L', '2', '6', '3'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Lead H.263");
-      break;
-
-    case GST_MAKE_FOURCC ('M', '2', '6', '3'):
-    case GST_MAKE_FOURCC ('m', '2', '6', '3'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft H.263");
-      break;
-
-    case GST_MAKE_FOURCC ('V', 'D', 'O', 'W'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("VDOLive");
-      break;
-
-    case GST_MAKE_FOURCC ('V', 'I', 'V', 'O'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Vivo H.263");
-      break;
-
-    case GST_MAKE_FOURCC ('x', '2', '6', '3'):
-      caps = gst_caps_new_simple ("video/x-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Xirlink H.263");
-      break;
-
-      /* apparently not standard H.263...? */
-    case GST_MAKE_FOURCC ('I', '2', '6', '3'):
-      caps = gst_caps_new_simple ("video/x-intel-h263", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Intel H.263");
-      break;
-
-    case GST_MAKE_FOURCC ('h', '2', '6', '4'):
-      caps = gst_caps_new_simple ("video/x-h264", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("ITU H.264");
-      break;
-
-    case GST_MAKE_FOURCC ('V', 'S', 'S', 'H'):
-      caps = gst_caps_new_simple ("video/x-h264", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("VideoSoft H.264");
-      break;
-
-    case GST_MAKE_FOURCC ('D', 'I', 'V', '3'):
-    case GST_MAKE_FOURCC ('d', 'i', 'v', '3'):
-    case GST_MAKE_FOURCC ('D', 'I', 'V', '4'):
-    case GST_MAKE_FOURCC ('d', 'i', 'v', '4'):
-    case GST_MAKE_FOURCC ('D', 'I', 'V', '5'):
-    case GST_MAKE_FOURCC ('d', 'i', 'v', '5'):
-    case GST_MAKE_FOURCC ('D', 'I', 'V', '6'):
-    case GST_MAKE_FOURCC ('d', 'i', 'v', '6'):
-      caps = gst_caps_new_simple ("video/x-divx",
-          "divxversion", G_TYPE_INT, 3, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("DivX MS-MPEG-4 Version 3");
-      break;
-
-    case GST_MAKE_FOURCC ('d', 'i', 'v', 'x'):
-    case GST_MAKE_FOURCC ('D', 'I', 'V', 'X'):
-      caps = gst_caps_new_simple ("video/x-divx",
-          "divxversion", G_TYPE_INT, 4, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("DivX MPEG-4 Version 4");
-      break;
-
-    case GST_MAKE_FOURCC ('B', 'L', 'Z', '0'):
-      caps = gst_caps_new_simple ("video/x-divx",
-          "divxversion", G_TYPE_INT, 4, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Blizzard DivX");
-      break;
-
-    case GST_MAKE_FOURCC ('D', 'X', '5', '0'):
-      caps = gst_caps_new_simple ("video/x-divx",
-          "divxversion", G_TYPE_INT, 5, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("DivX MPEG-4 Version 5");
-      break;
-
-    case GST_MAKE_FOURCC ('X', 'V', 'I', 'D'):
-    case GST_MAKE_FOURCC ('x', 'v', 'i', 'd'):
-      caps = gst_caps_new_simple ("video/x-xvid", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("XVID MPEG-4");
-      break;
-
-    case GST_MAKE_FOURCC ('M', 'P', 'G', '4'):
-    case GST_MAKE_FOURCC ('M', 'P', '4', 'S'):
-      caps = gst_caps_new_simple ("video/x-msmpeg",
-          "msmpegversion", G_TYPE_INT, 41, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft MPEG-4 4.1");
-      break;
-
-    case GST_MAKE_FOURCC ('m', 'p', '4', '2'):
-    case GST_MAKE_FOURCC ('M', 'P', '4', '2'):
-      caps = gst_caps_new_simple ("video/x-msmpeg",
-          "msmpegversion", G_TYPE_INT, 42, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft MPEG-4 4.2");
-      break;
-
-    case GST_MAKE_FOURCC ('m', 'p', '4', '3'):
-    case GST_MAKE_FOURCC ('M', 'P', '4', '3'):
-      caps = gst_caps_new_simple ("video/x-msmpeg",
-          "msmpegversion", G_TYPE_INT, 43, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft MPEG-4 4.3");
-      break;
-
-    case GST_MAKE_FOURCC ('3', 'I', 'V', '1'):
-    case GST_MAKE_FOURCC ('3', 'I', 'V', '2'):
-      caps = gst_caps_new_simple ("video/x-3ivx", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("3ivx");
-      break;
-
-    case GST_MAKE_FOURCC ('D', 'V', 'S', 'D'):
-    case GST_MAKE_FOURCC ('d', 'v', 's', 'd'):
-      caps = gst_caps_new_simple ("video/x-dv",
-          "systemstream", G_TYPE_BOOLEAN, FALSE, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Generic DV");
-      break;
-
-    case GST_MAKE_FOURCC ('W', 'M', 'V', '1'):
-      caps = gst_caps_new_simple ("video/x-wmv",
-          "wmvversion", G_TYPE_INT, 1, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft Windows Media 7 (WMV1)");
-      break;
-
-    case GST_MAKE_FOURCC ('W', 'M', 'V', '2'):
-      caps = gst_caps_new_simple ("video/x-wmv",
-          "wmvversion", G_TYPE_INT, 2, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft Windows Media 8 (WMV2)");
-      break;
-
-    case GST_MAKE_FOURCC ('W', 'M', 'V', '3'):
-      caps = gst_caps_new_simple ("video/x-wmv",
-          "wmvversion", G_TYPE_INT, 3, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft Windows Media 9 (WMV3)");
-      break;
-
-    case GST_MAKE_FOURCC ('c', 'v', 'i', 'd'):
-      caps = gst_caps_new_simple ("video/x-cinepak", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Cinepak video");
-      break;
-
-    case GST_MAKE_FOURCC ('M', 'S', 'V', 'C'):
-    case GST_MAKE_FOURCC ('m', 's', 'v', 'c'):
-    case GST_MAKE_FOURCC ('C', 'R', 'A', 'M'):
-    case GST_MAKE_FOURCC ('c', 'r', 'a', 'm'):
-    case GST_MAKE_FOURCC ('W', 'H', 'A', 'M'):
-    case GST_MAKE_FOURCC ('w', 'h', 'a', 'm'):
-      caps = gst_caps_new_simple ("video/x-msvideocodec",
-          "msvideoversion", G_TYPE_INT, 1, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("MS video v1");
-      break;
-
-    case GST_MAKE_FOURCC ('R', 'L', 'E', ' '):
-    case GST_MAKE_FOURCC ('m', 'r', 'l', 'e'):
-    case GST_MAKE_FOURCC (0x1, 0x0, 0x0, 0x0): /* why, why, why? */
-      caps = gst_caps_new_simple ("video/x-rle",
-          "layout", G_TYPE_STRING, "microsoft", NULL);
-      palette = strf_data;
-      strf_data = NULL;
-      if (strf) {
-        gst_caps_set_simple (caps,
-            "depth", G_TYPE_INT, (gint) strf->bit_cnt, NULL);
-      } else {
-        gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 1, 64, NULL);
-      }
-      if (codec_name)
-        *codec_name = g_strdup ("Microsoft RLE");
-      break;
-
-    case GST_MAKE_FOURCC ('X', 'x', 'a', 'n'):
-      caps = gst_caps_new_simple ("video/x-xan",
-          "wcversion", G_TYPE_INT, 4, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Xan Wing Commander 4");
-      break;
-
-    case GST_MAKE_FOURCC ('I', 'V', '5', '0'):
-      caps = gst_caps_new_simple ("video/x-intel",
-          "ivversion", G_TYPE_INT, 5, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Intel Video 5");
-      break;
-
-    default:
-      GST_WARNING ("Unknown video fourcc " GST_FOURCC_FORMAT,
-          GST_FOURCC_ARGS (codec_fcc));
-      return NULL;
-  }
-
-  if (strh != NULL) {
-    gdouble fps = 1. * strh->rate / strh->scale;
-
-    gst_caps_set_simple (caps, "framerate", G_TYPE_DOUBLE, fps, NULL);
-  } else {
-    gst_caps_set_simple (caps,
-        "framerate", GST_TYPE_DOUBLE_RANGE, 0., G_MAXDOUBLE, NULL);
-  }
-
-  if (strf != NULL) {
-    gst_caps_set_simple (caps,
-        "width", G_TYPE_INT, strf->width,
-        "height", G_TYPE_INT, strf->height, NULL);
-  } else {
-    gst_caps_set_simple (caps,
-        "width", GST_TYPE_INT_RANGE, 16, 4096,
-        "height", GST_TYPE_INT_RANGE, 16, 4096, NULL);
-  }
-
-  /* extradata */
-  if (strf_data || strd_data) {
-    gst_caps_set_simple (caps, "codec_data", GST_TYPE_BUFFER,
-        strf_data ? strf_data : strd_data, NULL);
-  }
-
-  /* palette */
-  if (palette && GST_BUFFER_SIZE (palette) >= 256 * 4) {
-    GstBuffer *copy = gst_buffer_copy (palette);
-
-#if (G_BYTE_ORDER == G_BIG_ENDIAN)
-    gint n;
-    guint32 *data = (guint32 *) GST_BUFFER_DATA (copy);
-
-    /* own endianness */
-    for (n = 0; n < 256; n++)
-      data[n] = GUINT32_FROM_LE (data[n]);
-#endif
-    gst_caps_set_simple (caps, "palette_data", GST_TYPE_BUFFER, copy, NULL);
-    gst_buffer_unref (copy);
-  }
-
-  return caps;
-}
-
-GstCaps *
-gst_riff_create_video_caps (guint32 codec_fcc,
-    gst_riff_strh * strh, gst_riff_strf_vids * strf, char **codec_name)
-{
-  return gst_riff_create_video_caps_with_data (codec_fcc,
-      strh, strf, NULL, NULL, codec_name);
-}
-
-GstCaps *
-gst_riff_create_audio_caps_with_data (guint16 codec_id,
-    gst_riff_strh * strh, gst_riff_strf_auds * strf,
-    GstBuffer * strf_data, GstBuffer * strd_data, char **codec_name)
-{
-  gboolean block_align = FALSE, rate_chan = TRUE;
-  GstCaps *caps = NULL;
-  gint rate_min = 1000, rate_max = 96000;
-  gint channels_max = 2;
-
-  switch (codec_id) {
-    case GST_RIFF_WAVE_FORMAT_MPEGL3:  /* mp3 */
-      caps = gst_caps_new_simple ("audio/mpeg",
-          "mpegversion", G_TYPE_INT, 1, "layer", G_TYPE_INT, 3, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("MPEG 1 layer 3");
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_MPEGL12: /* mp1 or mp2 */
-      caps = gst_caps_new_simple ("audio/mpeg",
-          "mpegversion", G_TYPE_INT, 1, "layer", G_TYPE_INT, 2, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("MPEG 1 layer 2");
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_PCM:     /* PCM */
-      if (strf != NULL) {
-        gint ba = strf->blockalign;
-        gint ch = strf->channels;
-        gint ws = strf->size;
-
-        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_caps_from_string ("audio/x-raw-int, "
-            "endianness = (int) LITTLE_ENDIAN, "
-            "signed = (boolean) { true, false }, "
-            "width = (int) { 8, 16 }, " "depth = (int) { 8, 16 }");
-      }
-      if (codec_name)
-        *codec_name = g_strdup ("Uncompressed PCM audio");
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_ADPCM:
-      caps = gst_caps_new_simple ("audio/x-adpcm",
-          "layout", G_TYPE_STRING, "microsoft", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("ADPCM audio");
-      block_align = TRUE;
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_DVI_ADPCM:
-      caps = gst_caps_new_simple ("audio/x-adpcm",
-          "layout", G_TYPE_STRING, "dvi", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("DVI ADPCM audio");
-      block_align = TRUE;
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_MULAW:
-      if (strf != NULL && strf->size != 8) {
-        GST_WARNING ("invalid depth (%d) of mulaw audio, overwriting.",
-            strf->size);
-        strf->size = 8;
-        strf->av_bps = 8;
-        strf->blockalign = strf->av_bps * strf->channels;
-      }
-      if (strf != NULL && (strf->av_bps == 0 || strf->blockalign == 0)) {
-        GST_WARNING ("fixing av_bps (%d) and blockalign (%d) of mulaw audio",
-            strf->av_bps, strf->blockalign);
-        strf->av_bps = strf->size;
-        strf->blockalign = strf->av_bps * strf->channels;
-      }
-      caps = gst_caps_new_simple ("audio/x-mulaw", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Mulaw");
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_ALAW:
-      if (strf != NULL && strf->size != 8) {
-        GST_WARNING ("invalid depth (%d) of alaw audio, overwriting.",
-            strf->size);
-        strf->size = 8;
-        strf->av_bps = 8;
-        strf->blockalign = strf->av_bps * strf->channels;
-      }
-      if (strf != NULL && (strf->av_bps == 0 || strf->blockalign == 0)) {
-        GST_WARNING ("fixing av_bps (%d) and blockalign (%d) of alaw audio",
-            strf->av_bps, strf->blockalign);
-        strf->av_bps = strf->size;
-        strf->blockalign = strf->av_bps * strf->channels;
-      }
-      caps = gst_caps_new_simple ("audio/x-alaw", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Alaw");
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_VORBIS1: /* ogg/vorbis mode 1 */
-    case GST_RIFF_WAVE_FORMAT_VORBIS2: /* ogg/vorbis mode 2 */
-    case GST_RIFF_WAVE_FORMAT_VORBIS3: /* ogg/vorbis mode 3 */
-    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_caps_new_simple ("audio/x-vorbis", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Vorbis");
-      break;
-
-    case GST_RIFF_WAVE_FORMAT_A52:
-      channels_max = 6;
-      caps = gst_caps_new_simple ("audio/x-ac3", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("AC3");
-      break;
-    case GST_RIFF_WAVE_FORMAT_WMAV1:
-    case GST_RIFF_WAVE_FORMAT_WMAV2:
-    case GST_RIFF_WAVE_FORMAT_WMAV3:
-    {
-      gint version = (codec_id - GST_RIFF_WAVE_FORMAT_WMAV1) + 1;
-
-      channels_max = 6;
-
-      block_align = TRUE;
-
-      caps = gst_caps_new_simple ("audio/x-wma",
-          "wmaversion", G_TYPE_INT, version, NULL);
-
-      if (codec_name)
-        *codec_name = g_strdup_printf ("WMA Version %d", version);
-
-      if (strf != NULL) {
-        gst_caps_set_simple (caps,
-            "bitrate", G_TYPE_INT, strf->av_bps * 8, NULL);
-      } else {
-        gst_caps_set_simple (caps,
-            "bitrate", GST_TYPE_INT_RANGE, 0, G_MAXINT, NULL);
-      }
-      break;
-    }
-    case GST_RIFF_WAVE_FORMAT_SONY_ATRAC3:
-      caps = gst_caps_new_simple ("audio/x-vnd.sony.atrac3", NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Sony ATRAC3");
-      break;
-
-    default:
-      GST_WARNING ("Unknown audio tag 0x%04x", codec_id);
-      return NULL;
-  }
-
-  if (strf != NULL) {
-    if (rate_chan) {
-      gst_caps_set_simple (caps,
-          "rate", G_TYPE_INT, strf->rate,
-          "channels", G_TYPE_INT, strf->channels, NULL);
-    }
-    if (block_align) {
-      gst_caps_set_simple (caps,
-          "block_align", G_TYPE_INT, strf->blockalign, NULL);
-    }
-  } else {
-    if (rate_chan) {
-      gst_caps_set_simple (caps,
-          "rate", GST_TYPE_INT_RANGE, rate_min, rate_max,
-          "channels", GST_TYPE_INT_RANGE, 1, channels_max, NULL);
-    }
-    if (block_align) {
-      gst_caps_set_simple (caps,
-          "block_align", GST_TYPE_INT_RANGE, 1, G_MAXINT, NULL);
-    }
-  }
-
-  /* extradata */
-  if (strf_data || strd_data) {
-    gst_caps_set_simple (caps, "codec_data", GST_TYPE_BUFFER,
-        strf_data ? strf_data : strd_data, NULL);
-  }
-
-  return caps;
-}
-
-GstCaps *
-gst_riff_create_audio_caps (guint16 codec_id,
-    gst_riff_strh * strh, gst_riff_strf_auds * strf, char **codec_name)
-{
-  return gst_riff_create_audio_caps_with_data (codec_id,
-      strh, strf, NULL, NULL, codec_name);
-}
-
-GstCaps *
-gst_riff_create_iavs_caps (guint32 codec_fcc,
-    gst_riff_strh * strh, gst_riff_strf_iavs * strf, char **codec_name)
-{
-  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_caps_new_simple ("video/x-dv",
-          "systemstream", G_TYPE_BOOLEAN, TRUE, NULL);
-      if (codec_name)
-        *codec_name = g_strdup ("Generic DV");
-      break;
-
-    default:
-      GST_WARNING ("Unknown IAVS fourcc " GST_FOURCC_FORMAT,
-          GST_FOURCC_ARGS (codec_fcc));
-      return NULL;
-  }
-
-  return caps;
-}
-
-/*
- * Functions below are for template caps. All is variable.
- */
-
-GstCaps *
-gst_riff_create_video_template_caps (void)
-{
-  guint32 tags[] = {
-    GST_MAKE_FOURCC ('I', '4', '2', '0'),
-    GST_MAKE_FOURCC ('Y', 'U', 'Y', '2'),
-    GST_MAKE_FOURCC ('M', 'J', 'P', 'G'),
-    GST_MAKE_FOURCC ('D', 'V', 'S', 'D'),
-    GST_MAKE_FOURCC ('W', 'M', 'V', '1'),
-    GST_MAKE_FOURCC ('W', 'M', 'V', '2'),
-    GST_MAKE_FOURCC ('W', 'M', 'V', '3'),
-    GST_MAKE_FOURCC ('M', 'P', 'G', '4'),
-    GST_MAKE_FOURCC ('M', 'P', '4', '2'),
-    GST_MAKE_FOURCC ('M', 'P', '4', '3'),
-    GST_MAKE_FOURCC ('H', 'F', 'Y', 'U'),
-    GST_MAKE_FOURCC ('D', 'I', 'V', '3'),
-    GST_MAKE_FOURCC ('M', 'P', 'E', 'G'),
-    GST_MAKE_FOURCC ('H', '2', '6', '3'),
-    GST_MAKE_FOURCC ('I', '2', '6', '3'),
-    GST_MAKE_FOURCC ('h', '2', '6', '4'),
-    GST_MAKE_FOURCC ('D', 'I', 'V', 'X'),
-    GST_MAKE_FOURCC ('D', 'X', '5', '0'),
-    GST_MAKE_FOURCC ('X', 'V', 'I', 'D'),
-    GST_MAKE_FOURCC ('3', 'I', 'V', '1'),
-    GST_MAKE_FOURCC ('c', 'v', 'i', 'd'),
-    GST_MAKE_FOURCC ('m', 's', 'v', 'c'),
-    GST_MAKE_FOURCC ('R', 'L', 'E', ' '),
-    GST_MAKE_FOURCC ('D', 'I', 'B', ' '),
-    GST_MAKE_FOURCC ('X', 'x', 'a', 'n'),
-    GST_MAKE_FOURCC ('I', 'V', '5', '0'),
-    /* FILL ME */
-    0
-  };
-  guint i;
-  GstCaps *caps, *one;
-
-  caps = gst_caps_new_empty ();
-  for (i = 0; tags[i] != 0; i++) {
-    one = gst_riff_create_video_caps (tags[i], NULL, NULL, NULL);
-    if (one)
-      gst_caps_append (caps, one);
-  }
-
-  return caps;
-}
-
-GstCaps *
-gst_riff_create_audio_template_caps (void)
-{
-  guint16 tags[] = {
-    GST_RIFF_WAVE_FORMAT_MPEGL3,
-    GST_RIFF_WAVE_FORMAT_MPEGL12,
-    GST_RIFF_WAVE_FORMAT_PCM,
-    GST_RIFF_WAVE_FORMAT_VORBIS1,
-    GST_RIFF_WAVE_FORMAT_A52,
-    GST_RIFF_WAVE_FORMAT_ALAW,
-    GST_RIFF_WAVE_FORMAT_MULAW,
-    GST_RIFF_WAVE_FORMAT_ADPCM,
-    GST_RIFF_WAVE_FORMAT_DVI_ADPCM,
-    GST_RIFF_WAVE_FORMAT_WMAV1,
-    GST_RIFF_WAVE_FORMAT_WMAV2,
-    GST_RIFF_WAVE_FORMAT_WMAV3,
-    /* FILL ME */
-    0
-  };
-  guint i;
-  GstCaps *caps, *one;
-
-  caps = gst_caps_new_empty ();
-  for (i = 0; tags[i] != 0; i++) {
-    one = gst_riff_create_audio_caps (tags[i], NULL, NULL, NULL);
-    if (one)
-      gst_caps_append (caps, one);
-  }
-
-  return caps;
-}
-
-GstCaps *
-gst_riff_create_iavs_template_caps (void)
-{
-  guint32 tags[] = {
-    GST_MAKE_FOURCC ('D', 'V', 'S', 'D'),
-    /* FILL ME */
-    0
-  };
-  guint i;
-  GstCaps *caps, *one;
-
-  caps = gst_caps_new_empty ();
-  for (i = 0; tags[i] != 0; i++) {
-    one = gst_riff_create_iavs_caps (tags[i], NULL, NULL, NULL);
-    if (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
deleted file mode 100644
index 6ff3ea1b..00000000
--- a/gst-libs/gst/riff/riff-media.h
+++ /dev/null
@@ -1,77 +0,0 @@
-/* GStreamer RIFF I/O
- * Copyright (C) 2003 Ronald Bultje <rbultje@ronald.bitfreak.net>
- *
- * riff-media.h: RIFF-id to/from caps routines
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#ifndef __GST_RIFF_MEDIA_H__
-#define __GST_RIFF_MEDIA_H__
-
-#include <glib.h>
-#include <gst/gst.h>
-#include "riff-ids.h"
-
-G_BEGIN_DECLS
-
-/*
- * Create one caps. strh/strf can be NULL (for non-fixed caps).
- */
-
-GstCaps *gst_riff_create_video_caps (guint32             codec_fcc,
-				     gst_riff_strh      *strh,
-				     gst_riff_strf_vids *strf,
-				     char **codec_name);
-GstCaps *gst_riff_create_audio_caps (guint16             codec_id,
-				     gst_riff_strh      *strh,
-				     gst_riff_strf_auds *strf,
-				     char **codec_name);
-GstCaps *gst_riff_create_iavs_caps  (guint32             codec_fcc,
-				     gst_riff_strh      *strh,
-				     gst_riff_strf_iavs *strf,
-				     char **codec_name);
-
-/*
- * Extended...
- */
-
-GstCaps *
-gst_riff_create_video_caps_with_data (guint32              codec_fcc,
-				      gst_riff_strh      * strh,
-				      gst_riff_strf_vids * strf,
-				      GstBuffer          * strf_data,
-				      GstBuffer          * strd_data,
-				      char              ** codec_name);
-
-GstCaps *
-gst_riff_create_audio_caps_with_data (guint16              codec_id,
-				      gst_riff_strh      * strh,
-				      gst_riff_strf_auds * strf,
-				      GstBuffer          * strf_data,
-				      GstBuffer          * strd_data,
-				      char              ** codec_name);
-/*
- * Create template caps (includes all known types).
- */
-
-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
-
-#endif /* __GST_RIFF_READ_H__ */
diff --git a/gst-libs/gst/riff/riff-read.c b/gst-libs/gst/riff/riff-read.c
deleted file mode 100644
index 21cdbbca..00000000
--- a/gst-libs/gst/riff/riff-read.c
+++ /dev/null
@@ -1,1016 +0,0 @@
-/* GStreamer RIFF I/O
- * Copyright (C) 2003 Ronald Bultje <rbultje@ronald.bitfreak.net>
- *
- * riff-read.c: RIFF input file parsing
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <string.h>
-#include <gst/gstutils.h>
-
-#include "riff-ids.h"
-#include "riff-read.h"
-
-GST_DEBUG_CATEGORY_STATIC (riffread_debug);
-#define GST_CAT_DEFAULT riffread_debug
-
-enum
-{
-  ARG_0,
-  ARG_METADATA
-      /* FILL ME */
-};
-
-static void gst_riff_read_class_init (GstRiffReadClass * klass);
-static void gst_riff_read_init (GstRiffRead * riff);
-
-static GstElementStateReturn gst_riff_read_change_state (GstElement * element);
-
-static GstElementClass *parent_class = NULL;
-
-GType
-gst_riff_read_get_type (void)
-{
-  static GType gst_riff_read_type = 0;
-
-  if (!gst_riff_read_type) {
-    static const GTypeInfo gst_riff_read_info = {
-      sizeof (GstRiffReadClass),
-      NULL,
-      NULL,
-      (GClassInitFunc) gst_riff_read_class_init,
-      NULL,
-      NULL,
-      sizeof (GstRiffRead),
-      0,
-      (GInstanceInitFunc) gst_riff_read_init,
-    };
-
-    gst_riff_read_type =
-        g_type_register_static (GST_TYPE_ELEMENT, "GstRiffRead",
-        &gst_riff_read_info, 0);
-  }
-
-  return gst_riff_read_type;
-}
-
-static void
-gst_riff_read_class_init (GstRiffReadClass * klass)
-{
-  GstElementClass *gstelement_class = GST_ELEMENT_CLASS (klass);
-
-  parent_class = g_type_class_ref (GST_TYPE_ELEMENT);
-
-  GST_DEBUG_CATEGORY_INIT (riffread_debug, "riffread",
-      0, "RIFF stream helper class");
-
-  gstelement_class->change_state = gst_riff_read_change_state;
-}
-
-static void
-gst_riff_read_init (GstRiffRead * riff)
-{
-  riff->sinkpad = NULL;
-  riff->bs = NULL;
-  riff->level = NULL;
-}
-
-static GstElementStateReturn
-gst_riff_read_change_state (GstElement * element)
-{
-  GstRiffRead *riff = GST_RIFF_READ (element);
-
-  switch (GST_STATE_TRANSITION (element)) {
-    case GST_STATE_READY_TO_PAUSED:
-      if (!riff->sinkpad)
-        return GST_STATE_FAILURE;
-      riff->bs = gst_bytestream_new (riff->sinkpad);
-      break;
-    case GST_STATE_PAUSED_TO_READY:
-      gst_bytestream_destroy (riff->bs);
-      while (riff->level) {
-        GstRiffLevel *level = riff->level->data;
-
-        riff->level = g_list_remove (riff->level, level);
-        g_free (level);
-      }
-      break;
-    default:
-      break;
-  }
-
-  if (GST_ELEMENT_CLASS (parent_class)->change_state)
-    return GST_ELEMENT_CLASS (parent_class)->change_state (element);
-
-  return GST_STATE_SUCCESS;
-}
-
-/*
- * Return: the amount of levels in the hierarchy that the
- * current element lies higher than the previous one.
- * The opposite isn't done - that's auto-done using list
- * element reading.
- */
-
-static guint
-gst_riff_read_element_level_up (GstRiffRead * riff)
-{
-  guint num = 0;
-  guint64 pos = gst_bytestream_tell (riff->bs);
-
-  while (riff->level != NULL) {
-    GList *last = g_list_last (riff->level);
-    GstRiffLevel *level = last->data;
-
-    if (pos >= level->start + level->length) {
-      riff->level = g_list_remove (riff->level, level);
-      g_free (level);
-      num++;
-    } else
-      break;
-  }
-
-  return num;
-}
-
-/*
- * Event handler. Basic:
- * - EOS: end-of-file, stop processing, forward EOS.
- * - Interrupt: stop processing.
- * - Discont: shouldn't be handled here but in the seek handler. Error.
- * - Flush: ignore, since we check for flush flags manually. Don't forward.
- * - Others: warn, ignore.
- * Return value indicates whether to continue processing.
- */
-
-static gboolean
-gst_riff_read_use_event (GstRiffRead * riff, GstEvent * event)
-{
-  if (!event) {
-    GST_ELEMENT_ERROR (riff, RESOURCE, READ, (NULL), (NULL));
-    return FALSE;
-  }
-
-  switch (GST_EVENT_TYPE (event)) {
-    case GST_EVENT_EOS:
-      gst_pad_event_default (riff->sinkpad, event);
-      return FALSE;
-
-    case GST_EVENT_INTERRUPT:
-      gst_event_unref (event);
-      return FALSE;
-
-    case GST_EVENT_DISCONTINUOUS:
-      GST_WARNING_OBJECT (riff, "Unexpected discont - might lose sync");
-      gst_event_unref (event);
-      return TRUE;
-
-    case GST_EVENT_FLUSH:
-      gst_event_unref (event);
-      return TRUE;
-
-    default:
-      GST_WARNING ("don't know how to handle event %d", GST_EVENT_TYPE (event));
-      gst_pad_event_default (riff->sinkpad, event);
-      return TRUE;
-  }
-
-  /* happy */
-  g_assert_not_reached ();
-  return FALSE;
-}
-
-static gboolean
-gst_riff_read_handle_event (GstRiffRead * riff)
-{
-  GstEvent *event = NULL;
-  guint32 remaining;
-
-  gst_bytestream_get_status (riff->bs, &remaining, &event);
-
-  return gst_riff_read_use_event (riff, event);
-}
-
-/*
- * Read the next tag plus length (may be NULL). Return
- * TRUE on success or FALSE on failure.
- */
-
-gboolean
-gst_riff_peek_head (GstRiffRead * riff,
-    guint32 * tag, guint32 * length, guint * level_up)
-{
-  GList *last;
-  guint8 *data;
-
-  /* if we're at the end of a chunk, but unaligned, then re-align.
-   * Those are essentially broken files, but unfortunately they
-   * exist. */
-  if ((last = g_list_last (riff->level)) != NULL) {
-    GstRiffLevel *level = last->data;
-    guint64 pos = gst_bytestream_tell (riff->bs);
-
-    if (level->start + level->length - pos < 8) {
-      if (!gst_bytestream_flush (riff->bs, level->start + level->length - pos)) {
-        GST_ELEMENT_ERROR (riff, RESOURCE, READ, (NULL), (NULL));
-        return FALSE;
-      }
-    }
-  }
-
-  /* read */
-  while (gst_bytestream_peek_bytes (riff->bs, &data, 8) != 8) {
-    if (!gst_riff_read_handle_event (riff))
-      return FALSE;
-  }
-
-  /* parse tag + length (if wanted) */
-  *tag = GST_READ_UINT32_LE (data);
-  if (length)
-    *length = GST_READ_UINT32_LE (((guint32 *) data) + 1);
-
-  /* level */
-  if (level_up)
-    *level_up = gst_riff_read_element_level_up (riff);
-
-  return TRUE;
-}
-
-/*
- * Read: the actual data (plus alignment and flush).
- * Return: the data, as a GstBuffer.
- */
-
-GstBuffer *
-gst_riff_peek_element_data (GstRiffRead * riff, guint length, guint * got_bytes)
-{
-  GstBuffer *buf = NULL;
-  guint32 got;
-
-  while ((got = gst_bytestream_peek (riff->bs, &buf, length)) != length) {
-    if (buf)
-      gst_buffer_unref (buf);
-    if (!gst_riff_read_handle_event (riff))
-      return NULL;
-  }
-
-  if (got_bytes)
-    *got_bytes = got;
-
-  return buf;
-}
-
-GstBuffer *
-gst_riff_read_element_data (GstRiffRead * riff, guint length, guint * got_bytes)
-{
-  GstBuffer *buf;
-
-  if (!(buf = gst_riff_peek_element_data (riff, length, got_bytes)))
-    return NULL;
-
-  /* we need 16-bit alignment */
-  if (length & 1)
-    length++;
-
-  if (!gst_bytestream_flush (riff->bs, length)) {
-    gst_buffer_unref (buf);
-    return NULL;
-  }
-
-  return buf;
-}
-
-/*
- * Seek.
- */
-
-GstEvent *
-gst_riff_read_seek (GstRiffRead * riff, guint64 offset)
-{
-  guint64 length = gst_bytestream_length (riff->bs);
-  guint32 remaining;
-  GstEvent *event = NULL;
-  guchar *data;
-
-  /* hack for AVI files with broken idx1 size chunk markers */
-  if (offset > length)
-    offset = length;
-
-  /* first, flush remaining buffers */
-  gst_bytestream_get_status (riff->bs, &remaining, &event);
-  if (event) {
-    GST_WARNING ("Unexpected event before seek");
-    if (!gst_riff_read_use_event (riff, event))
-      return NULL;
-    event = NULL;
-  }
-
-  if (remaining)
-    gst_bytestream_flush_fast (riff->bs, remaining);
-
-  /* now seek */
-  if (!gst_bytestream_seek (riff->bs, offset, GST_SEEK_METHOD_SET)) {
-    GST_ELEMENT_ERROR (riff, RESOURCE, SEEK, (NULL), (NULL));
-    return NULL;
-  }
-
-  /* and now, peek a new byte. This will fail because there's a
-   * pending event. Then, take the event and return it. */
-  while (!event) {
-    if (gst_bytestream_peek_bytes (riff->bs, &data, 1)) {
-      GST_WARNING ("Unexpected data after seek - this means seek failed");
-      break;
-    }
-
-    /* get the discont event and return */
-    gst_bytestream_get_status (riff->bs, &remaining, &event);
-    if (!event) {
-      GST_WARNING ("No discontinuity event after seek - seek failed");
-      break;
-    } else if (GST_EVENT_TYPE (event) != GST_EVENT_DISCONTINUOUS) {
-      if (!gst_riff_read_use_event (riff, event))
-        return NULL;
-      event = NULL;
-    }
-  }
-
-  return event;
-}
-
-/*
- * Gives the tag of the next RIFF element.
- */
-
-guint32
-gst_riff_peek_tag (GstRiffRead * riff, guint * level_up)
-{
-  guint32 tag;
-
-  if (!gst_riff_peek_head (riff, &tag, NULL, level_up))
-    return 0;
-
-  return tag;
-}
-
-/*
- * Gives the tag of the next LIST/RIFF element.
- */
-
-guint32
-gst_riff_peek_list (GstRiffRead * riff)
-{
-  guint32 lst;
-  guint8 *data;
-
-  if (!gst_riff_peek_head (riff, &lst, NULL, NULL))
-    return FALSE;
-  if (lst != GST_RIFF_TAG_LIST) {
-    g_warning ("Not a LIST object");
-    return 0;
-  }
-
-  if (gst_bytestream_peek_bytes (riff->bs, &data, 12) != 12) {
-    GST_ELEMENT_ERROR (riff, RESOURCE, READ, (NULL), (NULL));
-    return 0;
-  }
-
-  return GST_READ_UINT32_LE (((guint32 *) data) + 2);
-}
-
-/*
- * Don't read data.
- */
-
-gboolean
-gst_riff_read_skip (GstRiffRead * riff)
-{
-  guint32 tag, length;
-  GstEvent *event = NULL;
-  guint32 remaining;
-
-  if (!gst_riff_peek_head (riff, &tag, &length, NULL))
-    return FALSE;
-
-  /* 16-bit alignment */
-  if (length & 1)
-    length++;
-
-  /* header itself */
-  length += 8;
-
-  /* see if we have that much data available */
-  gst_bytestream_get_status (riff->bs, &remaining, &event);
-  if (event) {
-    GST_WARNING ("Unexpected event in skip");
-    if (!gst_riff_read_use_event (riff, event))
-      return FALSE;
-  }
-
-  /* yes */
-  if (remaining >= length) {
-    gst_bytestream_flush_fast (riff->bs, length);
-    return TRUE;
-  }
-
-  /* no */
-  if (!(event = gst_riff_read_seek (riff,
-              gst_bytestream_tell (riff->bs) + length)))
-    return FALSE;
-
-  gst_event_unref (event);
-
-  return TRUE;
-}
-
-/*
- * Read any type of data.
- */
-
-gboolean
-gst_riff_read_data (GstRiffRead * riff, guint32 * tag, GstBuffer ** buf)
-{
-  guint32 length;
-
-  if (!gst_riff_peek_head (riff, tag, &length, NULL))
-    return FALSE;
-  gst_bytestream_flush_fast (riff->bs, 8);
-
-  return ((*buf = gst_riff_read_element_data (riff, length, NULL)) != NULL);
-}
-
-/*
- * Read a string.
- */
-
-gboolean
-gst_riff_read_ascii (GstRiffRead * riff, guint32 * tag, gchar ** str)
-{
-  GstBuffer *buf;
-
-  if (!gst_riff_read_data (riff, tag, &buf))
-    return FALSE;
-
-  *str = g_malloc (GST_BUFFER_SIZE (buf) + 1);
-  memcpy (*str, GST_BUFFER_DATA (buf), GST_BUFFER_SIZE (buf));
-  (*str)[GST_BUFFER_SIZE (buf)] = '\0';
-
-  gst_buffer_unref (buf);
-
-  return TRUE;
-}
-
-/*
- * Read media structs.
- */
-
-gboolean
-gst_riff_read_strh (GstRiffRead * riff, gst_riff_strh ** header)
-{
-  guint32 tag;
-  GstBuffer *buf;
-  gst_riff_strh *strh;
-
-  if (!gst_riff_read_data (riff, &tag, &buf))
-    return FALSE;
-
-  if (tag != GST_RIFF_TAG_strh) {
-    g_warning ("Not a strh chunk");
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-  if (GST_BUFFER_SIZE (buf) < sizeof (gst_riff_strh)) {
-    GST_WARNING ("Too small strh (%d available, %d needed)",
-        GST_BUFFER_SIZE (buf), (int) sizeof (gst_riff_strh));
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-
-  strh = g_memdup (GST_BUFFER_DATA (buf), GST_BUFFER_SIZE (buf));
-  gst_buffer_unref (buf);
-
-#if (G_BYTE_ORDER == G_BIG_ENDIAN)
-  strh->type = GUINT32_FROM_LE (strh->type);
-  strh->fcc_handler = GUINT32_FROM_LE (strh->fcc_handler);
-  strh->flags = GUINT32_FROM_LE (strh->flags);
-  strh->priority = GUINT32_FROM_LE (strh->priority);
-  strh->init_frames = GUINT32_FROM_LE (strh->init_frames);
-  strh->scale = GUINT32_FROM_LE (strh->scale);
-  strh->rate = GUINT32_FROM_LE (strh->rate);
-  strh->start = GUINT32_FROM_LE (strh->start);
-  strh->length = GUINT32_FROM_LE (strh->length);
-  strh->bufsize = GUINT32_FROM_LE (strh->bufsize);
-  strh->quality = GUINT32_FROM_LE (strh->quality);
-  strh->samplesize = GUINT32_FROM_LE (strh->samplesize);
-#endif
-
-  /* avoid divisions by zero */
-  if (!strh->scale)
-    strh->scale = 1;
-  if (!strh->rate)
-    strh->rate = 1;
-
-  /* debug */
-  GST_INFO ("strh tag found");
-  GST_INFO (" type        " GST_FOURCC_FORMAT, GST_FOURCC_ARGS (strh->type));
-  GST_INFO (" fcc_handler " GST_FOURCC_FORMAT,
-      GST_FOURCC_ARGS (strh->fcc_handler));
-  GST_INFO (" flags       0x%08x", strh->flags);
-  GST_INFO (" priority    %d", strh->priority);
-  GST_INFO (" init_frames %d", strh->init_frames);
-  GST_INFO (" scale       %d", strh->scale);
-  GST_INFO (" rate        %d", strh->rate);
-  GST_INFO (" start       %d", strh->start);
-  GST_INFO (" length      %d", strh->length);
-  GST_INFO (" bufsize     %d", strh->bufsize);
-  GST_INFO (" quality     %d", strh->quality);
-  GST_INFO (" samplesize  %d", strh->samplesize);
-
-  *header = strh;
-
-  return TRUE;
-}
-
-gboolean
-gst_riff_read_strf_vids_with_data (GstRiffRead * riff,
-    gst_riff_strf_vids ** header, GstBuffer ** extradata)
-{
-  guint32 tag;
-  GstBuffer *buf;
-  gst_riff_strf_vids *strf;
-
-  if (!gst_riff_read_data (riff, &tag, &buf))
-    return FALSE;
-
-  if (tag != GST_RIFF_TAG_strf) {
-    g_warning ("Not a strf chunk");
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-  if (GST_BUFFER_SIZE (buf) < sizeof (gst_riff_strf_vids)) {
-    GST_WARNING ("Too small strf_vids (%d available, %d needed)",
-        GST_BUFFER_SIZE (buf), (int) sizeof (gst_riff_strf_vids));
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-
-  strf = g_memdup (GST_BUFFER_DATA (buf), GST_BUFFER_SIZE (buf));
-
-#if (G_BYTE_ORDER == G_BIG_ENDIAN)
-  strf->size = GUINT32_FROM_LE (strf->size);
-  strf->width = GUINT32_FROM_LE (strf->width);
-  strf->height = GUINT32_FROM_LE (strf->height);
-  strf->planes = GUINT16_FROM_LE (strf->planes);
-  strf->bit_cnt = GUINT16_FROM_LE (strf->bit_cnt);
-  strf->compression = GUINT32_FROM_LE (strf->compression);
-  strf->image_size = GUINT32_FROM_LE (strf->image_size);
-  strf->xpels_meter = GUINT32_FROM_LE (strf->xpels_meter);
-  strf->ypels_meter = GUINT32_FROM_LE (strf->ypels_meter);
-  strf->num_colors = GUINT32_FROM_LE (strf->num_colors);
-  strf->imp_colors = GUINT32_FROM_LE (strf->imp_colors);
-#endif
-
-  /* size checking */
-  *extradata = NULL;
-  if (strf->size > GST_BUFFER_SIZE (buf)) {
-    g_warning ("strf_vids header gave %d bytes data, only %d available",
-        strf->size, GST_BUFFER_SIZE (buf));
-    strf->size = GST_BUFFER_SIZE (buf);
-  } else if (strf->size < GST_BUFFER_SIZE (buf)) {
-    gint len;
-
-    len = GST_BUFFER_SIZE (buf) - strf->size;
-    if (len > 0) {
-      *extradata = gst_buffer_create_sub (buf, strf->size, len);
-    }
-  } else if (strf->size > sizeof (gst_riff_strf_vids)) {
-    *extradata = gst_buffer_create_sub (buf,
-        sizeof (gst_riff_strf_vids), strf->size - sizeof (gst_riff_strf_vids));
-  }
-
-  /* debug */
-  GST_INFO ("strf tag found in context vids:");
-  GST_INFO (" size        %d", strf->size);
-  GST_INFO (" width       %d", strf->width);
-  GST_INFO (" height      %d", strf->height);
-  GST_INFO (" planes      %d", strf->planes);
-  GST_INFO (" bit_cnt     %d", strf->bit_cnt);
-  GST_INFO (" compression " GST_FOURCC_FORMAT,
-      GST_FOURCC_ARGS (strf->compression));
-  GST_INFO (" image_size  %d", strf->image_size);
-  GST_INFO (" xpels_meter %d", strf->xpels_meter);
-  GST_INFO (" ypels_meter %d", strf->ypels_meter);
-  GST_INFO (" num_colors  %d", strf->num_colors);
-  GST_INFO (" imp_colors  %d", strf->imp_colors);
-  if (*extradata)
-    GST_INFO (" %d bytes extra_data", GST_BUFFER_SIZE (*extradata));
-
-  gst_buffer_unref (buf);
-
-  *header = strf;
-
-  return TRUE;
-}
-
-/*
- * Obsolete, use gst_riff_read_strf_vids_with_data ().
- */
-gboolean
-gst_riff_read_strf_vids (GstRiffRead * riff, gst_riff_strf_vids ** header)
-{
-  GstBuffer *data = NULL;
-  gboolean ret;
-
-  ret = gst_riff_read_strf_vids_with_data (riff, header, &data);
-  if (data)
-    gst_buffer_unref (data);
-
-  return ret;
-}
-
-gboolean
-gst_riff_read_strf_auds_with_data (GstRiffRead * riff,
-    gst_riff_strf_auds ** header, GstBuffer ** extradata)
-{
-  guint32 tag;
-  GstBuffer *buf;
-  gst_riff_strf_auds *strf;
-
-  if (!gst_riff_read_data (riff, &tag, &buf))
-    return FALSE;
-
-  if (tag != GST_RIFF_TAG_strf && tag != GST_RIFF_TAG_fmt) {
-    g_warning ("Not a strf chunk");
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-  if (GST_BUFFER_SIZE (buf) < sizeof (gst_riff_strf_auds)) {
-    GST_WARNING ("Too small strf_auds (%d available, %d needed)",
-        GST_BUFFER_SIZE (buf), (int) sizeof (gst_riff_strf_auds));
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-
-  strf = g_memdup (GST_BUFFER_DATA (buf), GST_BUFFER_SIZE (buf));
-
-#if (G_BYTE_ORDER == G_BIG_ENDIAN)
-  strf->format = GUINT16_FROM_LE (strf->format);
-  strf->channels = GUINT16_FROM_LE (strf->channels);
-  strf->rate = GUINT32_FROM_LE (strf->rate);
-  strf->av_bps = GUINT32_FROM_LE (strf->av_bps);
-  strf->blockalign = GUINT16_FROM_LE (strf->blockalign);
-  strf->size = GUINT16_FROM_LE (strf->size);
-#endif
-
-  /* size checking */
-  *extradata = NULL;
-  if (GST_BUFFER_SIZE (buf) > sizeof (gst_riff_strf_auds) + 2) {
-    gint len;
-
-    len = GST_READ_UINT16_LE (&GST_BUFFER_DATA (buf)[16]);
-    if (len + 2 + sizeof (gst_riff_strf_auds) > GST_BUFFER_SIZE (buf)) {
-      GST_WARNING ("Extradata indicated %d bytes, but only %d available",
-          len, GST_BUFFER_SIZE (buf) - 2 - sizeof (gst_riff_strf_auds));
-      len = GST_BUFFER_SIZE (buf) - 2 - sizeof (gst_riff_strf_auds);
-    }
-    if (len > 0) {
-      *extradata = gst_buffer_create_sub (buf,
-          sizeof (gst_riff_strf_auds) + 2, len);
-    }
-  }
-
-  /* debug */
-  GST_INFO ("strf tag found in context auds:");
-  GST_INFO (" format      %d", strf->format);
-  GST_INFO (" channels    %d", strf->channels);
-  GST_INFO (" rate        %d", strf->rate);
-  GST_INFO (" av_bps      %d", strf->av_bps);
-  GST_INFO (" blockalign  %d", strf->blockalign);
-  GST_INFO (" size        %d", strf->size);     /* wordsize, not extrasize! */
-  if (*extradata)
-    GST_INFO (" %d bytes extra_data", GST_BUFFER_SIZE (*extradata));
-
-  gst_buffer_unref (buf);
-
-  *header = strf;
-
-  return TRUE;
-}
-
-/*
- * Obsolete, use gst_riff_read_strf_auds_with_data ().
- */
-gboolean
-gst_riff_read_strf_auds (GstRiffRead * riff, gst_riff_strf_auds ** header)
-{
-  GstBuffer *data = NULL;
-  gboolean ret;
-
-  ret = gst_riff_read_strf_auds_with_data (riff, header, &data);
-  if (data)
-    gst_buffer_unref (data);
-
-  return ret;
-}
-
-gboolean
-gst_riff_read_strf_iavs (GstRiffRead * riff, gst_riff_strf_iavs ** header)
-{
-  guint32 tag;
-  GstBuffer *buf;
-  gst_riff_strf_iavs *strf;
-
-  if (!gst_riff_read_data (riff, &tag, &buf))
-    return FALSE;
-
-  if (tag != GST_RIFF_TAG_strf) {
-    g_warning ("Not a strf chunk");
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-  if (GST_BUFFER_SIZE (buf) < sizeof (gst_riff_strf_iavs)) {
-    GST_WARNING ("Too small strf_iavs (%d available, %d needed)",
-        GST_BUFFER_SIZE (buf), (int) sizeof (gst_riff_strf_iavs));
-    gst_buffer_unref (buf);
-    return FALSE;
-  }
-
-  strf = g_memdup (GST_BUFFER_DATA (buf), GST_BUFFER_SIZE (buf));
-  gst_buffer_unref (buf);
-
-#if (G_BYTE_ORDER == G_BIG_ENDIAN)
-  strf->DVAAuxSrc = GUINT32_FROM_LE (strf->DVAAuxSrc);
-  strf->DVAAuxCtl = GUINT32_FROM_LE (strf->DVAAuxCtl);
-  strf->DVAAuxSrc1 = GUINT32_FROM_LE (strf->DVAAuxSrc1);
-  strf->DVAAuxCtl1 = GUINT32_FROM_LE (strf->DVAAuxCtl1);
-  strf->DVVAuxSrc = GUINT32_FROM_LE (strf->DVVAuxSrc);
-  strf->DVVAuxCtl = GUINT32_FROM_LE (strf->DVVAuxCtl);
-  strf->DVReserved1 = GUINT32_FROM_LE (strf->DVReserved1);
-  strf->DVReserved2 = GUINT32_FROM_LE (strf->DVReserved2);
-#endif
-
-  /* debug */
-  GST_INFO ("strf tag found in context iavs");
-  GST_INFO (" DVAAuxSrc   %08x", strf->DVAAuxSrc);
-  GST_INFO (" DVAAuxCtl   %08x", strf->DVAAuxCtl);
-  GST_INFO (" DVAAuxSrc1  %08x", strf->DVAAuxSrc1);
-  GST_INFO (" DVAAuxCtl1  %08x", strf->DVAAuxCtl1);
-  GST_INFO (" DVVAuxSrc   %08x", strf->DVVAuxSrc);
-  GST_INFO (" DVVAuxCtl   %08x", strf->DVVAuxCtl);
-  GST_INFO (" DVReserved1 %08x", strf->DVReserved1);
-  GST_INFO (" DVReserved2 %08x", strf->DVReserved2);
-
-  *header = strf;
-
-  return TRUE;
-}
-
-/*
- * Read a list.
- */
-
-gboolean
-gst_riff_read_list (GstRiffRead * riff, guint32 * tag)
-{
-  guint32 length, lst;
-  GstRiffLevel *level;
-  guint8 *data;
-
-  if (!gst_riff_peek_head (riff, &lst, &length, NULL))
-    return FALSE;
-  if (lst != GST_RIFF_TAG_LIST) {
-    g_warning ("Not a LIST object");
-    return FALSE;
-  }
-  gst_bytestream_flush_fast (riff->bs, 8);
-  if (gst_bytestream_peek_bytes (riff->bs, &data, 4) != 4) {
-    GST_ELEMENT_ERROR (riff, RESOURCE, READ, (NULL), (NULL));
-    return FALSE;
-  }
-  gst_bytestream_flush_fast (riff->bs, 4);
-  *tag = GST_READ_UINT32_LE (data);
-
-  /* remember level */
-  level = g_new (GstRiffLevel, 1);
-  level->start = gst_bytestream_tell (riff->bs);
-  level->length = length - 4;
-  riff->level = g_list_append (riff->level, level);
-
-  return TRUE;
-}
-
-/*
- * Utility function for reading metadata in a RIFF file.
- */
-
-gboolean
-gst_riff_read_info (GstRiffRead * riff)
-{
-  guint32 tag;
-  guint64 end;
-  GstRiffLevel *level;
-  GList *last;
-  gchar *name, *type;
-  GstTagList *taglist;
-  gboolean have_tags = FALSE;
-
-  /* What we're doing here is ugly (oh no!); we look
-   * at our LIST tag size and assure that we do not
-   * cross boundaries. This is to maintain the level
-   * counter for the client app. */
-  last = g_list_last (riff->level);
-  level = last->data;
-  riff->level = g_list_remove (riff->level, level);
-  end = level->start + level->length;
-  g_free (level);
-
-  taglist = gst_tag_list_new ();
-
-  while (gst_bytestream_tell (riff->bs) < end) {
-    if (!gst_riff_peek_head (riff, &tag, NULL, NULL)) {
-      return FALSE;
-    }
-
-    /* find out the type of metadata */
-    switch (tag) {
-      case GST_RIFF_INFO_IARL:
-        type = GST_TAG_LOCATION;
-        break;
-      case GST_RIFF_INFO_IART:
-        type = GST_TAG_ARTIST;
-        break;
-      case GST_RIFF_INFO_ICMS:
-        type = NULL;            /*"Commissioner"; */
-        break;
-      case GST_RIFF_INFO_ICMT:
-        type = GST_TAG_COMMENT;
-        break;
-      case GST_RIFF_INFO_ICOP:
-        type = GST_TAG_COPYRIGHT;
-        break;
-      case GST_RIFF_INFO_ICRD:
-        type = GST_TAG_DATE;
-        break;
-      case GST_RIFF_INFO_ICRP:
-        type = NULL;            /*"Cropped"; */
-        break;
-      case GST_RIFF_INFO_IDIM:
-        type = NULL;            /*"Dimensions"; */
-        break;
-      case GST_RIFF_INFO_IDPI:
-        type = NULL;            /*"Dots per Inch"; */
-        break;
-      case GST_RIFF_INFO_IENG:
-        type = NULL;            /*"Engineer"; */
-        break;
-      case GST_RIFF_INFO_IGNR:
-        type = GST_TAG_GENRE;
-        break;
-      case GST_RIFF_INFO_IKEY:
-        type = NULL; /*"Keywords"; */ ;
-        break;
-      case GST_RIFF_INFO_ILGT:
-        type = NULL;            /*"Lightness"; */
-        break;
-      case GST_RIFF_INFO_IMED:
-        type = NULL;            /*"Medium"; */
-        break;
-      case GST_RIFF_INFO_INAM:
-        type = GST_TAG_TITLE;
-        break;
-      case GST_RIFF_INFO_IPLT:
-        type = NULL;            /*"Palette"; */
-        break;
-      case GST_RIFF_INFO_IPRD:
-        type = NULL;            /*"Product"; */
-        break;
-      case GST_RIFF_INFO_ISBJ:
-        type = NULL;            /*"Subject"; */
-        break;
-      case GST_RIFF_INFO_ISFT:
-        type = GST_TAG_ENCODER;
-        break;
-      case GST_RIFF_INFO_ISHP:
-        type = NULL;            /*"Sharpness"; */
-        break;
-      case GST_RIFF_INFO_ISRC:
-        type = GST_TAG_ISRC;
-        break;
-      case GST_RIFF_INFO_ISRF:
-        type = NULL;            /*"Source Form"; */
-        break;
-      case GST_RIFF_INFO_ITCH:
-        type = NULL;            /*"Technician"; */
-        break;
-      default:
-        type = NULL;
-        GST_WARNING ("Unknown INFO (metadata) tag entry " GST_FOURCC_FORMAT,
-            GST_FOURCC_ARGS (tag));
-        break;
-    }
-
-    if (type) {
-      name = NULL;
-      if (!gst_riff_read_ascii (riff, &tag, &name)) {
-        return FALSE;
-      }
-
-      if (name && name[0] != '\0') {
-        GValue src = { 0 }
-        , dest = {
-        0};
-        GType dest_type = gst_tag_get_type (type);
-
-        have_tags = TRUE;
-        g_value_init (&src, G_TYPE_STRING);
-        g_value_set_string (&src, name);
-        g_value_init (&dest, dest_type);
-        g_value_transform (&src, &dest);
-        g_value_unset (&src);
-        gst_tag_list_add_values (taglist, GST_TAG_MERGE_APPEND,
-            type, &dest, NULL);
-        g_value_unset (&dest);
-      }
-      g_free (name);
-    } else {
-      gst_riff_read_skip (riff);
-    }
-  }
-
-  if (have_tags) {
-    GstElement *element = GST_ELEMENT (riff);
-    GstEvent *event = gst_event_new_tag (taglist);
-    const GList *padlist;
-
-    /* let the world know about this wonderful thing */
-    for (padlist = gst_element_get_pad_list (element);
-        padlist != NULL; padlist = padlist->next) {
-      if (GST_PAD_IS_SRC (padlist->data) && GST_PAD_IS_USABLE (padlist->data)) {
-        gst_event_ref (event);
-        gst_pad_push (GST_PAD (padlist->data), GST_DATA (event));
-      }
-    }
-
-    gst_element_found_tags (element, taglist);
-
-    gst_event_unref (event);
-  } else {
-    gst_tag_list_free (taglist);
-  }
-
-  return TRUE;
-}
-
-/*
- * Read RIFF header and document type.
- */
-
-gboolean
-gst_riff_read_header (GstRiffRead * riff, guint32 * doctype)
-{
-  GstRiffLevel *level;
-  guint32 tag, length;
-  guint8 *data;
-
-  /* We ignore size for openDML-2.0 support */
-  if (!gst_riff_peek_head (riff, &tag, &length, NULL))
-    return FALSE;
-  if (tag != GST_RIFF_TAG_RIFF) {
-    GST_ELEMENT_ERROR (riff, STREAM, WRONG_TYPE, (NULL), (NULL));
-    return FALSE;
-  }
-  gst_bytestream_flush_fast (riff->bs, 8);
-
-  /* doctype */
-  if (gst_bytestream_peek_bytes (riff->bs, &data, 4) != 4) {
-    GST_ELEMENT_ERROR (riff, RESOURCE, READ, (NULL), (NULL));
-    return FALSE;
-  }
-  gst_bytestream_flush_fast (riff->bs, 4);
-  *doctype = GST_READ_UINT32_LE (data);
-
-  /* remember level */
-  level = g_new (GstRiffLevel, 1);
-  level->start = gst_bytestream_tell (riff->bs);
-  level->length = length - 4;
-  riff->level = g_list_append (riff->level, level);
-
-  return TRUE;
-}
diff --git a/gst-libs/gst/riff/riff-read.h b/gst-libs/gst/riff/riff-read.h
deleted file mode 100644
index a0c12606..00000000
--- a/gst-libs/gst/riff/riff-read.h
+++ /dev/null
@@ -1,114 +0,0 @@
-/* GStreamer RIFF I/O
- * Copyright (C) 2003 Ronald Bultje <rbultje@ronald.bitfreak.net>
- *
- * riff-read.h: function declarations for parsing a RIFF file
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#ifndef __GST_RIFF_READ_H__
-#define __GST_RIFF_READ_H__
-
-#include <glib.h>
-#include <gst/gst.h>
-#include <gst/bytestream/bytestream.h>
-
-G_BEGIN_DECLS
-
-#define GST_TYPE_RIFF_READ \
-  (gst_riff_read_get_type ())
-#define GST_RIFF_READ(obj) \
-  (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_RIFF_READ, GstRiffRead))
-#define GST_RIFF_READ_CLASS(klass) \
-  (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_RIFF_READ, GstRiffReadClass))
-#define GST_IS_RIFF_READ(obj) \
-  (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_RIFF_READ))
-#define GST_IS_RIFF_READ_CLASS(obj) \
-  (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_RIFF_READ))
-#define GST_RIFF_READ_GET_CLASS(obj) \
-  (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_RIFF_READ, GstRiffReadClass))
-
-typedef struct _GstRiffLevel {
-  guint64 start,
-	  length;
-} GstRiffLevel;
-
-typedef struct _GstRiffRead {
-  GstElement parent;
-
-  GstPad *sinkpad;
-  GstByteStream *bs;
-
-  GList *level;
-} GstRiffRead;
-
-typedef struct _GstRiffReadClass {
-  GstElementClass parent;
-} GstRiffReadClass;
-
-GType    gst_riff_read_get_type  (void);
-
-guint32  gst_riff_peek_tag       (GstRiffRead *riff,
-				  guint       *level_up);
-guint32  gst_riff_peek_list      (GstRiffRead *riff);
-gboolean gst_riff_peek_head      (GstRiffRead *riff,
-				  guint32     *tag,
-				  guint32     *length,
-				  guint       *level_up);
-
-GstEvent *gst_riff_read_seek      (GstRiffRead *riff,
-				  guint64      offset);
-gboolean gst_riff_read_skip      (GstRiffRead *riff);
-gboolean gst_riff_read_data      (GstRiffRead *riff,
-				  guint32     *tag,
-				  GstBuffer  **buf);
-gboolean gst_riff_read_ascii     (GstRiffRead *riff,
-				  guint32     *tag,
-				  gchar      **str);
-gboolean gst_riff_read_list      (GstRiffRead *riff,
-				  guint32     *tag);
-gboolean gst_riff_read_header    (GstRiffRead *read,
-				  guint32     *doctype);
-GstBuffer *gst_riff_read_element_data (GstRiffRead *riff,
-				       guint        length,
-				       guint       *got_bytes);
-GstBuffer *gst_riff_peek_element_data (GstRiffRead *riff,
-				       guint        length,
-				       guint       *got_bytes);
-/*
- * Utility functions (including byteswapping).
- */
-gboolean gst_riff_read_strh      (GstRiffRead *riff,
-				  gst_riff_strh **header);
-gboolean gst_riff_read_strf_vids (GstRiffRead *riff,
-				  gst_riff_strf_vids **header);
-gboolean gst_riff_read_strf_vids_with_data
-				 (GstRiffRead *riff,
-				  gst_riff_strf_vids **header,
-				  GstBuffer  **extradata);
-gboolean gst_riff_read_strf_auds (GstRiffRead *riff,
-				  gst_riff_strf_auds **header);
-gboolean gst_riff_read_strf_auds_with_data
-				 (GstRiffRead *riff,
-				  gst_riff_strf_auds **header,
-				  GstBuffer **extradata);
-gboolean gst_riff_read_strf_iavs (GstRiffRead *riff,
-				  gst_riff_strf_iavs **header);
-gboolean gst_riff_read_info      (GstRiffRead *riff);
-
-G_END_DECLS
-
-#endif /* __GST_RIFF_READ_H__ */
diff --git a/gst-libs/gst/riff/riff.c b/gst-libs/gst/riff/riff.c
deleted file mode 100644
index ab8d47b5..00000000
--- a/gst-libs/gst/riff/riff.c
+++ /dev/null
@@ -1,38 +0,0 @@
-/* GStreamer RIFF I/O
- * Copyright (C) 2003 Ronald Bultje <rbultje@ronald.bitfreak.net>
- *
- * riff.c: plugin registering
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this library; if not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <gst/gst.h>
-
-static gboolean
-plugin_init (GstPlugin * plugin)
-{
-  return gst_library_load ("gstbytestream");
-}
-
-GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
-    GST_VERSION_MINOR,
-    "riff",
-    "RIFF I/O functions",
-    plugin_init, VERSION, GST_LICENSE, GST_PACKAGE, GST_ORIGIN)
diff --git a/gst-libs/gst/riff/riff.def b/gst-libs/gst/riff/riff.def
deleted file mode 100644
index c6ea2089..00000000
--- a/gst-libs/gst/riff/riff.def
+++ /dev/null
@@ -1,27 +0,0 @@
-EXPORTS
-    gst_plugin_desc
-    gst_riff_read_get_type
-    gst_riff_read_element_data
-    gst_riff_create_video_template_caps
-    gst_riff_create_video_caps
-    gst_riff_create_video_caps_with_data
-    gst_riff_create_audio_template_caps
-    gst_riff_create_audio_caps
-    gst_riff_create_audio_caps_with_data
-    gst_riff_create_iavs_template_caps
-    gst_riff_create_iavs_caps
-    gst_riff_read_header
-    gst_riff_read_data
-    gst_riff_read_seek
-    gst_riff_read_skip
-    gst_riff_read_info
-    gst_riff_read_list
-    gst_riff_read_ascii
-    gst_riff_read_strh
-    gst_riff_read_strf_iavs
-    gst_riff_read_strf_auds
-    gst_riff_read_strf_auds_with_data
-    gst_riff_read_strf_vids_with_data
-    gst_riff_peek_tag
-    gst_riff_peek_list
-    gst_riff_peek_head
diff --git a/gst-libs/gst/riff/riff.vcproj b/gst-libs/gst/riff/riff.vcproj
deleted file mode 100644
index dde87c07..00000000
--- a/gst-libs/gst/riff/riff.vcproj
+++ /dev/null
@@ -1,158 +0,0 @@
-<?xml version="1.0" encoding="Windows-1252"?>
-<VisualStudioProject
-	ProjectType="Visual C++"
-	Version="7.10"
-	Name="riff"
-	ProjectGUID="{979C216F-0ACF-4956-AE00-055A42D67890}"
-	Keyword="Win32Proj">
-	<Platforms>
-		<Platform
-			Name="Win32"/>
-	</Platforms>
-	<Configurations>
-		<Configuration
-			Name="Debug|Win32"
-			OutputDirectory="../../../win32/Debug"
-			IntermediateDirectory="../../../win32/Debug"
-			ConfigurationType="2"
-			CharacterSet="2">
-			<Tool
-				Name="VCCLCompilerTool"
-				Optimization="0"
-				AdditionalIncludeDirectories="../../../../gstreamer/win32;../../../../gstreamer;../../../../gstreamer/libs;../../../../glib;../../../../glib/glib;../../../../glib/gmodule;&quot;../../../gst-libs&quot;;../../../../popt/include;../../../../libxml2/include/libxml2"
-				PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;RIFF_EXPORTS;HAVE_CONFIG_H;_USE_MATH_DEFINES"
-				MinimalRebuild="TRUE"
-				BasicRuntimeChecks="3"
-				RuntimeLibrary="3"
-				UsePrecompiledHeader="0"
-				WarningLevel="3"
-				Detect64BitPortabilityProblems="TRUE"
-				DebugInformationFormat="4"/>
-			<Tool
-				Name="VCCustomBuildTool"/>
-			<Tool
-				Name="VCLinkerTool"
-				AdditionalDependencies="glib-2.0.lib gmodule-2.0.lib gthread-2.0.lib gobject-2.0.lib libgstreamer.lib gstbytestream.lib iconv.lib intl.lib"
-				OutputFile="$(OutDir)/gstriff.dll"
-				LinkIncremental="2"
-				AdditionalLibraryDirectories="../../../../gstreamer/win32/Debug;../../../../glib/glib;../../../../glib/gmodule;../../../../glib/gthread;../../../../glib/gobject;../../../../gettext/lib;../../../../libiconv/lib"
-				ModuleDefinitionFile="riff.def"
-				GenerateDebugInformation="TRUE"
-				ProgramDatabaseFile="$(OutDir)/riff.pdb"
-				SubSystem="2"
-				OptimizeReferences="2"
-				ImportLibrary="$(OutDir)/gstriff.lib"
-				TargetMachine="1"/>
-			<Tool
-				Name="VCMIDLTool"/>
-			<Tool
-				Name="VCPostBuildEventTool"
-				CommandLine="copy /Y $(TargetPath) c:\gstreamer\plugins"/>
-			<Tool
-				Name="VCPreBuildEventTool"/>
-			<Tool
-				Name="VCPreLinkEventTool"/>
-			<Tool
-				Name="VCResourceCompilerTool"/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"/>
-			<Tool
-				Name="VCWebDeploymentTool"/>
-			<Tool
-				Name="VCManagedWrapperGeneratorTool"/>
-			<Tool
-				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
-		</Configuration>
-		<Configuration
-			Name="Release|Win32"
-			OutputDirectory="../../../win32/Release"
-			IntermediateDirectory="../../../win32/Release"
-			ConfigurationType="2"
-			CharacterSet="2">
-			<Tool
-				Name="VCCLCompilerTool"
-				AdditionalIncludeDirectories="../../../../gstreamer/win32;../../../../gstreamer;../../../../gstreamer/libs;../../../../glib;../../../../glib/glib;../../../../glib/gmodule;&quot;../../../gst-libs&quot;;../../../../popt/include;../../../../libxml2/include/libxml2"
-				PreprocessorDefinitions="WIN32;NDEBUG;GST_DISABLE_GST_DEBUG;_WINDOWS;_USRDLL;RIFF_EXPORTS;HAVE_CONFIG_H;_USE_MATH_DEFINES"
-				RuntimeLibrary="2"
-				UsePrecompiledHeader="0"
-				WarningLevel="3"
-				Detect64BitPortabilityProblems="TRUE"
-				DebugInformationFormat="3"/>
-			<Tool
-				Name="VCCustomBuildTool"/>
-			<Tool
-				Name="VCLinkerTool"
-				AdditionalDependencies="glib-2.0.lib gmodule-2.0.lib gthread-2.0.lib gobject-2.0.lib libgstreamer.lib gstbytestream.lib iconv.lib intl.lib"
-				OutputFile="$(OutDir)/gstriff.dll"
-				LinkIncremental="1"
-				AdditionalLibraryDirectories="../../../../gstreamer/win32/Release;../../../../glib/glib;../../../../glib/gmodule;../../../../glib/gthread;../../../../glib/gobject;../../../../gettext/lib;../../../../libiconv/lib"
-				ModuleDefinitionFile="riff.def"
-				GenerateDebugInformation="TRUE"
-				SubSystem="2"
-				OptimizeReferences="2"
-				EnableCOMDATFolding="2"
-				ImportLibrary="$(OutDir)/gstriff.lib"
-				TargetMachine="1"/>
-			<Tool
-				Name="VCMIDLTool"/>
-			<Tool
-				Name="VCPostBuildEventTool"
-				CommandLine="copy /Y $(TargetPath) c:\gstreamer\plugins"/>
-			<Tool
-				Name="VCPreBuildEventTool"/>
-			<Tool
-				Name="VCPreLinkEventTool"/>
-			<Tool
-				Name="VCResourceCompilerTool"/>
-			<Tool
-				Name="VCWebServiceProxyGeneratorTool"/>
-			<Tool
-				Name="VCXMLDataGeneratorTool"/>
-			<Tool
-				Name="VCWebDeploymentTool"/>
-			<Tool
-				Name="VCManagedWrapperGeneratorTool"/>
-			<Tool
-				Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
-		</Configuration>
-	</Configurations>
-	<References>
-	</References>
-	<Files>
-		<Filter
-			Name="Source Files"
-			Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
-			UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">
-			<File
-				RelativePath=".\riff-media.c">
-			</File>
-			<File
-				RelativePath=".\riff-read.c">
-			</File>
-			<File
-				RelativePath=".\riff.c">
-			</File>
-			<File
-				RelativePath=".\riff.def">
-			</File>
-		</Filter>
-		<Filter
-			Name="Header Files"
-			Filter="h;hpp;hxx;hm;inl;inc;xsd"
-			UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
-			<File
-				RelativePath=".\riff-ids.h">
-			</File>
-			<File
-				RelativePath=".\riff-media.h">
-			</File>
-			<File
-				RelativePath=".\riff-read.h">
-			</File>
-		</Filter>
-	</Files>
-	<Globals>
-	</Globals>
-</VisualStudioProject>
-- 
cgit v1.2.1