Merge tag 'upstream/0.11.92'

Upstream version 0.11.92
diff --git a/ChangeLog b/ChangeLog
index b92861c..9b7303a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,9 +1,1020 @@
-=== release 0.11.91 ===
+=== release 0.11.92 ===
 
-2012-05-13  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+2012-06-07  Sebastian Dröge <sebastian.droege@collabora.co.uk>
 
 	* configure.ac:
-	  releasing 0.11.91, "Fee-fi-fo-fum"
+	  releasing 0.11.92, "Comfortably Numb"
+
+2012-06-07 13:24:48 +0100  Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
+
+	* ext/theora/gsttheoradec.c:
+	  theoradec: fix frame leaks
+
+2012-06-07 11:16:13 +0100  Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
+
+	* ext/theora/gsttheoradec.c:
+	  theoradec: fix video state leaks
+
+2012-06-07 11:15:57 +0100  Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
+
+	* gst-libs/gst/video/gstvideoutils.c:
+	  video: fix memory leak
+
+2012-06-07 10:52:53 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/playback/gstplaysink.c:
+	  playsink: fix compilation
+
+2012-05-24 11:02:59 -0300  Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
+
+	* gst/playback/gstplaybin2.c:
+	* gst/playback/gstplaysink.c:
+	* gst/playback/gstsubtitleoverlay.c:
+	  playbin2: Send flush events when changing subtitle tracks and use new input-selector modes for subtitle tracks
+	  For audio/video we should flush too for fastest stream switches but this
+	  currently isn't possible because the flushes would need to go to the sink,
+	  which then causes state changes and causes all timing information to be
+	  changed.
+	  Should work out of the box in 0.11 with the flush-stop that doesn't reset
+	  the times.
+	  Conflicts:
+	  gst/playback/gstplaybin2.c
+	  gst/playback/gstplaysink.c
+	  gst/playback/gstsubtitleoverlay.c
+
+2012-05-21 09:06:18 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst/playback/gstplaysink.c:
+	  playsink: Don't use // comments and prevent unnecessary memory allocation
+	  Conflicts:
+	  gst/playback/gstplaysink.c
+
+2012-05-20 12:51:17 -0300  Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
+
+	* gst/playback/gstplaybin2.c:
+	* gst/playback/gstplaysink.c:
+	  playbin2: Properly change subtitles
+	  Conflicts:
+	  gst/playback/gstplaysink.c
+
+2012-05-15 12:56:13 -0300  Thiago Santos <thiago.sousa.santos@collabora.com>
+
+	* gst/playback/gstplaybin2.c:
+	  playbin2: fix subtitle only seeks when switching to external subs
+	  Sending a non-flushing seek might not be enough for switching
+	  to an external sub that has already been used because the flushes
+	  are needed to reset the state of its decodebin's queue.
+	  For example, if the subtitle is short enough, the queue might get
+	  and EOS and keep its 'unexpected' return state. If the user switches
+	  to another subtitle and back to the external one, the buffers
+	  won't get past the queue.
+	  This patch fixes this by adding the flush flag to the seek and
+	  preventing that this flush leaves the suburidecodebin.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=638168
+	  Conflicts:
+	  gst/playback/gstplaybin2.c
+
+2012-05-16 10:41:41 -0300  Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
+
+	* gst/playback/gstplaysink.c:
+	  gstplaysink: Properly reset chain when receiving a custom flush event.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=638168
+	  Conflicts:
+	  gst/playback/gstplaysink.c
+
+2012-05-14 11:52:12 -0300  Thiago Santos <thiago.sousa.santos@collabora.com>
+
+	* gst/playback/gstplaysink.c:
+	  playsink: do not store more than a second of subtitles
+	  Use a shorter queue for subtitles to avoid switches for subtitles
+	  taking longer than they already take.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=638168
+
+2012-06-05 18:12:52 -0300  Thiago Santos <thiago.sousa.santos@collabora.com>
+
+	* gst/playback/gstsubtitleoverlay.c:
+	  subtitleoverlay: pass correct parameter to debug message
+	  Get the format name to pass to the debug message, as it expects a string
+
+2012-05-10 12:17:45 -0300  Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
+
+	* gst/playback/gstsubtitleoverlay.c:
+	  gstsuboverlay: Convert NewSegment events to always be in the TIME format.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=638168
+	  Conflicts:
+	  gst/playback/gstsubtitleoverlay.c
+
+2012-06-06 17:42:36 +0100  Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	  oggdemux: reject opus streams with negative start time
+	  This is used by Vorbis for sample accurate clipping, but this is
+	  deemed an invalid stream by the opus spec.
+
+2012-06-06 17:41:55 +0100  Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
+
+	* ext/ogg/gstoggstream.c:
+	* ext/ogg/gstoggstream.h:
+	  oggstream: add a flag to say whether start granule clamping is to be done
+
+2012-06-06 18:18:29 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* common:
+	  Automatic update of common submodule
+	  From 1fab359 to 03a0e57
+
+2012-06-06 16:41:03 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/rtsp/gstrtspconnection.c:
+	  rtspconnection: handle cancellation correctly
+
+2012-06-06 16:40:24 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/rtp/gstrtpbaseaudiopayload.c:
+	  audiopayload: disable broken bufferlist handling
+	  The bufferlist handling is broken so make sure it is never enabled.
+
+2012-06-06 14:53:43 +0200  David Svensson Fors <davidsf at axis.com>
+
+	* gst-libs/gst/rtsp/gstrtspconnection.c:
+	  rtsp: don't leak address and socket
+	  Fixes https://bugzilla.gnome.org/show_bug.cgi?id=677466
+
+2012-06-06 12:55:15 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	* ext/ogg/gstogmparse.c:
+	* ext/theora/gsttheoradec.c:
+	* gst-libs/gst/audio/gstaudiocdsrc.c:
+	* gst-libs/gst/audio/gstaudiodecoder.c:
+	* gst-libs/gst/audio/gstaudioencoder.c:
+	* gst-libs/gst/tag/gsttagdemux.c:
+	* gst-libs/gst/tag/gsttagmux.c:
+	* gst/audiotestsrc/gstaudiotestsrc.c:
+	* gst/playback/gstplaybin2.c:
+	* gst/subparse/gstssaparse.c:
+	* gst/subparse/gstsubparse.c:
+	  update for tag event change
+
+2012-06-06 11:01:13 +0100  Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	* ext/ogg/gstoggstream.c:
+	* ext/ogg/gstoggstream.h:
+	  oggstream: reject Ogg/Opus streams with nonsensical preskip/granpos setup
+	  As the spec mandates.
+
+2012-06-06 11:38:00 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video-format.c:
+	* gst-libs/gst/video/video-format.h:
+	  video: add pack_lines variable
+	  Use a separate variable to describe the amount of lines that will be used in
+	  packing instead of abusing the h_sub variable. Some formats might have no
+	  subsampling but need to operate on multipe lines.
+
+2012-06-06 11:15:50 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videotestsrc/gstvideotestsrc.c:
+	* gst/videotestsrc/gstvideotestsrc.h:
+	* gst/videotestsrc/videotestsrc.c:
+	* gst/videotestsrc/videotestsrc.h:
+	  videotestsrc: Remove more redundant code
+	  Use the video library to do the setup instead of keeping a separate incomplete
+	  list.
+
+2012-06-06 10:21:55 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video-frame.h:
+	  video: add macro for component depth
+
+2012-06-05 16:58:19 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videotestsrc/gstvideotestsrc.c:
+	  videotestsrc: don't artificially restrict caps
+	  Use all the formats that the video library supports without any restrictions on
+	  colorimetry or other parameters such as chroma-siting.
+
+2012-06-05 12:27:09 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* gst-libs/gst/pbutils/descriptions.c:
+	  pbutils: Add descriptor for E-AC3 and PGS subtitles
+
+2012-06-05 16:09:56 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* win32/common/libgstvideo.def:
+	  win32: update .def file for new video API
+
+2012-06-05 12:47:22 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/Makefile.am:
+	* gst-libs/gst/video/video-color.c:
+	* gst-libs/gst/video/video-color.h:
+	* gst-libs/gst/video/video-event.c:
+	* gst-libs/gst/video/video-event.h:
+	* gst-libs/gst/video/video-format.c:
+	* gst-libs/gst/video/video-format.h:
+	* gst-libs/gst/video/video-frame.c:
+	* gst-libs/gst/video/video-frame.h:
+	* gst-libs/gst/video/video-info.c:
+	* gst-libs/gst/video/video-info.h:
+	* gst-libs/gst/video/video.c:
+	* gst-libs/gst/video/video.h:
+	  video: move methods into separate files
+	  Move different video functionalities into different files
+
+2012-06-04 20:36:10 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	* gst/videoconvert/videoconvert.h:
+	  videoconvert: refactor matrix setup
+
+2012-06-04 18:24:03 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: don't add unknown colorimetry
+
+2012-06-04 18:17:42 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/gstvideodecoder.c:
+	  videodecoder: only copy known colorimetry values
+	  Avoid overriding the default colorimetry values.
+
+2012-06-04 18:08:11 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: add unknown colorimetry parameters as well..
+
+2012-06-04 18:00:42 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: use unknown colorimetry for unknown formats
+	  Use the default RGB colorimetry into only on RGB formats and use an unknown set
+	  of defaults for the unknown format.
+
+2012-06-04 16:15:25 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: (de)serialize colorimetry on caps
+
+2012-06-04 16:13:48 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	  videoconvert: fix 0_255 handling
+	  We also need to apply an offset to the Cb and Cr samples in the 0-255 case.
+
+2012-06-04 15:26:21 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: don't add empty colorimetry to caps
+	  Don't use extra default colorimetry entries in the table to construct an output
+	  colorimetry shortcut because they don't have a name.
+
+2012-06-04 14:51:41 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: fix default colorspace settings
+	  HD content is defined as height > 576
+
+2012-06-04 14:46:21 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/Makefile.am:
+	* gst/videoconvert/gstcms.c:
+	* gst/videoconvert/gstcms.h:
+	* gst/videoconvert/videoconvert.c:
+	* gst/videoconvert/videoconvert.h:
+	  videoconvert: improve color transform setup
+	  Remove hardcoded color matrices and compute the matrices using the cms helper
+	  library that was in cogcolorspace before.
+
+2012-06-04 10:08:59 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.h:
+	  video: add generic film primaries
+
+2012-06-04 13:07:36 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* tests/check/libs/video.c:
+	  video: Fix build of unit test
+
+2012-06-04 13:04:00 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* win32/common/libgstaudio.def:
+	* win32/common/libgstvideo.def:
+	  win32: Update exported symbols list
+
+2012-06-04 10:46:13 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/video/gstvideoencoder.c:
+	  videoencoder: Don't unref frame twice if not in the list
+
+2012-06-02 09:34:15 -0400  Matej Knopp <matej.knopp@gmail.com>
+
+	* gst-libs/gst/video/gstvideodecoder.c:
+	  videodecoder: Do not unref frame if not in the list
+
+2012-06-04 10:01:42 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/audio/gstaudiodecoder.c:
+	  Revert "audiodecoder: Error out earlier in a few places if something goes wrong"
+	  This reverts commit eb68a2d5a7e4e9598df6eb812589c092fe2cc89a.
+	  This sometimes errors out too early now, needs some more thoughts.
+
+2012-06-04 09:56:30 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/audio/gstaudiodecoder.c:
+	  audiodecoder: Return setcaps return value instead of always TRUE
+
+2012-06-02 17:15:42 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/audio/gstaudiodecoder.c:
+	  audiodecoder: Error out earlier in a few places if something goes wrong
+
+2012-06-02 17:02:10 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* ext/vorbis/gstvorbisdec.c:
+	  vorbisdec: Error out if handling a header packet failed instead of just finishing the frame
+
+2012-06-01 12:02:57 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/gstvideoconvert.c:
+	* gst/videoconvert/gstvideoconvert.h:
+	* gst/videoconvert/videoconvert.c:
+	* gst/videoconvert/videoconvert.h:
+	  videoconvert: use video helper library more
+	  Use VideoInfo to setup the conversion.
+	  Use the color matrix from the video info.
+
+2012-06-01 11:58:18 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: set default colorimetry info
+	  Set default colorimetry info when not otherwise specified in caps.
+
+2012-06-01 10:02:02 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* gst-libs/gst/video/videoblendorc-dist.c:
+	* gst-libs/gst/video/videoblendorc-dist.h:
+	  video: update disted orc backup files for recent changes
+
+2012-06-01 10:28:41 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* common:
+	  Automatic update of common submodule
+	  From f1b5a96 to 1fab359
+
+2012-05-31 18:55:32 -0300  Thiago Santos <thiago.sousa.santos@collabora.com>
+
+	* ext/theora/gsttheoraenc.c:
+	  theoraenc: do not use %zu, it is C99
+	  Cast the variables instead and fallback to %u
+
+2012-05-31 18:28:14 -0300  Thiago Santos <thiago.sousa.santos@collabora.com>
+
+	* ext/theora/gsttheoraenc.c:
+	  theoraenc: fix printf format variable
+
+2012-05-31 13:38:54 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/gstvideopool.c:
+	* gst-libs/gst/video/video.c:
+	* gst-libs/gst/video/video.h:
+	* gst/videoconvert/gstvideoconvert.c:
+	* gst/videoconvert/videoconvert.c:
+	  video: fix paletted format
+	  RGB8_PALETTED -> RGB8P
+	  Fix the definition of paletted formats, store the palette in the second
+	  plane.
+	  Make sure we copy the palette correctly in gst_video_frame_copy()
+	  Don't do alignment on the palette in videopool
+
+2012-05-31 13:08:04 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* common:
+	  Automatic update of common submodule
+	  From 92b7266 to f1b5a96
+
+2012-05-31 11:29:44 +0100  Bastien Nocera <hadess@hadess.net>
+
+	* gst/playback/gsturidecodebin.c:
+	  uridecodebin: Use cache dir for download buffering
+	  Instead of the temp directory. See:
+	  http://0pointer.de/blog/projects/tmp.html
+	  https://bugzilla.gnome.org/show_bug.cgi?id=677181
+
+2012-05-30 17:08:56 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	* gst/videoconvert/videoconvert.h:
+	  videoconvert: use video library pack/unpack
+	  Remove obsolete code and use the video pack/unpack functions
+
+2012-05-30 16:51:16 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videotestsrc/videotestsrc.c:
+	  videotestsrc: enable more formats
+
+2012-05-30 13:07:57 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/video/Makefile.am:
+	  video: And fix the build of the ORC sources
+
+2012-05-30 13:06:11 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/video/Makefile.am:
+	  video: Fix generation of orc sources
+
+2012-05-30 12:45:09 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* common:
+	  Automatic update of common submodule
+	  From ec1c4a8 to 92b7266
+
+2012-05-30 11:23:23 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* common:
+	  Automatic update of common submodule
+	  From 3429ba6 to ec1c4a8
+
+2012-05-30 09:25:12 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video-blend.c:
+	* gst-libs/gst/video/video-blend.h:
+	  video-blend: prepare for 0.11 porting
+	  Remove obsolete code.
+	  Remove the BlendInfo structure, we can do this better with GstVideoFrame
+	  Use GstVideoFrame in the API
+	  Prefix functions with gst_
+
+2012-05-30 09:21:46 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.h:
+	  video: add support for premultiplied alpha
+
+2012-05-29 17:48:45 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videotestsrc/gstvideotestsrc.c:
+	* gst/videotestsrc/gstvideotestsrc.h:
+	* gst/videotestsrc/videotestsrc.c:
+	* gst/videotestsrc/videotestsrc.h:
+	  videotestsrc: use generic packing code
+	  Use the pack functions of the video library to construct the target
+	  image.
+	  Remove redundant functions.
+
+2012-05-29 17:47:54 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	* gst/videoscale/gstvideoscale.c:
+	  video: update for removed formats
+
+2012-05-29 17:45:33 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.h:
+	  video: move enum difinition
+	  c++ doesn't seem to like the typedef
+
+2012-05-29 17:34:29 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	* gst-libs/gst/video/video.h:
+	* gst-libs/gst/video/videoblendorc.orc:
+	  video: Remove duplicate formats
+	  Remove Y800 and Y16 wich are the same as GRAY8 and GRAY16_LE
+	  Add const to the GstVideoFormatInfo when used in argument
+	  Add GRAY8 and GRAY16 pack/unpack functions
+
+2012-05-29 15:20:08 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	* gst-libs/gst/video/videoblendorc.orc:
+	  video: rename orc function names
+
+2012-05-29 15:12:16 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/Makefile.am:
+	* gst-libs/gst/video/video.c:
+	* gst-libs/gst/video/video.h:
+	* gst-libs/gst/video/videoblendorc-dist.c:
+	* gst-libs/gst/video/videoblendorc-dist.h:
+	* gst-libs/gst/video/videoblendorc.orc:
+	  video: fill in the pack/unpack functions
+	  Add support for supporting chroma subsampling correctly in the pack
+	  function.
+	  Fill in the pack and unpack functions for most formats.
+	  Add some missing pack/unpack functions to the orc file.
+
+2012-05-29 10:45:23 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/gstvideoconvertorc-dist.c:
+	* gst/videoconvert/gstvideoconvertorc-dist.h:
+	* gst/videoconvert/gstvideoconvertorc.orc:
+	  videoconvert: remove unused functions
+
+2012-05-29 10:44:59 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video-blend.c:
+	  video-blend: remove unused defines
+
+2012-05-28 14:18:10 -0300  Andre Moreira Magalhaes (andrunko) <andre.magalhaes@collabora.co.uk>
+
+	* ext/pango/gstbasetextoverlay.c:
+	* ext/pango/gstbasetextoverlay.h:
+	  textoverlay: Use an external lock
+	  Conflicts:
+	  ext/pango/gsttextoverlay.c
+	  ext/pango/gsttextoverlay.h
+
+2012-05-29 09:54:43 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/audio/audio.h:
+	  audio: add flags for the pack/unpack functions
+	  Add a flag argument to the pack and unpack function so that we can expand it
+	  later when needed. We could for example prefer a High Quality pack/unpack
+	  operation later.
+
+2012-05-29 09:53:15 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.h:
+	  video: add flags for the pack/unpack functions
+	  Add a flag argument to the pack and unpack function so that we can expand it
+	  later when needed. We could for example prefer a High Quality pack/unpack
+	  operation later.
+
+2012-05-29 09:52:40 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.h:
+	  video: add padding
+
+2012-05-28 17:11:46 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	* gst/videotestsrc/videotestsrc.c:
+	  video: fix UYVP packing function
+
+2012-05-28 16:30:56 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	  videoconvert: fix v216
+
+2012-05-28 16:16:24 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videotestsrc/videotestsrc.c:
+	* gst/videotestsrc/videotestsrc.h:
+	  videotestsrc: add support for I420_10 format
+	  Add support for the I420_10 formats
+	  Use the video frame api to get pixels and strides instead of our own
+	  custom versions. Fixes the YVU9 format and probably some others.
+
+2012-05-28 16:14:30 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	  video: fix v216 format description
+	  Fix the offsets of v216 video
+	  Add the complex flag to some formats
+
+2012-05-28 16:13:42 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* docs/design/part-mediatype-video-raw.txt:
+	  docs: update v216 format
+	  Fix the v216 format description
+
+2012-05-28 14:58:52 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videotestsrc/videotestsrc.c:
+	  videotestsrc: fix AYUV64 format string
+
+2012-05-28 14:49:52 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* docs/design/part-mediatype-video-raw.txt:
+	  docs: update video formats document
+
+2012-05-28 12:50:49 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/videoconvert/videoconvert.c:
+	  videoconvert: add support for 10bit I420
+	  Add support for 10bit I420
+	  Reorganize some macros, have separate plane and component macros, fix
+	  a problem with YV12 in the process.
+	  Fixes https://bugzilla.gnome.org/show_bug.cgi?id=665034
+
+2012-05-28 11:08:18 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/gstvideopool.c:
+	  videopool: take pixel stride into account
+	  When we need to add borders, take the pixel stride into account to move to the
+	  right horizintal offset.
+
+2012-05-26 19:56:48 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* tests/check/libs/tag.c:
+	* tests/examples/playback/playback-test.c:
+	* tests/examples/seek/jsseek.c:
+	  tests: don't use GstStructure API on tag lists
+
+2012-05-26 19:56:30 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* gst-libs/gst/tag/gstxmptag.c:
+	* gst-libs/gst/tag/id3v2.c:
+	  tag: don't use GstStructure API on tag lists
+
+2012-05-26 19:53:50 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* tools/gst-discoverer.c:
+	  gst-discoverer: print all entries for a certain tag
+	  If there are multiple entries for a tag, print all of them
+	  individually.
+
+2012-05-26 19:50:46 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* tools/gst-discoverer.c:
+	  gst-discoverer: don't use GstStructure API on tag lists
+
+2012-05-25 16:58:50 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/video/video.c:
+	* gst-libs/gst/video/video.h:
+	  video: add 10 bits I420 format
+	  Add 10 bits I420 format definitions
+	  Move encoded format as second entry in the array so that it doesn't end up in a
+	  weird place when we add formats.
+	  See https://bugzilla.gnome.org/show_bug.cgi?id=665034
+
+2012-05-25 16:05:29 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* tests/check/libs/video.c:
+	  check: Update video test for GST_VIDEO_FORMAT_ENCODED
+
+2012-05-25 16:05:06 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* tests/check/libs/struct_x86_64.h:
+	  tests: Update ABI libs structure
+
+2012-05-25 15:12:53 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/playback/gstplaybin2.c:
+	* tests/check/elements/playbin.c:
+	  playbin: add current-*uri properties
+	  Make the uri property getter return the next uri, like it was configured in the
+	  setter.
+	  Make a new current-uri and current-suburi property that reflects the currently
+	  playing uri and suburi.
+	  Fixes https://bugzilla.gnome.org/show_bug.cgi?id=676665
+
+2012-05-25 15:57:45 +0530  Arun Raghavan <arun.raghavan@collabora.co.uk>
+
+	* gst-libs/gst/audio/gstaudioiec61937.c:
+	  audio: Fix DTS IEC61937 payloading
+	  DTS type I-III specify the burst length in bits. Only type IV (which we
+	  do not currently support) needs it to be specified in bytes. Thanks to
+	  Julien Moutte for pointing this out.
+
+2012-05-24 13:43:06 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst/playback/gstplaybin2.c:
+	  playbin: fix compilation
+
+2012-05-24 13:28:33 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* ext/cdparanoia/gstcdparanoiasrc.c:
+	  cdparanoia: always set the read_speed
+	  Always set the read speed to the configured value. Clarify that 0 or -1
+	  speed means full speed.
+	  Fixes https://bugzilla.gnome.org/show_bug.cgi?id=676361
+
+2012-05-24 12:31:34 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* common:
+	  Automatic update of common submodule
+	  From dc70203 to 3429ba6
+
+2012-05-23 16:34:37 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst/playback/gstplaybin2.c:
+	  playbin2: Put sinks before the other element factories in the autoplug factory list
+	  This makes sure that we always prefer sinks that support a format without
+	  decoding, independant of its rank. Previously we only sorted by rank.
+	  Conflicts:
+	  gst/playback/gstplaybin2.c
+
+2012-05-21 13:34:02 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* ext/theora/gsttheoradec.c:
+	  theoradec: remove usless checking of return val.
+	  fixes https://bugzilla.gnome.org/show_bug.cgi?id=676525
+
+2012-05-20 23:27:42 +0300  Raimo Järvi <raimo.jarvi@gmail.com>
+
+	* gst-libs/gst/video/gstvideodecoder.c:
+	* gst-libs/gst/video/gstvideoencoder.c:
+	  video: Fix printf format warnings on mingw-w64
+	  https://bugzilla.gnome.org/show_bug.cgi?id=676442
+
+2012-05-23 16:09:37 +0200  Sebastian Rasmussen <sebrn@axis.com>
+
+	* gst/audioresample/gstaudioresample.c:
+	  Fix bug where debug category was declared inside a function
+	  Fixes https://bugzilla.gnome.org/show_bug.cgi?id=676670
+
+2012-05-22 16:49:58 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* gst-libs/gst/video/gstvideodecoder.c:
+	  videodecoder: improve doc
+
+2012-05-23 01:49:49 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* ext/theora/gsttheoradec.c:
+	  theoradec: remove the nonuse parameter from handle_type_packet() method
+
+2012-05-22 15:24:36 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* gst-libs/gst/video/gstvideoutils.h:
+	  videoutils: improve doc
+
+2012-05-22 15:17:37 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* ext/theora/gsttheoradec.c:
+	  theoradec: stream is marking as non-packeized so that the data gets parsed and keyframes marked
+
+2012-05-22 13:52:28 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* win32/common/libgstpbutils.def:
+	  win32: Update defs file
+
+2012-05-21 13:14:32 +0200  Andoni Morales Alastruey <ylatuya@gmail.com>
+
+	* configure.ac:
+	* tests/examples/playback/Makefile.am:
+	* tests/examples/playback/playback-test.c:
+	  playback: Fix compilation with the GDK Quartz backend
+
+2012-05-21 08:01:09 +0200  Stefan Sauer <ensonic@users.sf.net>
+
+	* tests/examples/playback/playback-test.c:
+	  playback-test: remove not needed state-change
+	  We go back to paused if needed (scrubbing in paused) in stop_seek().
+
+2012-05-21 10:08:33 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* gst-libs/gst/pbutils/gstdiscoverer.h:
+	  discoverer: Put back accidentially deleted line
+
+2012-05-21 02:01:17 +0300  Anton Belka <antonbelka@gmail.com>
+
+	* docs/libs/gst-plugins-base-libs-sections.txt:
+	* gst-libs/gst/pbutils/gstdiscoverer-types.c:
+	* gst-libs/gst/pbutils/gstdiscoverer.c:
+	* gst-libs/gst/pbutils/gstdiscoverer.h:
+	* gst-libs/gst/pbutils/pbutils-private.h:
+	* tools/gst-discoverer.c:
+	  discoverer: Add TOC support to discoverer and add -c/--toc parameters to gst-discoverer utility
+
+2012-05-19 15:17:18 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* gst/encoding/gstencodebin.c:
+	  encodebin: don't access GstElementFactory structure directly
+
+2012-05-15 16:09:05 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* sys/xvimage/xvimagesink.c:
+	  xvimagesink: remove unused assignment
+	  https://bugzilla.gnome.org/show_bug.cgi?id=676344
+
+2012-05-16 12:25:09 +0300  Sreerenj Balachandran <sreerenj.balachandran@intel.com>
+
+	* tests/icles/test-box.c:
+	  tests/icles: fix type of format field in 0.11 video caps
+	  https://bugzilla.gnome.org/show_bug.cgi?id=676344
+
+2012-05-15 19:21:15 +0200  Andoni Morales Alastruey <ylatuya@gmail.com>
+
+	* ext/alsa/gstalsa.c:
+	* ext/alsa/gstalsa.h:
+	* ext/alsa/gstalsasink.c:
+	* ext/alsa/gstalsasrc.c:
+	  alsasink: check for spdif support only in the current device
+
+2012-05-18 09:20:54 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/rtsp/gstrtspconnection.c:
+	  rtsp: unref sockets in _close
+	  When closing the connection, unref the currently used sockets. This should close
+	  them when not in use. We need to do this because else we cannot reconnect
+	  anymore after a close, the connect function requires that the sockets are NULL.
+
+2012-05-18 09:18:29 +0200  Wim Taymans <wim.taymans@collabora.co.uk>
+
+	* gst-libs/gst/rtsp/gstrtspconnection.c:
+	  rtsp: clear the GError for pending connect
+	  Clear the GError after g_socket_connect tells us that the connection is pending.
+	  If we don't do this, glib complains when we try to reuse the non-NULL GError
+	  variable a little below.
+
+2012-05-17 22:06:45 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* gst-libs/gst/app/gstappsrc.c:
+	  appsrc: simplify get_property for "caps" property
+
+2012-05-17 22:04:24 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* gst-libs/gst/app/gstappsrc.c:
+	* gst-libs/gst/app/gstappsrc.h:
+	  appsrc: remove filter argument from gst_app_src_get_caps()
+	  Was presumably added by mistaken in the grand _get_caps()
+	  conversion. Doesn't really make sense for a property accessor.
+
+2012-05-17 16:38:58 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/cdparanoia/gstcdparanoiasrc.c:
+	  cdparanoiasrc: include stdio.h for SEEK_SET
+	  https://bugzilla.gnome.org/show_bug.cgi?id=676255
+
+2012-05-16 15:10:41 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/vorbis/gstvorbisdeclib.h:
+	  vorbis: give libvorbis-based decoder and vorbisidec decoder different type names
+	  Should fix "cannot register existing type `GstVorbisDec'" criticals
+	  when both libvorbis and vorbisidec are available.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=673333
+
+2012-05-16 13:46:57 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* docs/libs/gst-plugins-base-libs-sections.txt:
+	* gst-libs/gst/video/gstvideoutils.c:
+	* gst-libs/gst/video/gstvideoutils.h:
+	* win32/common/libgstvideo.def:
+	  video: Rename gst_video_codec_frame_set_hook() to gst_video_codec_frame_set_user_data()
+	  And also add a getter and allow to set NULL user_data but still call
+	  the passed destroy notify.
+
+2012-05-16 12:40:07 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* gst-libs/gst/video/gstvideodecoder.c:
+	* gst-libs/gst/video/gstvideoencoder.c:
+	* gst-libs/gst/video/gstvideoutils.h:
+	  docs: fix up video decoder/encoder docs a bit
+	  Makes gtk-doc happy.
+
+2012-01-01 20:48:29 +0100  Idar Tollefsen <itollefs@cisco.com>
+
+	* configure.ac:
+	  build: Make sure AC_INCLUDES_DEFAULT is used.
+	  Without using AC_INCLUDES_DEFAULT explicitly,
+	  certain platforms will complain that the header
+	  was found, but not usable by the compiler.
+	  This happens for instance on Solaris where certain
+	  headers are needed to pull in proper defines.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=667307
+	  Conflicts:
+	  configure.ac
+
+2012-05-16 09:12:44 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* configure.ac:
+	  configure: Require core/base 0.11.91
+
+2012-01-13 17:58:37 -0500  Matej Knopp <matej.knopp@gmail.com>
+
+	* .gitignore:
+	  .gitignore: add visual studio IDE files and OS X .DS_Store files
+	  https://bugzilla.gnome.org/show_bug.cgi?id=667899
+
+2012-05-14 07:01:18 +0200  Alban Browaeys <prahal@yahoo.com>
+
+	* gst/playback/gstplaysink.c:
+	  playsink: do not abort if a property is not found.
+	  If a property is not found (for example last-sample when
+	  gst_debug_bin_to_dot_file is used while the pipeline is
+	  slightly broken (thus no last-sample) the unref of the item
+	  gvalue which is not refed fails. Only unref if it was found.
+
+2012-05-14 20:08:38 +0200  Alban Browaeys <prahal@yahoo.com>
+
+	* gst/playback/gstplaysink.c:
+	  playsink: missing guard around gst pad add probe
+	  This miss prevent from switching from one track to the other.
+	  Issue encountered with rhythmbox and totem ports.
+
+2012-05-14 17:53:59 +0200  Edward Hervey <edward.hervey@collabora.co.uk>
+
+	* ext/theora/gsttheoraenc.c:
+	  theoraenc: Don't leak incoming frames (and buffers)
+	  We get given a reference in ::handle_frame(), remove it when we're done.
+
+2012-05-11 10:58:45 +0200  Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>
+
+	* gst/playback/gstplaybin2.c:
+	* gst/playback/gstplaysink.c:
+	  playbin2: default text element is now subtitleoverlay
+	  ... and not so much textoverlay, though the former also uses the latter.
+
+2012-05-13 23:11:20 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	  oggdemux: fix potential crash in SEEKING query handler
+	  Take chain lock when accessing chains. Fall back gracefully
+	  when there's no current chain Hopefully fixes crash when
+	  seeking in Jamendo or Magnatune streams in Amarok.
+	  https://bugzilla.gnome.org/show_bug.cgi?id=675609
+
+2012-05-13 18:49:31 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	* gst-libs/gst/pbutils/descriptions.c:
+	* gst/typefind/gsttypefindfunctions.c:
+	  typefinding, ogg: don't bother with annodex media types
+	  They're hardly used, and probably more confusing than anything
+	  else, and it's not clear that anyone would really need to be
+	  able to tell them apart at the media type level.
+
+2012-05-12 14:36:09 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	* ext/ogg/gstoggstream.c:
+	* ext/ogg/gstoggstream.h:
+	  oggdemux: don't expose Annodex CMML streams any more
+	  This never really took off - it's hardly used anywhere
+	  and deprecated in favour of Kate. Exposing pads just
+	  leads to confusing 'you are missing a plug-in' messages
+	  when people come across such streams. We could still post
+	  the data on the bus for applications to parse.
+
+2012-05-12 14:24:24 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	  oggdemux: update some comments that refer to internal decoders
+	  We don't do that any more, we now have stream mappers for this.
+
+2012-05-12 14:22:23 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/ogg/gstoggdemux.c:
+	* ext/ogg/gstoggdemux.h:
+	  oggdemux: remove unused GstOggPadMode enum
+
+2012-05-13 17:10:57 +0100  Tim-Philipp Müller <tim.muller@collabora.co.uk>
+
+	* ext/libvisual/visual.c:
+	  libvisual: include string.h for strcmp()
+
+2012-05-13 16:59:42 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* configure.ac:
+	  Back to development
+
+=== release 0.11.91 ===
+
+2012-05-13 16:20:00 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* ChangeLog:
+	* NEWS:
+	* RELEASE:
+	* common:
+	* configure.ac:
+	* gst-plugins-base.doap:
+	* win32/common/_stdint.h:
+	* win32/common/config.h:
+	  Release 0.11.91
+
+2012-05-13 16:19:32 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
+
+	* po/af.po:
+	* po/az.po:
+	* po/bg.po:
+	* po/ca.po:
+	* po/cs.po:
+	* po/da.po:
+	* po/de.po:
+	* po/el.po:
+	* po/en_GB.po:
+	* po/eo.po:
+	* po/es.po:
+	* po/eu.po:
+	* po/fi.po:
+	* po/fr.po:
+	* po/gl.po:
+	* po/hu.po:
+	* po/id.po:
+	* po/it.po:
+	* po/ja.po:
+	* po/lt.po:
+	* po/lv.po:
+	* po/nb.po:
+	* po/nl.po:
+	* po/or.po:
+	* po/pl.po:
+	* po/pt_BR.po:
+	* po/ro.po:
+	* po/ru.po:
+	* po/sk.po:
+	* po/sl.po:
+	* po/sq.po:
+	* po/sr.po:
+	* po/sv.po:
+	* po/tr.po:
+	* po/uk.po:
+	* po/vi.po:
+	* po/zh_CN.po:
+	  Update .po files
 
 2012-05-13 15:55:54 +0200  Sebastian Dröge <sebastian.droege@collabora.co.uk>
 
diff --git a/Makefile.in b/Makefile.in
index 028e614..832cc44 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -61,6 +61,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(srcdir)/config.h.in \
 	$(srcdir)/gst-plugins-base.spec.in \
@@ -286,8 +287,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -458,7 +465,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/NEWS b/NEWS
index ccdee24..cd55c3c 100644
--- a/NEWS
+++ b/NEWS
@@ -1,4 +1,11 @@
-This is GStreamer Base Plug-ins 0.11.91 "Fee-fi-fo-fum"
+This is GStreamer Base Plug-ins 0.11.92 "Comfortably Numb"
+
+New in 0.11.92:
+
+      * Parallel installability with 0.10.x series
+      * API cleanup and minor API improvements
+      * Major cleanup of video/audio libraries
+      * Lots of bugfixes, cleanup and other improvements
 
 New in 0.11.91:
 
diff --git a/RELEASE b/RELEASE
index ef83aa2..1609b3a 100644
--- a/RELEASE
+++ b/RELEASE
@@ -1,5 +1,5 @@
 
-Release notes for GStreamer Base Plug-ins 0.11.91 "Fee-fi-fo-fum"
+Release notes for GStreamer Base Plug-ins 0.11.92 "Comfortably Numb"
         
 
 
@@ -8,6 +8,7 @@
 GStreamer Base Plug-ins.
 
 
+
 The 0.11.x series is an unstable series targeted at developers.
 It is not API or ABI compatible with the stable 0.10.x series.
 It is, however, parallel installable with the 0.10.x series.
@@ -56,11 +57,9 @@
 Features of this release
     
       * Parallel installability with 0.10.x series
-      * Threadsafe design and API
-      * Compressed audio passthrough support in alsasink
-      * Removal of interfaces library, mixer and tuner interface
-      * Addition of video encoder and decoder base classes
-      * Improvements/cleanup for the video library API
+      * API cleanup and minor API improvements
+      * Major cleanup of video/audio libraries
+      * Lots of bugfixes, cleanup and other improvements
 There were no bugs fixed in this release
     
 
@@ -91,22 +90,24 @@
   
 Contributors to this release
     
-      * Akihiro Tsukada
-      * Alessandro Decina
+      * Alban Browaeys
       * Andoni Morales Alastruey
+      * Andre Moreira Magalhaes (andrunko)
+      * Anton Belka
+      * Arun Raghavan
+      * Bastien Nocera
+      * David Svensson Fors
       * Edward Hervey
-      * Julian Scheel
+      * Idar Tollefsen
       * Mark Nauwelaerts
       * Matej Knopp
-      * Nicolas Dufresne
-      * Reynaldo H. Verdejo Pinochet
+      * Raimo Järvi
       * Sebastian Dröge
       * Sebastian Rasmussen
+      * Sreerenj Balachandran
       * Stefan Sauer
-      * Thibault Saunier
+      * Thiago Santos
       * Tim-Philipp Müller
-      * Vivia Nikolaidou
-      * Víctor Manuel Jáquez Leal
+      * Vincent Penquerc'h
       * Wim Taymans
-      * Руслан Ижбулатов
  
\ No newline at end of file
diff --git a/common/Makefile.in b/common/Makefile.in
index af1e480..f44b79e 100644
--- a/common/Makefile.in
+++ b/common/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = common
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ChangeLog
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -251,8 +252,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -423,7 +430,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/common/gstdoc-scangobj b/common/gstdoc-scangobj
index b0699c7..0d69a86 100755
--- a/common/gstdoc-scangobj
+++ b/common/gstdoc-scangobj
@@ -245,11 +245,13 @@
       if (gst_plugin_get_filename (plugin) == NULL)
         continue;
 
-      $debug_log ("plugin: %s source: %s", plugin->desc.name, source);
+      $debug_log ("plugin: %s source: %s", gst_plugin_get_name (plugin), source);
 
       if (reinspect) {
+        gchar *basename;
+
         inspect_name = g_strdup_printf ("$INSPECT_DIR" G_DIR_SEPARATOR_S "plugin-%s.xml",
-            plugin->desc.name);
+            gst_plugin_get_name (plugin));
         inspect = fopen (inspect_name, "w");
         if (inspect == NULL) {
           g_error ("Could not open %s for writing: %s\\n", inspect_name,
@@ -257,23 +259,27 @@
         }
         g_free (inspect_name);
 
+		  basename = g_path_get_basename (gst_plugin_get_filename (plugin));
+
         /* output plugin data */
         fputs ("<plugin>\\n",inspect);
-        fputs (xmlprint(2, "name", plugin->desc.name),inspect);
-        fputs (xmlprint(2, "description", plugin->desc.description),inspect);
-        fputs (xmlprint(2, "filename", plugin->filename),inspect);
-        fputs (xmlprint(2, "basename", plugin->basename),inspect);
-        fputs (xmlprint(2, "version", plugin->desc.version),inspect);
-        fputs (xmlprint(2, "license", plugin->desc.license),inspect);
-        fputs (xmlprint(2, "source", plugin->desc.source),inspect);
-        fputs (xmlprint(2, "package", plugin->desc.package),inspect);
-        fputs (xmlprint(2, "origin", plugin->desc.origin),inspect);
+        fputs (xmlprint(2, "name", gst_plugin_get_name (plugin)),inspect);
+        fputs (xmlprint(2, "description", gst_plugin_get_description (plugin)),inspect);
+        fputs (xmlprint(2, "filename", gst_plugin_get_filename (plugin)),inspect);
+        fputs (xmlprint(2, "basename", basename),inspect);
+        fputs (xmlprint(2, "version", gst_plugin_get_version (plugin)),inspect);
+        fputs (xmlprint(2, "license", gst_plugin_get_license (plugin)),inspect);
+        fputs (xmlprint(2, "source", gst_plugin_get_source (plugin)),inspect);
+        fputs (xmlprint(2, "package", gst_plugin_get_package (plugin)),inspect);
+        fputs (xmlprint(2, "origin", gst_plugin_get_origin (plugin)),inspect);
         fputs ("  <elements>\\n", inspect);
+
+		  g_free (basename);
       }
 
       features =
           gst_registry_get_feature_list_by_plugin (gst_registry_get (),
-          plugin->desc.name);
+          gst_plugin_get_name (plugin));
 
       /* sort factories by feature->name */
       features = g_list_sort (features, gst_feature_sort_compare);
diff --git a/common/m4/Makefile.am b/common/m4/Makefile.am
index 2ddb8a7..856d6e3 100644
--- a/common/m4/Makefile.am
+++ b/common/m4/Makefile.am
@@ -8,7 +8,6 @@
 	as-gcc-inline-assembly.m4 \
 	as-libtool.m4 \
 	as-libtool-tags.m4 \
-	as-objc.m4 \
 	as-python.m4 \
 	as-scrub-include.m4 \
 	as-version.m4 \
diff --git a/common/m4/Makefile.in b/common/m4/Makefile.in
index 54c8607..185abb4 100644
--- a/common/m4/Makefile.in
+++ b/common/m4/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = common/m4
 DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -211,8 +212,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -383,7 +390,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
@@ -397,7 +408,6 @@
 	as-gcc-inline-assembly.m4 \
 	as-libtool.m4 \
 	as-libtool-tags.m4 \
-	as-objc.m4 \
 	as-python.m4 \
 	as-scrub-include.m4 \
 	as-version.m4 \
diff --git a/common/m4/as-compiler-flag.m4 b/common/m4/as-compiler-flag.m4
index 882a4c7..8bb853a 100644
--- a/common/m4/as-compiler-flag.m4
+++ b/common/m4/as-compiler-flag.m4
@@ -62,3 +62,35 @@
   AC_MSG_RESULT([$flag_ok])
 ])
 
+dnl AS_OBJC_COMPILER_FLAG(CPPFLAGS, ACTION-IF-ACCEPTED, [ACTION-IF-NOT-ACCEPTED])
+dnl Tries to compile with the given CPPFLAGS.
+dnl Runs ACTION-IF-ACCEPTED if the compiler can compile with the flags,
+dnl and ACTION-IF-NOT-ACCEPTED otherwise.
+
+AC_DEFUN([AS_OBJC_COMPILER_FLAG],
+[
+  AC_REQUIRE([AC_PROG_OBJC])
+
+  AC_MSG_CHECKING([to see if Objective C compiler understands $1])
+
+  save_CPPFLAGS="$CPPFLAGS"
+  CPPFLAGS="$CPPFLAGS $1"
+
+  AC_LANG_PUSH([Objective C])
+
+  AC_TRY_COMPILE([ ], [], [flag_ok=yes], [flag_ok=no])
+  CPPFLAGS="$save_CPPFLAGS"
+
+  if test "X$flag_ok" = Xyes ; then
+    $2
+    true
+  else
+    $3
+    true
+  fi
+
+  AC_LANG_POP([Objective C])
+
+  AC_MSG_RESULT([$flag_ok])
+])
+
diff --git a/common/m4/as-objc.m4 b/common/m4/as-objc.m4
deleted file mode 100644
index 1e7066a..0000000
--- a/common/m4/as-objc.m4
+++ /dev/null
@@ -1,56 +0,0 @@
-
-
-# AC_PROG_OBJC([LIST-OF-COMPILERS])
-#
-AC_DEFUN([AS_PROG_OBJC],
-[
-AC_CHECK_TOOLS(OBJC,
-	[m4_default([$1], [objcc objc gcc cc CC])],
-	none)
-AC_SUBST(OBJC)
-OBJC_LDFLAGS="-lobjc"
-AC_SUBST(OBJC_LDFLAGS)
-if test "x$OBJC" != xnone ; then
-  _AM_DEPENDENCIES(OBJC)
-  AC_MSG_CHECKING([if Objective C compiler works])
-  cat >>conftest.m <<EOF
-#include <objc/Object.h>
-@interface Moo:Object
-{
-}
-- moo;
-int main();
-@end
-
-@implementation Moo
-- moo
-{
-  exit(0);
-}
-
-int main()
-{
-  id moo;
-  moo = [[Moo new]];
-  [[moo moo]];
-  return 1;
-}
-@end
-EOF
-  ${OBJC} conftest.m ${OBJC_LDFLAGS} >&5 2>&5
-  if test -f a.out -o -f a.exe ; then
-    result=yes
-  else
-    result=no
-    echo failed program is: >&5
-    cat conftest.m >&5
-  fi
-  rm -f conftest.m a.out a.exe
-  AC_MSG_RESULT([$result])
-else
-  _AM_DEPENDENCIES(OBJC)
-fi
-
-])
-
-
diff --git a/common/m4/gst-arch.m4 b/common/m4/gst-arch.m4
index 2e935d2..ff0954a 100644
--- a/common/m4/gst-arch.m4
+++ b/common/m4/gst-arch.m4
@@ -6,31 +6,32 @@
 AC_DEFUN([AG_GST_ARCH],
 [
   AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use host_ variables
+  AC_REQUIRE([AC_CANONICAL_TARGET]) dnl we use target_ variables
 
   dnl Determine CPU
-  case "x${host_cpu}" in
+  case "x${target_cpu}" in
     xi?86 | xk? | xi?86_64)
-      case $host_os in
+      case $target_os in
          solaris*)
             AC_CHECK_DECL([__i386],	[I386_ABI="yes"], [I386_ABI="no"])
             AC_CHECK_DECL([__amd64], [AMD64_ABI="yes"], [AMD64_ABI="no"])
 
             if test "x$I386_ABI" = "xyes" ; then
                HAVE_CPU_I386=yes
-               AC_DEFINE(HAVE_CPU_I386, 1, [Define if the host CPU is an x86])
+               AC_DEFINE(HAVE_CPU_I386, 1, [Define if the target CPU is an x86])
             fi
             if test "x$AMD64_ABI" = "xyes" ; then
                 HAVE_CPU_X86_64=yes
-                AC_DEFINE(HAVE_CPU_X86_64, 1, [Define if the host CPU is a x86_64])
+                AC_DEFINE(HAVE_CPU_X86_64, 1, [Define if the target CPU is a x86_64])
             fi
             ;;
          *)
             HAVE_CPU_I386=yes
-            AC_DEFINE(HAVE_CPU_I386, 1, [Define if the host CPU is an x86])
+            AC_DEFINE(HAVE_CPU_I386, 1, [Define if the target CPU is an x86])
 
             dnl FIXME could use some better detection
             dnl (ie CPUID)
-            case "x${host_cpu}" in
+            case "x${target_cpu}" in
               xi386 | xi486) ;;
             *)
               AC_DEFINE(HAVE_RDTSC, 1, [Define if RDTSC is available]) ;;
@@ -40,43 +41,43 @@
       ;;
     xpowerpc)
       HAVE_CPU_PPC=yes
-      AC_DEFINE(HAVE_CPU_PPC, 1, [Define if the host CPU is a PowerPC]) ;;
+      AC_DEFINE(HAVE_CPU_PPC, 1, [Define if the target CPU is a PowerPC]) ;;
     xpowerpc64)
       HAVE_CPU_PPC64=yes
-      AC_DEFINE(HAVE_CPU_PPC64, 1, [Define if the host CPU is a 64 bit PowerPC]) ;;
+      AC_DEFINE(HAVE_CPU_PPC64, 1, [Define if the target CPU is a 64 bit PowerPC]) ;;
     xalpha*)
       HAVE_CPU_ALPHA=yes
-      AC_DEFINE(HAVE_CPU_ALPHA, 1, [Define if the host CPU is an Alpha]) ;;
+      AC_DEFINE(HAVE_CPU_ALPHA, 1, [Define if the target CPU is an Alpha]) ;;
     xarm*)
       HAVE_CPU_ARM=yes
-      AC_DEFINE(HAVE_CPU_ARM, 1, [Define if the host CPU is an ARM]) ;;
+      AC_DEFINE(HAVE_CPU_ARM, 1, [Define if the target CPU is an ARM]) ;;
     xsparc*)
       HAVE_CPU_SPARC=yes
-      AC_DEFINE(HAVE_CPU_SPARC, 1, [Define if the host CPU is a SPARC]) ;;
+      AC_DEFINE(HAVE_CPU_SPARC, 1, [Define if the target CPU is a SPARC]) ;;
     xmips*)
       HAVE_CPU_MIPS=yes
-      AC_DEFINE(HAVE_CPU_MIPS, 1, [Define if the host CPU is a MIPS]) ;;
+      AC_DEFINE(HAVE_CPU_MIPS, 1, [Define if the target CPU is a MIPS]) ;;
     xhppa*)
       HAVE_CPU_HPPA=yes
-      AC_DEFINE(HAVE_CPU_HPPA, 1, [Define if the host CPU is a HPPA]) ;;
+      AC_DEFINE(HAVE_CPU_HPPA, 1, [Define if the target CPU is a HPPA]) ;;
     xs390*)
       HAVE_CPU_S390=yes
-      AC_DEFINE(HAVE_CPU_S390, 1, [Define if the host CPU is a S390]) ;;
+      AC_DEFINE(HAVE_CPU_S390, 1, [Define if the target CPU is a S390]) ;;
     xia64*)
       HAVE_CPU_IA64=yes
-      AC_DEFINE(HAVE_CPU_IA64, 1, [Define if the host CPU is a IA64]) ;;
+      AC_DEFINE(HAVE_CPU_IA64, 1, [Define if the target CPU is a IA64]) ;;
     xm68k*)
       HAVE_CPU_M68K=yes
-      AC_DEFINE(HAVE_CPU_M68K, 1, [Define if the host CPU is a M68K]) ;;
+      AC_DEFINE(HAVE_CPU_M68K, 1, [Define if the target CPU is a M68K]) ;;
     xx86_64)
       HAVE_CPU_X86_64=yes
-      AC_DEFINE(HAVE_CPU_X86_64, 1, [Define if the host CPU is a x86_64]) ;;
+      AC_DEFINE(HAVE_CPU_X86_64, 1, [Define if the target CPU is a x86_64]) ;;
     xcris)
       HAVE_CPU_CRIS=yes
-      AC_DEFINE(HAVE_CPU_CRIS, 1, [Define if the host CPU is a CRIS]) ;;
+      AC_DEFINE(HAVE_CPU_CRIS, 1, [Define if the target CPU is a CRIS]) ;;
     xcrisv32)
       HAVE_CPU_CRISV32=yes
-      AC_DEFINE(HAVE_CPU_CRISV32, 1, [Define if the host CPU is a CRISv32]) ;;
+      AC_DEFINE(HAVE_CPU_CRISV32, 1, [Define if the target CPU is a CRISv32]) ;;
   esac
 
   dnl Determine endianness
@@ -98,6 +99,7 @@
   AM_CONDITIONAL(HAVE_CPU_CRISV32,    test "x$HAVE_CPU_CRISV32" = "xyes")
 
   AC_DEFINE_UNQUOTED(HOST_CPU, "$host_cpu", [the host CPU])
+  AC_DEFINE_UNQUOTED(TARGET_CPU, "$target_cpu", [the target CPU])
 ])
 
 dnl check if unaligned memory access works correctly
diff --git a/common/m4/gst-args.m4 b/common/m4/gst-args.m4
index 2dc0184..4872e3c 100644
--- a/common/m4/gst-args.m4
+++ b/common/m4/gst-args.m4
@@ -111,13 +111,13 @@
     dnl if gcov is used, we do not want default -O2 CFLAGS
     if test "x$GST_GCOV_ENABLED" = "xyes"
     then
-      CFLAGS="-O0"
+      CFLAGS="$CFLAGS -O0"
       AC_SUBST(CFLAGS)
-      CXXFLAGS="-O0"
+      CXXFLAGS="$CXXFLAGS -O0"
       AC_SUBST(CXXFLAGS)
-      FFLAGS="-O0"
+      FFLAGS="$FFLAGS -O0"
       AC_SUBST(FFLAGS)
-      CCASFLAGS="-O0"
+      CCASFLAGS="$CCASFLAGS -O0"
       AC_SUBST(CCASFLAGS)
       AC_MSG_NOTICE([gcov enabled, setting CFLAGS and friends to $CFLAGS])
     fi
diff --git a/common/m4/gst-error.m4 b/common/m4/gst-error.m4
index f8f2364..e12a04c 100644
--- a/common/m4/gst-error.m4
+++ b/common/m4/gst-error.m4
@@ -196,6 +196,91 @@
   AC_MSG_NOTICE([set ERROR_CXXFLAGS to $ERROR_CXXFLAGS])
 ])
 
+dnl Sets WARNING_OBJCFLAGS and ERROR_OBJCFLAGS to something the compiler 
+dnl will accept and AC_SUBST them so they are available in Makefile
+dnl
+dnl WARNING_OBJCFLAGS will contain flags to make the compiler emit more
+dnl   warnings.
+dnl ERROR_OBJCFLAGS will contain flags to make those warnings fatal,
+dnl   unless ADD-WERROR is set to "no"
+dnl 
+dnl If MORE_FLAGS is set, tries to add each of the given flags
+dnl to WARNING_CFLAGS if the compiler supports them. Each flag is 
+dnl tested separately.
+dnl
+dnl These flags can be overridden at make time:
+dnl make ERROR_OBJCFLAGS=
+AC_DEFUN([AG_GST_SET_ERROR_OBJCFLAGS],
+[
+  AC_REQUIRE([AC_PROG_OBJC])
+  AC_REQUIRE([AS_OBJC_COMPILER_FLAG])
+
+  ERROR_OBJCFLAGS=""
+  WARNING_OBJCFLAGS=""
+
+  dnl if we support -Wall, set it unconditionally
+  AS_OBJC_COMPILER_FLAG(-Wall, WARNING_OBJCFLAGS="$WARNING_OBJCFLAGS -Wall")
+
+  dnl if asked for, add -Werror if supported
+  if test "x$1" != "xno"
+  then
+    AS_OBJC_COMPILER_FLAG(-Werror, ERROR_OBJCFLAGS="$ERROR_OBJCFLAGS -Werror")
+
+    if test "x$ERROR_OBJCFLAGS" != "x"
+    then
+	dnl Add -fno-strict-aliasing for GLib versions before 2.19.8
+	dnl as before G_LOCK and friends caused strict aliasing compiler
+	dnl warnings.
+	PKG_CHECK_EXISTS([glib-2.0 < 2.19.8], [
+	  AS_OBJC_COMPILER_FLAG([-fno-strict-aliasing],
+	    ERROR_OBJCFLAGS="$ERROR_OBJCFLAGS -fno-strict-aliasing")
+	  ])
+    else
+      dnl if -Werror isn't suported, try -errwarn=%all
+      AS_OBJC_COMPILER_FLAG([-errwarn=%all], ERROR_OBJCFLAGS="$ERROR_OBJCFLAGS -errwarn=%all")
+      if test "x$ERROR_OBJCFLAGS" != "x"; then
+        dnl try -errwarn=%all,no%E_EMPTY_DECLARATION,
+        dnl no%E_STATEMENT_NOT_REACHED,no%E_ARGUEMENT_MISMATCH,
+        dnl no%E_MACRO_REDEFINED (Sun Forte case)
+        dnl For Forte we need disable "empty declaration" warning produced by un-needed semicolon
+        dnl "statement not reached" disabled because there is g_assert_not_reached () in some places
+        dnl "macro redefined" because of gst/gettext.h
+        dnl FIXME: is it really supposed to be 'ARGUEMENT' and not 'ARGUMENT'?
+        dnl FIXME: do any of these work with the c++ compiler? if not, why
+        dnl do we check at all?
+        for f in 'no%E_EMPTY_DECLARATION' \
+                 'no%E_STATEMENT_NOT_REACHED' \
+                 'no%E_ARGUEMENT_MISMATCH' \
+                 'no%E_MACRO_REDEFINED' \
+                 'no%E_LOOP_NOT_ENTERED_AT_TOP'
+        do
+          AS_OBJC_COMPILER_FLAG([-errwarn=%all,$f], ERROR_OBJCFLAGS="$ERROR_OBJCFLAGS,$f")
+        done
+      fi
+    fi
+  fi
+
+  if test "x$2" != "x"
+  then
+    UNSUPPORTED=""
+    list="$2"
+    for each in $list
+    do
+      AS_OBJC_COMPILER_FLAG($each,
+          WARNING_OBJCFLAGS="$WARNING_OBJCFLAGS $each",
+          UNSUPPORTED="$UNSUPPORTED $each")
+    done
+    if test "X$UNSUPPORTED" != X ; then
+      AC_MSG_NOTICE([unsupported compiler flags: $UNSUPPORTED])
+    fi
+  fi
+
+  AC_SUBST(WARNING_OBJCFLAGS)
+  AC_SUBST(ERROR_OBJCFLAGS)
+  AC_MSG_NOTICE([set WARNING_OBJCFLAGS to $WARNING_OBJCFLAGS])
+  AC_MSG_NOTICE([set ERROR_OBJCFLAGS to $ERROR_OBJCFLAGS])
+])
+
 dnl Sets the default error level for debugging messages
 AC_DEFUN([AG_GST_SET_LEVEL_DEFAULT],
 [
diff --git a/common/m4/gtk-doc.m4 b/common/m4/gtk-doc.m4
index 39a4e7d..0c1a305 100644
--- a/common/m4/gtk-doc.m4
+++ b/common/m4/gtk-doc.m4
@@ -6,8 +6,15 @@
 dnl   GTK_DOC_CHECK([minimum-gtk-doc-version])
 AC_DEFUN([GTK_DOC_CHECK],
 [
+  AC_REQUIRE([PKG_PROG_PKG_CONFIG])
   AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
   AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
+
+  dnl check for tools we added during development
+  AC_PATH_PROG([GTKDOC_CHECK],[gtkdoc-check])
+  AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true])
+  AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf])
+
   dnl for overriding the documentation installation directory
   AC_ARG_WITH([html-dir],
     AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
@@ -26,7 +33,13 @@
       [PKG_CHECK_EXISTS([gtk-doc],,
                         AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))],
       [PKG_CHECK_EXISTS([gtk-doc >= $1],,
-                        AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build gtk-doc]))])
+                        AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build $PACKAGE_NAME]))])
+    dnl don't check for glib if we build glib
+    if test "x$PACKAGE_NAME" != "xglib"; then
+      dnl don't fail if someone does not have glib
+      PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0,,)
+    fi
+    dnl don't rely on sed being pulled in implicitly. Fixes Solaris build.
     if test -z "$SED"; then
       AC_PROG_SED
     fi
@@ -35,8 +48,24 @@
   AC_MSG_CHECKING([whether to build gtk-doc documentation])
   AC_MSG_RESULT($enable_gtk_doc)
 
-  AC_PATH_PROGS(GTKDOC_CHECK,gtkdoc-check,)
+  dnl enable/disable output formats
+  AC_ARG_ENABLE([gtk-doc-html],
+    AS_HELP_STRING([--enable-gtk-doc-html],
+                   [build documentation in html format [[default=yes]]]),,
+    [enable_gtk_doc_html=yes])
+    AC_ARG_ENABLE([gtk-doc-pdf],
+      AS_HELP_STRING([--enable-gtk-doc-pdf],
+                     [build documentation in pdf format [[default=no]]]),,
+      [enable_gtk_doc_pdf=no])
+
+  if test -z "$GTKDOC_MKPDF"; then
+    enable_gtk_doc_pdf=no
+  fi
+
 
   AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
+  AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
+  AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])
   AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"])
+  AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"])
 ])
diff --git a/config.h.in b/config.h.in
index 0e8d8b0..8c517bc 100644
--- a/config.h.in
+++ b/config.h.in
@@ -100,46 +100,46 @@
    the CoreFoundation framework. */
 #undef HAVE_CFPREFERENCESCOPYAPPVALUE
 
-/* Define if the host CPU is an Alpha */
+/* Define if the target CPU is an Alpha */
 #undef HAVE_CPU_ALPHA
 
-/* Define if the host CPU is an ARM */
+/* Define if the target CPU is an ARM */
 #undef HAVE_CPU_ARM
 
-/* Define if the host CPU is a CRIS */
+/* Define if the target CPU is a CRIS */
 #undef HAVE_CPU_CRIS
 
-/* Define if the host CPU is a CRISv32 */
+/* Define if the target CPU is a CRISv32 */
 #undef HAVE_CPU_CRISV32
 
-/* Define if the host CPU is a HPPA */
+/* Define if the target CPU is a HPPA */
 #undef HAVE_CPU_HPPA
 
-/* Define if the host CPU is an x86 */
+/* Define if the target CPU is an x86 */
 #undef HAVE_CPU_I386
 
-/* Define if the host CPU is a IA64 */
+/* Define if the target CPU is a IA64 */
 #undef HAVE_CPU_IA64
 
-/* Define if the host CPU is a M68K */
+/* Define if the target CPU is a M68K */
 #undef HAVE_CPU_M68K
 
-/* Define if the host CPU is a MIPS */
+/* Define if the target CPU is a MIPS */
 #undef HAVE_CPU_MIPS
 
-/* Define if the host CPU is a PowerPC */
+/* Define if the target CPU is a PowerPC */
 #undef HAVE_CPU_PPC
 
-/* Define if the host CPU is a 64 bit PowerPC */
+/* Define if the target CPU is a 64 bit PowerPC */
 #undef HAVE_CPU_PPC64
 
-/* Define if the host CPU is a S390 */
+/* Define if the target CPU is a S390 */
 #undef HAVE_CPU_S390
 
-/* Define if the host CPU is a SPARC */
+/* Define if the target CPU is a SPARC */
 #undef HAVE_CPU_SPARC
 
-/* Define if the host CPU is a x86_64 */
+/* Define if the target CPU is a x86_64 */
 #undef HAVE_CPU_X86_64
 
 /* Define if the GNU dcgettext() function is already present or preinstalled.
@@ -342,6 +342,9 @@
 /* Define to 1 if you have the ANSI C header files. */
 #undef STDC_HEADERS
 
+/* the target CPU */
+#undef TARGET_CPU
+
 /* "Define if building for android" */
 #undef USE_TREMOLO
 
diff --git a/configure b/configure
index 810fc4a..926ccf5 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for GStreamer Base Plug-ins 0.11.91.
+# Generated by GNU Autoconf 2.69 for GStreamer Base Plug-ins 0.11.92.
 #
 # Report bugs to <http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer>.
 #
@@ -591,8 +591,8 @@
 # Identity of this package.
 PACKAGE_NAME='GStreamer Base Plug-ins'
 PACKAGE_TARNAME='gst-plugins-base'
-PACKAGE_VERSION='0.11.91'
-PACKAGE_STRING='GStreamer Base Plug-ins 0.11.91'
+PACKAGE_VERSION='0.11.92'
+PACKAGE_STRING='GStreamer Base Plug-ins 0.11.92'
 PACKAGE_BUGREPORT='http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer'
 PACKAGE_URL=''
 
@@ -772,10 +772,14 @@
 QT4_MOC
 QT_LIBS
 QT_CFLAGS
+HAVE_GTK_QUARTZ_FALSE
+HAVE_GTK_QUARTZ_TRUE
 HAVE_GTK_X11_FALSE
 HAVE_GTK_X11_TRUE
 HAVE_GTK_FALSE
 HAVE_GTK_TRUE
+GTK_QUARTZ_LIBS
+GTK_QUARTZ_CFLAGS
 GTK_X11_LIBS
 GTK_X11_CFLAGS
 GTK_LIBS
@@ -825,12 +829,22 @@
 PYTHON_PREFIX
 PYTHON_VERSION
 PYTHON
+GTK_DOC_USE_REBASE_FALSE
+GTK_DOC_USE_REBASE_TRUE
 GTK_DOC_USE_LIBTOOL_FALSE
 GTK_DOC_USE_LIBTOOL_TRUE
+GTK_DOC_BUILD_PDF_FALSE
+GTK_DOC_BUILD_PDF_TRUE
+GTK_DOC_BUILD_HTML_FALSE
+GTK_DOC_BUILD_HTML_TRUE
 ENABLE_GTK_DOC_FALSE
 ENABLE_GTK_DOC_TRUE
-GTKDOC_CHECK
+GTKDOC_DEPS_LIBS
+GTKDOC_DEPS_CFLAGS
 HTML_DIR
+GTKDOC_MKPDF
+GTKDOC_REBASE
+GTKDOC_CHECK
 HAVE_INTROSPECTION_FALSE
 HAVE_INTROSPECTION_TRUE
 INTROSPECTION_MAKEFILE
@@ -880,6 +894,10 @@
 HAVE_CPU_PPC_TRUE
 HAVE_CPU_I386_FALSE
 HAVE_CPU_I386_TRUE
+target_os
+target_vendor
+target_cpu
+target
 BUILD_EXPERIMENTAL_FALSE
 BUILD_EXPERIMENTAL_TRUE
 USE_EXPERIMENTAL_FALSE
@@ -1093,6 +1111,8 @@
 enable_introspection
 with_html_dir
 enable_gtk_doc
+enable_gtk_doc_html
+enable_gtk_doc_pdf
 enable_gobject_cast_checks
 enable_glib_asserts
 enable_orc
@@ -1165,6 +1185,8 @@
 CXXFLAGS
 CCC
 CXXCPP
+GTKDOC_DEPS_CFLAGS
+GTKDOC_DEPS_LIBS
 GLIB_CFLAGS
 GLIB_LIBS
 GIO_CFLAGS
@@ -1183,6 +1205,8 @@
 GTK_LIBS
 GTK_X11_CFLAGS
 GTK_X11_LIBS
+GTK_QUARTZ_CFLAGS
+GTK_QUARTZ_LIBS
 QT_CFLAGS
 QT_LIBS
 ZLIB_CFLAGS
@@ -1746,7 +1770,7 @@
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures GStreamer Base Plug-ins 0.11.91 to adapt to many kinds of systems.
+\`configure' configures GStreamer Base Plug-ins 0.11.92 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1816,12 +1840,13 @@
 System types:
   --build=BUILD     configure for building on BUILD [guessed]
   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
+  --target=TARGET   configure for building compilers for TARGET [HOST]
 _ACEOF
 fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of GStreamer Base Plug-ins 0.11.91:";;
+     short | recursive ) echo "Configuration of GStreamer Base Plug-ins 0.11.92:";;
    esac
   cat <<\_ACEOF
 
@@ -1856,6 +1881,8 @@
   --enable-introspection=[no/auto/yes]
                           Enable introspection for this build
   --enable-gtk-doc        use gtk-doc to build documentation [[default=no]]
+  --enable-gtk-doc-html   build documentation in html format [[default=yes]]
+  --enable-gtk-doc-pdf    build documentation in pdf format [[default=no]]
   --enable-gobject-cast-checks=[no/auto/yes]
                           Enable GObject cast checks
   --enable-glib-asserts=[no/auto/yes]
@@ -1971,6 +1998,10 @@
   CXX         C++ compiler command
   CXXFLAGS    C++ compiler flags
   CXXCPP      C++ preprocessor
+  GTKDOC_DEPS_CFLAGS
+              C compiler flags for GTKDOC_DEPS, overriding pkg-config
+  GTKDOC_DEPS_LIBS
+              linker flags for GTKDOC_DEPS, overriding pkg-config
   GLIB_CFLAGS C compiler flags for GLIB, overriding pkg-config
   GLIB_LIBS   linker flags for GLIB, overriding pkg-config
   GIO_CFLAGS  C compiler flags for GIO, overriding pkg-config
@@ -1997,6 +2028,10 @@
               C compiler flags for GTK_X11, overriding pkg-config
   GTK_X11_LIBS
               linker flags for GTK_X11, overriding pkg-config
+  GTK_QUARTZ_CFLAGS
+              C compiler flags for GTK_QUARTZ, overriding pkg-config
+  GTK_QUARTZ_LIBS
+              linker flags for GTK_QUARTZ, overriding pkg-config
   QT_CFLAGS   C compiler flags for QT, overriding pkg-config
   QT_LIBS     linker flags for QT, overriding pkg-config
   ZLIB_CFLAGS C compiler flags for ZLIB, overriding pkg-config
@@ -2096,7 +2131,7 @@
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-GStreamer Base Plug-ins configure 0.11.91
+GStreamer Base Plug-ins configure 0.11.92
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2538,97 +2573,6 @@
 
 } # ac_fn_cxx_try_link
 
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
-  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
-  if eval \${$3+:} false; then :
-  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
-  $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
-	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
-  # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-  ac_header_compiler=yes
-else
-  ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h.  */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-  ac_header_preproc=yes
-else
-  ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
-  yes:no: )
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
-    ;;
-  no:yes:* )
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
-( $as_echo "## ------------------------------------------------------------------------ ##
-## Report this to http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer ##
-## ------------------------------------------------------------------------ ##"
-     ) | sed "s/^/$as_me: WARNING:     /" >&2
-    ;;
-esac
-  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
-  $as_echo_n "(cached) " >&6
-else
-  eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
-	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
-  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
 # -------------------------------------------
 # Tests whether TYPE exists after having included INCLUDES, setting cache
@@ -2865,11 +2809,102 @@
   as_fn_set_status $ac_retval
 
 } # ac_fn_c_compute_int
+
+# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
+# -------------------------------------------------------
+# Tests whether HEADER exists, giving a warning if it cannot be compiled using
+# the include files in INCLUDES and setting the cache variable VAR
+# accordingly.
+ac_fn_c_check_header_mongrel ()
+{
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+  if eval \${$3+:} false; then :
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+$as_echo_n "checking for $2... " >&6; }
+if eval \${$3+:} false; then :
+  $as_echo_n "(cached) " >&6
+fi
+eval ac_res=\$$3
+	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+else
+  # Is the header compilable?
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
+$as_echo_n "checking $2 usability... " >&6; }
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+$4
+#include <$2>
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_header_compiler=yes
+else
+  ac_header_compiler=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
+$as_echo "$ac_header_compiler" >&6; }
+
+# Is the header present?
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
+$as_echo_n "checking $2 presence... " >&6; }
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+#include <$2>
+_ACEOF
+if ac_fn_c_try_cpp "$LINENO"; then :
+  ac_header_preproc=yes
+else
+  ac_header_preproc=no
+fi
+rm -f conftest.err conftest.i conftest.$ac_ext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
+$as_echo "$ac_header_preproc" >&6; }
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
+  yes:no: )
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
+$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
+    ;;
+  no:yes:* )
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
+$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
+$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
+$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
+$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
+( $as_echo "## ------------------------------------------------------------------------ ##
+## Report this to http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer ##
+## ------------------------------------------------------------------------ ##"
+     ) | sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+$as_echo_n "checking for $2... " >&6; }
+if eval \${$3+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  eval "$3=\$ac_header_compiler"
+fi
+eval ac_res=\$$3
+	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+fi
+  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
+
+} # ac_fn_c_check_header_mongrel
 cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by GStreamer Base Plug-ins $as_me 0.11.91, which was
+It was created by GStreamer Base Plug-ins $as_me 0.11.92, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -3690,7 +3725,7 @@
 
 # Define the identity of the package.
  PACKAGE='gst-plugins-base'
- VERSION='0.11.91'
+ VERSION='0.11.92'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3813,9 +3848,9 @@
 
 
 
-  PACKAGE_VERSION_MAJOR=$(echo 0.11.91 | cut -d'.' -f1)
-  PACKAGE_VERSION_MINOR=$(echo 0.11.91 | cut -d'.' -f2)
-  PACKAGE_VERSION_MICRO=$(echo 0.11.91 | cut -d'.' -f3)
+  PACKAGE_VERSION_MAJOR=$(echo 0.11.92 | cut -d'.' -f1)
+  PACKAGE_VERSION_MINOR=$(echo 0.11.92 | cut -d'.' -f2)
+  PACKAGE_VERSION_MICRO=$(echo 0.11.92 | cut -d'.' -f3)
 
 
 
@@ -3826,7 +3861,7 @@
   { $as_echo "$as_me:${as_lineno-$LINENO}: checking nano version" >&5
 $as_echo_n "checking nano version... " >&6; }
 
-  NANO=$(echo 0.11.91 | cut -d'.' -f4)
+  NANO=$(echo 0.11.92 | cut -d'.' -f4)
 
   if test x"$NANO" = x || test "x$NANO" = "x0" ; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: 0 (release)" >&5
@@ -12815,7 +12850,7 @@
 
 
 
-GST_REQ=0.11.90
+GST_REQ=0.11.91
 
 
 
@@ -15187,13 +15222,13 @@
 
         if test "x$GST_GCOV_ENABLED" = "xyes"
     then
-      CFLAGS="-O0"
+      CFLAGS="$CFLAGS -O0"
 
-      CXXFLAGS="-O0"
+      CXXFLAGS="$CXXFLAGS -O0"
 
-      FFLAGS="-O0"
+      FFLAGS="$FFLAGS -O0"
 
-      CCASFLAGS="-O0"
+      CCASFLAGS="$CCASFLAGS -O0"
 
       { $as_echo "$as_me:${as_lineno-$LINENO}: gcov enabled, setting CFLAGS and friends to $CFLAGS" >&5
 $as_echo "$as_me: gcov enabled, setting CFLAGS and friends to $CFLAGS" >&6;}
@@ -15698,11 +15733,50 @@
 
 
 
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
+$as_echo_n "checking target system type... " >&6; }
+if ${ac_cv_target+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test "x$target_alias" = x; then
+  ac_cv_target=$ac_cv_host
+else
+  ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
+    as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
+fi
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
+$as_echo "$ac_cv_target" >&6; }
+case $ac_cv_target in
+*-*-*) ;;
+*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
+esac
+target=$ac_cv_target
+ac_save_IFS=$IFS; IFS='-'
+set x $ac_cv_target
+shift
+target_cpu=$1
+target_vendor=$2
+shift; shift
+# Remember, the first character of IFS is used to create $*,
+# except with old shells:
+target_os=$*
+IFS=$ac_save_IFS
+case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
 
 
-    case "x${host_cpu}" in
+# The aliases save the names the user supplied, while $host etc.
+# will get canonicalized.
+test -n "$target_alias" &&
+  test "$program_prefix$program_suffix$program_transform_name" = \
+    NONENONEs,x,x, &&
+  program_prefix=${target_alias}-
+
+
+    case "x${target_cpu}" in
     xi?86 | xk? | xi?86_64)
-      case $host_os in
+      case $target_os in
          solaris*)
             ac_fn_c_check_decl "$LINENO" "__i386" "ac_cv_have_decl___i386" "$ac_includes_default"
 if test "x$ac_cv_have_decl___i386" = xyes; then :
@@ -15738,7 +15812,7 @@
 $as_echo "#define HAVE_CPU_I386 1" >>confdefs.h
 
 
-                                    case "x${host_cpu}" in
+                                    case "x${target_cpu}" in
               xi386 | xi486) ;;
             *)
 
@@ -16159,6 +16233,11 @@
 _ACEOF
 
 
+cat >>confdefs.h <<_ACEOF
+#define TARGET_CPU "$target_cpu"
+_ACEOF
+
+
 
 # Check whether --enable-largefile was given.
 if test "${enable_largefile+set}" = set; then :
@@ -21234,6 +21313,135 @@
 
 
 
+
+    # Extract the first word of "gtkdoc-check", so it can be a program name with args.
+set dummy gtkdoc-check; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_path_GTKDOC_CHECK+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $GTKDOC_CHECK in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_GTKDOC_CHECK="$GTKDOC_CHECK" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+    ac_cv_path_GTKDOC_CHECK="$as_dir/$ac_word$ac_exec_ext"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+  ;;
+esac
+fi
+GTKDOC_CHECK=$ac_cv_path_GTKDOC_CHECK
+if test -n "$GTKDOC_CHECK"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_CHECK" >&5
+$as_echo "$GTKDOC_CHECK" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+  for ac_prog in gtkdoc-rebase
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_path_GTKDOC_REBASE+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $GTKDOC_REBASE in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_GTKDOC_REBASE="$GTKDOC_REBASE" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+    ac_cv_path_GTKDOC_REBASE="$as_dir/$ac_word$ac_exec_ext"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+  ;;
+esac
+fi
+GTKDOC_REBASE=$ac_cv_path_GTKDOC_REBASE
+if test -n "$GTKDOC_REBASE"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_REBASE" >&5
+$as_echo "$GTKDOC_REBASE" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+  test -n "$GTKDOC_REBASE" && break
+done
+test -n "$GTKDOC_REBASE" || GTKDOC_REBASE="true"
+
+  # Extract the first word of "gtkdoc-mkpdf", so it can be a program name with args.
+set dummy gtkdoc-mkpdf; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_path_GTKDOC_MKPDF+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  case $GTKDOC_MKPDF in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_GTKDOC_MKPDF="$GTKDOC_MKPDF" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+    ac_cv_path_GTKDOC_MKPDF="$as_dir/$ac_word$ac_exec_ext"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+  ;;
+esac
+fi
+GTKDOC_MKPDF=$ac_cv_path_GTKDOC_MKPDF
+if test -n "$GTKDOC_MKPDF"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_MKPDF" >&5
+$as_echo "$GTKDOC_MKPDF" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+
+
 # Check whether --with-html-dir was given.
 if test "${with_html_dir+set}" = set; then :
   withval=$with_html_dir;
@@ -21261,9 +21469,101 @@
   test $ac_status = 0; }; then
   :
 else
-  as_fn_error $? "You need to have gtk-doc >= 1.3 installed to build gtk-doc" "$LINENO" 5
+  as_fn_error $? "You need to have gtk-doc >= 1.3 installed to build $PACKAGE_NAME" "$LINENO" 5
 fi
-    if test -z "$SED"; then
+        if test "x$PACKAGE_NAME" != "xglib"; then
+
+pkg_failed=no
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTKDOC_DEPS" >&5
+$as_echo_n "checking for GTKDOC_DEPS... " >&6; }
+
+if test -n "$PKG_CONFIG"; then
+    if test -n "$GTKDOC_DEPS_CFLAGS"; then
+        pkg_cv_GTKDOC_DEPS_CFLAGS="$GTKDOC_DEPS_CFLAGS"
+    else
+        if test -n "$PKG_CONFIG" && \
+    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0\""; } >&5
+  ($PKG_CONFIG --exists --print-errors "glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then
+  pkg_cv_GTKDOC_DEPS_CFLAGS=`$PKG_CONFIG --cflags "glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0" 2>/dev/null`
+else
+  pkg_failed=yes
+fi
+    fi
+else
+	pkg_failed=untried
+fi
+if test -n "$PKG_CONFIG"; then
+    if test -n "$GTKDOC_DEPS_LIBS"; then
+        pkg_cv_GTKDOC_DEPS_LIBS="$GTKDOC_DEPS_LIBS"
+    else
+        if test -n "$PKG_CONFIG" && \
+    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0\""; } >&5
+  ($PKG_CONFIG --exists --print-errors "glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then
+  pkg_cv_GTKDOC_DEPS_LIBS=`$PKG_CONFIG --libs "glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0" 2>/dev/null`
+else
+  pkg_failed=yes
+fi
+    fi
+else
+	pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+        _pkg_short_errors_supported=yes
+else
+        _pkg_short_errors_supported=no
+fi
+        if test $_pkg_short_errors_supported = yes; then
+	        GTKDOC_DEPS_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0"`
+        else
+	        GTKDOC_DEPS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0"`
+        fi
+	# Put the nasty error message in config.log where it belongs
+	echo "$GTKDOC_DEPS_PKG_ERRORS" >&5
+
+	as_fn_error $? "Package requirements (glib-2.0 >= 2.10.0 gobject-2.0  >= 2.10.0) were not met:
+
+$GTKDOC_DEPS_PKG_ERRORS
+
+Consider adjusting the PKG_CONFIG_PATH environment variable if you
+installed software in a non-standard prefix.
+
+Alternatively, you may set the environment variables GTKDOC_DEPS_CFLAGS
+and GTKDOC_DEPS_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.
+" "$LINENO" 5
+elif test $pkg_failed = untried; then
+	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
+is in your PATH or set the PKG_CONFIG environment variable to the full
+path to pkg-config.
+
+Alternatively, you may set the environment variables GTKDOC_DEPS_CFLAGS
+and GTKDOC_DEPS_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.
+
+To get pkg-config, see <http://pkg-config.freedesktop.org/>.
+See \`config.log' for more details" "$LINENO" 5; }
+else
+	GTKDOC_DEPS_CFLAGS=$pkg_cv_GTKDOC_DEPS_CFLAGS
+	GTKDOC_DEPS_LIBS=$pkg_cv_GTKDOC_DEPS_LIBS
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+	:
+fi
+    fi
+        if test -z "$SED"; then
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
 if ${ac_cv_path_SED+:} false; then :
@@ -21341,50 +21641,24 @@
   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_gtk_doc" >&5
 $as_echo "$enable_gtk_doc" >&6; }
 
-  for ac_prog in gtkdoc-check
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GTKDOC_CHECK+:} false; then :
-  $as_echo_n "(cached) " >&6
+    # Check whether --enable-gtk-doc-html was given.
+if test "${enable_gtk_doc_html+set}" = set; then :
+  enableval=$enable_gtk_doc_html;
 else
-  case $GTKDOC_CHECK in
-  [\\/]* | ?:[\\/]*)
-  ac_cv_path_GTKDOC_CHECK="$GTKDOC_CHECK" # Let the user override the test with a path.
-  ;;
-  *)
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-    for ac_exec_ext in '' $ac_executable_extensions; do
-  if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_path_GTKDOC_CHECK="$as_dir/$ac_word$ac_exec_ext"
-    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
+  enable_gtk_doc_html=yes
+fi
+
+    # Check whether --enable-gtk-doc-pdf was given.
+if test "${enable_gtk_doc_pdf+set}" = set; then :
+  enableval=$enable_gtk_doc_pdf;
+else
+  enable_gtk_doc_pdf=no
+fi
+
+
+  if test -z "$GTKDOC_MKPDF"; then
+    enable_gtk_doc_pdf=no
   fi
-done
-  done
-IFS=$as_save_IFS
-
-  ;;
-esac
-fi
-GTKDOC_CHECK=$ac_cv_path_GTKDOC_CHECK
-if test -n "$GTKDOC_CHECK"; then
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_CHECK" >&5
-$as_echo "$GTKDOC_CHECK" >&6; }
-else
-  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-  test -n "$GTKDOC_CHECK" && break
-done
 
 
    if test x$enable_gtk_doc = xyes; then
@@ -21395,6 +21669,22 @@
   ENABLE_GTK_DOC_FALSE=
 fi
 
+   if test x$enable_gtk_doc_html = xyes; then
+  GTK_DOC_BUILD_HTML_TRUE=
+  GTK_DOC_BUILD_HTML_FALSE='#'
+else
+  GTK_DOC_BUILD_HTML_TRUE='#'
+  GTK_DOC_BUILD_HTML_FALSE=
+fi
+
+   if test x$enable_gtk_doc_pdf = xyes; then
+  GTK_DOC_BUILD_PDF_TRUE=
+  GTK_DOC_BUILD_PDF_FALSE='#'
+else
+  GTK_DOC_BUILD_PDF_TRUE='#'
+  GTK_DOC_BUILD_PDF_FALSE=
+fi
+
    if test -n "$LIBTOOL"; then
   GTK_DOC_USE_LIBTOOL_TRUE=
   GTK_DOC_USE_LIBTOOL_FALSE='#'
@@ -21403,6 +21693,14 @@
   GTK_DOC_USE_LIBTOOL_FALSE=
 fi
 
+   if test -n "$GTKDOC_REBASE"; then
+  GTK_DOC_USE_REBASE_TRUE=
+  GTK_DOC_USE_REBASE_FALSE='#'
+else
+  GTK_DOC_USE_REBASE_TRUE='#'
+  GTK_DOC_USE_REBASE_FALSE=
+fi
+
 
 
 
@@ -21844,7 +22142,8 @@
 
 for ac_header in sys/socket.h
 do :
-  ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
+  ac_fn_c_check_header_compile "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default
+"
 if test "x$ac_cv_header_sys_socket_h" = xyes; then :
   cat >>confdefs.h <<_ACEOF
 #define HAVE_SYS_SOCKET_H 1
@@ -21868,7 +22167,8 @@
 for ac_header in process.h sys/types.h sys/wait.h sys/stat.h
 do :
   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
+"
 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
   cat >>confdefs.h <<_ACEOF
 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
@@ -23674,6 +23974,77 @@
 	HAVE_GTK_X11=yes
 fi
 
+pkg_failed=no
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK_QUARTZ" >&5
+$as_echo_n "checking for GTK_QUARTZ... " >&6; }
+
+if test -n "$PKG_CONFIG"; then
+    if test -n "$GTK_QUARTZ_CFLAGS"; then
+        pkg_cv_GTK_QUARTZ_CFLAGS="$GTK_QUARTZ_CFLAGS"
+    else
+        if test -n "$PKG_CONFIG" && \
+    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-quartz-3.0 >= \$GTK_REQ\""; } >&5
+  ($PKG_CONFIG --exists --print-errors "gtk+-quartz-3.0 >= $GTK_REQ") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then
+  pkg_cv_GTK_QUARTZ_CFLAGS=`$PKG_CONFIG --cflags "gtk+-quartz-3.0 >= $GTK_REQ" 2>/dev/null`
+else
+  pkg_failed=yes
+fi
+    fi
+else
+	pkg_failed=untried
+fi
+if test -n "$PKG_CONFIG"; then
+    if test -n "$GTK_QUARTZ_LIBS"; then
+        pkg_cv_GTK_QUARTZ_LIBS="$GTK_QUARTZ_LIBS"
+    else
+        if test -n "$PKG_CONFIG" && \
+    { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-quartz-3.0 >= \$GTK_REQ\""; } >&5
+  ($PKG_CONFIG --exists --print-errors "gtk+-quartz-3.0 >= $GTK_REQ") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then
+  pkg_cv_GTK_QUARTZ_LIBS=`$PKG_CONFIG --libs "gtk+-quartz-3.0 >= $GTK_REQ" 2>/dev/null`
+else
+  pkg_failed=yes
+fi
+    fi
+else
+	pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+        _pkg_short_errors_supported=yes
+else
+        _pkg_short_errors_supported=no
+fi
+        if test $_pkg_short_errors_supported = yes; then
+	        GTK_QUARTZ_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "gtk+-quartz-3.0 >= $GTK_REQ"`
+        else
+	        GTK_QUARTZ_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gtk+-quartz-3.0 >= $GTK_REQ"`
+        fi
+	# Put the nasty error message in config.log where it belongs
+	echo "$GTK_QUARTZ_PKG_ERRORS" >&5
+
+	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+                HAVE_GTK_QUARTZ=no
+elif test $pkg_failed = untried; then
+	HAVE_GTK_QUARTZ=no
+else
+	GTK_QUARTZ_CFLAGS=$pkg_cv_GTK_QUARTZ_CFLAGS
+	GTK_QUARTZ_LIBS=$pkg_cv_GTK_QUARTZ_LIBS
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+	HAVE_GTK_QUARTZ=yes
+fi
+
 
 fi
  if test "x$HAVE_GTK" = "xyes"; then
@@ -23692,6 +24063,14 @@
   HAVE_GTK_X11_FALSE=
 fi
 
+ if test "x$HAVE_GTK_QUARTZ" = "xyes"; then
+  HAVE_GTK_QUARTZ_TRUE=
+  HAVE_GTK_QUARTZ_FALSE='#'
+else
+  HAVE_GTK_QUARTZ_TRUE='#'
+  HAVE_GTK_QUARTZ_FALSE=
+fi
+
 
 
 pkg_failed=no
@@ -27202,7 +27581,8 @@
   CFLAGS="$CFLAGS $X_CFLAGS"
   CPPFLAGS="$CPPFLAGS $X_CFLAGS"
 
-    ac_fn_c_check_header_mongrel "$LINENO" "X11/Xlib.h" "ac_cv_header_X11_Xlib_h" "$ac_includes_default"
+    ac_fn_c_check_header_compile "$LINENO" "X11/Xlib.h" "ac_cv_header_X11_Xlib_h" "$ac_includes_default
+"
 if test "x$ac_cv_header_X11_Xlib_h" = xyes; then :
   HAVE_X="yes"
 else
@@ -31323,10 +31703,22 @@
   as_fn_error $? "conditional \"ENABLE_GTK_DOC\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
+if test -z "${GTK_DOC_BUILD_HTML_TRUE}" && test -z "${GTK_DOC_BUILD_HTML_FALSE}"; then
+  as_fn_error $? "conditional \"GTK_DOC_BUILD_HTML\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
+if test -z "${GTK_DOC_BUILD_PDF_TRUE}" && test -z "${GTK_DOC_BUILD_PDF_FALSE}"; then
+  as_fn_error $? "conditional \"GTK_DOC_BUILD_PDF\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
 if test -z "${GTK_DOC_USE_LIBTOOL_TRUE}" && test -z "${GTK_DOC_USE_LIBTOOL_FALSE}"; then
   as_fn_error $? "conditional \"GTK_DOC_USE_LIBTOOL\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
+if test -z "${GTK_DOC_USE_REBASE_TRUE}" && test -z "${GTK_DOC_USE_REBASE_FALSE}"; then
+  as_fn_error $? "conditional \"GTK_DOC_USE_REBASE\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
 if test -z "${ENABLE_PLUGIN_DOCS_TRUE}" && test -z "${ENABLE_PLUGIN_DOCS_FALSE}"; then
   as_fn_error $? "conditional \"ENABLE_PLUGIN_DOCS\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
@@ -31359,6 +31751,10 @@
   as_fn_error $? "conditional \"HAVE_GTK_X11\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
+if test -z "${HAVE_GTK_QUARTZ_TRUE}" && test -z "${HAVE_GTK_QUARTZ_FALSE}"; then
+  as_fn_error $? "conditional \"HAVE_GTK_QUARTZ\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
 if test -z "${HAVE_QT_TRUE}" && test -z "${HAVE_QT_FALSE}"; then
   as_fn_error $? "conditional \"HAVE_QT\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
@@ -31940,7 +32336,7 @@
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by GStreamer Base Plug-ins $as_me 0.11.91, which was
+This file was extended by GStreamer Base Plug-ins $as_me 0.11.92, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -32006,7 +32402,7 @@
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-GStreamer Base Plug-ins config.status 0.11.91
+GStreamer Base Plug-ins config.status 0.11.92
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
diff --git a/configure.ac b/configure.ac
index 3671b5a..6a80dfd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5,7 +5,7 @@
 dnl initialize autoconf
 dnl releases only do -Wall, git and prerelease does -Werror too
 dnl use a three digit version number for releases, and four for git/prerelease
-AC_INIT(GStreamer Base Plug-ins, 0.11.91,
+AC_INIT(GStreamer Base Plug-ins, 0.11.92,
     http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer,
     gst-plugins-base)
 
@@ -53,7 +53,7 @@
 AS_LIBTOOL(GST, 0, 0, 0)
 
 dnl *** required versions of GStreamer stuff ***
-GST_REQ=0.11.90
+GST_REQ=0.11.91
 
 dnl *** autotools stuff ****
 
@@ -186,11 +186,11 @@
 
 dnl used in gst/tcp
 AC_CHECK_HEADERS([sys/socket.h],
-  HAVE_SYS_SOCKET_H="yes", HAVE_SYS_SOCKET_H="no")
+  [HAVE_SYS_SOCKET_H="yes"], [HAVE_SYS_SOCKET_H="no"], [AC_INCLUDES_DEFAULT])
 AM_CONDITIONAL(HAVE_SYS_SOCKET_H, test "x$HAVE_SYS_SOCKET_H" = "xyes")
 
 dnl used in gst-libs/gst/pbutils and associated unit test
-AC_CHECK_HEADERS([process.h sys/types.h sys/wait.h sys/stat.h])
+AC_CHECK_HEADERS([process.h sys/types.h sys/wait.h sys/stat.h], [], [], [AC_INCLUDES_DEFAULT])
 
 dnl also, Windows does not have long long
 AX_CREATE_STDINT_H
@@ -256,11 +256,13 @@
   PKG_CHECK_MODULES(GTK, gtk+-3.0 >= $GTK_REQ, HAVE_GTK=yes, HAVE_GTK=no)
   dnl some examples need gtk+-x11
   PKG_CHECK_MODULES(GTK_X11, gtk+-x11-3.0 >= $GTK_REQ, HAVE_GTK_X11=yes, HAVE_GTK_X11=no)
+  PKG_CHECK_MODULES(GTK_QUARTZ, gtk+-quartz-3.0 >= $GTK_REQ, HAVE_GTK_QUARTZ=yes, HAVE_GTK_QUARTZ=no)
   AC_SUBST(GTK_LIBS)
   AC_SUBST(GTK_CFLAGS)
 fi
 AM_CONDITIONAL(HAVE_GTK, test "x$HAVE_GTK" = "xyes")
 AM_CONDITIONAL(HAVE_GTK_X11, test "x$HAVE_GTK_X11" = "xyes")
+AM_CONDITIONAL(HAVE_GTK_QUARTZ, test "x$HAVE_GTK_QUARTZ" = "xyes")
 
 dnl QT is optional and only used in examples
 PKG_CHECK_MODULES(QT, QtGui >= 4.6, [
@@ -490,7 +492,7 @@
   CPPFLAGS="$CPPFLAGS $X_CFLAGS"
 
   dnl now try to find the HEADER
-  AC_CHECK_HEADER(X11/Xlib.h, HAVE_X="yes", HAVE_X="no")
+  AC_CHECK_HEADER([X11/Xlib.h], [HAVE_X="yes"], [HAVE_X="no"], [AC_INCLUDES_DEFAULT])
 
   if test "x$HAVE_X" = "xno"
   then
diff --git a/docs/Makefile.in b/docs/Makefile.in
index fc9b65d..d18b62b 100644
--- a/docs/Makefile.in
+++ b/docs/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = docs
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(srcdir)/version.entities.in
@@ -251,8 +252,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -423,7 +430,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/docs/design/Makefile.in b/docs/design/Makefile.in
index c02c7c7..e3d83f6 100644
--- a/docs/design/Makefile.in
+++ b/docs/design/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = docs/design
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -251,8 +252,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -423,7 +430,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/docs/libs/Makefile.in b/docs/libs/Makefile.in
index 25b7739..ddd14bb 100644
--- a/docs/libs/Makefile.in
+++ b/docs/libs/Makefile.in
@@ -69,6 +69,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/gtk-doc.mak \
 	$(top_srcdir)/common/upload-doc.mak
@@ -232,8 +233,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -404,7 +411,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/docs/libs/gst-plugins-base-libs-sections.txt b/docs/libs/gst-plugins-base-libs-sections.txt
index ec9fecb..41a1d00 100644
--- a/docs/libs/gst-plugins-base-libs-sections.txt
+++ b/docs/libs/gst-plugins-base-libs-sections.txt
@@ -2240,7 +2240,8 @@
 GST_VIDEO_CODEC_FRAME_UNSET_SYNC_POINT
 gst_video_codec_frame_ref
 gst_video_codec_frame_unref
-gst_video_codec_frame_set_hook
+gst_video_codec_frame_set_user_data
+gst_video_codec_frame_get_user_data
 GstVideoCodecState
 gst_video_codec_state_ref
 gst_video_codec_state_unref
@@ -2270,6 +2271,7 @@
 gst_discoverer_info_get_stream_info
 gst_discoverer_info_get_stream_list
 gst_discoverer_info_get_tags
+gst_discoverer_info_get_toc
 gst_discoverer_info_get_uri
 gst_discoverer_info_get_seekable
 gst_discoverer_info_ref
@@ -2285,6 +2287,7 @@
 gst_discoverer_stream_info_get_next
 gst_discoverer_stream_info_get_previous
 gst_discoverer_stream_info_get_tags
+gst_discoverer_stream_info_get_toc
 gst_discoverer_stream_info_ref
 gst_discoverer_stream_info_unref
 gst_discoverer_stream_info_list_free
diff --git a/docs/libs/html/api-index-full.html b/docs/libs/html/api-index-full.html
index 3a365f6..7e51993 100644
--- a/docs/libs/html/api-index-full.html
+++ b/docs/libs/html/api-index-full.html
@@ -1191,6 +1191,10 @@
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-toc" title="gst_discoverer_info_get_toc ()">gst_discoverer_info_get_toc</a>, function in <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html" title="gstdiscoverer">gstdiscoverer</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-uri" title="gst_discoverer_info_get_uri ()">gst_discoverer_info_get_uri</a>, function in <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html" title="gstdiscoverer">gstdiscoverer</a>
 </dt>
 <dd></dd>
@@ -1243,6 +1247,10 @@
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-toc" title="gst_discoverer_stream_info_get_toc ()">gst_discoverer_stream_info_get_toc</a>, function in <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html" title="gstdiscoverer">gstdiscoverer</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-list-free" title="gst_discoverer_stream_info_list_free ()">gst_discoverer_stream_info_list_free</a>, function in <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html" title="gstdiscoverer">gstdiscoverer</a>
 </dt>
 <dd></dd>
@@ -4001,6 +4009,10 @@
 </dt>
 <dd></dd>
 <dt>
+<a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-get-user-data" title="gst_video_codec_frame_get_user_data ()">gst_video_codec_frame_get_user_data</a>, function in <a class="link" href="gst-plugins-base-libs-gstvideoutils.html" title="gstvideoutils">gstvideoutils</a>
+</dt>
+<dd></dd>
+<dt>
 <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GST-VIDEO-CODEC-FRAME-IS-DECODE-ONLY:CAPS" title="GST_VIDEO_CODEC_FRAME_IS_DECODE_ONLY()">GST_VIDEO_CODEC_FRAME_IS_DECODE_ONLY</a>, macro in <a class="link" href="gst-plugins-base-libs-gstvideoutils.html" title="gstvideoutils">gstvideoutils</a>
 </dt>
 <dd></dd>
@@ -4033,11 +4045,11 @@
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-hook" title="gst_video_codec_frame_set_hook ()">gst_video_codec_frame_set_hook</a>, function in <a class="link" href="gst-plugins-base-libs-gstvideoutils.html" title="gstvideoutils">gstvideoutils</a>
+<a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GST-VIDEO-CODEC-FRAME-SET-SYNC-POINT:CAPS" title="GST_VIDEO_CODEC_FRAME_SET_SYNC_POINT()">GST_VIDEO_CODEC_FRAME_SET_SYNC_POINT</a>, macro in <a class="link" href="gst-plugins-base-libs-gstvideoutils.html" title="gstvideoutils">gstvideoutils</a>
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GST-VIDEO-CODEC-FRAME-SET-SYNC-POINT:CAPS" title="GST_VIDEO_CODEC_FRAME_SET_SYNC_POINT()">GST_VIDEO_CODEC_FRAME_SET_SYNC_POINT</a>, macro in <a class="link" href="gst-plugins-base-libs-gstvideoutils.html" title="gstvideoutils">gstvideoutils</a>
+<a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-user-data" title="gst_video_codec_frame_set_user_data ()">gst_video_codec_frame_set_user_data</a>, function in <a class="link" href="gst-plugins-base-libs-gstvideoutils.html" title="gstvideoutils">gstvideoutils</a>
 </dt>
 <dd></dd>
 <dt>
@@ -4713,10 +4725,6 @@
 </dt>
 <dd></dd>
 <dt>
-<a class="link" href="gst-plugins-base-libs-gstvideo.html#gst-video-parse-caps-palette" title="gst_video_parse_caps_palette ()">gst_video_parse_caps_palette</a>, function in <a class="link" href="gst-plugins-base-libs-gstvideo.html" title="gstvideo">gstvideo</a>
-</dt>
-<dd></dd>
-<dt>
 <a class="link" href="gst-plugins-base-libs-gstvideosink.html#gst-video-sink-center-rect" title="gst_video_sink_center_rect ()">gst_video_sink_center_rect</a>, function in <a class="link" href="gst-plugins-base-libs-gstvideosink.html" title="gstvideosink">gstvideosink</a>
 </dt>
 <dd></dd>
diff --git a/docs/libs/html/compiling.html b/docs/libs/html/compiling.html
index 746ec97..85e80ee 100644
--- a/docs/libs/html/compiling.html
+++ b/docs/libs/html/compiling.html
@@ -31,7 +31,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp8230528"></a><h2>Compiling against the base plugins libraries</h2>
+<a name="idp7003648"></a><h2>Compiling against the base plugins libraries</h2>
 <p>
 To compile against these libraries, you need to tell the compiler where to 
 find the header files and libraries. This is done with the
diff --git a/docs/libs/html/gst-plugins-base-libs-GstVideoDecoder.html b/docs/libs/html/gst-plugins-base-libs-GstVideoDecoder.html
index d5e042a..029f3c3 100644
--- a/docs/libs/html/gst-plugins-base-libs-GstVideoDecoder.html
+++ b/docs/libs/html/gst-plugins-base-libs-GstVideoDecoder.html
@@ -552,8 +552,7 @@
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>n_bytes</code></em> :</span></p></td>
-<td>an encoded <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a>
-</td>
+<td>the number of bytes to add</td>
 </tr>
 </tbody>
 </table></div>
@@ -565,8 +564,7 @@
 <pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="returnvalue">GstBuffer</span></a> *         gst_video_decoder_alloc_output_buffer
                                                         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-GstVideoDecoder.html#GstVideoDecoder" title="struct GstVideoDecoder"><span class="type">GstVideoDecoder</span></a> *decoder</code></em>);</pre>
 <p>
-Helper function that uses <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#gst-pad-alloc-buffer-and-set-caps"><code class="function">gst_pad_alloc_buffer_and_set_caps()</code></a></code></em>
-to allocate a buffer to hold a video frame for <em class="parameter"><code>decoder</code></em>'s
+Helper function that allocates a buffer to hold a video frame for <em class="parameter"><code>decoder</code></em>'s
 current <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState"><span class="type">GstVideoCodecState</span></a>.
 </p>
 <div class="variablelist"><table border="0">
@@ -593,10 +591,9 @@
                                                         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-GstVideoDecoder.html#GstVideoDecoder" title="struct GstVideoDecoder"><span class="type">GstVideoDecoder</span></a> *decoder</code></em>,
                                                          <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>);</pre>
 <p>
-Helper function that uses <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#gst-pad-alloc-buffer-and-set-caps"><code class="function">gst_pad_alloc_buffer_and_set_caps()</code></a></code></em>
-to allocate a buffer to hold a video frame for <em class="parameter"><code>decoder</code></em>'s
-current <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState"><span class="type">GstVideoCodecState</span></a>.  Subclass should already have configured video state
-and set src pad caps.
+Helper function that allocates a buffer to hold a video frame for <em class="parameter"><code>decoder</code></em>'s
+current <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState"><span class="type">GstVideoCodecState</span></a>.  Subclass should already have configured video
+state and set src pad caps.
 </p>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
@@ -613,7 +610,8 @@
 </tr>
 <tr>
 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
-<td>result from pad alloc call</td>
+<td>
+<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstPad.html#GST-FLOW-OK:CAPS"><code class="literal">GST_FLOW_OK</code></a> if an output buffer could be allocated</td>
 </tr>
 </tbody>
 </table></div>
@@ -843,6 +841,10 @@
 <pre class="programlisting"><span class="returnvalue">void</span>                gst_video_decoder_get_latency       (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-GstVideoDecoder.html#GstVideoDecoder" title="struct GstVideoDecoder"><span class="type">GstVideoDecoder</span></a> *decoder</code></em>,
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> *min_latency</code></em>,
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> *max_latency</code></em>);</pre>
+<p>
+Query the configured decoder latency. Results will be returned via
+<em class="parameter"><code>min_latency</code></em> and <em class="parameter"><code>max_latency</code></em>.
+</p>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -853,18 +855,16 @@
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>min_latency</code></em> :</span></p></td>
-<td>the configured minimum latency. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
+<td>address of variable in which to store the
+configured minimum latency, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
 </td>
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>max_latency</code></em> :</span></p></td>
-<td>the configured maximum latency. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
+<td>address of variable in which to store the
+configured mximum latency, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
 </td>
 </tr>
-<tr>
-<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
-<td>the configured encoding latency.</td>
-</tr>
 </tbody>
 </table></div>
 <p class="since">Since 0.10.36</p>
@@ -876,7 +876,9 @@
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> min_latency</code></em>,
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> max_latency</code></em>);</pre>
 <p>
-Informs baseclass of encoding latency.
+Lets <a class="link" href="gst-plugins-base-libs-GstVideoDecoder.html#GstVideoDecoder" title="struct GstVideoDecoder"><span class="type">GstVideoDecoder</span></a> sub-classes tell the baseclass what the decoder
+latency is. Will also post a LATENCY message on the bus so the pipeline
+can reconfigure its global latency.
 </p>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
diff --git a/docs/libs/html/gst-plugins-base-libs-GstVideoEncoder.html b/docs/libs/html/gst-plugins-base-libs-GstVideoEncoder.html
index f318d75..137de8a 100644
--- a/docs/libs/html/gst-plugins-base-libs-GstVideoEncoder.html
+++ b/docs/libs/html/gst-plugins-base-libs-GstVideoEncoder.html
@@ -571,6 +571,10 @@
 <pre class="programlisting"><span class="returnvalue">void</span>                gst_video_encoder_get_latency       (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-GstVideoEncoder.html#GstVideoEncoder" title="struct GstVideoEncoder"><span class="type">GstVideoEncoder</span></a> *encoder</code></em>,
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> *min_latency</code></em>,
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> *max_latency</code></em>);</pre>
+<p>
+Query the configured encoding latency. Results will be returned via
+<em class="parameter"><code>min_latency</code></em> and <em class="parameter"><code>max_latency</code></em>.
+</p>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -581,18 +585,16 @@
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>min_latency</code></em> :</span></p></td>
-<td>the configured minimum latency. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
+<td>address of variable in which to store the
+configured minimum latency, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
 </td>
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>max_latency</code></em> :</span></p></td>
-<td>the configured maximum latency. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
+<td>address of variable in which to store the
+configured maximum latency, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
 </td>
 </tr>
-<tr>
-<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
-<td>the configured encoding latency.</td>
-</tr>
 </tbody>
 </table></div>
 <p class="since">Since 0.10.36</p>
diff --git a/docs/libs/html/gst-plugins-base-libs-appsrc.html b/docs/libs/html/gst-plugins-base-libs-appsrc.html
index 67cbd66..51ed715 100644
--- a/docs/libs/html/gst-plugins-base-libs-appsrc.html
+++ b/docs/libs/html/gst-plugins-base-libs-appsrc.html
@@ -44,8 +44,7 @@
 enum                <a class="link" href="gst-plugins-base-libs-appsrc.html#GstAppStreamType" title="enum GstAppStreamType">GstAppStreamType</a>;
 <span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-appsrc.html#gst-app-src-set-caps" title="gst_app_src_set_caps ()">gst_app_src_set_caps</a>                (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/gst-plugins-base-plugins-appsrc.html#GstAppSrc"><span class="type">GstAppSrc</span></a> *appsrc</code></em>,
                                                          <em class="parameter"><code>const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *caps</code></em>);
-<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="returnvalue">GstCaps</span></a> *           <a class="link" href="gst-plugins-base-libs-appsrc.html#gst-app-src-get-caps" title="gst_app_src_get_caps ()">gst_app_src_get_caps</a>                (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/gst-plugins-base-plugins-appsrc.html#GstAppSrc"><span class="type">GstAppSrc</span></a> *appsrc</code></em>,
-                                                         <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *filter</code></em>);
+<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="returnvalue">GstCaps</span></a> *           <a class="link" href="gst-plugins-base-libs-appsrc.html#gst-app-src-get-caps" title="gst_app_src_get_caps ()">gst_app_src_get_caps</a>                (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/gst-plugins-base-plugins-appsrc.html#GstAppSrc"><span class="type">GstAppSrc</span></a> *appsrc</code></em>);
 <span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-appsrc.html#gst-app-src-get-latency" title="gst_app_src_get_latency ()">gst_app_src_get_latency</a>             (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/gst-plugins-base-plugins-appsrc.html#GstAppSrc"><span class="type">GstAppSrc</span></a> *appsrc</code></em>,
                                                          <em class="parameter"><code><span class="type">guint64</span> *min</code></em>,
                                                          <em class="parameter"><code><span class="type">guint64</span> *max</code></em>);
@@ -221,8 +220,7 @@
 <hr>
 <div class="refsect2">
 <a name="gst-app-src-get-caps"></a><h3>gst_app_src_get_caps ()</h3>
-<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="returnvalue">GstCaps</span></a> *           gst_app_src_get_caps                (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/gst-plugins-base-plugins-appsrc.html#GstAppSrc"><span class="type">GstAppSrc</span></a> *appsrc</code></em>,
-                                                         <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *filter</code></em>);</pre>
+<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="returnvalue">GstCaps</span></a> *           gst_app_src_get_caps                (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/gst-plugins-base-plugins-appsrc.html#GstAppSrc"><span class="type">GstAppSrc</span></a> *appsrc</code></em>);</pre>
 <p>
 Get the configured caps on <em class="parameter"><code>appsrc</code></em>.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-encoding-profile.html b/docs/libs/html/gst-plugins-base-libs-encoding-profile.html
index ba2f0c7..291445d 100644
--- a/docs/libs/html/gst-plugins-base-libs-encoding-profile.html
+++ b/docs/libs/html/gst-plugins-base-libs-encoding-profile.html
@@ -182,7 +182,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp25528832"></a><p>
+<a name="idp25217920"></a><p>
 Functions to create and handle encoding profiles.
 </p>
 <p>
@@ -212,7 +212,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp25536400"></a><h3>Example: Creating a profile</h3>
+<a name="idp25225488"></a><h3>Example: Creating a profile</h3>
 <p>
 </p>
 <div class="informalexample">
@@ -283,7 +283,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp25539392"></a><h3>Example: Listing categories, targets and profiles</h3>
+<a name="idp25228480"></a><h3>Example: Listing categories, targets and profiles</h3>
 <p>
 </p>
 <div class="informalexample">
diff --git a/docs/libs/html/gst-plugins-base-libs-gstaudiocdsrc.html b/docs/libs/html/gst-plugins-base-libs-gstaudiocdsrc.html
index 46c35be..fbdaad7 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstaudiocdsrc.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstaudiocdsrc.html
@@ -85,7 +85,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp8421984"></a><h3>Using GstAudioCdSrc-based elements in applications</h3>
+<a name="idp8117088"></a><h3>Using GstAudioCdSrc-based elements in applications</h3>
 <p>
 Provides a base class for CD digital audio (CDDA) sources, which handles
 things like seeking, querying, discid calculation, tags, and buffer
diff --git a/docs/libs/html/gst-plugins-base-libs-gstaudioringbuffer.html b/docs/libs/html/gst-plugins-base-libs-gstaudioringbuffer.html
index 8aefba7..6a7cabe 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstaudioringbuffer.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstaudioringbuffer.html
@@ -122,7 +122,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp13203760"></a><p>
+<a name="idp12901776"></a><p>
 This object is the base class for audio ringbuffers used by the base
 audio source and sink classes.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstcolorbalance.html b/docs/libs/html/gst-plugins-base-libs-gstcolorbalance.html
index 8c7a8ae..968879a 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstcolorbalance.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstcolorbalance.html
@@ -77,7 +77,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp29273040"></a><p>
+<a name="idp27811536"></a><p>
 This interface is implemented by elements which can perform some color
 balance operation on video frames they process. For example, modifying
 the brightness, contrast, hue or saturation.
diff --git a/docs/libs/html/gst-plugins-base-libs-gstcolorbalancechannel.html b/docs/libs/html/gst-plugins-base-libs-gstcolorbalancechannel.html
index 1982ba5..ff5ec88 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstcolorbalancechannel.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstcolorbalancechannel.html
@@ -67,7 +67,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp24335184"></a><p>The <a class="link" href="gst-plugins-base-libs-gstcolorbalancechannel.html#GstColorBalanceChannel"><span class="type">GstColorBalanceChannel</span></a> object represents a parameter
+<a name="idp21570528"></a><p>The <a class="link" href="gst-plugins-base-libs-gstcolorbalancechannel.html#GstColorBalanceChannel"><span class="type">GstColorBalanceChannel</span></a> object represents a parameter
 for modifying the color balance implemented by an element providing the
 <a class="link" href="gst-plugins-base-libs-gstcolorbalance.html#GstColorBalance"><span class="type">GstColorBalance</span></a> interface. For example, Hue or Saturation.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstdiscoverer.html b/docs/libs/html/gst-plugins-base-libs-gstdiscoverer.html
index 603a5e8..b51c18f 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstdiscoverer.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstdiscoverer.html
@@ -66,6 +66,7 @@
                                                         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);
 <a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#GList"><span class="returnvalue">GList</span></a> *             <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-stream-list" title="gst_discoverer_info_get_stream_list ()">gst_discoverer_info_get_stream_list</a> (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);
 const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstTagList.html#GstTagList"><span class="returnvalue">GstTagList</span></a> *  <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-tags" title="gst_discoverer_info_get_tags ()">gst_discoverer_info_get_tags</a>        (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);
+const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstToc.html#GstToc"><span class="returnvalue">GstToc</span></a> *      <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-toc" title="gst_discoverer_info_get_toc ()">gst_discoverer_info_get_toc</a>         (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);
 const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-uri" title="gst_discoverer_info_get_uri ()">gst_discoverer_info_get_uri</a>         (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);
 <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>            <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-seekable" title="gst_discoverer_info_get_seekable ()">gst_discoverer_info_get_seekable</a>    (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);
 #define             <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-ref" title="gst_discoverer_info_ref()">gst_discoverer_info_ref</a>             (info)
@@ -84,6 +85,7 @@
 <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererStreamInfo" title="GstDiscovererStreamInfo"><span class="returnvalue">GstDiscovererStreamInfo</span></a> * <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-previous" title="gst_discoverer_stream_info_get_previous ()">gst_discoverer_stream_info_get_previous</a>
                                                         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererStreamInfo" title="GstDiscovererStreamInfo"><span class="type">GstDiscovererStreamInfo</span></a> *info</code></em>);
 const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstTagList.html#GstTagList"><span class="returnvalue">GstTagList</span></a> *  <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-tags" title="gst_discoverer_stream_info_get_tags ()">gst_discoverer_stream_info_get_tags</a> (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererStreamInfo" title="GstDiscovererStreamInfo"><span class="type">GstDiscovererStreamInfo</span></a> *info</code></em>);
+const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstToc.html#GstToc"><span class="returnvalue">GstToc</span></a> *      <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-toc" title="gst_discoverer_stream_info_get_toc ()">gst_discoverer_stream_info_get_toc</a>  (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererStreamInfo" title="GstDiscovererStreamInfo"><span class="type">GstDiscovererStreamInfo</span></a> *info</code></em>);
 #define             <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-ref" title="gst_discoverer_stream_info_ref()">gst_discoverer_stream_info_ref</a>      (info)
 #define             <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-unref" title="gst_discoverer_stream_info_unref()">gst_discoverer_stream_info_unref</a>    (info)
 <span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-list-free" title="gst_discoverer_stream_info_list_free ()">gst_discoverer_stream_info_list_free</a>
@@ -537,6 +539,28 @@
 </div>
 <hr>
 <div class="refsect2">
+<a name="gst-discoverer-info-get-toc"></a><h3>gst_discoverer_info_get_toc ()</h3>
+<pre class="programlisting">const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstToc.html#GstToc"><span class="returnvalue">GstToc</span></a> *      gst_discoverer_info_get_toc         (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);</pre>
+<div class="variablelist"><table border="0">
+<col align="left" valign="top">
+<tbody>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>info</code></em> :</span></p></td>
+<td>a <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a>
+</td>
+</tr>
+<tr>
+<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
+<td>TOC contained in the URI. If you wish to use
+the TOC after the life-time of <em class="parameter"><code>info</code></em>, you will need to copy it. <span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span>
+</td>
+</tr>
+</tbody>
+</table></div>
+<p class="since">Since 0.11.92</p>
+</div>
+<hr>
+<div class="refsect2">
 <a name="gst-discoverer-info-get-uri"></a><h3>gst_discoverer_info_get_uri ()</h3>
 <pre class="programlisting">const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> *       gst_discoverer_info_get_uri         (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererInfo"><span class="type">GstDiscovererInfo</span></a> *info</code></em>);</pre>
 <div class="variablelist"><table border="0">
@@ -799,6 +823,28 @@
 </div>
 <hr>
 <div class="refsect2">
+<a name="gst-discoverer-stream-info-get-toc"></a><h3>gst_discoverer_stream_info_get_toc ()</h3>
+<pre class="programlisting">const <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstToc.html#GstToc"><span class="returnvalue">GstToc</span></a> *      gst_discoverer_stream_info_get_toc  (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererStreamInfo" title="GstDiscovererStreamInfo"><span class="type">GstDiscovererStreamInfo</span></a> *info</code></em>);</pre>
+<div class="variablelist"><table border="0">
+<col align="left" valign="top">
+<tbody>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>info</code></em> :</span></p></td>
+<td>a <a class="link" href="gst-plugins-base-libs-gstdiscoverer.html#GstDiscovererStreamInfo" title="GstDiscovererStreamInfo"><span class="type">GstDiscovererStreamInfo</span></a>
+</td>
+</tr>
+<tr>
+<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
+<td>the TOC contained in this stream. If you wish to
+use the TOC after the life-time of <em class="parameter"><code>info</code></em> you will need to copy it. <span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span>
+</td>
+</tr>
+</tbody>
+</table></div>
+<p class="since">Since 0.11.92</p>
+</div>
+<hr>
+<div class="refsect2">
 <a name="gst-discoverer-stream-info-ref"></a><h3>gst_discoverer_stream_info_ref()</h3>
 <pre class="programlisting">#define gst_discoverer_stream_info_ref(info) ((GstDiscovererStreamInfo*) g_object_ref((GObject*) info))
 </pre>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstpbutils.html b/docs/libs/html/gst-plugins-base-libs-gstpbutils.html
index 22aaef3..8fd664e 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstpbutils.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstpbutils.html
@@ -48,7 +48,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp13061536"></a><h3>Linking to this library</h3>
+<a name="idp9848960"></a><h3>Linking to this library</h3>
 <p>
 libgstpbutils is a general utility library for plugins and applications,
 available since gst-plugins-base 0.10.12. It currently provides the
diff --git a/docs/libs/html/gst-plugins-base-libs-gstpbutilscodecutils.html b/docs/libs/html/gst-plugins-base-libs-gstpbutilscodecutils.html
index 31a3325..c087178 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstpbutilscodecutils.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstpbutilscodecutils.html
@@ -78,7 +78,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp24082256"></a><p>
+<a name="idp23830656"></a><p>
 Provides codec-specific ulility functions such as functions to provide the
 codec profile and level in human-readable string form from header data.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstpbutilsdescriptions.html b/docs/libs/html/gst-plugins-base-libs-gstpbutilsdescriptions.html
index d168a17..d6cbb5d 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstpbutilsdescriptions.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstpbutilsdescriptions.html
@@ -62,7 +62,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp21197200"></a><p>
+<a name="idp21642416"></a><p>
 The above functions provide human-readable strings for media formats
 and decoder/demuxer/depayloader/encoder/muxer/payloader elements for use
 in error dialogs or other messages shown to users.
diff --git a/docs/libs/html/gst-plugins-base-libs-gstpbutilsinstallplugins.html b/docs/libs/html/gst-plugins-base-libs-gstpbutilsinstallplugins.html
index 22ba584..109aaf9 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstpbutilsinstallplugins.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstpbutilsinstallplugins.html
@@ -67,7 +67,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp21458976"></a><h3>Overview</h3>
+<a name="idp21298992"></a><h3>Overview</h3>
 <p>
 Using this API, applications can request the installation of missing
 GStreamer plugins. These may be missing decoders/demuxers or encoders/muxers
diff --git a/docs/libs/html/gst-plugins-base-libs-gstpbutilsmissingplugins.html b/docs/libs/html/gst-plugins-base-libs-gstpbutilsmissingplugins.html
index 2b6b5e0..55961a0 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstpbutilsmissingplugins.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstpbutilsmissingplugins.html
@@ -74,7 +74,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp24416880"></a><p>
+<a name="idp24641392"></a><p>
 Functions to create, recognise and parse missing-plugins messages for
 applications and elements.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstpluginsbaseversion.html b/docs/libs/html/gst-plugins-base-libs-gstpluginsbaseversion.html
index b45e1a3..f4bb30a 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstpluginsbaseversion.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstpluginsbaseversion.html
@@ -90,7 +90,7 @@
 <hr>
 <div class="refsect2">
 <a name="GST-PLUGINS-BASE-VERSION-MICRO:CAPS"></a><h3>GST_PLUGINS_BASE_VERSION_MICRO</h3>
-<pre class="programlisting">#define GST_PLUGINS_BASE_VERSION_MICRO (91)
+<pre class="programlisting">#define GST_PLUGINS_BASE_VERSION_MICRO (92)
 </pre>
 <p>
 The micro version of GStreamer's gst-plugins-base libraries at compile time.
diff --git a/docs/libs/html/gst-plugins-base-libs-gstrtcpbuffer.html b/docs/libs/html/gst-plugins-base-libs-gstrtcpbuffer.html
index bd023dd..178f8eb 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstrtcpbuffer.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstrtcpbuffer.html
@@ -176,7 +176,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp16389952"></a><p>
+<a name="idp16670464"></a><p>
 The GstRTPCBuffer helper functions makes it easy to parse and create regular 
 <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a> objects that contain compound RTCP packets. These buffers are typically
 of 'application/x-rtcp' <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a>.
diff --git a/docs/libs/html/gst-plugins-base-libs-gstrtpbaseaudiopayload.html b/docs/libs/html/gst-plugins-base-libs-gstrtpbaseaudiopayload.html
index 0464764..3949431 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstrtpbaseaudiopayload.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstrtpbaseaudiopayload.html
@@ -110,7 +110,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp14728384"></a><h3>Usage</h3>
+<a name="idp15202640"></a><h3>Usage</h3>
 <p>
 To use this base class, your child element needs to call either
 <a class="link" href="gst-plugins-base-libs-gstrtpbaseaudiopayload.html#gst-rtp-base-audio-payload-set-frame-based" title="gst_rtp_base_audio_payload_set_frame_based ()"><code class="function">gst_rtp_base_audio_payload_set_frame_based()</code></a> or
diff --git a/docs/libs/html/gst-plugins-base-libs-gstrtpbuffer.html b/docs/libs/html/gst-plugins-base-libs-gstrtpbuffer.html
index 4bc56fa..94d21c9 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstrtpbuffer.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstrtpbuffer.html
@@ -151,7 +151,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp15981600"></a><p>
+<a name="idp16433216"></a><p>
 The GstRTPBuffer helper functions makes it easy to parse and create regular 
 <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a> objects that contain RTP payloads. These buffers are typically of
 'application/x-rtp' <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a>.
diff --git a/docs/libs/html/gst-plugins-base-libs-gstrtppayloads.html b/docs/libs/html/gst-plugins-base-libs-gstrtppayloads.html
index b48ff3a..d91bccd 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstrtppayloads.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstrtppayloads.html
@@ -53,7 +53,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp15527360"></a><p>
+<a name="idp14256528"></a><p>
 The GstRTPPayloads helper functions makes it easy to deal with static and dynamic
 payloads. Its main purpose is to retrieve properties such as the default clock-rate 
 and get session bandwidth information.
diff --git a/docs/libs/html/gst-plugins-base-libs-gstrtspextension.html b/docs/libs/html/gst-plugins-base-libs-gstrtspextension.html
index 2cd3101..96d351b 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstrtspextension.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstrtspextension.html
@@ -49,7 +49,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp10284464"></a><p>
+<a name="idp13098528"></a><p>
  This interface is implemented e.g. by the Windows Media Streaming RTSP
  exentension (rtspwms) and the RealMedia RTSP extension (rtspreal).
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstsdpmessage.html b/docs/libs/html/gst-plugins-base-libs-gstsdpmessage.html
index 86181c9..ce41929 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstsdpmessage.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstsdpmessage.html
@@ -209,7 +209,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp22662448"></a><p>
+<a name="idp22412656"></a><p>
 The GstSDPMessage helper functions makes it easy to parse and create SDP
 messages.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gststreamvolume.html b/docs/libs/html/gst-plugins-base-libs-gststreamvolume.html
index 634834a..c6980e3 100644
--- a/docs/libs/html/gst-plugins-base-libs-gststreamvolume.html
+++ b/docs/libs/html/gst-plugins-base-libs-gststreamvolume.html
@@ -86,7 +86,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp12023536"></a><p>
+<a name="idp13256512"></a><p>
 This interface is implemented by elements that provide a stream volume. Examples for
 such elements are <span class="type">volume</span> and <span class="type">playbin2</span>.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttag.html b/docs/libs/html/gst-plugins-base-libs-gsttag.html
index f38cba5..327ac55 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttag.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttag.html
@@ -91,7 +91,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp17468672"></a><p>
+<a name="idp20414752"></a><p>
 Contains additional standardized GStreamer tag definitions for plugins
 and applications, and functions to register them with the GStreamer
 tag system.
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttagdemux.html b/docs/libs/html/gst-plugins-base-libs-gsttagdemux.html
index 29cb633..f7c7b38 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttagdemux.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttagdemux.html
@@ -51,7 +51,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp15580112"></a><h3>Deriving from GstTagDemux</h3>
+<a name="idp9323184"></a><h3>Deriving from GstTagDemux</h3>
 <p>
 Provides a base class for demuxing tags at the beginning or end of a
 stream and handles things like typefinding, querying, seeking, and
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttagid3.html b/docs/libs/html/gst-plugins-base-libs-gsttagid3.html
index a1e6daf..98e1599 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttagid3.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttagid3.html
@@ -61,7 +61,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp20818768"></a><p>
+<a name="idp8756128"></a><p>
 Contains various utility functions for plugins to parse or create
 ID3 tags and map ID3v2 identifiers to and from GStreamer identifiers.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttaglanguagecodes.html b/docs/libs/html/gst-plugins-base-libs-gsttaglanguagecodes.html
index 1f3cbb5..02baa7e 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttaglanguagecodes.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttaglanguagecodes.html
@@ -56,7 +56,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp22582832"></a><p>
+<a name="idp21746368"></a><p>
 Provides helper functions to convert between the various ISO-639 language
 codes, and to map language codes to language names.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttagmux.html b/docs/libs/html/gst-plugins-base-libs-gsttagmux.html
index c755c7b..c704082 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttagmux.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttagmux.html
@@ -50,7 +50,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9718656"></a><h3>Deriving from GstTagMux</h3>
+<a name="idp8486624"></a><h3>Deriving from GstTagMux</h3>
 <p>
 Provides a base class for adding tags at the beginning or end of a
 stream.
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttagvorbis.html b/docs/libs/html/gst-plugins-base-libs-gsttagvorbis.html
index 073e586..b02ab8c 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttagvorbis.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttagvorbis.html
@@ -66,7 +66,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp17451568"></a><p>
+<a name="idp20607664"></a><p>
 Contains various utility functions for plugins to parse or create
 vorbiscomments and map them to and from <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstTagList.html#GstTagList"><span class="type">GstTagList</span></a>s.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gsttagxmpwriter.html b/docs/libs/html/gst-plugins-base-libs-gsttagxmpwriter.html
index 58d0972..a5755a0 100644
--- a/docs/libs/html/gst-plugins-base-libs-gsttagxmpwriter.html
+++ b/docs/libs/html/gst-plugins-base-libs-gsttagxmpwriter.html
@@ -57,7 +57,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp22401328"></a><p>
+<a name="idp17832512"></a><p>
 This interface is implemented by elements that are able to do XMP serialization. Examples for
 such elements are <span class="type">jifmux</span> and <span class="type">qtmux</span>.
 </p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstvideo.html b/docs/libs/html/gst-plugins-base-libs-gstvideo.html
index f829ac9..85cc965 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstvideo.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstvideo.html
@@ -49,14 +49,17 @@
                     <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoColorimetry" title="GstVideoColorimetry">GstVideoColorimetry</a>;
 enum                <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFlags" title="enum GstVideoFlags">GstVideoFlags</a>;
 enum                <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatFlags" title="enum GstVideoFormatFlags">GstVideoFormatFlags</a>;
-<span class="returnvalue">void</span>                (<a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatPack" title="GstVideoFormatPack ()">*GstVideoFormatPack</a>)               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+<span class="returnvalue">void</span>                (<a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatPack" title="GstVideoFormatPack ()">*GstVideoFormatPack</a>)               (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+                                                         <em class="parameter"><code><span class="type">GstVideoPackFlags</span> flags</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> src</code></em>,
+                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> sstride</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data[GST_VIDEO_MAX_PLANES]</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> stride[GST_VIDEO_MAX_PLANES]</code></em>,
-                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x</code></em>,
+                                                         <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoChromaSite" title="enum GstVideoChromaSite"><span class="type">GstVideoChromaSite</span></a> chroma_site</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>);
-<span class="returnvalue">void</span>                (<a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatUnpack" title="GstVideoFormatUnpack ()">*GstVideoFormatUnpack</a>)             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+<span class="returnvalue">void</span>                (<a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatUnpack" title="GstVideoFormatUnpack ()">*GstVideoFormatUnpack</a>)             (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+                                                         <em class="parameter"><code><span class="type">GstVideoPackFlags</span> flags</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> dest</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data[GST_VIDEO_MAX_PLANES]</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> stride[GST_VIDEO_MAX_PLANES]</code></em>,
@@ -184,7 +187,6 @@
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"><span class="type">guint</span></a> display_par_d</code></em>);
 <span class="returnvalue">guint32</span>             <a class="link" href="gst-plugins-base-libs-gstvideo.html#gst-video-format-to-fourcc" title="gst_video_format_to_fourcc ()">gst_video_format_to_fourcc</a>          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormat" title="enum GstVideoFormat"><span class="type">GstVideoFormat</span></a> format</code></em>);
 <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormat" title="enum GstVideoFormat"><span class="returnvalue">GstVideoFormat</span></a>      <a class="link" href="gst-plugins-base-libs-gstvideo.html#gst-video-format-from-fourcc" title="gst_video_format_from_fourcc ()">gst_video_format_from_fourcc</a>        (<em class="parameter"><code><span class="type">guint32</span> fourcc</code></em>);
-<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="returnvalue">GstBuffer</span></a> *         <a class="link" href="gst-plugins-base-libs-gstvideo.html#gst-video-parse-caps-palette" title="gst_video_parse_caps_palette ()">gst_video_parse_caps_palette</a>        (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *caps</code></em>);
 <span class="returnvalue">void</span>                (<a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoConvertSampleCallback" title="GstVideoConvertSampleCallback ()">*GstVideoConvertSampleCallback</a>)    (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstSample.html#GstSample"><span class="type">GstSample</span></a> *sample</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> *error</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>);
@@ -231,7 +233,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp25775616"></a><p>
+<a name="idp26138944"></a><p>
 This library contains some helper functions and includes the
 videosink and videofilter base classes.
 </p>
@@ -268,6 +270,59 @@
   GST_VIDEO_CHROMA_SITE_DV        = (GST_VIDEO_CHROMA_SITE_COSITED | GST_VIDEO_CHROMA_SITE_ALT_LINE),
 } GstVideoChromaSite;
 </pre>
+<p>
+Various Chroma sitings.
+</p>
+<div class="variablelist"><table border="0">
+<col align="left" valign="top">
+<tbody>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-UNKNOWN:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_UNKNOWN</code></span></p></td>
+<td>unknown cositing
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-NONE:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_NONE</code></span></p></td>
+<td>no cositing
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-H-COSITED:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_H_COSITED</code></span></p></td>
+<td>chroma is horizontally cosited
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-V-COSITED:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_V_COSITED</code></span></p></td>
+<td>chroma is vertically cosited
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-ALT-LINE:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_ALT_LINE</code></span></p></td>
+<td>choma samples are sited on alternate lines
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-COSITED:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_COSITED</code></span></p></td>
+<td>chroma samples cosited with luma samples
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-JPEG:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_JPEG</code></span></p></td>
+<td>jpeg style cositing, also for mpeg1 and mjpeg
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-MPEG2:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_MPEG2</code></span></p></td>
+<td>mpeg2 style cositing
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-CHROMA-SITE-DV:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_CHROMA_SITE_DV</code></span></p></td>
+<td>DV style cositing
+</td>
+</tr>
+</tbody>
+</table></div>
 </div>
 <hr>
 <div class="refsect2">
@@ -330,7 +385,8 @@
   GST_VIDEO_COLOR_PRIMARIES_BT470M,
   GST_VIDEO_COLOR_PRIMARIES_BT470BG,
   GST_VIDEO_COLOR_PRIMARIES_SMPTE170M,
-  GST_VIDEO_COLOR_PRIMARIES_SMPTE240M
+  GST_VIDEO_COLOR_PRIMARIES_SMPTE240M,
+  GST_VIDEO_COLOR_PRIMARIES_FILM
 } GstVideoColorPrimaries;
 </pre>
 <p>
@@ -370,6 +426,11 @@
 <td>SMPTE240M primaries
 </td>
 </tr>
+<tr>
+<td><p><a name="GST-VIDEO-COLOR-PRIMARIES-FILM:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_COLOR_PRIMARIES_FILM</code></span></p></td>
+<td>Generic film
+</td>
+</tr>
 </tbody>
 </table></div>
 </div>
@@ -449,8 +510,9 @@
 <div class="refsect2">
 <a name="GstVideoFlags"></a><h3>enum GstVideoFlags</h3>
 <pre class="programlisting">typedef enum {
-  GST_VIDEO_FLAG_NONE         = 0,
-  GST_VIDEO_FLAG_VARIABLE_FPS = (1 &lt;&lt; 0)
+  GST_VIDEO_FLAG_NONE                = 0,
+  GST_VIDEO_FLAG_VARIABLE_FPS        = (1 &lt;&lt; 0),
+  GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA = (1 &lt;&lt; 1)
 } GstVideoFlags;
 </pre>
 <p>
@@ -467,7 +529,13 @@
 <tr>
 <td><p><a name="GST-VIDEO-FLAG-VARIABLE-FPS:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FLAG_VARIABLE_FPS</code></span></p></td>
 <td>a variable fps is selected, fps_n and fps_d
-denote the maximum fps of the video
+    denote the maximum fps of the video
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-FLAG-PREMULTIPLIED-ALPHA:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA</code></span></p></td>
+<td>Each color has been scaled by the alpha
+    value.
 </td>
 </tr>
 </tbody>
@@ -524,7 +592,8 @@
 </tr>
 <tr>
 <td><p><a name="GST-VIDEO-FORMAT-FLAG-PALETTE:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_FLAG_PALETTE</code></span></p></td>
-<td>The video format has a palette.
+<td>The video format has a palette. The palette
+  is stored in the second plane and indexes are stored in the first plane.
 </td>
 </tr>
 <tr>
@@ -539,11 +608,13 @@
 <hr>
 <div class="refsect2">
 <a name="GstVideoFormatPack"></a><h3>GstVideoFormatPack ()</h3>
-<pre class="programlisting"><span class="returnvalue">void</span>                (*GstVideoFormatPack)               (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+<pre class="programlisting"><span class="returnvalue">void</span>                (*GstVideoFormatPack)               (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+                                                         <em class="parameter"><code><span class="type">GstVideoPackFlags</span> flags</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> src</code></em>,
+                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> sstride</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data[GST_VIDEO_MAX_PLANES]</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> stride[GST_VIDEO_MAX_PLANES]</code></em>,
-                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x</code></em>,
+                                                         <em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoChromaSite" title="enum GstVideoChromaSite"><span class="type">GstVideoChromaSite</span></a> chroma_site</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>);</pre>
 <p>
@@ -551,6 +622,11 @@
 format <em class="parameter"><code>info</code></em>. The pixels from source have each component interleaved
 and will be packed into the planes in <em class="parameter"><code>data</code></em>.
 </p>
+<p>
+This function operates on pack_lines lines, meaning that <em class="parameter"><code>src</code></em> should
+contain at least pack_lines lines with a stride of <em class="parameter"><code>sstride</code></em> and <em class="parameter"><code>y</code></em>
+should be a multiple of pack_lines.
+</p>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -560,10 +636,18 @@
 </td>
 </tr>
 <tr>
+<td><p><span class="term"><em class="parameter"><code>flags</code></em> :</span></p></td>
+<td>flags to control the packing</td>
+</tr>
+<tr>
 <td><p><span class="term"><em class="parameter"><code>src</code></em> :</span></p></td>
 <td>a source array</td>
 </tr>
 <tr>
+<td><p><span class="term"><em class="parameter"><code>sstride</code></em> :</span></p></td>
+<td>the source array stride</td>
+</tr>
+<tr>
 <td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td>
 <td>pointers to the destination data planes</td>
 </tr>
@@ -572,8 +656,8 @@
 <td>strides of the destination planes</td>
 </tr>
 <tr>
-<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
-<td>the x position in the image to pack to</td>
+<td><p><span class="term"><em class="parameter"><code>chroma_site</code></em> :</span></p></td>
+<td>the chroma siting of the target when subsampled</td>
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
@@ -589,7 +673,8 @@
 <hr>
 <div class="refsect2">
 <a name="GstVideoFormatUnpack"></a><h3>GstVideoFormatUnpack ()</h3>
-<pre class="programlisting"><span class="returnvalue">void</span>                (*GstVideoFormatUnpack)             (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+<pre class="programlisting"><span class="returnvalue">void</span>                (*GstVideoFormatUnpack)             (<em class="parameter"><code>const <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo" title="struct GstVideoFormatInfo"><span class="type">GstVideoFormatInfo</span></a> *info</code></em>,
+                                                         <em class="parameter"><code><span class="type">GstVideoPackFlags</span> flags</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> dest</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> data[GST_VIDEO_MAX_PLANES]</code></em>,
                                                          <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> stride[GST_VIDEO_MAX_PLANES]</code></em>,
@@ -611,6 +696,10 @@
 </td>
 </tr>
 <tr>
+<td><p><span class="term"><em class="parameter"><code>flags</code></em> :</span></p></td>
+<td>flags to control the unpacking</td>
+</tr>
+<tr>
 <td><p><span class="term"><em class="parameter"><code>dest</code></em> :</span></p></td>
 <td>a destination array</td>
 </tr>
@@ -777,6 +866,7 @@
 <a name="GstVideoFormat"></a><h3>enum GstVideoFormat</h3>
 <pre class="programlisting">typedef enum {
   GST_VIDEO_FORMAT_UNKNOWN,
+  GST_VIDEO_FORMAT_ENCODED,
   GST_VIDEO_FORMAT_I420,
   GST_VIDEO_FORMAT_YV12,
   GST_VIDEO_FORMAT_YUY2,
@@ -804,22 +894,21 @@
   GST_VIDEO_FORMAT_GRAY16_BE,
   GST_VIDEO_FORMAT_GRAY16_LE,
   GST_VIDEO_FORMAT_v308,
-  GST_VIDEO_FORMAT_Y800,
-  GST_VIDEO_FORMAT_Y16,
   GST_VIDEO_FORMAT_RGB16,
   GST_VIDEO_FORMAT_BGR16,
   GST_VIDEO_FORMAT_RGB15,
   GST_VIDEO_FORMAT_BGR15,
   GST_VIDEO_FORMAT_UYVP,
   GST_VIDEO_FORMAT_A420,
-  GST_VIDEO_FORMAT_RGB8_PALETTED,
+  GST_VIDEO_FORMAT_RGB8P,
   GST_VIDEO_FORMAT_YUV9,
   GST_VIDEO_FORMAT_YVU9,
   GST_VIDEO_FORMAT_IYU1,
   GST_VIDEO_FORMAT_ARGB64,
   GST_VIDEO_FORMAT_AYUV64,
   GST_VIDEO_FORMAT_r210,
-  GST_VIDEO_FORMAT_ENCODED
+  GST_VIDEO_FORMAT_I420_10BE,
+  GST_VIDEO_FORMAT_I420_10LE
 } GstVideoFormat;
 </pre>
 <p>
@@ -834,6 +923,11 @@
 </td>
 </tr>
 <tr>
+<td><p><a name="GST-VIDEO-FORMAT-ENCODED:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_ENCODED</code></span></p></td>
+<td>Encoded video format
+</td>
+</tr>
+<tr>
 <td><p><a name="GST-VIDEO-FORMAT-I420:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_I420</code></span></p></td>
 <td>planar 4:2:0 YUV
 </td>
@@ -969,16 +1063,6 @@
 </td>
 </tr>
 <tr>
-<td><p><a name="GST-VIDEO-FORMAT-Y800:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_Y800</code></span></p></td>
-<td>same as GST_VIDEO_FORMAT_GRAY8 (Since: 0.10.30)
-</td>
-</tr>
-<tr>
-<td><p><a name="GST-VIDEO-FORMAT-Y16:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_Y16</code></span></p></td>
-<td>same as GST_VIDEO_FORMAT_GRAY16_LE (Since: 0.10.30)
-</td>
-</tr>
-<tr>
 <td><p><a name="GST-VIDEO-FORMAT-RGB16:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_RGB16</code></span></p></td>
 <td>rgb 5-6-5 bits per component (Since: 0.10.30)
 </td>
@@ -1009,7 +1093,7 @@
 </td>
 </tr>
 <tr>
-<td><p><a name="GST-VIDEO-FORMAT-RGB8-PALETTED:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_RGB8_PALETTED</code></span></p></td>
+<td><p><a name="GST-VIDEO-FORMAT-RGB8P:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_RGB8P</code></span></p></td>
 <td>8-bit paletted RGB (Since: 0.10.32)
 </td>
 </tr>
@@ -1044,8 +1128,13 @@
 </td>
 </tr>
 <tr>
-<td><p><a name="GST-VIDEO-FORMAT-ENCODED:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_ENCODED</code></span></p></td>
-<td>Encoded video format
+<td><p><a name="GST-VIDEO-FORMAT-I420-10BE:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_I420_10BE</code></span></p></td>
+<td>planar 4:2:0 YUV, 10 bits per channel
+</td>
+</tr>
+<tr>
+<td><p><a name="GST-VIDEO-FORMAT-I420-10LE:CAPS"></a><span class="term"><code class="literal">GST_VIDEO_FORMAT_I420_10LE</code></span></p></td>
+<td>planar 4:2:0 YUV, 10 bits per channel
 </td>
 </tr>
 </tbody>
@@ -1072,7 +1161,10 @@
 
   GstVideoFormat unpack_format;
   GstVideoFormatUnpack unpack_func;
+  gint pack_lines;
   GstVideoFormatPack pack_func;
+
+  gpointer _gst_reserved[GST_PADDING];
 };
 </pre>
 <p>
@@ -1156,9 +1248,17 @@
 <td>an unpack function for this format</td>
 </tr>
 <tr>
+<td><p><span class="term"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstVideoFormatInfo.pack-lines"></a>pack_lines</code></em>;</span></p></td>
+<td>the amount of lines that will be packed</td>
+</tr>
+<tr>
 <td><p><span class="term"><a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoFormatPack" title="GstVideoFormatPack ()"><span class="type">GstVideoFormatPack</span></a> <em class="structfield"><code><a name="GstVideoFormatInfo.pack-func"></a>pack_func</code></em>;</span></p></td>
 <td>an pack function for this format</td>
 </tr>
+<tr>
+<td><p><span class="term"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> <em class="structfield"><code><a name="GstVideoFormatInfo.-gst-reserved"></a>_gst_reserved</code></em>[GST_PADDING];</span></p></td>
+<td></td>
+</tr>
 </tbody>
 </table></div>
 </div>
@@ -1326,8 +1426,6 @@
   GstVideoChromaSite        chroma_site;
   GstVideoColorimetry       colorimetry;
 
-  GstBuffer                *palette;
-
   gint                      par_n;
   gint                      par_d;
   gint                      fps_n;
@@ -1386,10 +1484,6 @@
 <td>the colorimetry info</td>
 </tr>
 <tr>
-<td><p><span class="term"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a> *<em class="structfield"><code><a name="GstVideoInfo.palette"></a>palette</code></em>;</span></p></td>
-<td>a buffer with palette data</td>
-</tr>
-<tr>
 <td><p><span class="term"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> <em class="structfield"><code><a name="GstVideoInfo.par-n"></a>par_n</code></em>;</span></p></td>
 <td>the pixel-aspect-ratio numerator</td>
 </tr>
@@ -1634,6 +1728,47 @@
                                                          <em class="parameter"><code><span class="type">gint64</span> src_value</code></em>,
                                                          <em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> dest_format</code></em>,
                                                          <em class="parameter"><code><span class="type">gint64</span> *dest_value</code></em>);</pre>
+<p>
+Converts among various <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> types.  This function handles
+GST_FORMAT_BYTES, GST_FORMAT_TIME, and GST_FORMAT_DEFAULT.  For
+raw video, GST_FORMAT_DEFAULT corresponds to video frames.  This
+function can be used to handle pad queries of the type GST_QUERY_CONVERT.
+</p>
+<div class="variablelist"><table border="0">
+<col align="left" valign="top">
+<tbody>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>info</code></em> :</span></p></td>
+<td>a <a class="link" href="gst-plugins-base-libs-gstvideo.html#GstVideoInfo" title="struct GstVideoInfo"><span class="type">GstVideoInfo</span></a>
+</td>
+</tr>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>src_format</code></em> :</span></p></td>
+<td>
+<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> of the <em class="parameter"><code>src_value</code></em>
+</td>
+</tr>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>src_value</code></em> :</span></p></td>
+<td>value to convert</td>
+</tr>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>dest_format</code></em> :</span></p></td>
+<td>
+<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstFormat.html#GstFormat"><span class="type">GstFormat</span></a> of the <em class="parameter"><code>dest_value</code></em>
+</td>
+</tr>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>dest_value</code></em> :</span></p></td>
+<td>pointer to destination value</td>
+</tr>
+<tr>
+<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
+<td>TRUE if the conversion was successful.</td>
+</tr>
+</tbody>
+</table></div>
+<p class="since">Since 0.10.16</p>
 </div>
 <hr>
 <div class="refsect2">
@@ -1846,31 +1981,6 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="gst-video-parse-caps-palette"></a><h3>gst_video_parse_caps_palette ()</h3>
-<pre class="programlisting"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="returnvalue">GstBuffer</span></a> *         gst_video_parse_caps_palette        (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> *caps</code></em>);</pre>
-<p>
-Returns the palette data from the caps as a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a>. For
-<a class="link" href="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB8-PALETTED:CAPS"><span class="type">GST_VIDEO_FORMAT_RGB8_PALETTED</span></a> this is containing 256 <span class="type">guint32</span>
-values, each containing ARGB colors in native endianness.
-</p>
-<div class="variablelist"><table border="0">
-<col align="left" valign="top">
-<tbody>
-<tr>
-<td><p><span class="term"><em class="parameter"><code>caps</code></em> :</span></p></td>
-<td>
-<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstCaps.html#GstCaps"><span class="type">GstCaps</span></a> to parse</td>
-</tr>
-<tr>
-<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
-<td>a <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstBuffer.html#GstBuffer"><span class="type">GstBuffer</span></a> containing the palette data. Unref after usage.</td>
-</tr>
-</tbody>
-</table></div>
-<p class="since">Since 0.10.32</p>
-</div>
-<hr>
-<div class="refsect2">
 <a name="GstVideoConvertSampleCallback"></a><h3>GstVideoConvertSampleCallback ()</h3>
 <pre class="programlisting"><span class="returnvalue">void</span>                (*GstVideoConvertSampleCallback)    (<em class="parameter"><code><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gstreamer-GstSample.html#GstSample"><span class="type">GstSample</span></a> *sample</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Error-Reporting.html#GError"><span class="type">GError</span></a> *error</code></em>,
diff --git a/docs/libs/html/gst-plugins-base-libs-gstvideofilter.html b/docs/libs/html/gst-plugins-base-libs-gstvideofilter.html
index f85b52a..d4c80ab 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstvideofilter.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstvideofilter.html
@@ -62,7 +62,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp24731744"></a><p>
+<a name="idp5945904"></a><p>
 Provides useful functions and a base class for video filters.
 </p>
 <p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstvideooverlay.html b/docs/libs/html/gst-plugins-base-libs-gstvideooverlay.html
index 8b84646..111e555 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstvideooverlay.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstvideooverlay.html
@@ -75,7 +75,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp28156752"></a><p>
+<a name="idp25488800"></a><p>
 The <a class="link" href="gst-plugins-base-libs-gstvideooverlay.html#GstVideoOverlay"><span class="type">GstVideoOverlay</span></a> interface is used for 2 main purposes :
 </p>
 <div class="itemizedlist"><ul class="itemizedlist" type="disc">
@@ -187,7 +187,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp28166848"></a><h3>Two basic usage scenarios</h3>
+<a name="idp24933824"></a><h3>Two basic usage scenarios</h3>
 <p>
 There are two basic usage scenarios: in the simplest case, the application
 knows exactly what particular element is used for video output, which is
@@ -232,7 +232,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp29541664"></a><h3>GstVideoOverlay and Gtk+</h3>
+<a name="idp21545392"></a><h3>GstVideoOverlay and Gtk+</h3>
 <p>
 </p>
 <div class="informalexample">
@@ -441,7 +441,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp29546832"></a><h3>GstVideoOverlay and Qt</h3>
+<a name="idp27827456"></a><h3>GstVideoOverlay and Qt</h3>
 <p>
 </p>
 <div class="informalexample">
diff --git a/docs/libs/html/gst-plugins-base-libs-gstvideooverlaycomposition.html b/docs/libs/html/gst-plugins-base-libs-gstvideooverlaycomposition.html
index 21945ac..5fcfd01 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstvideooverlaycomposition.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstvideooverlaycomposition.html
@@ -121,7 +121,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp28292272"></a><p>
+<a name="idp27926912"></a><p>
 Functions to create and handle overlay compositions on video buffers.
 </p>
 <p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstvideosink.html b/docs/libs/html/gst-plugins-base-libs-gstvideosink.html
index 29d43a3..1f80622 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstvideosink.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstvideosink.html
@@ -78,7 +78,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp24318960"></a><p>
+<a name="idp24251952"></a><p>
 Provides useful functions and a base class for video sinks. 
 </p>
 <p>
diff --git a/docs/libs/html/gst-plugins-base-libs-gstvideoutils.html b/docs/libs/html/gst-plugins-base-libs-gstvideoutils.html
index 88ad57b..ab05068 100644
--- a/docs/libs/html/gst-plugins-base-libs-gstvideoutils.html
+++ b/docs/libs/html/gst-plugins-base-libs-gstvideoutils.html
@@ -59,9 +59,10 @@
 #define             <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GST-VIDEO-CODEC-FRAME-UNSET-SYNC-POINT:CAPS" title="GST_VIDEO_CODEC_FRAME_UNSET_SYNC_POINT()">GST_VIDEO_CODEC_FRAME_UNSET_SYNC_POINT</a>(frame)
 <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="returnvalue">GstVideoCodecFrame</span></a> * <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-ref" title="gst_video_codec_frame_ref ()">gst_video_codec_frame_ref</a>          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>);
 <span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-unref" title="gst_video_codec_frame_unref ()">gst_video_codec_frame_unref</a>         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>);
-<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-hook" title="gst_video_codec_frame_set_hook ()">gst_video_codec_frame_set_hook</a>      (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>,
-                                                         <em class="parameter"><code><span class="type">void</span> *hook</code></em>,
+<span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-user-data" title="gst_video_codec_frame_set_user_data ()">gst_video_codec_frame_set_user_data</a> (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>,
+                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> notify</code></em>);
+<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="returnvalue">gpointer</span></a>            <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-get-user-data" title="gst_video_codec_frame_get_user_data ()">gst_video_codec_frame_get_user_data</a> (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>);
 struct              <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState">GstVideoCodecState</a>;
 <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState"><span class="returnvalue">GstVideoCodecState</span></a> * <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-state-ref" title="gst_video_codec_state_ref ()">gst_video_codec_state_ref</a>          (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState"><span class="type">GstVideoCodecState</span></a> *state</code></em>);
 <span class="returnvalue">void</span>                <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-state-unref" title="gst_video_codec_state_unref ()">gst_video_codec_state_unref</a>         (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState" title="struct GstVideoCodecState"><span class="type">GstVideoCodecState</span></a> *state</code></em>);
@@ -89,10 +90,6 @@
   GstBuffer *output_buffer; /* ED */
 
   GstClockTime deadline; /* D */
-
-  /* Events that should be pushed downstream *before*
-   * the next output_buffer */
-  GList *events;		/* ED */
 };
 </pre>
 <p>
@@ -148,10 +145,6 @@
 <td><p><span class="term"><a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstClock.html#GstClockTime"><span class="type">GstClockTime</span></a> <em class="structfield"><code><a name="GstVideoCodecFrame.deadline"></a>deadline</code></em>;</span></p></td>
 <td>Running time when the frame will be used.</td>
 </tr>
-<tr>
-<td><p><span class="term"><a href="http://library.gnome.org/devel/glib/unstable/glib-Doubly-Linked-Lists.html#GList"><span class="type">GList</span></a> *<em class="structfield"><code><a name="GstVideoCodecFrame.events"></a>events</code></em>;</span></p></td>
-<td>Events that will be pushed downstream before this frame is pushed.</td>
-</tr>
 </tbody>
 </table></div>
 </div>
@@ -476,17 +469,17 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="gst-video-codec-frame-set-hook"></a><h3>gst_video_codec_frame_set_hook ()</h3>
-<pre class="programlisting"><span class="returnvalue">void</span>                gst_video_codec_frame_set_hook      (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>,
-                                                         <em class="parameter"><code><span class="type">void</span> *hook</code></em>,
+<a name="gst-video-codec-frame-set-user-data"></a><h3>gst_video_codec_frame_set_user_data ()</h3>
+<pre class="programlisting"><span class="returnvalue">void</span>                gst_video_codec_frame_set_user_data (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>,
+                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data</code></em>,
                                                          <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> notify</code></em>);</pre>
 <p>
-Sets the <a href="http://library.gnome.org/devel/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> that will be called (along with the <em class="parameter"><code>hook</code></em>) when
-the frame is freed.
+Sets <em class="parameter"><code>user_data</code></em> on the frame and the <a href="http://library.gnome.org/devel/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a> that will be called when
+the frame is freed. Allows to attach private data by the subclass to frames.
 </p>
 <p>
-If a <em class="parameter"><code>hook</code></em> was previously set, then the previous set <em class="parameter"><code>notify</code></em> will be called
-before the <em class="parameter"><code>hook</code></em> is replaced.
+If a <em class="parameter"><code>user_data</code></em> was previously set, then the previous set <em class="parameter"><code>notify</code></em> will be called
+before the <em class="parameter"><code>user_data</code></em> is replaced.
 </p>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
@@ -497,12 +490,36 @@
 </td>
 </tr>
 <tr>
-<td><p><span class="term"><em class="parameter"><code>hook</code></em> :</span></p></td>
+<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
 <td>private data</td>
 </tr>
 <tr>
 <td><p><span class="term"><em class="parameter"><code>notify</code></em> :</span></p></td>
-<td>a <a href="http://library.gnome.org/devel/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a>. <span class="annotation">[<acronym title="This parameter is a 'user_data', for callbacks; many bindings can pass NULL here."><span class="acronym">closure</span></acronym> hook]</span>
+<td>a <a href="http://library.gnome.org/devel/glib/unstable/glib-Datasets.html#GDestroyNotify"><span class="type">GDestroyNotify</span></a>. <span class="annotation">[<acronym title="This parameter is a 'user_data', for callbacks; many bindings can pass NULL here."><span class="acronym">closure</span></acronym> user_data]</span>
+</td>
+</tr>
+</tbody>
+</table></div>
+</div>
+<hr>
+<div class="refsect2">
+<a name="gst-video-codec-frame-get-user-data"></a><h3>gst_video_codec_frame_get_user_data ()</h3>
+<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="returnvalue">gpointer</span></a>            gst_video_codec_frame_get_user_data (<em class="parameter"><code><a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a> *frame</code></em>);</pre>
+<p>
+Gets private data set on the frame by the subclass via
+<a class="link" href="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-user-data" title="gst_video_codec_frame_set_user_data ()"><code class="function">gst_video_codec_frame_set_user_data()</code></a> previously.
+</p>
+<div class="variablelist"><table border="0">
+<col align="left" valign="top">
+<tbody>
+<tr>
+<td><p><span class="term"><em class="parameter"><code>frame</code></em> :</span></p></td>
+<td>a <a class="link" href="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecFrame" title="struct GstVideoCodecFrame"><span class="type">GstVideoCodecFrame</span></a>
+</td>
+</tr>
+<tr>
+<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
+<td>The previously set user_data. <span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span>
 </td>
 </tr>
 </tbody>
diff --git a/docs/libs/html/gst-plugins-base-libs.devhelp2 b/docs/libs/html/gst-plugins-base-libs.devhelp2
index 7e2d5ce..161ad1e 100644
--- a/docs/libs/html/gst-plugins-base-libs.devhelp2
+++ b/docs/libs/html/gst-plugins-base-libs.devhelp2
@@ -162,7 +162,7 @@
     <keyword type="macro" name="GST_CLOCK_TIME_TO_FRAMES()" link="gst-plugins-base-libs-gstaudio.html#GST-CLOCK-TIME-TO-FRAMES:CAPS"/>
     <keyword type="macro" name="GST_AUDIO_DEF_RATE" link="gst-plugins-base-libs-gstaudio.html#GST-AUDIO-DEF-RATE:CAPS"/>
     <keyword type="function" name="gst_audio_buffer_clip ()" link="gst-plugins-base-libs-gstaudio.html#gst-audio-buffer-clip" since="0.10.14"/>
-    <keyword type="" name="Using GstAudioCdSrc-based elements in applications" link="gst-plugins-base-libs-gstaudiocdsrc.html#idp8421984"/>
+    <keyword type="" name="Using GstAudioCdSrc-based elements in applications" link="gst-plugins-base-libs-gstaudiocdsrc.html#idp8117088"/>
     <keyword type="struct" name="struct GstAudioCdSrc" link="gst-plugins-base-libs-gstaudiocdsrc.html#GstAudioCdSrc-struct"/>
     <keyword type="struct" name="struct GstAudioCdSrcClass" link="gst-plugins-base-libs-gstaudiocdsrc.html#GstAudioCdSrcClass"/>
     <keyword type="struct" name="struct GstAudioCdSrcTrack" link="gst-plugins-base-libs-gstaudiocdsrc.html#GstAudioCdSrcTrack"/>
@@ -290,7 +290,7 @@
     <keyword type="property" name="The &quot;provide-clock&quot; property" link="gst-plugins-base-libs-gstaudiobasesrc.html#GstAudioBaseSrc--provide-clock"/>
     <keyword type="property" name="The &quot;slave-method&quot; property" link="gst-plugins-base-libs-gstaudiobasesrc.html#GstAudioBaseSrc--slave-method"/>
     <keyword type="enum" name="enum GstAudioChannelPosition" link="gst-plugins-base-libs-gstmultichannel.html#GstAudioChannelPosition"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstaudioringbuffer.html#idp13203760"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstaudioringbuffer.html#idp12901776"/>
     <keyword type="struct" name="struct GstAudioRingBuffer" link="gst-plugins-base-libs-gstaudioringbuffer.html#GstAudioRingBuffer-struct"/>
     <keyword type="struct" name="struct GstAudioRingBufferClass" link="gst-plugins-base-libs-gstaudioringbuffer.html#GstAudioRingBufferClass"/>
     <keyword type="struct" name="struct GstAudioRingBufferSpec" link="gst-plugins-base-libs-gstaudioringbuffer.html#GstAudioRingBufferSpec"/>
@@ -328,7 +328,7 @@
     <keyword type="function" name="gst_audio_ring_buffer_set_flushing ()" link="gst-plugins-base-libs-gstaudioringbuffer.html#gst-audio-ring-buffer-set-flushing"/>
     <keyword type="function" name="gst_audio_iec61937_frame_size ()" link="gst-plugins-base-libs-gstaudioiec61937.html#gst-audio-iec61937-frame-size" since="0.10.36"/>
     <keyword type="function" name="gst_audio_iec61937_payload ()" link="gst-plugins-base-libs-gstaudioiec61937.html#gst-audio-iec61937-payload" since="0.10.36"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gststreamvolume.html#idp12023536"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gststreamvolume.html#idp13256512"/>
     <keyword type="struct" name="GstStreamVolume" link="gst-plugins-base-libs-gststreamvolume.html#GstStreamVolume-struct"/>
     <keyword type="enum" name="enum GstStreamVolumeFormat" link="gst-plugins-base-libs-gststreamvolume.html#GstStreamVolumeFormat" since="0.10.25"/>
     <keyword type="function" name="gst_stream_volume_get_volume ()" link="gst-plugins-base-libs-gststreamvolume.html#gst-stream-volume-get-volume" since="0.10.25"/>
@@ -383,7 +383,7 @@
     <keyword type="function" name="gst_riff_parse_strf_vids ()" link="gst-plugins-base-libs-gstriff.html#gst-riff-parse-strf-vids"/>
     <keyword type="function" name="gst_riff_parse_strh ()" link="gst-plugins-base-libs-gstriff.html#gst-riff-parse-strh"/>
     <keyword type="function" name="gst_riff_read_chunk ()" link="gst-plugins-base-libs-gstriff.html#gst-riff-read-chunk"/>
-    <keyword type="" name="Usage" link="gst-plugins-base-libs-gstrtpbaseaudiopayload.html#idp14728384"/>
+    <keyword type="" name="Usage" link="gst-plugins-base-libs-gstrtpbaseaudiopayload.html#idp15202640"/>
     <keyword type="struct" name="struct GstRTPBaseAudioPayload" link="gst-plugins-base-libs-gstrtpbaseaudiopayload.html#GstRTPBaseAudioPayload-struct"/>
     <keyword type="struct" name="struct GstRTPBaseAudioPayloadClass" link="gst-plugins-base-libs-gstrtpbaseaudiopayload.html#GstRTPBaseAudioPayloadClass"/>
     <keyword type="function" name="gst_rtp_base_audio_payload_set_frame_based ()" link="gst-plugins-base-libs-gstrtpbaseaudiopayload.html#gst-rtp-base-audio-payload-set-frame-based"/>
@@ -423,7 +423,7 @@
     <keyword type="property" name="The &quot;ssrc&quot; property" link="gst-plugins-base-libs-gstrtpbasepayload.html#GstRTPBasePayload--ssrc"/>
     <keyword type="property" name="The &quot;timestamp&quot; property" link="gst-plugins-base-libs-gstrtpbasepayload.html#GstRTPBasePayload--timestamp"/>
     <keyword type="property" name="The &quot;timestamp-offset&quot; property" link="gst-plugins-base-libs-gstrtpbasepayload.html#GstRTPBasePayload--timestamp-offset"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstrtpbuffer.html#idp15981600"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstrtpbuffer.html#idp16433216"/>
     <keyword type="macro" name="GST_RTP_VERSION" link="gst-plugins-base-libs-gstrtpbuffer.html#GST-RTP-VERSION:CAPS"/>
     <keyword type="function" name="gst_rtp_buffer_allocate_data ()" link="gst-plugins-base-libs-gstrtpbuffer.html#gst-rtp-buffer-allocate-data"/>
     <keyword type="function" name="gst_rtp_buffer_new_take_data ()" link="gst-plugins-base-libs-gstrtpbuffer.html#gst-rtp-buffer-new-take-data"/>
@@ -471,7 +471,7 @@
     <keyword type="function" name="gst_rtp_buffer_get_extension_twobytes_header ()" link="gst-plugins-base-libs-gstrtpbuffer.html#gst-rtp-buffer-get-extension-twobytes-header" since="0.10.31"/>
     <keyword type="function" name="gst_rtp_buffer_add_extension_onebyte_header ()" link="gst-plugins-base-libs-gstrtpbuffer.html#gst-rtp-buffer-add-extension-onebyte-header" since="0.10.31"/>
     <keyword type="function" name="gst_rtp_buffer_add_extension_twobytes_header ()" link="gst-plugins-base-libs-gstrtpbuffer.html#gst-rtp-buffer-add-extension-twobytes-header" since="0.10.31"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstrtcpbuffer.html#idp16389952"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstrtcpbuffer.html#idp16670464"/>
     <keyword type="macro" name="GST_RTCP_VERSION" link="gst-plugins-base-libs-gstrtcpbuffer.html#GST-RTCP-VERSION:CAPS"/>
     <keyword type="macro" name="GST_RTCP_MAX_SDES" link="gst-plugins-base-libs-gstrtcpbuffer.html#GST-RTCP-MAX-SDES:CAPS"/>
     <keyword type="macro" name="GST_RTCP_MAX_BYE_SSRC_COUNT" link="gst-plugins-base-libs-gstrtcpbuffer.html#GST-RTCP-MAX-BYE-SSRC-COUNT:CAPS"/>
@@ -537,7 +537,7 @@
     <keyword type="function" name="gst_rtcp_unix_to_ntp ()" link="gst-plugins-base-libs-gstrtcpbuffer.html#gst-rtcp-unix-to-ntp"/>
     <keyword type="function" name="gst_rtcp_sdes_name_to_type ()" link="gst-plugins-base-libs-gstrtcpbuffer.html#gst-rtcp-sdes-name-to-type" since="0.10.26"/>
     <keyword type="function" name="gst_rtcp_sdes_type_to_name ()" link="gst-plugins-base-libs-gstrtcpbuffer.html#gst-rtcp-sdes-type-to-name" since="0.10.26"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstrtppayloads.html#idp15527360"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstrtppayloads.html#idp14256528"/>
     <keyword type="enum" name="enum GstRTPPayload" link="gst-plugins-base-libs-gstrtppayloads.html#GstRTPPayload"/>
     <keyword type="macro" name="GST_RTP_PAYLOAD_IS_DYNAMIC()" link="gst-plugins-base-libs-gstrtppayloads.html#GST-RTP-PAYLOAD-IS-DYNAMIC:CAPS"/>
     <keyword type="struct" name="struct GstRTPPayloadInfo" link="gst-plugins-base-libs-gstrtppayloads.html#GstRTPPayloadInfo"/>
@@ -598,7 +598,7 @@
     <keyword type="function" name="gst_rtsp_options_as_text ()" link="gst-plugins-base-libs-gstrtspdefs.html#gst-rtsp-options-as-text" since="0.10.23"/>
     <keyword type="function" name="gst_rtsp_find_header_field ()" link="gst-plugins-base-libs-gstrtspdefs.html#gst-rtsp-find-header-field"/>
     <keyword type="function" name="gst_rtsp_find_method ()" link="gst-plugins-base-libs-gstrtspdefs.html#gst-rtsp-find-method"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstrtspextension.html#idp10284464"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstrtspextension.html#idp13098528"/>
     <keyword type="struct" name="GstRTSPExtension" link="gst-plugins-base-libs-gstrtspextension.html#GstRTSPExtension"/>
     <keyword type="struct" name="struct GstRTSPExtensionInterface" link="gst-plugins-base-libs-gstrtspextension.html#GstRTSPExtensionInterface"/>
     <keyword type="enum" name="enum GstRTSPMsgType" link="gst-plugins-base-libs-gstrtspmessage.html#GstRTSPMsgType"/>
@@ -655,7 +655,7 @@
     <keyword type="function" name="gst_rtsp_url_set_port ()" link="gst-plugins-base-libs-gstrtspurl.html#gst-rtsp-url-set-port"/>
     <keyword type="function" name="gst_rtsp_url_get_port ()" link="gst-plugins-base-libs-gstrtspurl.html#gst-rtsp-url-get-port"/>
     <keyword type="function" name="gst_rtsp_url_decode_path_components ()" link="gst-plugins-base-libs-gstrtspurl.html#gst-rtsp-url-decode-path-components" since="0.10.32"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstsdpmessage.html#idp22662448"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstsdpmessage.html#idp22412656"/>
     <keyword type="enum" name="enum GstSDPResult" link="gst-plugins-base-libs-gstsdpmessage.html#GstSDPResult"/>
     <keyword type="struct" name="GstSDPOrigin" link="gst-plugins-base-libs-gstsdpmessage.html#GstSDPOrigin"/>
     <keyword type="struct" name="GstSDPConnection" link="gst-plugins-base-libs-gstsdpmessage.html#GstSDPConnection"/>
@@ -749,7 +749,7 @@
     <keyword type="function" name="gst_sdp_media_get_attribute_val_n ()" link="gst-plugins-base-libs-gstsdpmessage.html#gst-sdp-media-get-attribute-val-n"/>
     <keyword type="function" name="gst_sdp_media_add_attribute ()" link="gst-plugins-base-libs-gstsdpmessage.html#gst-sdp-media-add-attribute"/>
     <keyword type="function" name="gst_sdp_media_as_text ()" link="gst-plugins-base-libs-gstsdpmessage.html#gst-sdp-media-as-text"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gsttag.html#idp17468672"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gsttag.html#idp20414752"/>
     <keyword type="macro" name="GST_TAG_MUSICBRAINZ_TRACKID" link="gst-plugins-base-libs-gsttag.html#GST-TAG-MUSICBRAINZ-TRACKID:CAPS"/>
     <keyword type="macro" name="GST_TAG_MUSICBRAINZ_ARTISTID" link="gst-plugins-base-libs-gsttag.html#GST-TAG-MUSICBRAINZ-ARTISTID:CAPS"/>
     <keyword type="macro" name="GST_TAG_MUSICBRAINZ_ALBUMID" link="gst-plugins-base-libs-gsttag.html#GST-TAG-MUSICBRAINZ-ALBUMID:CAPS"/>
@@ -788,14 +788,14 @@
     <keyword type="function" name="gst_tag_freeform_string_to_utf8 ()" link="gst-plugins-base-libs-gsttag.html#gst-tag-freeform-string-to-utf8" since="0.10.13"/>
     <keyword type="function" name="gst_tag_parse_extended_comment ()" link="gst-plugins-base-libs-gsttag.html#gst-tag-parse-extended-comment" since="0.10.10"/>
     <keyword type="enum" name="enum GstTagImageType" link="gst-plugins-base-libs-gsttag.html#GstTagImageType" since="0.10.9"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gsttagvorbis.html#idp17451568"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gsttagvorbis.html#idp20607664"/>
     <keyword type="function" name="gst_tag_from_vorbis_tag ()" link="gst-plugins-base-libs-gsttagvorbis.html#gst-tag-from-vorbis-tag"/>
     <keyword type="function" name="gst_tag_to_vorbis_tag ()" link="gst-plugins-base-libs-gsttagvorbis.html#gst-tag-to-vorbis-tag"/>
     <keyword type="function" name="gst_vorbis_tag_add ()" link="gst-plugins-base-libs-gsttagvorbis.html#gst-vorbis-tag-add"/>
     <keyword type="function" name="gst_tag_to_vorbis_comments ()" link="gst-plugins-base-libs-gsttagvorbis.html#gst-tag-to-vorbis-comments"/>
     <keyword type="function" name="gst_tag_list_from_vorbiscomment_buffer ()" link="gst-plugins-base-libs-gsttagvorbis.html#gst-tag-list-from-vorbiscomment-buffer"/>
     <keyword type="function" name="gst_tag_list_to_vorbiscomment_buffer ()" link="gst-plugins-base-libs-gsttagvorbis.html#gst-tag-list-to-vorbiscomment-buffer"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gsttagid3.html#idp20818768"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gsttagid3.html#idp8756128"/>
     <keyword type="function" name="gst_tag_id3_genre_count ()" link="gst-plugins-base-libs-gsttagid3.html#gst-tag-id3-genre-count"/>
     <keyword type="function" name="gst_tag_id3_genre_get ()" link="gst-plugins-base-libs-gsttagid3.html#gst-tag-id3-genre-get"/>
     <keyword type="function" name="gst_tag_list_new_from_id3v1 ()" link="gst-plugins-base-libs-gsttagid3.html#gst-tag-list-new-from-id3v1"/>
@@ -813,21 +813,21 @@
     <keyword type="function" name="gst_tag_list_to_xmp_buffer ()" link="gst-plugins-base-libs-gsttagxmp.html#gst-tag-list-to-xmp-buffer" since="0.10.29"/>
     <keyword type="function" name="gst_tag_list_to_xmp_buffer_full ()" link="gst-plugins-base-libs-gsttagxmp.html#gst-tag-list-to-xmp-buffer-full" since="0.10.33"/>
     <keyword type="function" name="gst_tag_xmp_list_schemas ()" link="gst-plugins-base-libs-gsttagxmp.html#gst-tag-xmp-list-schemas" since="0.10.33"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gsttagxmpwriter.html#idp22401328"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gsttagxmpwriter.html#idp17832512"/>
     <keyword type="function" name="gst_tag_xmp_writer_add_all_schemas ()" link="gst-plugins-base-libs-gsttagxmpwriter.html#gst-tag-xmp-writer-add-all-schemas" since="0.10.33"/>
     <keyword type="function" name="gst_tag_xmp_writer_add_schema ()" link="gst-plugins-base-libs-gsttagxmpwriter.html#gst-tag-xmp-writer-add-schema" since="0.10.33"/>
     <keyword type="function" name="gst_tag_xmp_writer_has_schema ()" link="gst-plugins-base-libs-gsttagxmpwriter.html#gst-tag-xmp-writer-has-schema" since="0.10.33"/>
     <keyword type="function" name="gst_tag_xmp_writer_remove_schema ()" link="gst-plugins-base-libs-gsttagxmpwriter.html#gst-tag-xmp-writer-remove-schema" since="0.10.33"/>
     <keyword type="function" name="gst_tag_xmp_writer_remove_all_schemas ()" link="gst-plugins-base-libs-gsttagxmpwriter.html#gst-tag-xmp-writer-remove-all-schemas" since="0.10.33"/>
     <keyword type="function" name="gst_tag_xmp_writer_tag_list_to_xmp_buffer ()" link="gst-plugins-base-libs-gsttagxmpwriter.html#gst-tag-xmp-writer-tag-list-to-xmp-buffer"/>
-    <keyword type="" name="Deriving from GstTagDemux" link="gst-plugins-base-libs-gsttagdemux.html#idp15580112"/>
+    <keyword type="" name="Deriving from GstTagDemux" link="gst-plugins-base-libs-gsttagdemux.html#idp9323184"/>
     <keyword type="struct" name="struct GstTagDemux" link="gst-plugins-base-libs-gsttagdemux.html#GstTagDemux" since="0.10.15"/>
     <keyword type="struct" name="struct GstTagDemuxClass" link="gst-plugins-base-libs-gsttagdemux.html#GstTagDemuxClass" since="0.10.15"/>
     <keyword type="enum" name="enum GstTagDemuxResult" link="gst-plugins-base-libs-gsttagdemux.html#GstTagDemuxResult" since="0.10.15"/>
-    <keyword type="" name="Deriving from GstTagMux" link="gst-plugins-base-libs-gsttagmux.html#idp9718656"/>
+    <keyword type="" name="Deriving from GstTagMux" link="gst-plugins-base-libs-gsttagmux.html#idp8486624"/>
     <keyword type="struct" name="struct GstTagMux" link="gst-plugins-base-libs-gsttagmux.html#GstTagMux" since="0.10.36"/>
     <keyword type="struct" name="struct GstTagMuxClass" link="gst-plugins-base-libs-gsttagmux.html#GstTagMuxClass" since="0.10.36"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gsttaglanguagecodes.html#idp22582832"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gsttaglanguagecodes.html#idp21746368"/>
     <keyword type="function" name="gst_tag_get_language_codes ()" link="gst-plugins-base-libs-gsttaglanguagecodes.html#gst-tag-get-language-codes" since="0.10.26"/>
     <keyword type="function" name="gst_tag_get_language_name ()" link="gst-plugins-base-libs-gsttaglanguagecodes.html#gst-tag-get-language-name" since="0.10.26"/>
     <keyword type="macro" name="gst_tag_get_language_code()" link="gst-plugins-base-libs-gsttaglanguagecodes.html#gst-tag-get-language-code" since="0.10.26"/>
@@ -843,7 +843,7 @@
     <keyword type="function" name="gst_tag_get_license_jurisdiction ()" link="gst-plugins-base-libs-gsttaglicenses.html#gst-tag-get-license-jurisdiction" since="0.10.36"/>
     <keyword type="function" name="gst_tag_get_license_version ()" link="gst-plugins-base-libs-gsttaglicenses.html#gst-tag-get-license-version" since="0.10.36"/>
     <keyword type="function" name="gst_tag_get_licenses ()" link="gst-plugins-base-libs-gsttaglicenses.html#gst-tag-get-licenses" since="0.10.36"/>
-    <keyword type="" name="Linking to this library" link="gst-plugins-base-libs-gstpbutils.html#idp13061536"/>
+    <keyword type="" name="Linking to this library" link="gst-plugins-base-libs-gstpbutils.html#idp9848960"/>
     <keyword type="function" name="gst_pb_utils_init ()" link="gst-plugins-base-libs-gstpbutils.html#gst-pb-utils-init" since="0.10.12"/>
     <keyword type="macro" name="GST_PLUGINS_BASE_VERSION_MAJOR" link="gst-plugins-base-libs-gstpluginsbaseversion.html#GST-PLUGINS-BASE-VERSION-MAJOR:CAPS" since="0.10.31"/>
     <keyword type="macro" name="GST_PLUGINS_BASE_VERSION_MINOR" link="gst-plugins-base-libs-gstpluginsbaseversion.html#GST-PLUGINS-BASE-VERSION-MINOR:CAPS" since="0.10.31"/>
@@ -852,7 +852,7 @@
     <keyword type="macro" name="GST_CHECK_PLUGINS_BASE_VERSION()" link="gst-plugins-base-libs-gstpluginsbaseversion.html#GST-CHECK-PLUGINS-BASE-VERSION:CAPS"/>
     <keyword type="function" name="gst_plugins_base_version ()" link="gst-plugins-base-libs-gstpluginsbaseversion.html#gst-plugins-base-version" since="0.10.31"/>
     <keyword type="function" name="gst_plugins_base_version_string ()" link="gst-plugins-base-libs-gstpluginsbaseversion.html#gst-plugins-base-version-string" since="0.10.31"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstpbutilscodecutils.html#idp24082256"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstpbutilscodecutils.html#idp23830656"/>
     <keyword type="function" name="gst_codec_utils_aac_get_sample_rate_from_index ()" link="gst-plugins-base-libs-gstpbutilscodecutils.html#gst-codec-utils-aac-get-sample-rate-from-index" since="0.10.31"/>
     <keyword type="function" name="gst_codec_utils_aac_get_profile ()" link="gst-plugins-base-libs-gstpbutilscodecutils.html#gst-codec-utils-aac-get-profile" since="0.10.31"/>
     <keyword type="function" name="gst_codec_utils_aac_get_level ()" link="gst-plugins-base-libs-gstpbutilscodecutils.html#gst-codec-utils-aac-get-level" since="0.10.31"/>
@@ -864,7 +864,7 @@
     <keyword type="function" name="gst_codec_utils_mpeg4video_get_profile ()" link="gst-plugins-base-libs-gstpbutilscodecutils.html#gst-codec-utils-mpeg4video-get-profile" since="0.10.31"/>
     <keyword type="function" name="gst_codec_utils_mpeg4video_get_level ()" link="gst-plugins-base-libs-gstpbutilscodecutils.html#gst-codec-utils-mpeg4video-get-level" since="0.10.31"/>
     <keyword type="function" name="gst_codec_utils_mpeg4video_caps_set_level_and_profile ()" link="gst-plugins-base-libs-gstpbutilscodecutils.html#gst-codec-utils-mpeg4video-caps-set-level-and-profile" since="0.10.31"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#idp21197200"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#idp21642416"/>
     <keyword type="function" name="gst_pb_utils_get_source_description ()" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#gst-pb-utils-get-source-description"/>
     <keyword type="function" name="gst_pb_utils_get_sink_description ()" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#gst-pb-utils-get-sink-description"/>
     <keyword type="function" name="gst_pb_utils_get_decoder_description ()" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#gst-pb-utils-get-decoder-description"/>
@@ -872,7 +872,7 @@
     <keyword type="function" name="gst_pb_utils_get_element_description ()" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#gst-pb-utils-get-element-description"/>
     <keyword type="function" name="gst_pb_utils_add_codec_description_to_tag_list ()" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#gst-pb-utils-add-codec-description-to-tag-list"/>
     <keyword type="function" name="gst_pb_utils_get_codec_description ()" link="gst-plugins-base-libs-gstpbutilsdescriptions.html#gst-pb-utils-get-codec-description"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#idp24416880"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#idp24641392"/>
     <keyword type="function" name="gst_missing_plugin_message_get_installer_detail ()" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#gst-missing-plugin-message-get-installer-detail"/>
     <keyword type="function" name="gst_missing_plugin_message_get_description ()" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#gst-missing-plugin-message-get-description"/>
     <keyword type="function" name="gst_is_missing_plugin_message ()" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#gst-is-missing-plugin-message"/>
@@ -886,7 +886,7 @@
     <keyword type="function" name="gst_missing_element_installer_detail_new ()" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#gst-missing-element-installer-detail-new" since="0.10.15"/>
     <keyword type="function" name="gst_missing_decoder_installer_detail_new ()" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#gst-missing-decoder-installer-detail-new" since="0.10.15"/>
     <keyword type="function" name="gst_missing_encoder_installer_detail_new ()" link="gst-plugins-base-libs-gstpbutilsmissingplugins.html#gst-missing-encoder-installer-detail-new" since="0.10.15"/>
-    <keyword type="" name="Overview" link="gst-plugins-base-libs-gstpbutilsinstallplugins.html#idp21458976"/>
+    <keyword type="" name="Overview" link="gst-plugins-base-libs-gstpbutilsinstallplugins.html#idp21298992"/>
     <keyword type="enum" name="enum GstInstallPluginsReturn" link="gst-plugins-base-libs-gstpbutilsinstallplugins.html#GstInstallPluginsReturn" since="0.10.12"/>
     <keyword type="function" name="GstInstallPluginsResultFunc ()" link="gst-plugins-base-libs-gstpbutilsinstallplugins.html#GstInstallPluginsResultFunc" since="0.10.12"/>
     <keyword type="function" name="gst_install_plugins_async ()" link="gst-plugins-base-libs-gstpbutilsinstallplugins.html#gst-install-plugins-async" since="0.10.12"/>
@@ -912,6 +912,7 @@
     <keyword type="function" name="gst_discoverer_info_get_stream_info ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-stream-info" since="0.10.31"/>
     <keyword type="function" name="gst_discoverer_info_get_stream_list ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-stream-list" since="0.10.31"/>
     <keyword type="function" name="gst_discoverer_info_get_tags ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-tags" since="0.10.31"/>
+    <keyword type="function" name="gst_discoverer_info_get_toc ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-toc" since="0.11.92"/>
     <keyword type="function" name="gst_discoverer_info_get_uri ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-uri" since="0.10.31"/>
     <keyword type="function" name="gst_discoverer_info_get_seekable ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-seekable" since="0.10.32"/>
     <keyword type="macro" name="gst_discoverer_info_ref()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-ref" since="0.10.31"/>
@@ -926,6 +927,7 @@
     <keyword type="function" name="gst_discoverer_stream_info_get_next ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-next" since="0.10.31"/>
     <keyword type="function" name="gst_discoverer_stream_info_get_previous ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-previous" since="0.10.31"/>
     <keyword type="function" name="gst_discoverer_stream_info_get_tags ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-tags" since="0.10.31"/>
+    <keyword type="function" name="gst_discoverer_stream_info_get_toc ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-toc" since="0.11.92"/>
     <keyword type="macro" name="gst_discoverer_stream_info_ref()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-ref" since="0.10.31"/>
     <keyword type="macro" name="gst_discoverer_stream_info_unref()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-unref" since="0.10.31"/>
     <keyword type="function" name="gst_discoverer_stream_info_list_free ()" link="gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-list-free"/>
@@ -958,9 +960,9 @@
     <keyword type="signal" name="The &quot;discovered&quot; signal" link="gst-plugins-base-libs-gstdiscoverer.html#GstDiscoverer-discovered"/>
     <keyword type="signal" name="The &quot;finished&quot; signal" link="gst-plugins-base-libs-gstdiscoverer.html#GstDiscoverer-finished"/>
     <keyword type="signal" name="The &quot;starting&quot; signal" link="gst-plugins-base-libs-gstdiscoverer.html#GstDiscoverer-starting"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-encoding-profile.html#idp25528832"/>
-    <keyword type="" name="Example: Creating a profile" link="gst-plugins-base-libs-encoding-profile.html#idp25536400"/>
-    <keyword type="" name="Example: Listing categories, targets and profiles" link="gst-plugins-base-libs-encoding-profile.html#idp25539392"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-encoding-profile.html#idp25217920"/>
+    <keyword type="" name="Example: Creating a profile" link="gst-plugins-base-libs-encoding-profile.html#idp25225488"/>
+    <keyword type="" name="Example: Listing categories, targets and profiles" link="gst-plugins-base-libs-encoding-profile.html#idp25228480"/>
     <keyword type="struct" name="GstEncodingProfile" link="gst-plugins-base-libs-encoding-profile.html#GstEncodingProfile-struct"/>
     <keyword type="macro" name="gst_encoding_profile_unref()" link="gst-plugins-base-libs-encoding-profile.html#gst-encoding-profile-unref" since="0.10.32"/>
     <keyword type="macro" name="gst_encoding_profile_ref()" link="gst-plugins-base-libs-encoding-profile.html#gst-encoding-profile-ref" since="0.10.32"/>
@@ -1014,7 +1016,7 @@
     <keyword type="function" name="gst_encoding_target_load_from_file ()" link="gst-plugins-base-libs-encoding-profile.html#gst-encoding-target-load-from-file" since="0.10.32"/>
     <keyword type="function" name="gst_encoding_list_all_targets ()" link="gst-plugins-base-libs-encoding-profile.html#gst-encoding-list-all-targets" since="0.10.32"/>
     <keyword type="function" name="gst_encoding_list_available_categories ()" link="gst-plugins-base-libs-encoding-profile.html#gst-encoding-list-available-categories" since="0.10.32"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstvideo.html#idp25775616"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstvideo.html#idp26138944"/>
     <keyword type="macro" name="GST_VIDEO_FPS_RANGE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FPS-RANGE:CAPS"/>
     <keyword type="macro" name="GST_VIDEO_SIZE_RANGE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-SIZE-RANGE:CAPS"/>
     <keyword type="enum" name="enum GstVideoChromaSite" link="gst-plugins-base-libs-gstvideo.html#GstVideoChromaSite"/>
@@ -1091,7 +1093,7 @@
     <keyword type="macro" name="GST_VIDEO_MAX_COMPONENTS" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-MAX-COMPONENTS:CAPS"/>
     <keyword type="macro" name="GST_VIDEO_MAX_PLANES" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-MAX-PLANES:CAPS"/>
     <keyword type="macro" name="GST_VIDEO_SUB_SCALE()" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-SUB-SCALE:CAPS"/>
-    <keyword type="function" name="gst_video_info_convert ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-info-convert"/>
+    <keyword type="function" name="gst_video_info_convert ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-info-convert" since="0.10.16"/>
     <keyword type="function" name="gst_video_info_from_caps ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-info-from-caps"/>
     <keyword type="function" name="gst_video_info_init ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-info-init"/>
     <keyword type="function" name="gst_video_info_set_format ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-info-set-format"/>
@@ -1099,7 +1101,6 @@
     <keyword type="function" name="gst_video_calculate_display_ratio ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-calculate-display-ratio" since="0.10.7"/>
     <keyword type="function" name="gst_video_format_to_fourcc ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-format-to-fourcc" since="0.10.16"/>
     <keyword type="function" name="gst_video_format_from_fourcc ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-format-from-fourcc" since="0.10.16"/>
-    <keyword type="function" name="gst_video_parse_caps_palette ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-parse-caps-palette" since="0.10.32"/>
     <keyword type="function" name="GstVideoConvertSampleCallback ()" link="gst-plugins-base-libs-gstvideo.html#GstVideoConvertSampleCallback"/>
     <keyword type="function" name="gst_video_convert_sample ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-convert-sample" since="0.10.31"/>
     <keyword type="function" name="gst_video_convert_sample_async ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-convert-sample-async" since="0.10.31"/>
@@ -1110,7 +1111,7 @@
     <keyword type="function" name="gst_video_event_is_force_key_unit ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-event-is-force-key-unit" since="0.10.36"/>
     <keyword type="function" name="gst_video_event_parse_upstream_force_key_unit ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-event-parse-upstream-force-key-unit" since="0.10.36"/>
     <keyword type="function" name="gst_video_event_parse_downstream_force_key_unit ()" link="gst-plugins-base-libs-gstvideo.html#gst-video-event-parse-downstream-force-key-unit" since="0.10.36"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#idp28292272"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#idp27926912"/>
     <keyword type="struct" name="GstVideoOverlayComposition" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#GstVideoOverlayComposition" since="0.10.36"/>
     <keyword type="struct" name="GstVideoOverlayCompositionClass" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#GstVideoOverlayCompositionClass"/>
     <keyword type="function" name="gst_video_overlay_composition_new ()" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#gst-video-overlay-composition-new" since="0.10.36"/>
@@ -1138,10 +1139,10 @@
     <keyword type="function" name="gst_video_overlay_rectangle_set_render_rectangle ()" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#gst-video-overlay-rectangle-set-render-rectangle" since="0.10.36"/>
     <keyword type="function" name="gst_video_overlay_rectangle_copy ()" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#gst-video-overlay-rectangle-copy" since="0.10.36"/>
     <keyword type="function" name="gst_video_overlay_rectangle_get_flags ()" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#gst-video-overlay-rectangle-get-flags" since="0.10.37"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstvideofilter.html#idp24731744"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstvideofilter.html#idp5945904"/>
     <keyword type="struct" name="struct GstVideoFilter" link="gst-plugins-base-libs-gstvideofilter.html#GstVideoFilter-struct"/>
     <keyword type="struct" name="struct GstVideoFilterClass" link="gst-plugins-base-libs-gstvideofilter.html#GstVideoFilterClass"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstvideosink.html#idp24318960"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstvideosink.html#idp24251952"/>
     <keyword type="struct" name="struct GstVideoSink" link="gst-plugins-base-libs-gstvideosink.html#GstVideoSink-struct"/>
     <keyword type="struct" name="struct GstVideoSinkClass" link="gst-plugins-base-libs-gstvideosink.html#GstVideoSinkClass"/>
     <keyword type="struct" name="struct GstVideoRectangle" link="gst-plugins-base-libs-gstvideosink.html#GstVideoRectangle"/>
@@ -1150,7 +1151,7 @@
     <keyword type="macro" name="GST_VIDEO_SINK_WIDTH()" link="gst-plugins-base-libs-gstvideosink.html#GST-VIDEO-SINK-WIDTH:CAPS"/>
     <keyword type="function" name="gst_video_sink_center_rect ()" link="gst-plugins-base-libs-gstvideosink.html#gst-video-sink-center-rect"/>
     <keyword type="property" name="The &quot;show-preroll-frame&quot; property" link="gst-plugins-base-libs-gstvideosink.html#GstVideoSink--show-preroll-frame"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstcolorbalance.html#idp29273040"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstcolorbalance.html#idp27811536"/>
     <keyword type="struct" name="GstColorBalance" link="gst-plugins-base-libs-gstcolorbalance.html#GstColorBalance-struct"/>
     <keyword type="struct" name="struct GstColorBalanceInterface" link="gst-plugins-base-libs-gstcolorbalance.html#GstColorBalanceInterface"/>
     <keyword type="enum" name="enum GstColorBalanceType" link="gst-plugins-base-libs-gstcolorbalance.html#GstColorBalanceType"/>
@@ -1160,7 +1161,7 @@
     <keyword type="function" name="gst_color_balance_value_changed ()" link="gst-plugins-base-libs-gstcolorbalance.html#gst-color-balance-value-changed"/>
     <keyword type="function" name="gst_color_balance_get_balance_type ()" link="gst-plugins-base-libs-gstcolorbalance.html#gst-color-balance-get-balance-type" since="0.10.24"/>
     <keyword type="signal" name="The &quot;value-changed&quot; signal" link="gst-plugins-base-libs-gstcolorbalance.html#GstColorBalance-value-changed"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstcolorbalancechannel.html#idp24335184"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstcolorbalancechannel.html#idp21570528"/>
     <keyword type="struct" name="struct GstColorBalanceChannel" link="gst-plugins-base-libs-gstcolorbalancechannel.html#GstColorBalanceChannel-struct"/>
     <keyword type="struct" name="struct GstColorBalanceChannelClass" link="gst-plugins-base-libs-gstcolorbalancechannel.html#GstColorBalanceChannelClass"/>
     <keyword type="signal" name="The &quot;value-changed&quot; signal" link="gst-plugins-base-libs-gstcolorbalancechannel.html#GstColorBalanceChannel-value-changed"/>
@@ -1174,10 +1175,10 @@
     <keyword type="function" name="gst_video_orientation_set_hflip ()" link="gst-plugins-base-libs-gstvideoorientation.html#gst-video-orientation-set-hflip" since="0.10.11"/>
     <keyword type="function" name="gst_video_orientation_set_vcenter ()" link="gst-plugins-base-libs-gstvideoorientation.html#gst-video-orientation-set-vcenter" since="0.10.11"/>
     <keyword type="function" name="gst_video_orientation_set_vflip ()" link="gst-plugins-base-libs-gstvideoorientation.html#gst-video-orientation-set-vflip" since="0.10.11"/>
-    <keyword type="" name="" link="gst-plugins-base-libs-gstvideooverlay.html#idp28156752"/>
-    <keyword type="" name="Two basic usage scenarios" link="gst-plugins-base-libs-gstvideooverlay.html#idp28166848"/>
-    <keyword type="" name="GstVideoOverlay and Gtk+" link="gst-plugins-base-libs-gstvideooverlay.html#idp29541664"/>
-    <keyword type="" name="GstVideoOverlay and Qt" link="gst-plugins-base-libs-gstvideooverlay.html#idp29546832"/>
+    <keyword type="" name="" link="gst-plugins-base-libs-gstvideooverlay.html#idp25488800"/>
+    <keyword type="" name="Two basic usage scenarios" link="gst-plugins-base-libs-gstvideooverlay.html#idp24933824"/>
+    <keyword type="" name="GstVideoOverlay and Gtk+" link="gst-plugins-base-libs-gstvideooverlay.html#idp21545392"/>
+    <keyword type="" name="GstVideoOverlay and Qt" link="gst-plugins-base-libs-gstvideooverlay.html#idp27827456"/>
     <keyword type="struct" name="GstVideoOverlay" link="gst-plugins-base-libs-gstvideooverlay.html#GstVideoOverlay-struct"/>
     <keyword type="struct" name="struct GstVideoOverlayInterface" link="gst-plugins-base-libs-gstvideooverlay.html#GstVideoOverlayInterface"/>
     <keyword type="function" name="gst_video_overlay_got_window_handle ()" link="gst-plugins-base-libs-gstvideooverlay.html#gst-video-overlay-got-window-handle"/>
@@ -1261,7 +1262,8 @@
     <keyword type="macro" name="GST_VIDEO_CODEC_FRAME_UNSET_SYNC_POINT()" link="gst-plugins-base-libs-gstvideoutils.html#GST-VIDEO-CODEC-FRAME-UNSET-SYNC-POINT:CAPS"/>
     <keyword type="function" name="gst_video_codec_frame_ref ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-ref"/>
     <keyword type="function" name="gst_video_codec_frame_unref ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-unref"/>
-    <keyword type="function" name="gst_video_codec_frame_set_hook ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-hook"/>
+    <keyword type="function" name="gst_video_codec_frame_set_user_data ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-user-data"/>
+    <keyword type="function" name="gst_video_codec_frame_get_user_data ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-get-user-data"/>
     <keyword type="struct" name="struct GstVideoCodecState" link="gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState"/>
     <keyword type="function" name="gst_video_codec_state_ref ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-state-ref"/>
     <keyword type="function" name="gst_video_codec_state_unref ()" link="gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-state-unref"/>
@@ -1568,6 +1570,15 @@
     <keyword type="constant" name="GST_DISCOVERER_TIMEOUT" link="gst-plugins-base-libs-gstdiscoverer.html#GST-DISCOVERER-TIMEOUT:CAPS"/>
     <keyword type="constant" name="GST_DISCOVERER_BUSY" link="gst-plugins-base-libs-gstdiscoverer.html#GST-DISCOVERER-BUSY:CAPS"/>
     <keyword type="constant" name="GST_DISCOVERER_MISSING_PLUGINS" link="gst-plugins-base-libs-gstdiscoverer.html#GST-DISCOVERER-MISSING-PLUGINS:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_UNKNOWN" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-UNKNOWN:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_NONE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-NONE:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_H_COSITED" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-H-COSITED:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_V_COSITED" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-V-COSITED:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_ALT_LINE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-ALT-LINE:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_COSITED" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-COSITED:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_JPEG" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-JPEG:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_MPEG2" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-MPEG2:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_CHROMA_SITE_DV" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-DV:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_MATRIX_UNKNOWN" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-MATRIX-UNKNOWN:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_MATRIX_RGB" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-MATRIX-RGB:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_MATRIX_FCC" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-MATRIX-FCC:CAPS"/>
@@ -1580,11 +1591,13 @@
     <keyword type="constant" name="GST_VIDEO_COLOR_PRIMARIES_BT470BG" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-BT470BG:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_PRIMARIES_SMPTE170M" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-SMPTE170M:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_PRIMARIES_SMPTE240M" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-SMPTE240M:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_COLOR_PRIMARIES_FILM" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-FILM:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_RANGE_UNKNOWN" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-RANGE-UNKNOWN:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_RANGE_0_255" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-RANGE-0-255:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_COLOR_RANGE_16_235" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-RANGE-16-235:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FLAG_NONE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FLAG-NONE:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FLAG_VARIABLE_FPS" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FLAG-VARIABLE-FPS:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FLAG-PREMULTIPLIED-ALPHA:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_FLAG_YUV" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-FLAG-YUV:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_FLAG_RGB" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-FLAG-RGB:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_FLAG_GRAY" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-FLAG-GRAY:CAPS"/>
@@ -1608,6 +1621,7 @@
     <keyword type="constant" name="GST_VIDEO_TRANSFER_LOG100" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-TRANSFER-LOG100:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_TRANSFER_LOG316" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-TRANSFER-LOG316:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_UNKNOWN" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-UNKNOWN:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_FORMAT_ENCODED" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-ENCODED:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_I420" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-I420:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_YV12" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YV12:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_YUY2" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YUY2:CAPS"/>
@@ -1635,22 +1649,21 @@
     <keyword type="constant" name="GST_VIDEO_FORMAT_GRAY16_BE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-GRAY16-BE:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_GRAY16_LE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-GRAY16-LE:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_v308" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-v308"/>
-    <keyword type="constant" name="GST_VIDEO_FORMAT_Y800" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-Y800:CAPS"/>
-    <keyword type="constant" name="GST_VIDEO_FORMAT_Y16" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-Y16:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_RGB16" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB16:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_BGR16" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-BGR16:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_RGB15" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB15:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_BGR15" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-BGR15:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_UYVP" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-UYVP:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_A420" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-A420:CAPS"/>
-    <keyword type="constant" name="GST_VIDEO_FORMAT_RGB8_PALETTED" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB8-PALETTED:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_FORMAT_RGB8P" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB8P:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_YUV9" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YUV9:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_YVU9" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YVU9:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_IYU1" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-IYU1:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_ARGB64" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-ARGB64:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_AYUV64" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-AYUV64:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_FORMAT_r210" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-r210"/>
-    <keyword type="constant" name="GST_VIDEO_FORMAT_ENCODED" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-ENCODED:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_FORMAT_I420_10BE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-I420-10BE:CAPS"/>
+    <keyword type="constant" name="GST_VIDEO_FORMAT_I420_10LE" link="gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-I420-10LE:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_OVERLAY_FORMAT_FLAG_NONE" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#GST-VIDEO-OVERLAY-FORMAT-FLAG-NONE:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_OVERLAY_FORMAT_FLAG_PREMULTIPLIED_ALPHA" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#GST-VIDEO-OVERLAY-FORMAT-FLAG-PREMULTIPLIED-ALPHA:CAPS"/>
     <keyword type="constant" name="GST_VIDEO_OVERLAY_FORMAT_FLAG_GLOBAL_ALPHA" link="gst-plugins-base-libs-gstvideooverlaycomposition.html#GST-VIDEO-OVERLAY-FORMAT-FLAG-GLOBAL-ALPHA:CAPS"/>
diff --git a/docs/libs/html/index.html b/docs/libs/html/index.html
index 2d5b8ee..7c060cb 100644
--- a/docs/libs/html/index.html
+++ b/docs/libs/html/index.html
@@ -15,7 +15,7 @@
 <div>
 <div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">GStreamer Base Plugins 1.0 Library Reference Manual</p></th></tr></table></div>
 <div><p class="releaseinfo">
-      for GStreamer Base Library 1.0 (0.11.91)
+      for GStreamer Base Library 1.0 (0.11.92)
       <a class="ulink" href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/" target="_top">http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/</a>.
     </p></div>
 </div>
diff --git a/docs/libs/html/index.sgml b/docs/libs/html/index.sgml
index 18168fc..c6081db 100644
--- a/docs/libs/html/index.sgml
+++ b/docs/libs/html/index.sgml
@@ -1390,6 +1390,7 @@
 <ANCHOR id="gst-discoverer-info-get-stream-info" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-stream-info">
 <ANCHOR id="gst-discoverer-info-get-stream-list" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-stream-list">
 <ANCHOR id="gst-discoverer-info-get-tags" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-tags">
+<ANCHOR id="gst-discoverer-info-get-toc" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-toc">
 <ANCHOR id="gst-discoverer-info-get-uri" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-uri">
 <ANCHOR id="gst-discoverer-info-get-seekable" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-get-seekable">
 <ANCHOR id="gst-discoverer-info-ref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-info-ref">
@@ -1404,6 +1405,7 @@
 <ANCHOR id="gst-discoverer-stream-info-get-next" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-next">
 <ANCHOR id="gst-discoverer-stream-info-get-previous" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-previous">
 <ANCHOR id="gst-discoverer-stream-info-get-tags" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-tags">
+<ANCHOR id="gst-discoverer-stream-info-get-toc" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-get-toc">
 <ANCHOR id="gst-discoverer-stream-info-ref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-ref">
 <ANCHOR id="gst-discoverer-stream-info-unref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-unref">
 <ANCHOR id="gst-discoverer-stream-info-list-free" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstdiscoverer.html#gst-discoverer-stream-info-list-free">
@@ -1508,6 +1510,15 @@
 <ANCHOR id="GST-VIDEO-FPS-RANGE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FPS-RANGE:CAPS">
 <ANCHOR id="GST-VIDEO-SIZE-RANGE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-SIZE-RANGE:CAPS">
 <ANCHOR id="GstVideoChromaSite" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoChromaSite">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-UNKNOWN:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-UNKNOWN:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-NONE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-NONE:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-H-COSITED:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-H-COSITED:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-V-COSITED:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-V-COSITED:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-ALT-LINE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-ALT-LINE:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-COSITED:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-COSITED:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-JPEG:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-JPEG:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-MPEG2:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-MPEG2:CAPS">
+<ANCHOR id="GST-VIDEO-CHROMA-SITE-DV:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-CHROMA-SITE-DV:CAPS">
 <ANCHOR id="GstVideoColorMatrix" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoColorMatrix">
 <ANCHOR id="GST-VIDEO-COLOR-MATRIX-UNKNOWN:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-MATRIX-UNKNOWN:CAPS">
 <ANCHOR id="GST-VIDEO-COLOR-MATRIX-RGB:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-MATRIX-RGB:CAPS">
@@ -1522,6 +1533,7 @@
 <ANCHOR id="GST-VIDEO-COLOR-PRIMARIES-BT470BG:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-BT470BG:CAPS">
 <ANCHOR id="GST-VIDEO-COLOR-PRIMARIES-SMPTE170M:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-SMPTE170M:CAPS">
 <ANCHOR id="GST-VIDEO-COLOR-PRIMARIES-SMPTE240M:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-SMPTE240M:CAPS">
+<ANCHOR id="GST-VIDEO-COLOR-PRIMARIES-FILM:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-PRIMARIES-FILM:CAPS">
 <ANCHOR id="GstVideoColorRange" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoColorRange">
 <ANCHOR id="GST-VIDEO-COLOR-RANGE-UNKNOWN:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-RANGE-UNKNOWN:CAPS">
 <ANCHOR id="GST-VIDEO-COLOR-RANGE-0-255:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-COLOR-RANGE-0-255:CAPS">
@@ -1530,6 +1542,7 @@
 <ANCHOR id="GstVideoFlags" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoFlags">
 <ANCHOR id="GST-VIDEO-FLAG-NONE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FLAG-NONE:CAPS">
 <ANCHOR id="GST-VIDEO-FLAG-VARIABLE-FPS:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FLAG-VARIABLE-FPS:CAPS">
+<ANCHOR id="GST-VIDEO-FLAG-PREMULTIPLIED-ALPHA:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FLAG-PREMULTIPLIED-ALPHA:CAPS">
 <ANCHOR id="GstVideoFormatFlags" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoFormatFlags">
 <ANCHOR id="GST-VIDEO-FORMAT-FLAG-YUV:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-FLAG-YUV:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-FLAG-RGB:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-FLAG-RGB:CAPS">
@@ -1559,6 +1572,7 @@
 <ANCHOR id="GST-VIDEO-TRANSFER-LOG316:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-TRANSFER-LOG316:CAPS">
 <ANCHOR id="GstVideoFormat" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoFormat">
 <ANCHOR id="GST-VIDEO-FORMAT-UNKNOWN:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-UNKNOWN:CAPS">
+<ANCHOR id="GST-VIDEO-FORMAT-ENCODED:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-ENCODED:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-I420:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-I420:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-YV12:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YV12:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-YUY2:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YUY2:CAPS">
@@ -1586,22 +1600,21 @@
 <ANCHOR id="GST-VIDEO-FORMAT-GRAY16-BE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-GRAY16-BE:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-GRAY16-LE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-GRAY16-LE:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-v308" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-v308">
-<ANCHOR id="GST-VIDEO-FORMAT-Y800:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-Y800:CAPS">
-<ANCHOR id="GST-VIDEO-FORMAT-Y16:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-Y16:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-RGB16:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB16:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-BGR16:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-BGR16:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-RGB15:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB15:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-BGR15:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-BGR15:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-UYVP:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-UYVP:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-A420:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-A420:CAPS">
-<ANCHOR id="GST-VIDEO-FORMAT-RGB8-PALETTED:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB8-PALETTED:CAPS">
+<ANCHOR id="GST-VIDEO-FORMAT-RGB8P:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-RGB8P:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-YUV9:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YUV9:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-YVU9:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-YVU9:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-IYU1:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-IYU1:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-ARGB64:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-ARGB64:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-AYUV64:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-AYUV64:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-r210" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-r210">
-<ANCHOR id="GST-VIDEO-FORMAT-ENCODED:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-ENCODED:CAPS">
+<ANCHOR id="GST-VIDEO-FORMAT-I420-10BE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-I420-10BE:CAPS">
+<ANCHOR id="GST-VIDEO-FORMAT-I420-10LE:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-I420-10LE:CAPS">
 <ANCHOR id="GstVideoFormatInfo" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoFormatInfo">
 <ANCHOR id="GST-VIDEO-FORMAT-INFO-BITS:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-INFO-BITS:CAPS">
 <ANCHOR id="GST-VIDEO-FORMAT-INFO-DATA:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GST-VIDEO-FORMAT-INFO-DATA:CAPS">
@@ -1672,7 +1685,6 @@
 <ANCHOR id="gst-video-calculate-display-ratio" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#gst-video-calculate-display-ratio">
 <ANCHOR id="gst-video-format-to-fourcc" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#gst-video-format-to-fourcc">
 <ANCHOR id="gst-video-format-from-fourcc" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#gst-video-format-from-fourcc">
-<ANCHOR id="gst-video-parse-caps-palette" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#gst-video-parse-caps-palette">
 <ANCHOR id="GstVideoConvertSampleCallback" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#GstVideoConvertSampleCallback">
 <ANCHOR id="gst-video-convert-sample" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#gst-video-convert-sample">
 <ANCHOR id="gst-video-convert-sample-async" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideo.html#gst-video-convert-sample-async">
@@ -1892,7 +1904,8 @@
 <ANCHOR id="GST-VIDEO-CODEC-FRAME-UNSET-SYNC-POINT:CAPS" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#GST-VIDEO-CODEC-FRAME-UNSET-SYNC-POINT:CAPS">
 <ANCHOR id="gst-video-codec-frame-ref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-ref">
 <ANCHOR id="gst-video-codec-frame-unref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-unref">
-<ANCHOR id="gst-video-codec-frame-set-hook" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-hook">
+<ANCHOR id="gst-video-codec-frame-set-user-data" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-set-user-data">
+<ANCHOR id="gst-video-codec-frame-get-user-data" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-frame-get-user-data">
 <ANCHOR id="GstVideoCodecState" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#GstVideoCodecState">
 <ANCHOR id="gst-video-codec-state-ref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-state-ref">
 <ANCHOR id="gst-video-codec-state-unref" href="gst-plugins-base-libs-1.0/gst-plugins-base-libs-gstvideoutils.html#gst-video-codec-state-unref">
diff --git a/docs/plugins/Makefile.in b/docs/plugins/Makefile.in
index 5186e7a..2322e6f 100644
--- a/docs/plugins/Makefile.in
+++ b/docs/plugins/Makefile.in
@@ -67,6 +67,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/gtk-doc-plugins.mak \
 	$(top_srcdir)/common/upload-doc.mak
@@ -230,8 +231,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -402,7 +409,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/docs/plugins/gst-plugins-base-plugins.args b/docs/plugins/gst-plugins-base-plugins.args
index f461674..c37ac5b 100644
--- a/docs/plugins/gst-plugins-base-plugins.args
+++ b/docs/plugins/gst-plugins-base-plugins.args
@@ -1059,6 +1059,16 @@
 </ARG>
 
 <ARG>
+<NAME>GstDecodeBin::connection-speed</NAME>
+<TYPE>guint64</TYPE>
+<RANGE><= 18446744073709551</RANGE>
+<FLAGS>rw</FLAGS>
+<NICK>Connection Speed</NICK>
+<BLURB>Network connection speed in kbps (0 = unknown).</BLURB>
+<DEFAULT>0</DEFAULT>
+</ARG>
+
+<ARG>
 <NAME>GstPlayBin::audio-sink</NAME>
 <TYPE>GstElement*</TYPE>
 <RANGE></RANGE>
@@ -1294,7 +1304,7 @@
 <RANGE></RANGE>
 <FLAGS>rw</FLAGS>
 <NICK>Text plugin</NICK>
-<BLURB>the text output element to use (NULL = default textoverlay).</BLURB>
+<BLURB>the text output element to use (NULL = default subtitleoverlay).</BLURB>
 <DEFAULT></DEFAULT>
 </ARG>
 
@@ -1309,6 +1319,26 @@
 </ARG>
 
 <ARG>
+<NAME>GstPlayBin::current-suburi</NAME>
+<TYPE>gchar*</TYPE>
+<RANGE></RANGE>
+<FLAGS>r</FLAGS>
+<NICK>Current .sub-URI</NICK>
+<BLURB>The currently playing URI of a subtitle.</BLURB>
+<DEFAULT>NULL</DEFAULT>
+</ARG>
+
+<ARG>
+<NAME>GstPlayBin::current-uri</NAME>
+<TYPE>gchar*</TYPE>
+<RANGE></RANGE>
+<FLAGS>r</FLAGS>
+<NICK>Current URI</NICK>
+<BLURB>The currently playing URI.</BLURB>
+<DEFAULT>NULL</DEFAULT>
+</ARG>
+
+<ARG>
 <NAME>GstAudiorate::add</NAME>
 <TYPE>guint64</TYPE>
 <RANGE></RANGE>
@@ -1551,10 +1581,10 @@
 <ARG>
 <NAME>GstTheoraEnc::speed-level</NAME>
 <TYPE>gint</TYPE>
-<RANGE>[0,2]</RANGE>
-<FLAGS>rwx</FLAGS>
+<RANGE>[0,3]</RANGE>
+<FLAGS>rw</FLAGS>
 <NICK>Speed level</NICK>
-<BLURB>Controls the amount of analysis performed when encoding. Higher values trade compression quality for speed. This property requires libtheora version >= 1.0, and the maximum value may vary based on encoder version.</BLURB>
+<BLURB>Controls the amount of motion vector searching done while encoding.  This property requires libtheora version >= 1.0.</BLURB>
 <DEFAULT>1</DEFAULT>
 </ARG>
 
@@ -1563,8 +1593,8 @@
 <TYPE>gboolean</TYPE>
 <RANGE></RANGE>
 <FLAGS>rw</FLAGS>
-<NICK>Cap Overflow</NICK>
-<BLURB>Enable capping of bit reservoir overflows.</BLURB>
+<NICK>VP3 Compatible</NICK>
+<BLURB>Enable capping of bit reservoir overflows.  This property requires libtheora version >= 1.1.</BLURB>
 <DEFAULT>TRUE</DEFAULT>
 </ARG>
 
@@ -1573,8 +1603,8 @@
 <TYPE>gboolean</TYPE>
 <RANGE></RANGE>
 <FLAGS>rw</FLAGS>
-<NICK>Cap Underflow</NICK>
-<BLURB>Enable capping of bit reservoir underflows.</BLURB>
+<NICK>VP3 Compatible</NICK>
+<BLURB>Enable capping of bit reservoir underflows.  This property requires libtheora version >= 1.1.</BLURB>
 <DEFAULT>FALSE</DEFAULT>
 </ARG>
 
@@ -1583,8 +1613,8 @@
 <TYPE>gboolean</TYPE>
 <RANGE></RANGE>
 <FLAGS>rw</FLAGS>
-<NICK>Drop Frames</NICK>
-<BLURB>Allow or disallow frame dropping.</BLURB>
+<NICK>VP3 Compatible</NICK>
+<BLURB>Allow or disallow frame dropping.  This property requires libtheora version >= 1.1.</BLURB>
 <DEFAULT>TRUE</DEFAULT>
 </ARG>
 
@@ -1594,7 +1624,7 @@
 <RANGE>[0,1000]</RANGE>
 <FLAGS>rw</FLAGS>
 <NICK>Rate Control Buffer</NICK>
-<BLURB>Sets the size of the rate control buffer, in units of frames.  The default value of 0 instructs the encoder to automatically select an appropriate value.</BLURB>
+<BLURB>Sets the size of the rate control buffer, in units of frames.  The default value of 0 instructs the encoder to automatically select an appropriate value.  This property requires libtheora version >= 1.1.</BLURB>
 <DEFAULT>0</DEFAULT>
 </ARG>
 
@@ -1604,7 +1634,7 @@
 <RANGE></RANGE>
 <FLAGS>rw</FLAGS>
 <NICK>VP3 Compatible</NICK>
-<BLURB>Disables non-VP3 compatible features.</BLURB>
+<BLURB>Disables non-VP3 compatible features.  This property requires libtheora version >= 1.1.</BLURB>
 <DEFAULT>FALSE</DEFAULT>
 </ARG>
 
@@ -2584,7 +2614,7 @@
 <RANGE>>= G_MAXULONG</RANGE>
 <FLAGS>rw</FLAGS>
 <NICK>Read speed</NICK>
-<BLURB>Read from device at specified speed.</BLURB>
+<BLURB>Read from device at specified speed (-1 and 0 = full speed).</BLURB>
 <DEFAULT>-1</DEFAULT>
 </ARG>
 
@@ -3804,7 +3834,7 @@
 <RANGE></RANGE>
 <FLAGS>rw</FLAGS>
 <NICK>Text sink</NICK>
-<BLURB>the text output element to use (NULL = default textoverlay).</BLURB>
+<BLURB>the text output element to use (NULL = default subtitleoverlay).</BLURB>
 <DEFAULT></DEFAULT>
 </ARG>
 
diff --git a/docs/plugins/gst-plugins-base-plugins.hierarchy b/docs/plugins/gst-plugins-base-plugins.hierarchy
index d6e5300..4892627 100644
--- a/docs/plugins/gst-plugins-base-plugins.hierarchy
+++ b/docs/plugins/gst-plugins-base-plugins.hierarchy
@@ -12,7 +12,6 @@
       GstControlSource
       GstElement
         GstAdder
-        GstAlsaMixerElement
         GstAudioDecoder
           GstVorbisDec
         GstAudioEncoder
@@ -83,9 +82,11 @@
         GstSsaParse
         GstSubParse
         GstTextRender
-        GstTheoraDec
-        GstTheoraEnc
         GstTheoraParse
+        GstVideoDecoder
+          GstTheoraDec
+        GstVideoEncoder
+          GstTheoraEnc
         GstVisual
           GstVisualbumpscope
           GstVisualcorona
@@ -111,7 +112,6 @@
   GSocket
   GstColorBalanceChannel
   GstEncodingProfile
-  GstMixerTrack
   PangoContext
   PangoFontMap
     PangoFcFontMap
@@ -122,7 +122,6 @@
   GTypePlugin
   GstChildProxy
   GstColorBalance
-  GstMixer
   GstNavigation
   GstPreset
   GstStreamVolume
diff --git a/docs/plugins/gst-plugins-base-plugins.interfaces b/docs/plugins/gst-plugins-base-plugins.interfaces
index 2b9b942..48f258b 100644
--- a/docs/plugins/gst-plugins-base-plugins.interfaces
+++ b/docs/plugins/gst-plugins-base-plugins.interfaces
@@ -33,8 +33,10 @@
 GstURIDecodeBin GstChildProxy
 GstV4lElement GstImplementsInterface GstTuner GstXOverlay GstColorBalance GstPropertyProbe
 GstV4lSrc GstImplementsInterface GstTuner GstXOverlay GstColorBalance GstPropertyProbe
+GstVideoEncoder GstPreset
 GstVolume GstImplementsInterface GstMixer GstStreamVolume
 GstVolume GstMixer GstStreamVolume
+GstVolume GstStreamVolume
 GstVorbisEnc GstPreset GstTagSetter
 GstVorbisEnc GstTagSetter GstPreset
 GstVorbisTag GstTagSetter
diff --git a/docs/plugins/html/ch01.html b/docs/plugins/html/ch01.html
index 6e7acf4..126a171 100644
--- a/docs/plugins/html/ch01.html
+++ b/docs/plugins/html/ch01.html
@@ -21,7 +21,7 @@
 </tr></table>
 <div class="chapter">
 <div class="titlepage"><div><div><h2 class="title">
-<a name="idp4168720"></a>gst-plugins-base Elements</h2></div></div></div>
+<a name="idp282608"></a>gst-plugins-base Elements</h2></div></div></div>
 <div class="toc"><dl>
 <dt>
 <span class="refentrytitle"><a href="gst-plugins-base-plugins-adder.html">adder</a></span><span class="refpurpose"> — Add N audio channels together</span>
@@ -33,7 +33,7 @@
 <span class="refentrytitle"><a href="gst-plugins-base-plugins-appsink.html">appsink</a></span><span class="refpurpose"> — Allow the application to get access to raw buffer</span>
 </dt>
 <dt>
-<span class="refentrytitle"><a href="gst-plugins-base-plugins-alsamixer.html">alsamixer</a></span><span class="refpurpose"> — Control sound input and output levels with ALSA</span>
+<span class="refentrytitle"><a href="gst-plugins-base-plugins-alsamixer.html">alsamixer</a></span><span class="refpurpose"></span>
 </dt>
 <dt>
 <span class="refentrytitle"><a href="gst-plugins-base-plugins-alsasink.html">alsasink</a></span><span class="refpurpose"> — Output to a sound card via ALSA</span>
diff --git a/docs/plugins/html/ch02.html b/docs/plugins/html/ch02.html
index 2441775..58f399a 100644
--- a/docs/plugins/html/ch02.html
+++ b/docs/plugins/html/ch02.html
@@ -21,7 +21,7 @@
 </tr></table>
 <div class="chapter">
 <div class="titlepage"><div><div><h2 class="title">
-<a name="idp37152"></a>gst-plugins-base Plugins</h2></div></div></div>
+<a name="idp36384"></a>gst-plugins-base Plugins</h2></div></div></div>
 <div class="toc"><dl>
 <dt>
 <span class="refentrytitle"><a href="gst-plugins-base-plugins-plugin-adder.html">adder</a></span><span class="refpurpose"> — <a name="plugin-adder"></a>Adds multiple streams</span>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-adder.html b/docs/plugins/html/gst-plugins-base-plugins-adder.html
index 4b5589c..dee39c9 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-adder.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-adder.html
@@ -73,7 +73,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp8203424"></a><h3>Example launch line</h3>
+<a name="idp8081200"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -94,7 +94,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp8338832"></a><h3>Element Information</h3>
+<a name="idp7940384"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -117,7 +117,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idm39456"></a><h3>Element Pads</h3>
+<a name="idm32688"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-alsamixer.html b/docs/plugins/html/gst-plugins-base-plugins-alsamixer.html
index b983e0b..fcde49e 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-alsamixer.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-alsamixer.html
@@ -31,7 +31,7 @@
 <div class="refnamediv"><table width="100%"><tr>
 <td valign="top">
 <h2><span class="refentrytitle"><a name="gst-plugins-base-plugins-alsamixer.top_of_page"></a>alsamixer</span></h2>
-<p>alsamixer — Control sound input and output levels with ALSA</p>
+<p>alsamixer</p>
 </td>
 <td valign="top" align="right"></td>
 </tr></table></div>
@@ -41,35 +41,6 @@
 </div>
 <div class="refsect1">
 <a name="gst-plugins-base-plugins-alsamixer.description"></a><h2>Description</h2>
-<div class="refsynopsisdiv">
-<h2>Synopsis</h2>
-<div class="refsect2">
-<a name="idp9325760"></a><h3>Element Information</h3>
-<div class="variablelist"><table border="0">
-<col align="left" valign="top">
-<tbody>
-<tr>
-<td><p><span class="term">plugin</span></p></td>
-<td>
-            <a class="link" href="gst-plugins-base-plugins-plugin-alsa.html#plugin-alsa">alsa</a>
-          </td>
-</tr>
-<tr>
-<td><p><span class="term">author</span></p></td>
-<td>Leif Johnson &lt;leif@ambient.2y.net&gt;</td>
-</tr>
-<tr>
-<td><p><span class="term">class</span></p></td>
-<td>Generic/Audio</td>
-</tr>
-</tbody>
-</table></div>
-</div>
-<hr>
-<div class="refsect2">
-<a name="idp6984048"></a><h3>Element Pads</h3>
-</div>
-</div>
 <p>
 </p>
 </div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-alsasink.html b/docs/plugins/html/gst-plugins-base-plugins-alsasink.html
index ccf3f50..0e378e0 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-alsasink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-alsasink.html
@@ -78,7 +78,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7652208"></a><h3>Element Information</h3>
+<a name="idp5481552"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -101,7 +101,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp7659664"></a><h3>Element Pads</h3>
+<a name="idp5489008"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -123,7 +123,19 @@
 </tr>
 <tr>
 <td><p><span class="term"></span></p></td>
-<td> audio/x-iec958</td>
+<td> audio/x-ac3, framed=(boolean)true</td>
+</tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> audio/x-eac3, framed=(boolean)true</td>
+</tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> audio/x-dts, framed=(boolean)true, block-size=(int){ 512, 1024, 2048 }</td>
+</tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> audio/mpeg, mpegversion=(int)1, mpegaudioversion=(int)[ 1, 2 ], parsed=(boolean)true</td>
 </tr>
 </tbody>
 </table></div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-alsasrc.html b/docs/plugins/html/gst-plugins-base-plugins-alsasrc.html
index 3f42d33..96cc66b 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-alsasrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-alsasrc.html
@@ -79,7 +79,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp8412864"></a><h3>Element Information</h3>
+<a name="idp7512080"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -102,7 +102,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp8420320"></a><h3>Element Pads</h3>
+<a name="idp7519536"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-appsink.html b/docs/plugins/html/gst-plugins-base-plugins-appsink.html
index b5fa6be..a657403 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-appsink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-appsink.html
@@ -104,7 +104,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9939184"></a><h3>Element Information</h3>
+<a name="idp9772480"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -127,7 +127,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9946672"></a><h3>Element Pads</h3>
+<a name="idp9779888"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-appsrc.html b/docs/plugins/html/gst-plugins-base-plugins-appsrc.html
index 856f41d..87cd180 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-appsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-appsrc.html
@@ -106,7 +106,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7386384"></a><h3>Element Information</h3>
+<a name="idp9327856"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -129,7 +129,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp7393872"></a><h3>Element Pads</h3>
+<a name="idp9335264"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-audioconvert.html b/docs/plugins/html/gst-plugins-base-plugins-audioconvert.html
index a5078ab..f7d70c3 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-audioconvert.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-audioconvert.html
@@ -74,7 +74,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp6321904"></a><h3>Example launch line</h3>
+<a name="idp6934944"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -108,7 +108,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9276176"></a><h3>Element Information</h3>
+<a name="idp8129456"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -131,7 +131,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9029200"></a><h3>Element Pads</h3>
+<a name="idp8657616"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-audiorate.html b/docs/plugins/html/gst-plugins-base-plugins-audiorate.html
index 43eaff7..5444a56 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-audiorate.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-audiorate.html
@@ -103,7 +103,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp8565120"></a><h3>Example pipelines</h3>
+<a name="idp6467600"></a><h3>Example pipelines</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -122,7 +122,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp10427616"></a><h3>Element Information</h3>
+<a name="idp10027808"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -145,7 +145,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp10435072"></a><h3>Element Pads</h3>
+<a name="idp10035264"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-audioresample.html b/docs/plugins/html/gst-plugins-base-plugins-audioresample.html
index a6942e4..b27d417 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-audioresample.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-audioresample.html
@@ -71,7 +71,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9365952"></a><h3>Example launch line</h3>
+<a name="idp9219552"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -90,7 +90,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7848656"></a><h3>Element Information</h3>
+<a name="idp9274944"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -113,7 +113,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp8632432"></a><h3>Element Pads</h3>
+<a name="idp10371280"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-audiotestsrc.html b/docs/plugins/html/gst-plugins-base-plugins-audiotestsrc.html
index 2706b52..b9e4045 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-audiotestsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-audiotestsrc.html
@@ -78,7 +78,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp10244384"></a><h3>Example launch line</h3>
+<a name="idp10148304"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -110,7 +110,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp10248256"></a><h3>Element Information</h3>
+<a name="idp10152176"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -133,7 +133,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp10540240"></a><h3>Element Pads</h3>
+<a name="idp10391520"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-cdparanoiasrc.html b/docs/plugins/html/gst-plugins-base-plugins-cdparanoiasrc.html
index 792911c..b3934b2 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-cdparanoiasrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-cdparanoiasrc.html
@@ -89,7 +89,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp5269504"></a><h3>Element Information</h3>
+<a name="idp8481728"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -112,7 +112,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp10759264"></a><h3>Element Pads</h3>
+<a name="idp5342592"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -167,7 +167,7 @@
 <div class="refsect2">
 <a name="GstCdParanoiaSrc--read-speed"></a><h3>The <code class="literal">"read-speed"</code> property</h3>
 <pre class="programlisting">  "read-speed"               <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write</pre>
-<p>Read from device at specified speed.</p>
+<p>Read from device at specified speed (-1 and 0 = full speed).</p>
 <p>Allowed values: &gt;= G_MAXULONG</p>
 <p>Default value: -1</p>
 </div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-clockoverlay.html b/docs/plugins/html/gst-plugins-base-plugins-clockoverlay.html
index bb16b82..95e7358 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-clockoverlay.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-clockoverlay.html
@@ -66,7 +66,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp6165216"></a><h3>Element Information</h3>
+<a name="idp8730160"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -89,7 +89,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp7673408"></a><h3>Element Pads</h3>
+<a name="idp10104016"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-decodebin.html b/docs/plugins/html/gst-plugins-base-plugins-decodebin.html
index c91581b..5c650ae 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-decodebin.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-decodebin.html
@@ -80,6 +80,7 @@
   "<a class="link" href="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--post-stream-topology" title='The "post-stream-topology" property'>post-stream-topology</a>"     <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--subtitle-encoding" title='The "subtitle-encoding" property'>subtitle-encoding</a>"        <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--use-buffering" title='The "use-buffering" property'>use-buffering</a>"            <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
+  "<a class="link" href="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--connection-speed" title='The "connection-speed" property'>connection-speed</a>"         <span class="type">guint64</span>               : Read / Write
 </pre>
 </div>
 <div class="refsect1">
@@ -109,7 +110,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp10897904"></a><h3>Element Information</h3>
+<a name="idp10842048"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -132,7 +133,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp10905424"></a><h3>Element Pads</h3>
+<a name="idp10849568"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -290,6 +291,14 @@
 <p>Emit GST_MESSAGE_BUFFERING based on low-/high-percent thresholds.</p>
 <p>Default value: FALSE</p>
 </div>
+<hr>
+<div class="refsect2">
+<a name="GstDecodeBin--connection-speed"></a><h3>The <code class="literal">"connection-speed"</code> property</h3>
+<pre class="programlisting">  "connection-speed"         <span class="type">guint64</span>               : Read / Write</pre>
+<p>Network connection speed in kbps (0 = unknown).</p>
+<p>Allowed values: &lt;= 18446744073709551</p>
+<p>Default value: 0</p>
+</div>
 </div>
 <div class="refsect1">
 <a name="gst-plugins-base-plugins-decodebin.signal-details"></a><h2>Signal Details</h2>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-encodebin.html b/docs/plugins/html/gst-plugins-base-plugins-encodebin.html
index 5446734..5aa1cdc 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-encodebin.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-encodebin.html
@@ -99,7 +99,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9863536"></a><h3>Features</h3>
+<a name="idp5808960"></a><h3>Features</h3>
 <div class="itemizedlist"><ul class="itemizedlist" type="disc">
 <li class="listitem">
 Automatic encoder and muxer selection based on elements available on the
@@ -164,7 +164,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp11290832"></a><h3>Element Information</h3>
+<a name="idp6176848"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -187,7 +187,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp11298240"></a><h3>Element Pads</h3>
+<a name="idp10782016"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-gdpdepay.html b/docs/plugins/html/gst-plugins-base-plugins-gdpdepay.html
index f919996..cdb662d 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-gdpdepay.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-gdpdepay.html
@@ -61,7 +61,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp8368432"></a><div class="informalexample">
+<a name="idp9026848"></a><div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
       <tr>
@@ -79,7 +79,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp6714976"></a><h3>Element Information</h3>
+<a name="idp8482384"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -102,7 +102,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9237360"></a><h3>Element Pads</h3>
+<a name="idp6854240"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-gdppay.html b/docs/plugins/html/gst-plugins-base-plugins-gdppay.html
index 897fc0e..740a816 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-gdppay.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-gdppay.html
@@ -71,7 +71,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9422512"></a><div class="informalexample">
+<a name="idp6942016"></a><div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
       <tr>
@@ -89,7 +89,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp8275808"></a><h3>Element Information</h3>
+<a name="idp7895936"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -112,7 +112,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp11205344"></a><h3>Element Pads</h3>
+<a name="idp10604048"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-giosink.html b/docs/plugins/html/gst-plugins-base-plugins-giosink.html
index d692bc5..50cf97f 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-giosink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-giosink.html
@@ -101,7 +101,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp7541712"></a><h3>Example pipelines</h3>
+<a name="idp11085984"></a><h3>Example pipelines</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -144,7 +144,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7546560"></a><h3>Element Information</h3>
+<a name="idp6894272"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -167,7 +167,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp11607184"></a><h3>Element Pads</h3>
+<a name="idp10504192"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-giosrc.html b/docs/plugins/html/gst-plugins-base-plugins-giosrc.html
index e6f8789..59fa193 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-giosrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-giosrc.html
@@ -95,7 +95,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp8044096"></a><h3>Example launch lines</h3>
+<a name="idp10711488"></a><h3>Example launch lines</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -139,7 +139,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7562480"></a><h3>Element Information</h3>
+<a name="idp10716336"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -162,7 +162,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp7570000"></a><h3>Element Pads</h3>
+<a name="idp8550112"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-giostreamsink.html b/docs/plugins/html/gst-plugins-base-plugins-giostreamsink.html
index 6f35b68..50025d4 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-giostreamsink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-giostreamsink.html
@@ -74,7 +74,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp11377200"></a><h3>Example code</h3>
+<a name="idp10629072"></a><h3>Example code</h3>
 <p>
 The following example writes the received data to a <a href="http://library.gnome.org/devel/gio/unstable/GMemoryOutputStream.html"><span class="type">GMemoryOutputStream</span></a>.
 </p>
@@ -141,7 +141,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp11381552"></a><h3>Element Information</h3>
+<a name="idp11059232"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -164,7 +164,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp11581488"></a><h3>Element Pads</h3>
+<a name="idp10760192"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-giostreamsrc.html b/docs/plugins/html/gst-plugins-base-plugins-giostreamsrc.html
index 2851ebc..72d44db 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-giostreamsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-giostreamsrc.html
@@ -75,7 +75,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9214272"></a><h3>Example code</h3>
+<a name="idp9048000"></a><h3>Example code</h3>
 <p>
 The following example reads data from a <a href="http://library.gnome.org/devel/gio/unstable/GMemoryInputStream.html"><span class="type">GMemoryInputStream</span></a>.
 </p>
@@ -140,7 +140,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9218672"></a><h3>Element Information</h3>
+<a name="idp10585856"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -163,7 +163,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp11508592"></a><h3>Element Pads</h3>
+<a name="idp8615808"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-multifdsink.html b/docs/plugins/html/gst-plugins-base-plugins-multifdsink.html
index 3bf91a9..50fb4a5 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-multifdsink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-multifdsink.html
@@ -194,7 +194,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp11944528"></a><h3>Element Information</h3>
+<a name="idp11355312"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -217,7 +217,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp11951936"></a><h3>Element Pads</h3>
+<a name="idp11362720"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-multisocketsink.html b/docs/plugins/html/gst-plugins-base-plugins-multisocketsink.html
index bc254e5..861edd5 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-multisocketsink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-multisocketsink.html
@@ -192,7 +192,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp12285424"></a><h3>Element Information</h3>
+<a name="idp12672928"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -215,7 +215,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp12292992"></a><h3>Element Pads</h3>
+<a name="idp12680496"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-oggdemux.html b/docs/plugins/html/gst-plugins-base-plugins-oggdemux.html
index e145b9e..e5b6fe3 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-oggdemux.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-oggdemux.html
@@ -57,7 +57,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9672240"></a><h3>Element Information</h3>
+<a name="idp6069168"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -80,7 +80,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9705008"></a><h3>Element Pads</h3>
+<a name="idp6061232"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -102,7 +102,15 @@
 </tr>
 <tr>
 <td><p><span class="term"></span></p></td>
-<td> application/x-annodex</td>
+<td> audio/ogg</td>
+</tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> video/ogg</td>
+</tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> application/kate</td>
 </tr>
 </tbody>
 </table></div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-oggmux.html b/docs/plugins/html/gst-plugins-base-plugins-oggmux.html
index 4ca7b16..50adb82 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-oggmux.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-oggmux.html
@@ -76,7 +76,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9135856"></a><h3>Element Information</h3>
+<a name="idp11730016"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -99,7 +99,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9130208"></a><h3>Element Pads</h3>
+<a name="idp11723536"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -226,6 +226,14 @@
 <td><p><span class="term">details</span></p></td>
 <td>application/ogg</td>
 </tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> audio/ogg</td>
+</tr>
+<tr>
+<td><p><span class="term"></span></p></td>
+<td> video/ogg</td>
+</tr>
 </tbody>
 </table></div>
 </div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-playbin.html b/docs/plugins/html/gst-plugins-base-plugins-playbin.html
index b229ac2..1208e04 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-playbin.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-playbin.html
@@ -95,6 +95,8 @@
   "<a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--suburi" title='The "suburi" property'>suburi</a>"                   <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--text-sink" title='The "text-sink" property'>text-sink</a>"                <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>*           : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--uri" title='The "uri" property'>uri</a>"                      <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read / Write
+  "<a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--current-suburi" title='The "current-suburi" property'>current-suburi</a>"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read
+  "<a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--current-uri" title='The "current-uri" property'>current-uri</a>"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read
 </pre>
 </div>
 <div class="refsect1">
@@ -159,7 +161,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp13186528"></a><h3>Usage</h3>
+<a name="idp13063216"></a><h3>Usage</h3>
 <p>
 A playbin element can be created just like any other element using
 <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElementFactory.html#gst-element-factory-make"><code class="function">gst_element_factory_make()</code></a>. The file/URI to play should be set via the <a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--uri" title='The "uri" property'><span class="type">"uri"</span></a>
@@ -207,7 +209,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13202640"></a><h3>Advanced Usage: specifying the audio and video sink</h3>
+<a name="idp13079328"></a><h3>Advanced Usage: specifying the audio and video sink</h3>
 <p>
 By default, if no audio sink or video sink has been specified via the
 <a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--audio-sink" title='The "audio-sink" property'><span class="type">"audio-sink"</span></a> or <a class="link" href="gst-plugins-base-plugins-playbin.html#GstPlayBin--video-sink" title='The "video-sink" property'><span class="type">"video-sink"</span></a> property, playbin will use the autoaudiosink
@@ -248,7 +250,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13213200"></a><h3>Retrieving Tags and Other Meta Data</h3>
+<a name="idp13089968"></a><h3>Retrieving Tags and Other Meta Data</h3>
 <p>
 Most of the common meta data (artist, title, etc.) can be retrieved by
 watching for TAG messages on the pipeline's bus (see above).
@@ -263,7 +265,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13215312"></a><h3>Buffering</h3>
+<a name="idp13092080"></a><h3>Buffering</h3>
 Playbin handles buffering automatically for the most part, but applications
 need to handle parts of the buffering process as well. Whenever playbin is
 buffering, it will post BUFFERING messages on the bus with a percentage
@@ -308,7 +310,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13218080"></a><h3>Embedding the video window in your application</h3>
+<a name="idp13094848"></a><h3>Embedding the video window in your application</h3>
 By default, playbin (or rather the video sinks used) will create their own
 window. Applications will usually want to force output to a window of their
 own, however. This can be done using the <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-gstvideooverlay.html#GstVideoOverlay"><span class="type">GstVideoOverlay</span></a> interface, which most
@@ -318,7 +320,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13220048"></a><h3>Specifying which CD/DVD device to use</h3>
+<a name="idp13096816"></a><h3>Specifying which CD/DVD device to use</h3>
 The device to use for CDs/DVDs needs to be set on the source element
 playbin creates before it is opened. The most generic way of doing this
 is to connect to playbin's "source-setup" (or "notify::source") signal,
@@ -334,7 +336,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13221616"></a><h3>Handling redirects</h3>
+<a name="idp13098384"></a><h3>Handling redirects</h3>
 <p>
 Some elements may post 'redirect' messages on the bus to tell the
 application to open another location. These are element messages containing
@@ -347,7 +349,7 @@
 </p>
 <hr>
 <div class="refsect2">
-<a name="idp13223296"></a><h3>Examples</h3>
+<a name="idp13100064"></a><h3>Examples</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -393,7 +395,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp13228192"></a><h3>Element Information</h3>
+<a name="idp13105040"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -416,7 +418,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp13235648"></a><h3>Element Pads</h3>
+<a name="idp13112496"></a><h3>Element Pads</h3>
 </div>
 </div>
 <p>
@@ -719,7 +721,7 @@
 <div class="refsect2">
 <a name="GstPlayBin--text-sink"></a><h3>The <code class="literal">"text-sink"</code> property</h3>
 <pre class="programlisting">  "text-sink"                <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html"><span class="type">GstElement</span></a>*           : Read / Write</pre>
-<p>the text output element to use (NULL = default textoverlay).</p>
+<p>the text output element to use (NULL = default subtitleoverlay).</p>
 </div>
 <hr>
 <div class="refsect2">
@@ -731,6 +733,24 @@
 </p>
 <p>Default value: NULL</p>
 </div>
+<hr>
+<div class="refsect2">
+<a name="GstPlayBin--current-suburi"></a><h3>The <code class="literal">"current-suburi"</code> property</h3>
+<pre class="programlisting">  "current-suburi"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read</pre>
+<p>
+The currently playing subtitle uri.
+</p>
+<p>Default value: NULL</p>
+</div>
+<hr>
+<div class="refsect2">
+<a name="GstPlayBin--current-uri"></a><h3>The <code class="literal">"current-uri"</code> property</h3>
+<pre class="programlisting">  "current-uri"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>*                : Read</pre>
+<p>
+The currently playing uri.
+</p>
+<p>Default value: NULL</p>
+</div>
 </div>
 <div class="refsect1">
 <a name="gst-plugins-base-plugins-playbin.signal-details"></a><h2>Signal Details</h2>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-adder.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-adder.html
index ab0ba02..a153057 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-adder.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-adder.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp8964480"></a><h2>Plugin Information</h2>
+<a name="idp6536912"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp6341520"></a><h2>Elements</h2>
+<a name="idp7614720"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-alsa.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-alsa.html
index 8c26ffb..014898a 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-alsa.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-alsa.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp8659488"></a><h2>Plugin Information</h2>
+<a name="idp14821936"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,15 +57,11 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp7131520"></a><h2>Elements</h2>
+<a name="idp6523040"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
 <tr>
-<td><p><span class="term"><a class="link" href="gst-plugins-base-plugins-alsamixer.html" title="alsamixer">alsamixer</a></span></p></td>
-<td>Control sound input and output levels with ALSA</td>
-</tr>
-<tr>
 <td><p><span class="term"><a class="link" href="gst-plugins-base-plugins-alsasink.html" title="alsasink">alsasink</a></span></p></td>
 <td>Output to a sound card via ALSA</td>
 </tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-app.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-app.html
index ae37d4d..196df7b 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-app.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-app.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9300752"></a><h2>Plugin Information</h2>
+<a name="idp16031216"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp7199840"></a><h2>Elements</h2>
+<a name="idp9192752"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-audioconvert.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-audioconvert.html
index 7cc9ce6..5ac82ac 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-audioconvert.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-audioconvert.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp6678848"></a><h2>Plugin Information</h2>
+<a name="idp8943088"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp9517056"></a><h2>Elements</h2>
+<a name="idp13387200"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-audiorate.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-audiorate.html
index 36f15b2..244351d 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-audiorate.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-audiorate.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9470688"></a><h2>Plugin Information</h2>
+<a name="idp6534976"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp12494784"></a><h2>Elements</h2>
+<a name="idp9034240"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-audioresample.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-audioresample.html
index 13d1c60..b5b51d9 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-audioresample.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-audioresample.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp8062608"></a><h2>Plugin Information</h2>
+<a name="idp5792048"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp7737696"></a><h2>Elements</h2>
+<a name="idp6430384"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-audiotestsrc.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-audiotestsrc.html
index f8558c7..670a2c6 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-audiotestsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-audiotestsrc.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp16316176"></a><h2>Plugin Information</h2>
+<a name="idp11567072"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp10650992"></a><h2>Elements</h2>
+<a name="idp10691872"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-cdparanoia.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-cdparanoia.html
index ed9cfbd..8e16d85 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-cdparanoia.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-cdparanoia.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp7179024"></a><h2>Plugin Information</h2>
+<a name="idp5865184"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp10318848"></a><h2>Elements</h2>
+<a name="idp5502560"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-decodebin.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-decodebin.html
index e8511f1..f73a745 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-decodebin.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-decodebin.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp8609824"></a><h2>Plugin Information</h2>
+<a name="idp5627344"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp7067008"></a><h2>Elements</h2>
+<a name="idp10325376"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-encoding.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-encoding.html
index 167683a..ab9fe8f 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-encoding.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-encoding.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9296576"></a><h2>Plugin Information</h2>
+<a name="idp8238432"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp9821632"></a><h2>Elements</h2>
+<a name="idp10220448"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-gdp.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-gdp.html
index 9c4a7f3..2971c32 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-gdp.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-gdp.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp6309920"></a><h2>Plugin Information</h2>
+<a name="idp6695728"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp6582448"></a><h2>Elements</h2>
+<a name="idp8294064"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-gio.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-gio.html
index a4cec2c..8b8ad61 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-gio.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-gio.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp15484528"></a><h2>Plugin Information</h2>
+<a name="idp6033216"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp6101440"></a><h2>Elements</h2>
+<a name="idp9023056"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-libvisual.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-libvisual.html
index 40860c3..08b924d 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-libvisual.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-libvisual.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9426752"></a><h2>Plugin Information</h2>
+<a name="idp11104816"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp9075488"></a><h2>Elements</h2>
+<a name="idp9750000"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-ogg.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-ogg.html
index 837df39..09fd324 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-ogg.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-ogg.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp7766704"></a><h2>Plugin Information</h2>
+<a name="idp15240752"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp6628544"></a><h2>Elements</h2>
+<a name="idp10726896"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-pango.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-pango.html
index f26d103..524fd59 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-pango.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-pango.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp16419216"></a><h2>Plugin Information</h2>
+<a name="idp6276032"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp8823616"></a><h2>Elements</h2>
+<a name="idp9033712"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-playback.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-playback.html
index e173ac2..8df2747 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-playback.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-playback.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp14475584"></a><h2>Plugin Information</h2>
+<a name="idp9277072"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp9577296"></a><h2>Elements</h2>
+<a name="idp9612832"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-subparse.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-subparse.html
index 74e241c..68c5e4a 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-subparse.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-subparse.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9338048"></a><h2>Plugin Information</h2>
+<a name="idp15858256"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp5836144"></a><h2>Elements</h2>
+<a name="idp5192592"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-tcp.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-tcp.html
index ded4bdc..315a742 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-tcp.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-tcp.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp14462512"></a><h2>Plugin Information</h2>
+<a name="idp15203440"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp8799408"></a><h2>Elements</h2>
+<a name="idp12232336"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-theora.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-theora.html
index 04529ff..9d3369e 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-theora.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-theora.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9419824"></a><h2>Plugin Information</h2>
+<a name="idp11770336"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp6068352"></a><h2>Elements</h2>
+<a name="idp15983920"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-typefindfunctions.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-typefindfunctions.html
index 5d456c4..6b22c8e 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-typefindfunctions.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-typefindfunctions.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp16634576"></a><h2>Plugin Information</h2>
+<a name="idp15849488"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp7746144"></a><h2>Elements</h2>
+<a name="idp6873488"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody></tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-videoconvert.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-videoconvert.html
index 4c973bc..416ad22 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-videoconvert.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-videoconvert.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp6167616"></a><h2>Plugin Information</h2>
+<a name="idp8068368"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp7963456"></a><h2>Elements</h2>
+<a name="idp10271552"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-videorate.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-videorate.html
index 03b780c..264f028 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-videorate.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-videorate.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp16670080"></a><h2>Plugin Information</h2>
+<a name="idp6520288"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp5847360"></a><h2>Elements</h2>
+<a name="idp5837520"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-videoscale.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-videoscale.html
index 2d49f4c..59fd07b 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-videoscale.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-videoscale.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9331424"></a><h2>Plugin Information</h2>
+<a name="idp5267808"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp16661472"></a><h2>Elements</h2>
+<a name="idp6871088"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-videotestsrc.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-videotestsrc.html
index ae25e30..5f693ad 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-videotestsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-videotestsrc.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9073168"></a><h2>Plugin Information</h2>
+<a name="idp5956528"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp11146128"></a><h2>Elements</h2>
+<a name="idp7389280"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-volume.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-volume.html
index d0960b0..ef37fca 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-volume.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-volume.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp6069664"></a><h2>Plugin Information</h2>
+<a name="idp16844016"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp6246608"></a><h2>Elements</h2>
+<a name="idp8972608"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-vorbis.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-vorbis.html
index a248913..5d45842 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-vorbis.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-vorbis.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp5966736"></a><h2>Plugin Information</h2>
+<a name="idp5515904"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp10390256"></a><h2>Elements</h2>
+<a name="idp15500784"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-ximagesink.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-ximagesink.html
index 0b8e032..d803fb6 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-ximagesink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-ximagesink.html
@@ -29,7 +29,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp9609296"></a><h2>Plugin Information</h2>
+<a name="idp13544096"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -39,7 +39,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -57,7 +57,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp16625248"></a><h2>Elements</h2>
+<a name="idp12302144"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-plugin-xvimagesink.html b/docs/plugins/html/gst-plugins-base-plugins-plugin-xvimagesink.html
index dfad77d..25f1146 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-plugin-xvimagesink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-plugin-xvimagesink.html
@@ -28,7 +28,7 @@
 <td valign="top" align="right"></td>
 </tr></table></div>
 <div class="refsect1">
-<a name="idp7824192"></a><h2>Plugin Information</h2>
+<a name="idp7461024"></a><h2>Plugin Information</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -38,7 +38,7 @@
 </tr>
 <tr>
 <td><p><span class="term">version</span></p></td>
-<td>0.11.90</td>
+<td>0.11.92</td>
 </tr>
 <tr>
 <td><p><span class="term">run-time license</span></p></td>
@@ -56,7 +56,7 @@
 </table></div>
 </div>
 <div class="refsect1">
-<a name="idp8218208"></a><h2>Elements</h2>
+<a name="idp7370640"></a><h2>Elements</h2>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody><tr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-subtitleoverlay.html b/docs/plugins/html/gst-plugins-base-plugins-subtitleoverlay.html
index 7a934f0..5a717b2 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-subtitleoverlay.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-subtitleoverlay.html
@@ -84,7 +84,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp6455072"></a><h3>Examples</h3>
+<a name="idp10592256"></a><h3>Examples</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -102,7 +102,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp6137248"></a><h3>Element Information</h3>
+<a name="idp6930448"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -125,7 +125,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp12766128"></a><h3>Element Pads</h3>
+<a name="idp11108752"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-tcpclientsink.html b/docs/plugins/html/gst-plugins-base-plugins-tcpclientsink.html
index e05177e..7719d05 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-tcpclientsink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-tcpclientsink.html
@@ -68,7 +68,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp12774016"></a><h3>Example launch line</h3>
+<a name="idp10681904"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -92,7 +92,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp12776624"></a><h3>Element Information</h3>
+<a name="idp8137504"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -115,7 +115,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp12919440"></a><h3>Element Pads</h3>
+<a name="idp7685568"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-tcpclientsrc.html b/docs/plugins/html/gst-plugins-base-plugins-tcpclientsrc.html
index b33439f..ec54fca 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-tcpclientsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-tcpclientsrc.html
@@ -69,7 +69,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9563568"></a><h3>Example launch line</h3>
+<a name="idp11891296"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -93,7 +93,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp12138240"></a><h3>Element Information</h3>
+<a name="idp11852464"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -116,7 +116,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp12145648"></a><h3>Element Pads</h3>
+<a name="idp12282432"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-tcpserversink.html b/docs/plugins/html/gst-plugins-base-plugins-tcpserversink.html
index 6ad5c32..9ff299d 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-tcpserversink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-tcpserversink.html
@@ -69,7 +69,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp13604432"></a><h3>Example launch line</h3>
+<a name="idp11844064"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -93,7 +93,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9163040"></a><h3>Element Information</h3>
+<a name="idp11549952"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -116,7 +116,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp13635040"></a><h3>Element Pads</h3>
+<a name="idp13918800"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-tcpserversrc.html b/docs/plugins/html/gst-plugins-base-plugins-tcpserversrc.html
index acfed6f..a540f97 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-tcpserversrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-tcpserversrc.html
@@ -69,7 +69,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp12729552"></a><h3>Example launch line</h3>
+<a name="idp11920240"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -93,7 +93,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp12732320"></a><h3>Element Information</h3>
+<a name="idp11926224"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -116,7 +116,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9180320"></a><h3>Element Pads</h3>
+<a name="idp11933520"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-textoverlay.html b/docs/plugins/html/gst-plugins-base-plugins-textoverlay.html
index 6116a92..c29c88f 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-textoverlay.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-textoverlay.html
@@ -85,7 +85,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp14054208"></a><h3>Element Information</h3>
+<a name="idp12519200"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -108,7 +108,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp14061616"></a><h3>Element Pads</h3>
+<a name="idp12526608"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-textrender.html b/docs/plugins/html/gst-plugins-base-plugins-textrender.html
index 77c387d..28523d7 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-textrender.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-textrender.html
@@ -70,7 +70,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp6020640"></a><h3>Element Information</h3>
+<a name="idp6409936"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -93,7 +93,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp13714128"></a><h3>Element Pads</h3>
+<a name="idp13332832"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-theoradec.html b/docs/plugins/html/gst-plugins-base-plugins-theoradec.html
index 50e6069..9780490 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-theoradec.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-theoradec.html
@@ -51,7 +51,8 @@
    +----<a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GInitiallyUnowned">GInitiallyUnowned</a>
          +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstObject.html">GstObject</a>
                +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html">GstElement</a>
-                     +----GstTheoraDec
+                     +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-GstVideoDecoder.html#GstVideoDecoder">GstVideoDecoder</a>
+                           +----GstTheoraDec
 </pre>
 </div>
 <div class="refsect1">
@@ -65,7 +66,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7062304"></a><h3>Element Information</h3>
+<a name="idp11064000"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -88,7 +89,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp13589088"></a><h3>Element Pads</h3>
+<a name="idp13358864"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-theoraenc.html b/docs/plugins/html/gst-plugins-base-plugins-theoraenc.html
index 60eac21..02aa53f 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-theoraenc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-theoraenc.html
@@ -53,7 +53,8 @@
    +----<a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GInitiallyUnowned">GInitiallyUnowned</a>
          +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstObject.html">GstObject</a>
                +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/GstElement.html">GstElement</a>
-                     +----GstTheoraEnc
+                     +----<a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-GstVideoEncoder.html#GstVideoEncoder">GstVideoEncoder</a>
+                           +----GstTheoraEnc
 </pre>
 </div>
 <div class="refsect1">
@@ -77,7 +78,7 @@
   "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--quality" title='The "quality" property'>quality</a>"                  <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--quick" title='The "quick" property'>quick</a>"                    <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--sharpness" title='The "sharpness" property'>sharpness</a>"                <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write
-  "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--speed-level" title='The "speed-level" property'>speed-level</a>"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write / Construct
+  "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--speed-level" title='The "speed-level" property'>speed-level</a>"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--cap-overflow" title='The "cap-overflow" property'>cap-overflow</a>"             <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--cap-underflow" title='The "cap-underflow" property'>cap-underflow</a>"            <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
   "<a class="link" href="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--drop-frames" title='The "drop-frames" property'>drop-frames</a>"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write
@@ -93,7 +94,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp14549296"></a><h3>Element Information</h3>
+<a name="idp14195888"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -116,7 +117,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp14556752"></a><h3>Element Pads</h3>
+<a name="idp14203344"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -269,37 +270,37 @@
 <hr>
 <div class="refsect2">
 <a name="GstTheoraEnc--speed-level"></a><h3>The <code class="literal">"speed-level"</code> property</h3>
-<pre class="programlisting">  "speed-level"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write / Construct</pre>
-<p>Controls the amount of analysis performed when encoding. Higher values trade compression quality for speed. This property requires libtheora version &gt;= 1.0, and the maximum value may vary based on encoder version.</p>
-<p>Allowed values: [0,2]</p>
+<pre class="programlisting">  "speed-level"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write</pre>
+<p>Controls the amount of motion vector searching done while encoding.  This property requires libtheora version &gt;= 1.0.</p>
+<p>Allowed values: [0,3]</p>
 <p>Default value: 1</p>
 </div>
 <hr>
 <div class="refsect2">
 <a name="GstTheoraEnc--cap-overflow"></a><h3>The <code class="literal">"cap-overflow"</code> property</h3>
 <pre class="programlisting">  "cap-overflow"             <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
-<p>Enable capping of bit reservoir overflows.</p>
+<p>Enable capping of bit reservoir overflows.  This property requires libtheora version &gt;= 1.1.</p>
 <p>Default value: TRUE</p>
 </div>
 <hr>
 <div class="refsect2">
 <a name="GstTheoraEnc--cap-underflow"></a><h3>The <code class="literal">"cap-underflow"</code> property</h3>
 <pre class="programlisting">  "cap-underflow"            <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
-<p>Enable capping of bit reservoir underflows.</p>
+<p>Enable capping of bit reservoir underflows.  This property requires libtheora version &gt;= 1.1.</p>
 <p>Default value: FALSE</p>
 </div>
 <hr>
 <div class="refsect2">
 <a name="GstTheoraEnc--drop-frames"></a><h3>The <code class="literal">"drop-frames"</code> property</h3>
 <pre class="programlisting">  "drop-frames"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
-<p>Allow or disallow frame dropping.</p>
+<p>Allow or disallow frame dropping.  This property requires libtheora version &gt;= 1.1.</p>
 <p>Default value: TRUE</p>
 </div>
 <hr>
 <div class="refsect2">
 <a name="GstTheoraEnc--rate-buffer"></a><h3>The <code class="literal">"rate-buffer"</code> property</h3>
 <pre class="programlisting">  "rate-buffer"              <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a>                  : Read / Write</pre>
-<p>Sets the size of the rate control buffer, in units of frames.  The default value of 0 instructs the encoder to automatically select an appropriate value.</p>
+<p>Sets the size of the rate control buffer, in units of frames.  The default value of 0 instructs the encoder to automatically select an appropriate value.  This property requires libtheora version &gt;= 1.1.</p>
 <p>Allowed values: [0,1000]</p>
 <p>Default value: 0</p>
 </div>
@@ -307,7 +308,7 @@
 <div class="refsect2">
 <a name="GstTheoraEnc--vp3-compatible"></a><h3>The <code class="literal">"vp3-compatible"</code> property</h3>
 <pre class="programlisting">  "vp3-compatible"           <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a>              : Read / Write</pre>
-<p>Disables non-VP3 compatible features.</p>
+<p>Disables non-VP3 compatible features.  This property requires libtheora version &gt;= 1.1.</p>
 <p>Default value: FALSE</p>
 </div>
 <hr>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-theoraparse.html b/docs/plugins/html/gst-plugins-base-plugins-theoraparse.html
index 38f65ea..dc3f5fe 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-theoraparse.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-theoraparse.html
@@ -65,7 +65,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9697744"></a><h3>Element Information</h3>
+<a name="idp9628384"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -88,7 +88,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp14210192"></a><h3>Element Pads</h3>
+<a name="idp13437696"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-timeoverlay.html b/docs/plugins/html/gst-plugins-base-plugins-timeoverlay.html
index 853b132..65c58bd 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-timeoverlay.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-timeoverlay.html
@@ -58,7 +58,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp7914960"></a><h3>Element Information</h3>
+<a name="idp5646416"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -81,7 +81,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp8696096"></a><h3>Element Pads</h3>
+<a name="idp6100464"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-uridecodebin.html b/docs/plugins/html/gst-plugins-base-plugins-uridecodebin.html
index 2d909e2..1e42aef 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-uridecodebin.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-uridecodebin.html
@@ -103,7 +103,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp14708688"></a><h3>Element Information</h3>
+<a name="idp14496368"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -126,7 +126,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp14716144"></a><h3>Element Pads</h3>
+<a name="idp14503824"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-videoconvert.html b/docs/plugins/html/gst-plugins-base-plugins-videoconvert.html
index 24d8bcd..421013e 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-videoconvert.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-videoconvert.html
@@ -70,7 +70,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9260976"></a><h3>Example launch line</h3>
+<a name="idp7107984"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -88,7 +88,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9729344"></a><h3>Element Information</h3>
+<a name="idp7663696"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -111,7 +111,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp10701504"></a><h3>Element Pads</h3>
+<a name="idp6133392"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -129,7 +129,7 @@
 </tr>
 <tr>
 <td><p><span class="term">details</span></p></td>
-<td>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, Y800, Y16, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8_PALETTED, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
+<td>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
 </tr>
 </tbody>
 </table></div>
@@ -150,7 +150,7 @@
 </tr>
 <tr>
 <td><p><span class="term">details</span></p></td>
-<td>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, Y800, Y16, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8_PALETTED, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
+<td>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
 </tr>
 </tbody>
 </table></div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-videorate.html b/docs/plugins/html/gst-plugins-base-plugins-videorate.html
index 734aa48..06f16e0 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-videorate.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-videorate.html
@@ -115,7 +115,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp15058912"></a><h3>Example pipelines</h3>
+<a name="idp11701664"></a><h3>Example pipelines</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -149,7 +149,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp15063328"></a><h3>Element Information</h3>
+<a name="idp12342448"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -172,7 +172,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp15070784"></a><h3>Element Pads</h3>
+<a name="idp8724224"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-videoscale.html b/docs/plugins/html/gst-plugins-base-plugins-videoscale.html
index 8ed8210..ac103d7 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-videoscale.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-videoscale.html
@@ -84,7 +84,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp15176432"></a><h3>Example pipelines</h3>
+<a name="idp16041312"></a><h3>Example pipelines</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -120,7 +120,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp15180832"></a><h3>Element Information</h3>
+<a name="idp16045712"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -143,7 +143,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp14498672"></a><h3>Element Pads</h3>
+<a name="idp14353696"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-videotestsrc.html b/docs/plugins/html/gst-plugins-base-plugins-videotestsrc.html
index 1ec23e0..f020c56 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-videotestsrc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-videotestsrc.html
@@ -92,7 +92,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp15578096"></a><h3>Example launch line</h3>
+<a name="idp14849584"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -110,7 +110,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp15575728"></a><h3>Element Information</h3>
+<a name="idp14852240"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -133,7 +133,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp15566928"></a><h3>Element Pads</h3>
+<a name="idp14859696"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -151,155 +151,11 @@
 </tr>
 <tr>
 <td><p><span class="term">details</span></p></td>
-<td>video/x-raw, format=(string)YUY2, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
+<td>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
 </tr>
 <tr>
 <td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)UYVY, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)YVYU, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)v308, colorimetry=(string){ bt601, bt709 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)AYUV, colorimetry=(string){ bt601, bt709 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)v210, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)v216, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)UYVP, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)AY64, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)YVU9, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)YUV9, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)YV12, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)I420, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)NV12, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)NV21, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)Y41B, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)Y42B, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)Y444, colorimetry=(string){ bt601, bt709 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)Y800, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)GRAY8, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)GRAY16_LE, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)xRGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)xBGR, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)RGBx, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)BGRx, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)ARGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)ABGR, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)RGBA, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)BGRA, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)RGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)BGR, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)RGB16, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)RGB15, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-raw, format=(string)ARGB64, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-bayer, format=(string)bggr, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-bayer, format=(string)rggb, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-bayer, format=(string)grbg, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
-</tr>
-<tr>
-<td><p><span class="term"></span></p></td>
-<td> video/x-bayer, format=(string)gbrg, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
+<td> video/x-bayer, format=(string){ bggr, rggb, grbg, gbrg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</td>
 </tr>
 </tbody>
 </table></div>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-volume.html b/docs/plugins/html/gst-plugins-base-plugins-volume.html
index ac91011..744b6db 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-volume.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-volume.html
@@ -62,7 +62,7 @@
 <a name="gst-plugins-base-plugins-volume.implemented-interfaces"></a><h2>Implemented Interfaces</h2>
 <p>
 GstVolume implements
- <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-gstmixer.html#GstMixer">GstMixer</a> and  <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-gststreamvolume.html#GstStreamVolume">GstStreamVolume</a>.</p>
+ <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base-libs/html/gst-plugins-base-libs-gststreamvolume.html#GstStreamVolume">GstStreamVolume</a>.</p>
 </div>
 <div class="refsect1">
 <a name="gst-plugins-base-plugins-volume.properties"></a><h2>Properties</h2>
@@ -79,7 +79,7 @@
 <p>
 </p>
 <div class="refsect2">
-<a name="idp9527088"></a><h3>Example launch line</h3>
+<a name="idp9288432"></a><h3>Example launch line</h3>
 <div class="informalexample">
   <table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
     <tbody>
@@ -99,7 +99,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp14334416"></a><h3>Element Information</h3>
+<a name="idp8601296"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -122,7 +122,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp14262080"></a><h3>Element Pads</h3>
+<a name="idp14366032"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-vorbisdec.html b/docs/plugins/html/gst-plugins-base-plugins-vorbisdec.html
index 4fad008..15e106c 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-vorbisdec.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-vorbisdec.html
@@ -58,7 +58,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9598656"></a><h3>Element Information</h3>
+<a name="idp5282032"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -81,7 +81,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp6388992"></a><h3>Element Pads</h3>
+<a name="idp7184176"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-vorbisenc.html b/docs/plugins/html/gst-plugins-base-plugins-vorbisenc.html
index 1299a74..d1d9314 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-vorbisenc.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-vorbisenc.html
@@ -79,7 +79,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp15030224"></a><h3>Element Information</h3>
+<a name="idp15387312"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -102,7 +102,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp15037632"></a><h3>Element Pads</h3>
+<a name="idp15394720"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-vorbisparse.html b/docs/plugins/html/gst-plugins-base-plugins-vorbisparse.html
index e4c81ef..1fb8d4e 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-vorbisparse.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-vorbisparse.html
@@ -58,7 +58,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp9174784"></a><h3>Element Information</h3>
+<a name="idp5801664"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -81,7 +81,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp6351584"></a><h3>Element Pads</h3>
+<a name="idp7369296"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-vorbistag.html b/docs/plugins/html/gst-plugins-base-plugins-vorbistag.html
index 0ecd49c..2c791d3 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-vorbistag.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-vorbistag.html
@@ -66,7 +66,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp6642160"></a><h3>Element Information</h3>
+<a name="idp8679456"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -89,7 +89,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp9226848"></a><h3>Element Pads</h3>
+<a name="idp14750720"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-ximagesink.html b/docs/plugins/html/gst-plugins-base-plugins-ximagesink.html
index 910e335..d03aaf6 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-ximagesink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-ximagesink.html
@@ -82,7 +82,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp15395728"></a><h3>Element Information</h3>
+<a name="idp14446896"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -105,7 +105,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp15403184"></a><h3>Element Pads</h3>
+<a name="idp15619072"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins-xvimagesink.html b/docs/plugins/html/gst-plugins-base-plugins-xvimagesink.html
index 288de67..62ef940 100644
--- a/docs/plugins/html/gst-plugins-base-plugins-xvimagesink.html
+++ b/docs/plugins/html/gst-plugins-base-plugins-xvimagesink.html
@@ -92,7 +92,7 @@
 <div class="refsynopsisdiv">
 <h2>Synopsis</h2>
 <div class="refsect2">
-<a name="idp16429584"></a><h3>Element Information</h3>
+<a name="idp15717248"></a><h3>Element Information</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
@@ -115,7 +115,7 @@
 </div>
 <hr>
 <div class="refsect2">
-<a name="idp16437040"></a><h3>Element Pads</h3>
+<a name="idp15724704"></a><h3>Element Pads</h3>
 <div class="variablelist"><table border="0">
 <col align="left" valign="top">
 <tbody>
diff --git a/docs/plugins/html/gst-plugins-base-plugins.devhelp2 b/docs/plugins/html/gst-plugins-base-plugins.devhelp2
index d7000a8..3d3f408 100644
--- a/docs/plugins/html/gst-plugins-base-plugins.devhelp2
+++ b/docs/plugins/html/gst-plugins-base-plugins.devhelp2
@@ -84,13 +84,13 @@
     </sub>
   </chapters>
   <functions>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-adder.html#idp8203424"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-adder.html#idp8338832"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-adder.html#idm39456"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-adder.html#idp8081200"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-adder.html#idp7940384"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-adder.html#idm32688"/>
     <keyword type="struct" name="struct GstAdder" link="gst-plugins-base-plugins-adder.html#GstAdder-struct"/>
     <keyword type="property" name="The &quot;caps&quot; property" link="gst-plugins-base-plugins-adder.html#GstAdder--caps"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-appsrc.html#idp7386384"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-appsrc.html#idp7393872"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-appsrc.html#idp9327856"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-appsrc.html#idp9335264"/>
     <keyword type="struct" name="struct GstAppSrc" link="gst-plugins-base-plugins-appsrc.html#GstAppSrc-struct"/>
     <keyword type="property" name="The &quot;block&quot; property" link="gst-plugins-base-plugins-appsrc.html#GstAppSrc--block"/>
     <keyword type="property" name="The &quot;caps&quot; property" link="gst-plugins-base-plugins-appsrc.html#GstAppSrc--caps"/>
@@ -108,8 +108,8 @@
     <keyword type="signal" name="The &quot;need-data&quot; signal" link="gst-plugins-base-plugins-appsrc.html#GstAppSrc-need-data"/>
     <keyword type="signal" name="The &quot;push-buffer&quot; signal" link="gst-plugins-base-plugins-appsrc.html#GstAppSrc-push-buffer"/>
     <keyword type="signal" name="The &quot;seek-data&quot; signal" link="gst-plugins-base-plugins-appsrc.html#GstAppSrc-seek-data"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-appsink.html#idp9939184"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-appsink.html#idp9946672"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-appsink.html#idp9772480"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-appsink.html#idp9779888"/>
     <keyword type="struct" name="struct GstAppSink" link="gst-plugins-base-plugins-appsink.html#GstAppSink-struct"/>
     <keyword type="property" name="The &quot;caps&quot; property" link="gst-plugins-base-plugins-appsink.html#GstAppSink--caps"/>
     <keyword type="property" name="The &quot;drop&quot; property" link="gst-plugins-base-plugins-appsink.html#GstAppSink--drop"/>
@@ -125,31 +125,29 @@
     <keyword type="signal" name="The &quot;pull-buffer-list&quot; signal" link="gst-plugins-base-plugins-appsink.html#GstAppSink-pull-buffer-list"/>
     <keyword type="signal" name="The &quot;new-sample&quot; signal" link="gst-plugins-base-plugins-appsink.html#GstAppSink-new-sample"/>
     <keyword type="signal" name="The &quot;pull-sample&quot; signal" link="gst-plugins-base-plugins-appsink.html#GstAppSink-pull-sample"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-alsamixer.html#idp9325760"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-alsamixer.html#idp6984048"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-alsasink.html#idp7652208"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-alsasink.html#idp7659664"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-alsasink.html#idp5481552"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-alsasink.html#idp5489008"/>
     <keyword type="struct" name="struct GstAlsaSink" link="gst-plugins-base-plugins-alsasink.html#GstAlsaSink-struct"/>
     <keyword type="property" name="The &quot;device&quot; property" link="gst-plugins-base-plugins-alsasink.html#GstAlsaSink--device"/>
     <keyword type="property" name="The &quot;device-name&quot; property" link="gst-plugins-base-plugins-alsasink.html#GstAlsaSink--device-name"/>
     <keyword type="property" name="The &quot;card-name&quot; property" link="gst-plugins-base-plugins-alsasink.html#GstAlsaSink--card-name"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-alsasrc.html#idp8412864"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-alsasrc.html#idp8420320"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-alsasrc.html#idp7512080"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-alsasrc.html#idp7519536"/>
     <keyword type="struct" name="struct GstAlsaSrc" link="gst-plugins-base-plugins-alsasrc.html#GstAlsaSrc-struct"/>
     <keyword type="property" name="The &quot;device&quot; property" link="gst-plugins-base-plugins-alsasrc.html#GstAlsaSrc--device"/>
     <keyword type="property" name="The &quot;device-name&quot; property" link="gst-plugins-base-plugins-alsasrc.html#GstAlsaSrc--device-name"/>
     <keyword type="property" name="The &quot;card-name&quot; property" link="gst-plugins-base-plugins-alsasrc.html#GstAlsaSrc--card-name"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-audioconvert.html#idp6321904"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audioconvert.html#idp9276176"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audioconvert.html#idp9029200"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-audioconvert.html#idp6934944"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audioconvert.html#idp8129456"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audioconvert.html#idp8657616"/>
     <keyword type="struct" name="struct GstAudioConvert" link="gst-plugins-base-plugins-audioconvert.html#GstAudioConvert-struct"/>
     <keyword type="enum" name="enum GstAudioConvertDithering" link="gst-plugins-base-plugins-audioconvert.html#GstAudioConvertDithering"/>
     <keyword type="enum" name="enum GstAudioConvertNoiseShaping" link="gst-plugins-base-plugins-audioconvert.html#GstAudioConvertNoiseShaping"/>
     <keyword type="property" name="The &quot;dithering&quot; property" link="gst-plugins-base-plugins-audioconvert.html#GstAudioConvert--dithering"/>
     <keyword type="property" name="The &quot;noise-shaping&quot; property" link="gst-plugins-base-plugins-audioconvert.html#GstAudioConvert--noise-shaping"/>
-    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-audiorate.html#idp8565120"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audiorate.html#idp10427616"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audiorate.html#idp10435072"/>
+    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-audiorate.html#idp6467600"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audiorate.html#idp10027808"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audiorate.html#idp10035264"/>
     <keyword type="struct" name="struct GstAudioRate" link="gst-plugins-base-plugins-audiorate.html#GstAudioRate-struct"/>
     <keyword type="property" name="The &quot;add&quot; property" link="gst-plugins-base-plugins-audiorate.html#GstAudioRate--add"/>
     <keyword type="property" name="The &quot;drop&quot; property" link="gst-plugins-base-plugins-audiorate.html#GstAudioRate--drop"/>
@@ -158,15 +156,15 @@
     <keyword type="property" name="The &quot;silent&quot; property" link="gst-plugins-base-plugins-audiorate.html#GstAudioRate--silent"/>
     <keyword type="property" name="The &quot;tolerance&quot; property" link="gst-plugins-base-plugins-audiorate.html#GstAudioRate--tolerance"/>
     <keyword type="property" name="The &quot;skip-to-first&quot; property" link="gst-plugins-base-plugins-audiorate.html#GstAudioRate--skip-to-first"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-audioresample.html#idp9365952"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audioresample.html#idp7848656"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audioresample.html#idp8632432"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-audioresample.html#idp9219552"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audioresample.html#idp9274944"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audioresample.html#idp10371280"/>
     <keyword type="struct" name="struct GstAudioResample" link="gst-plugins-base-plugins-audioresample.html#GstAudioResample-struct"/>
     <keyword type="property" name="The &quot;filter-length&quot; property" link="gst-plugins-base-plugins-audioresample.html#GstAudioResample--filter-length"/>
     <keyword type="property" name="The &quot;quality&quot; property" link="gst-plugins-base-plugins-audioresample.html#GstAudioResample--quality"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-audiotestsrc.html#idp10244384"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audiotestsrc.html#idp10248256"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audiotestsrc.html#idp10540240"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-audiotestsrc.html#idp10148304"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-audiotestsrc.html#idp10152176"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-audiotestsrc.html#idp10391520"/>
     <keyword type="struct" name="struct GstAudioTestSrc" link="gst-plugins-base-plugins-audiotestsrc.html#GstAudioTestSrc-struct"/>
     <keyword type="enum" name="enum GstAudioTestSrcWave" link="gst-plugins-base-plugins-audiotestsrc.html#GstAudioTestSrcWave"/>
     <keyword type="property" name="The &quot;freq&quot; property" link="gst-plugins-base-plugins-audiotestsrc.html#GstAudioTestSrc--freq"/>
@@ -177,8 +175,8 @@
     <keyword type="property" name="The &quot;wave&quot; property" link="gst-plugins-base-plugins-audiotestsrc.html#GstAudioTestSrc--wave"/>
     <keyword type="property" name="The &quot;can-activate-pull&quot; property" link="gst-plugins-base-plugins-audiotestsrc.html#GstAudioTestSrc--can-activate-pull"/>
     <keyword type="property" name="The &quot;can-activate-push&quot; property" link="gst-plugins-base-plugins-audiotestsrc.html#GstAudioTestSrc--can-activate-push"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-cdparanoiasrc.html#idp5269504"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-cdparanoiasrc.html#idp10759264"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-cdparanoiasrc.html#idp8481728"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-cdparanoiasrc.html#idp5342592"/>
     <keyword type="struct" name="struct GstCdParanoiaSrc" link="gst-plugins-base-plugins-cdparanoiasrc.html#GstCdParanoiaSrc-struct"/>
     <keyword type="property" name="The &quot;generic-device&quot; property" link="gst-plugins-base-plugins-cdparanoiasrc.html#GstCdParanoiaSrc--generic-device"/>
     <keyword type="property" name="The &quot;paranoia-mode&quot; property" link="gst-plugins-base-plugins-cdparanoiasrc.html#GstCdParanoiaSrc--paranoia-mode"/>
@@ -187,12 +185,12 @@
     <keyword type="property" name="The &quot;cache-size&quot; property" link="gst-plugins-base-plugins-cdparanoiasrc.html#GstCdParanoiaSrc--cache-size"/>
     <keyword type="signal" name="The &quot;transport-error&quot; signal" link="gst-plugins-base-plugins-cdparanoiasrc.html#GstCdParanoiaSrc-transport-error"/>
     <keyword type="signal" name="The &quot;uncorrected-error&quot; signal" link="gst-plugins-base-plugins-cdparanoiasrc.html#GstCdParanoiaSrc-uncorrected-error"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-clockoverlay.html#idp6165216"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-clockoverlay.html#idp7673408"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-clockoverlay.html#idp8730160"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-clockoverlay.html#idp10104016"/>
     <keyword type="struct" name="struct GstClockOverlay" link="gst-plugins-base-plugins-clockoverlay.html#GstClockOverlay-struct"/>
     <keyword type="property" name="The &quot;time-format&quot; property" link="gst-plugins-base-plugins-clockoverlay.html#GstClockOverlay--time-format"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-decodebin.html#idp10897904"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-decodebin.html#idp10905424"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-decodebin.html#idp10842048"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-decodebin.html#idp10849568"/>
     <keyword type="struct" name="struct GstDecodeBin" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-struct"/>
     <keyword type="property" name="The &quot;threaded&quot; property" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--threaded"/>
     <keyword type="property" name="The &quot;sink-caps&quot; property" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--sink-caps"/>
@@ -206,6 +204,7 @@
     <keyword type="property" name="The &quot;post-stream-topology&quot; property" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--post-stream-topology"/>
     <keyword type="property" name="The &quot;subtitle-encoding&quot; property" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--subtitle-encoding"/>
     <keyword type="property" name="The &quot;use-buffering&quot; property" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--use-buffering"/>
+    <keyword type="property" name="The &quot;connection-speed&quot; property" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin--connection-speed"/>
     <keyword type="signal" name="The &quot;new-decoded-pad&quot; signal" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-new-decoded-pad"/>
     <keyword type="signal" name="The &quot;removed-decoded-pad&quot; signal" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-removed-decoded-pad"/>
     <keyword type="signal" name="The &quot;unknown-type&quot; signal" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-unknown-type"/>
@@ -214,9 +213,9 @@
     <keyword type="signal" name="The &quot;autoplug-select&quot; signal" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-autoplug-select"/>
     <keyword type="signal" name="The &quot;autoplug-sort&quot; signal" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-autoplug-sort"/>
     <keyword type="signal" name="The &quot;drained&quot; signal" link="gst-plugins-base-plugins-decodebin.html#GstDecodeBin-drained"/>
-    <keyword type="" name="Features" link="gst-plugins-base-plugins-encodebin.html#idp9863536"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-encodebin.html#idp11290832"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-encodebin.html#idp11298240"/>
+    <keyword type="" name="Features" link="gst-plugins-base-plugins-encodebin.html#idp5808960"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-encodebin.html#idp6176848"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-encodebin.html#idp10782016"/>
     <keyword type="struct" name="GstEncodeBin" link="gst-plugins-base-plugins-encodebin.html#GstEncodeBin-struct"/>
     <keyword type="property" name="The &quot;audio-jitter-tolerance&quot; property" link="gst-plugins-base-plugins-encodebin.html#GstEncodeBin--audio-jitter-tolerance"/>
     <keyword type="property" name="The &quot;avoid-reencoding&quot; property" link="gst-plugins-base-plugins-encodebin.html#GstEncodeBin--avoid-reencoding"/>
@@ -226,46 +225,46 @@
     <keyword type="property" name="The &quot;queue-time-max&quot; property" link="gst-plugins-base-plugins-encodebin.html#GstEncodeBin--queue-time-max"/>
     <keyword type="property" name="The &quot;flags&quot; property" link="gst-plugins-base-plugins-encodebin.html#GstEncodeBin--flags"/>
     <keyword type="signal" name="The &quot;request-pad&quot; signal" link="gst-plugins-base-plugins-encodebin.html#GstEncodeBin-request-pad"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-videoconvert.html#idp9260976"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videoconvert.html#idp9729344"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videoconvert.html#idp10701504"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-videoconvert.html#idp7107984"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videoconvert.html#idp7663696"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videoconvert.html#idp6133392"/>
     <keyword type="struct" name="struct GstVideoConvert" link="gst-plugins-base-plugins-videoconvert.html#GstVideoConvert-struct"/>
     <keyword type="property" name="The &quot;dither&quot; property" link="gst-plugins-base-plugins-videoconvert.html#GstVideoConvert--dither"/>
-    <keyword type="" name="" link="gst-plugins-base-plugins-gdpdepay.html#idp8368432"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-gdpdepay.html#idp6714976"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-gdpdepay.html#idp9237360"/>
+    <keyword type="" name="" link="gst-plugins-base-plugins-gdpdepay.html#idp9026848"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-gdpdepay.html#idp8482384"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-gdpdepay.html#idp6854240"/>
     <keyword type="struct" name="struct GstGDPDepay" link="gst-plugins-base-plugins-gdpdepay.html#GstGDPDepay-struct"/>
-    <keyword type="" name="" link="gst-plugins-base-plugins-gdppay.html#idp9422512"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-gdppay.html#idp8275808"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-gdppay.html#idp11205344"/>
+    <keyword type="" name="" link="gst-plugins-base-plugins-gdppay.html#idp6942016"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-gdppay.html#idp7895936"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-gdppay.html#idp10604048"/>
     <keyword type="struct" name="struct GstGDPPay" link="gst-plugins-base-plugins-gdppay.html#GstGDPPay-struct"/>
     <keyword type="property" name="The &quot;crc-header&quot; property" link="gst-plugins-base-plugins-gdppay.html#GstGDPPay--crc-header"/>
     <keyword type="property" name="The &quot;crc-payload&quot; property" link="gst-plugins-base-plugins-gdppay.html#GstGDPPay--crc-payload"/>
     <keyword type="property" name="The &quot;version&quot; property" link="gst-plugins-base-plugins-gdppay.html#GstGDPPay--version"/>
-    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-giosink.html#idp7541712"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giosink.html#idp7546560"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giosink.html#idp11607184"/>
+    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-giosink.html#idp11085984"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giosink.html#idp6894272"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giosink.html#idp10504192"/>
     <keyword type="struct" name="struct GstGioSink" link="gst-plugins-base-plugins-giosink.html#GstGioSink-struct"/>
     <keyword type="property" name="The &quot;location&quot; property" link="gst-plugins-base-plugins-giosink.html#GstGioSink--location"/>
     <keyword type="property" name="The &quot;file&quot; property" link="gst-plugins-base-plugins-giosink.html#GstGioSink--file"/>
-    <keyword type="" name="Example launch lines" link="gst-plugins-base-plugins-giosrc.html#idp8044096"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giosrc.html#idp7562480"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giosrc.html#idp7570000"/>
+    <keyword type="" name="Example launch lines" link="gst-plugins-base-plugins-giosrc.html#idp10711488"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giosrc.html#idp10716336"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giosrc.html#idp8550112"/>
     <keyword type="struct" name="struct GstGioSrc" link="gst-plugins-base-plugins-giosrc.html#GstGioSrc-struct"/>
     <keyword type="property" name="The &quot;location&quot; property" link="gst-plugins-base-plugins-giosrc.html#GstGioSrc--location"/>
     <keyword type="property" name="The &quot;file&quot; property" link="gst-plugins-base-plugins-giosrc.html#GstGioSrc--file"/>
-    <keyword type="" name="Example code" link="gst-plugins-base-plugins-giostreamsink.html#idp11377200"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giostreamsink.html#idp11381552"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giostreamsink.html#idp11581488"/>
+    <keyword type="" name="Example code" link="gst-plugins-base-plugins-giostreamsink.html#idp10629072"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giostreamsink.html#idp11059232"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giostreamsink.html#idp10760192"/>
     <keyword type="struct" name="struct GstGioStreamSink" link="gst-plugins-base-plugins-giostreamsink.html#GstGioStreamSink-struct"/>
     <keyword type="property" name="The &quot;stream&quot; property" link="gst-plugins-base-plugins-giostreamsink.html#GstGioStreamSink--stream"/>
-    <keyword type="" name="Example code" link="gst-plugins-base-plugins-giostreamsrc.html#idp9214272"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giostreamsrc.html#idp9218672"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giostreamsrc.html#idp11508592"/>
+    <keyword type="" name="Example code" link="gst-plugins-base-plugins-giostreamsrc.html#idp9048000"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-giostreamsrc.html#idp10585856"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-giostreamsrc.html#idp8615808"/>
     <keyword type="struct" name="struct GstGioStreamSrc" link="gst-plugins-base-plugins-giostreamsrc.html#GstGioStreamSrc-struct"/>
     <keyword type="property" name="The &quot;stream&quot; property" link="gst-plugins-base-plugins-giostreamsrc.html#GstGioStreamSrc--stream"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-multifdsink.html#idp11944528"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-multifdsink.html#idp11951936"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-multifdsink.html#idp11355312"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-multifdsink.html#idp11362720"/>
     <keyword type="struct" name="struct GstMultiFdSink" link="gst-plugins-base-plugins-multifdsink.html#GstMultiFdSink-struct"/>
     <keyword type="enum" name="enum GstRecoverPolicy" link="gst-plugins-base-plugins-multifdsink.html#GstRecoverPolicy"/>
     <keyword type="enum" name="enum GstSyncMethod" link="gst-plugins-base-plugins-multifdsink.html#GstSyncMethod"/>
@@ -303,8 +302,8 @@
     <keyword type="signal" name="The &quot;add-full&quot; signal" link="gst-plugins-base-plugins-multifdsink.html#GstMultiFdSink-add-full"/>
     <keyword type="signal" name="The &quot;remove-flush&quot; signal" link="gst-plugins-base-plugins-multifdsink.html#GstMultiFdSink-remove-flush"/>
     <keyword type="signal" name="The &quot;client-handle-removed&quot; signal" link="gst-plugins-base-plugins-multifdsink.html#GstMultiFdSink-client-handle-removed"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-multisocketsink.html#idp12285424"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-multisocketsink.html#idp12292992"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-multisocketsink.html#idp12672928"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-multisocketsink.html#idp12680496"/>
     <keyword type="struct" name="struct GstMultiSocketSink" link="gst-plugins-base-plugins-multisocketsink.html#GstMultiSocketSink-struct"/>
     <keyword type="enum" name="enum GstRecoverPolicy" link="gst-plugins-base-plugins-multisocketsink.html#GstRecoverPolicy"/>
     <keyword type="enum" name="enum GstSyncMethod" link="gst-plugins-base-plugins-multisocketsink.html#GstSyncMethod"/>
@@ -339,26 +338,26 @@
     <keyword type="signal" name="The &quot;remove&quot; signal" link="gst-plugins-base-plugins-multisocketsink.html#GstMultiSocketSink-remove"/>
     <keyword type="signal" name="The &quot;remove-flush&quot; signal" link="gst-plugins-base-plugins-multisocketsink.html#GstMultiSocketSink-remove-flush"/>
     <keyword type="signal" name="The &quot;client-handle-removed&quot; signal" link="gst-plugins-base-plugins-multisocketsink.html#GstMultiSocketSink-client-handle-removed"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-oggdemux.html#idp9672240"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-oggdemux.html#idp9705008"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-oggdemux.html#idp6069168"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-oggdemux.html#idp6061232"/>
     <keyword type="struct" name="struct GstOggDemux" link="gst-plugins-base-plugins-oggdemux.html#GstOggDemux-struct"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-oggmux.html#idp9135856"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-oggmux.html#idp9130208"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-oggmux.html#idp11730016"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-oggmux.html#idp11723536"/>
     <keyword type="struct" name="struct GstOggMux" link="gst-plugins-base-plugins-oggmux.html#GstOggMux-struct"/>
     <keyword type="property" name="The &quot;max-delay&quot; property" link="gst-plugins-base-plugins-oggmux.html#GstOggMux--max-delay"/>
     <keyword type="property" name="The &quot;max-page-delay&quot; property" link="gst-plugins-base-plugins-oggmux.html#GstOggMux--max-page-delay"/>
     <keyword type="property" name="The &quot;max-tolerance&quot; property" link="gst-plugins-base-plugins-oggmux.html#GstOggMux--max-tolerance"/>
     <keyword type="property" name="The &quot;skeleton&quot; property" link="gst-plugins-base-plugins-oggmux.html#GstOggMux--skeleton"/>
-    <keyword type="" name="Usage" link="gst-plugins-base-plugins-playbin.html#idp13186528"/>
-    <keyword type="" name="Advanced Usage: specifying the audio and video sink" link="gst-plugins-base-plugins-playbin.html#idp13202640"/>
-    <keyword type="" name="Retrieving Tags and Other Meta Data" link="gst-plugins-base-plugins-playbin.html#idp13213200"/>
-    <keyword type="" name="Buffering" link="gst-plugins-base-plugins-playbin.html#idp13215312"/>
-    <keyword type="" name="Embedding the video window in your application" link="gst-plugins-base-plugins-playbin.html#idp13218080"/>
-    <keyword type="" name="Specifying which CD/DVD device to use" link="gst-plugins-base-plugins-playbin.html#idp13220048"/>
-    <keyword type="" name="Handling redirects" link="gst-plugins-base-plugins-playbin.html#idp13221616"/>
-    <keyword type="" name="Examples" link="gst-plugins-base-plugins-playbin.html#idp13223296"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-playbin.html#idp13228192"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-playbin.html#idp13235648"/>
+    <keyword type="" name="Usage" link="gst-plugins-base-plugins-playbin.html#idp13063216"/>
+    <keyword type="" name="Advanced Usage: specifying the audio and video sink" link="gst-plugins-base-plugins-playbin.html#idp13079328"/>
+    <keyword type="" name="Retrieving Tags and Other Meta Data" link="gst-plugins-base-plugins-playbin.html#idp13089968"/>
+    <keyword type="" name="Buffering" link="gst-plugins-base-plugins-playbin.html#idp13092080"/>
+    <keyword type="" name="Embedding the video window in your application" link="gst-plugins-base-plugins-playbin.html#idp13094848"/>
+    <keyword type="" name="Specifying which CD/DVD device to use" link="gst-plugins-base-plugins-playbin.html#idp13096816"/>
+    <keyword type="" name="Handling redirects" link="gst-plugins-base-plugins-playbin.html#idp13098384"/>
+    <keyword type="" name="Examples" link="gst-plugins-base-plugins-playbin.html#idp13100064"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-playbin.html#idp13105040"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-playbin.html#idp13112496"/>
     <keyword type="struct" name="struct GstPlayBin" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-struct"/>
     <keyword type="enum" name="enum GstPlayFlags" link="gst-plugins-base-plugins-playbin.html#GstPlayFlags"/>
     <keyword type="property" name="The &quot;audio-sink&quot; property" link="gst-plugins-base-plugins-playbin.html#GstPlayBin--audio-sink"/>
@@ -386,6 +385,8 @@
     <keyword type="property" name="The &quot;suburi&quot; property" link="gst-plugins-base-plugins-playbin.html#GstPlayBin--suburi"/>
     <keyword type="property" name="The &quot;text-sink&quot; property" link="gst-plugins-base-plugins-playbin.html#GstPlayBin--text-sink"/>
     <keyword type="property" name="The &quot;uri&quot; property" link="gst-plugins-base-plugins-playbin.html#GstPlayBin--uri"/>
+    <keyword type="property" name="The &quot;current-suburi&quot; property" link="gst-plugins-base-plugins-playbin.html#GstPlayBin--current-suburi"/>
+    <keyword type="property" name="The &quot;current-uri&quot; property" link="gst-plugins-base-plugins-playbin.html#GstPlayBin--current-uri"/>
     <keyword type="signal" name="The &quot;about-to-finish&quot; signal" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-about-to-finish"/>
     <keyword type="signal" name="The &quot;audio-changed&quot; signal" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-audio-changed"/>
     <keyword type="signal" name="The &quot;audio-tags-changed&quot; signal" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-audio-tags-changed"/>
@@ -401,42 +402,42 @@
     <keyword type="signal" name="The &quot;text-tags-changed&quot; signal" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-text-tags-changed"/>
     <keyword type="signal" name="The &quot;video-changed&quot; signal" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-video-changed"/>
     <keyword type="signal" name="The &quot;video-tags-changed&quot; signal" link="gst-plugins-base-plugins-playbin.html#GstPlayBin-video-tags-changed"/>
-    <keyword type="" name="Examples" link="gst-plugins-base-plugins-subtitleoverlay.html#idp6455072"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-subtitleoverlay.html#idp6137248"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-subtitleoverlay.html#idp12766128"/>
+    <keyword type="" name="Examples" link="gst-plugins-base-plugins-subtitleoverlay.html#idp10592256"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-subtitleoverlay.html#idp6930448"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-subtitleoverlay.html#idp11108752"/>
     <keyword type="struct" name="struct GstSubtitleOverlay" link="gst-plugins-base-plugins-subtitleoverlay.html#GstSubtitleOverlay-struct"/>
     <keyword type="property" name="The &quot;font-desc&quot; property" link="gst-plugins-base-plugins-subtitleoverlay.html#GstSubtitleOverlay--font-desc"/>
     <keyword type="property" name="The &quot;silent&quot; property" link="gst-plugins-base-plugins-subtitleoverlay.html#GstSubtitleOverlay--silent"/>
     <keyword type="property" name="The &quot;subtitle-encoding&quot; property" link="gst-plugins-base-plugins-subtitleoverlay.html#GstSubtitleOverlay--subtitle-encoding"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpclientsrc.html#idp9563568"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpclientsrc.html#idp12138240"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpclientsrc.html#idp12145648"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpclientsrc.html#idp11891296"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpclientsrc.html#idp11852464"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpclientsrc.html#idp12282432"/>
     <keyword type="struct" name="struct GstTCPClientSrc" link="gst-plugins-base-plugins-tcpclientsrc.html#GstTCPClientSrc-struct"/>
     <keyword type="property" name="The &quot;host&quot; property" link="gst-plugins-base-plugins-tcpclientsrc.html#GstTCPClientSrc--host"/>
     <keyword type="property" name="The &quot;port&quot; property" link="gst-plugins-base-plugins-tcpclientsrc.html#GstTCPClientSrc--port"/>
     <keyword type="property" name="The &quot;protocol&quot; property" link="gst-plugins-base-plugins-tcpclientsrc.html#GstTCPClientSrc--protocol"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpclientsink.html#idp12774016"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpclientsink.html#idp12776624"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpclientsink.html#idp12919440"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpclientsink.html#idp10681904"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpclientsink.html#idp8137504"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpclientsink.html#idp7685568"/>
     <keyword type="struct" name="struct GstTCPClientSink" link="gst-plugins-base-plugins-tcpclientsink.html#GstTCPClientSink-struct"/>
     <keyword type="property" name="The &quot;host&quot; property" link="gst-plugins-base-plugins-tcpclientsink.html#GstTCPClientSink--host"/>
     <keyword type="property" name="The &quot;port&quot; property" link="gst-plugins-base-plugins-tcpclientsink.html#GstTCPClientSink--port"/>
     <keyword type="property" name="The &quot;protocol&quot; property" link="gst-plugins-base-plugins-tcpclientsink.html#GstTCPClientSink--protocol"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpserversrc.html#idp12729552"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpserversrc.html#idp12732320"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpserversrc.html#idp9180320"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpserversrc.html#idp11920240"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpserversrc.html#idp11926224"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpserversrc.html#idp11933520"/>
     <keyword type="struct" name="struct GstTCPServerSrc" link="gst-plugins-base-plugins-tcpserversrc.html#GstTCPServerSrc-struct"/>
     <keyword type="property" name="The &quot;host&quot; property" link="gst-plugins-base-plugins-tcpserversrc.html#GstTCPServerSrc--host"/>
     <keyword type="property" name="The &quot;port&quot; property" link="gst-plugins-base-plugins-tcpserversrc.html#GstTCPServerSrc--port"/>
     <keyword type="property" name="The &quot;protocol&quot; property" link="gst-plugins-base-plugins-tcpserversrc.html#GstTCPServerSrc--protocol"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpserversink.html#idp13604432"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpserversink.html#idp9163040"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpserversink.html#idp13635040"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-tcpserversink.html#idp11844064"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-tcpserversink.html#idp11549952"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-tcpserversink.html#idp13918800"/>
     <keyword type="struct" name="struct GstTCPServerSink" link="gst-plugins-base-plugins-tcpserversink.html#GstTCPServerSink-struct"/>
     <keyword type="property" name="The &quot;host&quot; property" link="gst-plugins-base-plugins-tcpserversink.html#GstTCPServerSink--host"/>
     <keyword type="property" name="The &quot;port&quot; property" link="gst-plugins-base-plugins-tcpserversink.html#GstTCPServerSink--port"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-textoverlay.html#idp14054208"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-textoverlay.html#idp14061616"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-textoverlay.html#idp12519200"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-textoverlay.html#idp12526608"/>
     <keyword type="struct" name="struct GstTextOverlay" link="gst-plugins-base-plugins-textoverlay.html#GstTextOverlay-struct"/>
     <keyword type="property" name="The &quot;deltax&quot; property" link="gst-plugins-base-plugins-textoverlay.html#GstTextOverlay--deltax"/>
     <keyword type="property" name="The &quot;deltay&quot; property" link="gst-plugins-base-plugins-textoverlay.html#GstTextOverlay--deltay"/>
@@ -458,8 +459,8 @@
     <keyword type="property" name="The &quot;color&quot; property" link="gst-plugins-base-plugins-textoverlay.html#GstTextOverlay--color"/>
     <keyword type="property" name="The &quot;xpos&quot; property" link="gst-plugins-base-plugins-textoverlay.html#GstTextOverlay--xpos"/>
     <keyword type="property" name="The &quot;ypos&quot; property" link="gst-plugins-base-plugins-textoverlay.html#GstTextOverlay--ypos"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-textrender.html#idp6020640"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-textrender.html#idp13714128"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-textrender.html#idp6409936"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-textrender.html#idp13332832"/>
     <keyword type="struct" name="struct GstTextRender" link="gst-plugins-base-plugins-textrender.html#GstTextRender-struct"/>
     <keyword type="property" name="The &quot;font-desc&quot; property" link="gst-plugins-base-plugins-textrender.html#GstTextRender--font-desc"/>
     <keyword type="property" name="The &quot;halignment&quot; property" link="gst-plugins-base-plugins-textrender.html#GstTextRender--halignment"/>
@@ -467,12 +468,12 @@
     <keyword type="property" name="The &quot;valignment&quot; property" link="gst-plugins-base-plugins-textrender.html#GstTextRender--valignment"/>
     <keyword type="property" name="The &quot;xpad&quot; property" link="gst-plugins-base-plugins-textrender.html#GstTextRender--xpad"/>
     <keyword type="property" name="The &quot;ypad&quot; property" link="gst-plugins-base-plugins-textrender.html#GstTextRender--ypad"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-theoradec.html#idp7062304"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-theoradec.html#idp13589088"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-theoradec.html#idp11064000"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-theoradec.html#idp13358864"/>
     <keyword type="struct" name="struct GstTheoraDec" link="gst-plugins-base-plugins-theoradec.html#GstTheoraDec-struct"/>
     <keyword type="property" name="The &quot;crop&quot; property" link="gst-plugins-base-plugins-theoradec.html#GstTheoraDec--crop"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-theoraenc.html#idp14549296"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-theoraenc.html#idp14556752"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-theoraenc.html#idp14195888"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-theoraenc.html#idp14203344"/>
     <keyword type="struct" name="struct GstTheoraEnc" link="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc-struct"/>
     <keyword type="property" name="The &quot;bitrate&quot; property" link="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--bitrate"/>
     <keyword type="property" name="The &quot;border&quot; property" link="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--border"/>
@@ -495,15 +496,15 @@
     <keyword type="property" name="The &quot;multipass-cache-file&quot; property" link="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--multipass-cache-file"/>
     <keyword type="property" name="The &quot;multipass-mode&quot; property" link="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--multipass-mode"/>
     <keyword type="property" name="The &quot;dup-on-gap&quot; property" link="gst-plugins-base-plugins-theoraenc.html#GstTheoraEnc--dup-on-gap"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-theoraparse.html#idp9697744"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-theoraparse.html#idp14210192"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-theoraparse.html#idp9628384"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-theoraparse.html#idp13437696"/>
     <keyword type="struct" name="struct GstTheoraParse" link="gst-plugins-base-plugins-theoraparse.html#GstTheoraParse-struct"/>
     <keyword type="property" name="The &quot;synchronization-points&quot; property" link="gst-plugins-base-plugins-theoraparse.html#GstTheoraParse--synchronization-points"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-timeoverlay.html#idp7914960"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-timeoverlay.html#idp8696096"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-timeoverlay.html#idp5646416"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-timeoverlay.html#idp6100464"/>
     <keyword type="struct" name="struct GstTimeOverlay" link="gst-plugins-base-plugins-timeoverlay.html#GstTimeOverlay-struct"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-uridecodebin.html#idp14708688"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-uridecodebin.html#idp14716144"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-uridecodebin.html#idp14496368"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-uridecodebin.html#idp14503824"/>
     <keyword type="struct" name="struct GstURIDecodeBin" link="gst-plugins-base-plugins-uridecodebin.html#GstURIDecodeBin-struct"/>
     <keyword type="enum" name="enum GstAutoplugSelectResult" link="gst-plugins-base-plugins-uridecodebin.html#GstAutoplugSelectResult"/>
     <keyword type="property" name="The &quot;uri&quot; property" link="gst-plugins-base-plugins-uridecodebin.html#GstURIDecodeBin--uri"/>
@@ -524,9 +525,9 @@
     <keyword type="signal" name="The &quot;drained&quot; signal" link="gst-plugins-base-plugins-uridecodebin.html#GstURIDecodeBin-drained"/>
     <keyword type="signal" name="The &quot;autoplug-sort&quot; signal" link="gst-plugins-base-plugins-uridecodebin.html#GstURIDecodeBin-autoplug-sort"/>
     <keyword type="signal" name="The &quot;source-setup&quot; signal" link="gst-plugins-base-plugins-uridecodebin.html#GstURIDecodeBin-source-setup"/>
-    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-videorate.html#idp15058912"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videorate.html#idp15063328"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videorate.html#idp15070784"/>
+    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-videorate.html#idp11701664"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videorate.html#idp12342448"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videorate.html#idp8724224"/>
     <keyword type="struct" name="struct GstVideoRate" link="gst-plugins-base-plugins-videorate.html#GstVideoRate-struct"/>
     <keyword type="property" name="The &quot;drop&quot; property" link="gst-plugins-base-plugins-videorate.html#GstVideoRate--drop"/>
     <keyword type="property" name="The &quot;duplicate&quot; property" link="gst-plugins-base-plugins-videorate.html#GstVideoRate--duplicate"/>
@@ -538,9 +539,9 @@
     <keyword type="property" name="The &quot;average-period&quot; property" link="gst-plugins-base-plugins-videorate.html#GstVideoRate--average-period"/>
     <keyword type="property" name="The &quot;drop-only&quot; property" link="gst-plugins-base-plugins-videorate.html#GstVideoRate--drop-only"/>
     <keyword type="property" name="The &quot;max-rate&quot; property" link="gst-plugins-base-plugins-videorate.html#GstVideoRate--max-rate"/>
-    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-videoscale.html#idp15176432"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videoscale.html#idp15180832"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videoscale.html#idp14498672"/>
+    <keyword type="" name="Example pipelines" link="gst-plugins-base-plugins-videoscale.html#idp16041312"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videoscale.html#idp16045712"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videoscale.html#idp14353696"/>
     <keyword type="struct" name="struct GstVideoScale" link="gst-plugins-base-plugins-videoscale.html#GstVideoScale-struct"/>
     <keyword type="enum" name="enum GstVideoScaleMethod" link="gst-plugins-base-plugins-videoscale.html#GstVideoScaleMethod"/>
     <keyword type="property" name="The &quot;method&quot; property" link="gst-plugins-base-plugins-videoscale.html#GstVideoScale--method"/>
@@ -549,9 +550,9 @@
     <keyword type="property" name="The &quot;envelope&quot; property" link="gst-plugins-base-plugins-videoscale.html#GstVideoScale--envelope"/>
     <keyword type="property" name="The &quot;sharpen&quot; property" link="gst-plugins-base-plugins-videoscale.html#GstVideoScale--sharpen"/>
     <keyword type="property" name="The &quot;sharpness&quot; property" link="gst-plugins-base-plugins-videoscale.html#GstVideoScale--sharpness"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-videotestsrc.html#idp15578096"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videotestsrc.html#idp15575728"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videotestsrc.html#idp15566928"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-videotestsrc.html#idp14849584"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-videotestsrc.html#idp14852240"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-videotestsrc.html#idp14859696"/>
     <keyword type="struct" name="struct GstVideoTestSrc" link="gst-plugins-base-plugins-videotestsrc.html#GstVideoTestSrc-struct"/>
     <keyword type="enum" name="enum GstVideoTestSrcPattern" link="gst-plugins-base-plugins-videotestsrc.html#GstVideoTestSrcPattern"/>
     <keyword type="property" name="The &quot;pattern&quot; property" link="gst-plugins-base-plugins-videotestsrc.html#GstVideoTestSrc--pattern"/>
@@ -574,17 +575,17 @@
     <keyword type="property" name="The &quot;background-color&quot; property" link="gst-plugins-base-plugins-videotestsrc.html#GstVideoTestSrc--background-color"/>
     <keyword type="property" name="The &quot;foreground-color&quot; property" link="gst-plugins-base-plugins-videotestsrc.html#GstVideoTestSrc--foreground-color"/>
     <keyword type="property" name="The &quot;horizontal-speed&quot; property" link="gst-plugins-base-plugins-videotestsrc.html#GstVideoTestSrc--horizontal-speed"/>
-    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-volume.html#idp9527088"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-volume.html#idp14334416"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-volume.html#idp14262080"/>
+    <keyword type="" name="Example launch line" link="gst-plugins-base-plugins-volume.html#idp9288432"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-volume.html#idp8601296"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-volume.html#idp14366032"/>
     <keyword type="struct" name="struct GstVolume" link="gst-plugins-base-plugins-volume.html#GstVolume-struct"/>
     <keyword type="property" name="The &quot;mute&quot; property" link="gst-plugins-base-plugins-volume.html#GstVolume--mute"/>
     <keyword type="property" name="The &quot;volume&quot; property" link="gst-plugins-base-plugins-volume.html#GstVolume--volume"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbisdec.html#idp9598656"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbisdec.html#idp6388992"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbisdec.html#idp5282032"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbisdec.html#idp7184176"/>
     <keyword type="struct" name="struct GstVorbisDec" link="gst-plugins-base-plugins-vorbisdec.html#GstVorbisDec-struct"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbisenc.html#idp15030224"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbisenc.html#idp15037632"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbisenc.html#idp15387312"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbisenc.html#idp15394720"/>
     <keyword type="struct" name="struct GstVorbisEnc" link="gst-plugins-base-plugins-vorbisenc.html#GstVorbisEnc-struct"/>
     <keyword type="property" name="The &quot;bitrate&quot; property" link="gst-plugins-base-plugins-vorbisenc.html#GstVorbisEnc--bitrate"/>
     <keyword type="property" name="The &quot;last-message&quot; property" link="gst-plugins-base-plugins-vorbisenc.html#GstVorbisEnc--last-message"/>
@@ -592,14 +593,14 @@
     <keyword type="property" name="The &quot;max-bitrate&quot; property" link="gst-plugins-base-plugins-vorbisenc.html#GstVorbisEnc--max-bitrate"/>
     <keyword type="property" name="The &quot;min-bitrate&quot; property" link="gst-plugins-base-plugins-vorbisenc.html#GstVorbisEnc--min-bitrate"/>
     <keyword type="property" name="The &quot;quality&quot; property" link="gst-plugins-base-plugins-vorbisenc.html#GstVorbisEnc--quality"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbisparse.html#idp9174784"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbisparse.html#idp6351584"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbisparse.html#idp5801664"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbisparse.html#idp7369296"/>
     <keyword type="struct" name="struct GstVorbisParse" link="gst-plugins-base-plugins-vorbisparse.html#GstVorbisParse-struct"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbistag.html#idp6642160"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbistag.html#idp9226848"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-vorbistag.html#idp8679456"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-vorbistag.html#idp14750720"/>
     <keyword type="struct" name="struct GstVorbisTag" link="gst-plugins-base-plugins-vorbistag.html#GstVorbisTag-struct"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-ximagesink.html#idp15395728"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-ximagesink.html#idp15403184"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-ximagesink.html#idp14446896"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-ximagesink.html#idp15619072"/>
     <keyword type="struct" name="struct GstXImageSink" link="gst-plugins-base-plugins-ximagesink.html#GstXImageSink-struct"/>
     <keyword type="property" name="The &quot;display&quot; property" link="gst-plugins-base-plugins-ximagesink.html#GstXImageSink--display"/>
     <keyword type="property" name="The &quot;pixel-aspect-ratio&quot; property" link="gst-plugins-base-plugins-ximagesink.html#GstXImageSink--pixel-aspect-ratio"/>
@@ -609,8 +610,8 @@
     <keyword type="property" name="The &quot;handle-expose&quot; property" link="gst-plugins-base-plugins-ximagesink.html#GstXImageSink--handle-expose"/>
     <keyword type="property" name="The &quot;window-height&quot; property" link="gst-plugins-base-plugins-ximagesink.html#GstXImageSink--window-height"/>
     <keyword type="property" name="The &quot;window-width&quot; property" link="gst-plugins-base-plugins-ximagesink.html#GstXImageSink--window-width"/>
-    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-xvimagesink.html#idp16429584"/>
-    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-xvimagesink.html#idp16437040"/>
+    <keyword type="" name="Element Information" link="gst-plugins-base-plugins-xvimagesink.html#idp15717248"/>
+    <keyword type="" name="Element Pads" link="gst-plugins-base-plugins-xvimagesink.html#idp15724704"/>
     <keyword type="struct" name="struct GstXvImageSink" link="gst-plugins-base-plugins-xvimagesink.html#GstXvImageSink-struct"/>
     <keyword type="property" name="The &quot;brightness&quot; property" link="gst-plugins-base-plugins-xvimagesink.html#GstXvImageSink--brightness"/>
     <keyword type="property" name="The &quot;contrast&quot; property" link="gst-plugins-base-plugins-xvimagesink.html#GstXvImageSink--contrast"/>
diff --git a/docs/plugins/html/index.html b/docs/plugins/html/index.html
index 5fd54ab..10b033a 100644
--- a/docs/plugins/html/index.html
+++ b/docs/plugins/html/index.html
@@ -15,7 +15,7 @@
 <div>
 <div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">GStreamer Base Plugins 1.0 Plugins Reference Manual</p></th></tr></table></div>
 <div><p class="releaseinfo">
-      for GStreamer Base Plugins 1.0 (0.11.90.1)
+      for GStreamer Base Plugins 1.0 (0.11.92)
       The latest version of this documentation can be found on-line at
       <a class="ulink" href="http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/" target="_top">http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-base/html/</a>.
     </p></div>
@@ -35,7 +35,7 @@
 <span class="refentrytitle"><a href="gst-plugins-base-plugins-appsink.html">appsink</a></span><span class="refpurpose"> — Allow the application to get access to raw buffer</span>
 </dt>
 <dt>
-<span class="refentrytitle"><a href="gst-plugins-base-plugins-alsamixer.html">alsamixer</a></span><span class="refpurpose"> — Control sound input and output levels with ALSA</span>
+<span class="refentrytitle"><a href="gst-plugins-base-plugins-alsamixer.html">alsamixer</a></span><span class="refpurpose"></span>
 </dt>
 <dt>
 <span class="refentrytitle"><a href="gst-plugins-base-plugins-alsasink.html">alsasink</a></span><span class="refpurpose"> — Output to a sound card via ALSA</span>
diff --git a/docs/plugins/html/index.sgml b/docs/plugins/html/index.sgml
index 17a495e..440696b 100644
--- a/docs/plugins/html/index.sgml
+++ b/docs/plugins/html/index.sgml
@@ -226,6 +226,7 @@
 <ANCHOR id="GstDecodeBin--post-stream-topology" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#GstDecodeBin--post-stream-topology">
 <ANCHOR id="GstDecodeBin--subtitle-encoding" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#GstDecodeBin--subtitle-encoding">
 <ANCHOR id="GstDecodeBin--use-buffering" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#GstDecodeBin--use-buffering">
+<ANCHOR id="GstDecodeBin--connection-speed" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#GstDecodeBin--connection-speed">
 <ANCHOR id="gst-plugins-base-plugins-decodebin.signal-details" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#gst-plugins-base-plugins-decodebin.signal-details">
 <ANCHOR id="GstDecodeBin-new-decoded-pad" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#GstDecodeBin-new-decoded-pad">
 <ANCHOR id="GstDecodeBin-removed-decoded-pad" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-decodebin.html#GstDecodeBin-removed-decoded-pad">
@@ -511,6 +512,8 @@
 <ANCHOR id="GstPlayBin--suburi" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin--suburi">
 <ANCHOR id="GstPlayBin--text-sink" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin--text-sink">
 <ANCHOR id="GstPlayBin--uri" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin--uri">
+<ANCHOR id="GstPlayBin--current-suburi" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin--current-suburi">
+<ANCHOR id="GstPlayBin--current-uri" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin--current-uri">
 <ANCHOR id="gst-plugins-base-plugins-playbin.signal-details" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#gst-plugins-base-plugins-playbin.signal-details">
 <ANCHOR id="GstPlayBin-about-to-finish" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin-about-to-finish">
 <ANCHOR id="GstPlayBin-audio-changed" href="gst-plugins-base-plugins-1.0/gst-plugins-base-plugins-playbin.html#GstPlayBin-audio-changed">
diff --git a/docs/plugins/inspect/plugin-adder.xml b/docs/plugins/inspect/plugin-adder.xml
index fd505e0..c375d9d 100644
--- a/docs/plugins/inspect/plugin-adder.xml
+++ b/docs/plugins/inspect/plugin-adder.xml
@@ -3,7 +3,7 @@
   <description>Adds multiple streams</description>
   <filename>../../gst/adder/.libs/libgstadder.so</filename>
   <basename>libgstadder.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-alsa.xml b/docs/plugins/inspect/plugin-alsa.xml
index dc4c84d..1983172 100644
--- a/docs/plugins/inspect/plugin-alsa.xml
+++ b/docs/plugins/inspect/plugin-alsa.xml
@@ -3,22 +3,13 @@
   <description>ALSA plugin library</description>
   <filename>../../ext/alsa/.libs/libgstalsa.so</filename>
   <basename>libgstalsa.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
   <origin>Unknown package origin</origin>
   <elements>
     <element>
-      <name>alsamixer</name>
-      <longname>Alsa mixer</longname>
-      <class>Generic/Audio</class>
-      <description>Control sound input and output levels with ALSA</description>
-      <author>Leif Johnson &lt;leif@ambient.2y.net&gt;</author>
-      <pads>
-      </pads>
-    </element>
-    <element>
       <name>alsasink</name>
       <longname>Audio sink (ALSA)</longname>
       <class>Sink/Audio</class>
@@ -29,7 +20,7 @@
           <name>sink</name>
           <direction>sink</direction>
           <presence>always</presence>
-          <details>audio/x-raw, format=(string){ S8, U8, S16LE, S16BE, U16LE, U16BE, S24_32LE, S24_32BE, U24_32LE, U24_32BE, S32LE, S32BE, U32LE, U32BE, S24LE, S24BE, U24LE, U24BE, S20LE, S20BE, U20LE, U20BE, S18LE, S18BE, U18LE, U18BE, F32LE, F32BE, F64LE, F64BE }, layout=(string)interleaved, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 2147483647 ]; audio/x-iec958</details>
+          <details>audio/x-raw, format=(string){ S8, U8, S16LE, S16BE, U16LE, U16BE, S24_32LE, S24_32BE, U24_32LE, U24_32BE, S32LE, S32BE, U32LE, U32BE, S24LE, S24BE, U24LE, U24BE, S20LE, S20BE, U20LE, U20BE, S18LE, S18BE, U18LE, U18BE, F32LE, F32BE, F64LE, F64BE }, layout=(string)interleaved, rate=(int)[ 1, 2147483647 ], channels=(int)[ 1, 2147483647 ]; audio/x-ac3, framed=(boolean)true; audio/x-eac3, framed=(boolean)true; audio/x-dts, framed=(boolean)true, block-size=(int){ 512, 1024, 2048 }; audio/mpeg, mpegversion=(int)1, mpegaudioversion=(int)[ 1, 2 ], parsed=(boolean)true</details>
         </caps>
       </pads>
     </element>
diff --git a/docs/plugins/inspect/plugin-app.xml b/docs/plugins/inspect/plugin-app.xml
index 364438c..2c6d041 100644
--- a/docs/plugins/inspect/plugin-app.xml
+++ b/docs/plugins/inspect/plugin-app.xml
@@ -3,7 +3,7 @@
   <description>Elements used to communicate with applications</description>
   <filename>../../gst/app/.libs/libgstapp.so</filename>
   <basename>libgstapp.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-audioconvert.xml b/docs/plugins/inspect/plugin-audioconvert.xml
index 09451f7..547d1d9 100644
--- a/docs/plugins/inspect/plugin-audioconvert.xml
+++ b/docs/plugins/inspect/plugin-audioconvert.xml
@@ -3,7 +3,7 @@
   <description>Convert audio to different formats</description>
   <filename>../../gst/audioconvert/.libs/libgstaudioconvert.so</filename>
   <basename>libgstaudioconvert.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-audiorate.xml b/docs/plugins/inspect/plugin-audiorate.xml
index eadfe01..f0777ca 100644
--- a/docs/plugins/inspect/plugin-audiorate.xml
+++ b/docs/plugins/inspect/plugin-audiorate.xml
@@ -3,7 +3,7 @@
   <description>Adjusts audio frames</description>
   <filename>../../gst/audiorate/.libs/libgstaudiorate.so</filename>
   <basename>libgstaudiorate.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-audioresample.xml b/docs/plugins/inspect/plugin-audioresample.xml
index e7f5bac..4ef9907 100644
--- a/docs/plugins/inspect/plugin-audioresample.xml
+++ b/docs/plugins/inspect/plugin-audioresample.xml
@@ -3,7 +3,7 @@
   <description>Resamples audio</description>
   <filename>../../gst/audioresample/.libs/libgstaudioresample.so</filename>
   <basename>libgstaudioresample.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-audiotestsrc.xml b/docs/plugins/inspect/plugin-audiotestsrc.xml
index ae4daec..1a7739c 100644
--- a/docs/plugins/inspect/plugin-audiotestsrc.xml
+++ b/docs/plugins/inspect/plugin-audiotestsrc.xml
@@ -3,7 +3,7 @@
   <description>Creates audio test signals of given frequency and volume</description>
   <filename>../../gst/audiotestsrc/.libs/libgstaudiotestsrc.so</filename>
   <basename>libgstaudiotestsrc.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-cdparanoia.xml b/docs/plugins/inspect/plugin-cdparanoia.xml
index f151f5c..d6da423 100644
--- a/docs/plugins/inspect/plugin-cdparanoia.xml
+++ b/docs/plugins/inspect/plugin-cdparanoia.xml
@@ -3,7 +3,7 @@
   <description>Read audio from CD in paranoid mode</description>
   <filename>../../ext/cdparanoia/.libs/libgstcdparanoia.so</filename>
   <basename>libgstcdparanoia.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-encoding.xml b/docs/plugins/inspect/plugin-encoding.xml
index 06870bf..d708431 100644
--- a/docs/plugins/inspect/plugin-encoding.xml
+++ b/docs/plugins/inspect/plugin-encoding.xml
@@ -3,7 +3,7 @@
   <description>various encoding-related elements</description>
   <filename>../../gst/encoding/.libs/libgstencodebin.so</filename>
   <basename>libgstencodebin.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-gdp.xml b/docs/plugins/inspect/plugin-gdp.xml
index 9b84442..b82784c 100644
--- a/docs/plugins/inspect/plugin-gdp.xml
+++ b/docs/plugins/inspect/plugin-gdp.xml
@@ -3,7 +3,7 @@
   <description>Payload/depayload GDP packets</description>
   <filename>../../gst/gdp/.libs/libgstgdp.so</filename>
   <basename>libgstgdp.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-gio.xml b/docs/plugins/inspect/plugin-gio.xml
index c5262a0..0b08649 100644
--- a/docs/plugins/inspect/plugin-gio.xml
+++ b/docs/plugins/inspect/plugin-gio.xml
@@ -3,7 +3,7 @@
   <description>GIO elements</description>
   <filename>../../gst/gio/.libs/libgstgio.so</filename>
   <basename>libgstgio.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-libvisual.xml b/docs/plugins/inspect/plugin-libvisual.xml
index 4541202..ae223f5 100644
--- a/docs/plugins/inspect/plugin-libvisual.xml
+++ b/docs/plugins/inspect/plugin-libvisual.xml
@@ -3,7 +3,7 @@
   <description>libvisual visualization plugins</description>
   <filename>../../ext/libvisual/.libs/libgstlibvisual.so</filename>
   <basename>libgstlibvisual.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-ogg.xml b/docs/plugins/inspect/plugin-ogg.xml
index 1ecc114..2e6a3d4 100644
--- a/docs/plugins/inspect/plugin-ogg.xml
+++ b/docs/plugins/inspect/plugin-ogg.xml
@@ -3,7 +3,7 @@
   <description>ogg stream manipulation (info about ogg: http://xiph.org)</description>
   <filename>../../ext/ogg/.libs/libgstogg.so</filename>
   <basename>libgstogg.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
@@ -41,7 +41,7 @@
           <name>sink</name>
           <direction>sink</direction>
           <presence>always</presence>
-          <details>application/ogg; application/x-annodex</details>
+          <details>application/ogg; audio/ogg; video/ogg; application/kate</details>
         </caps>
         <caps>
           <name>src_%08x</name>
@@ -80,7 +80,7 @@
           <name>src</name>
           <direction>source</direction>
           <presence>always</presence>
-          <details>application/ogg</details>
+          <details>application/ogg; audio/ogg; video/ogg</details>
         </caps>
       </pads>
     </element>
diff --git a/docs/plugins/inspect/plugin-pango.xml b/docs/plugins/inspect/plugin-pango.xml
index 0a25279..b53fe49 100644
--- a/docs/plugins/inspect/plugin-pango.xml
+++ b/docs/plugins/inspect/plugin-pango.xml
@@ -3,7 +3,7 @@
   <description>Pango-based text rendering and overlay</description>
   <filename>../../ext/pango/.libs/libgstpango.so</filename>
   <basename>libgstpango.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-playback.xml b/docs/plugins/inspect/plugin-playback.xml
index f840f01..cad6865 100644
--- a/docs/plugins/inspect/plugin-playback.xml
+++ b/docs/plugins/inspect/plugin-playback.xml
@@ -3,7 +3,7 @@
   <description>various playback elements</description>
   <filename>../../gst/playback/.libs/libgstplayback.so</filename>
   <basename>libgstplayback.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-subparse.xml b/docs/plugins/inspect/plugin-subparse.xml
index 4b2589e..accc0c8 100644
--- a/docs/plugins/inspect/plugin-subparse.xml
+++ b/docs/plugins/inspect/plugin-subparse.xml
@@ -3,7 +3,7 @@
   <description>Subtitle parsing</description>
   <filename>../../gst/subparse/.libs/libgstsubparse.so</filename>
   <basename>libgstsubparse.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-tcp.xml b/docs/plugins/inspect/plugin-tcp.xml
index 76d5753..0ef3862 100644
--- a/docs/plugins/inspect/plugin-tcp.xml
+++ b/docs/plugins/inspect/plugin-tcp.xml
@@ -3,7 +3,7 @@
   <description>transfer data over the network via TCP</description>
   <filename>../../gst/tcp/.libs/libgsttcp.so</filename>
   <basename>libgsttcp.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-theora.xml b/docs/plugins/inspect/plugin-theora.xml
index db0d35e..c4a372f 100644
--- a/docs/plugins/inspect/plugin-theora.xml
+++ b/docs/plugins/inspect/plugin-theora.xml
@@ -3,7 +3,7 @@
   <description>Theora plugin library</description>
   <filename>../../ext/theora/.libs/libgsttheora.so</filename>
   <basename>libgsttheora.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-typefindfunctions.xml b/docs/plugins/inspect/plugin-typefindfunctions.xml
index 6021f0b..e080515 100644
--- a/docs/plugins/inspect/plugin-typefindfunctions.xml
+++ b/docs/plugins/inspect/plugin-typefindfunctions.xml
@@ -3,7 +3,7 @@
   <description>default typefind functions</description>
   <filename>../../gst/typefind/.libs/libgsttypefindfunctions.so</filename>
   <basename>libgsttypefindfunctions.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-videoconvert.xml b/docs/plugins/inspect/plugin-videoconvert.xml
index 31eb157..1d41c6c 100644
--- a/docs/plugins/inspect/plugin-videoconvert.xml
+++ b/docs/plugins/inspect/plugin-videoconvert.xml
@@ -3,7 +3,7 @@
   <description>Colorspace conversion</description>
   <filename>../../gst/videoconvert/.libs/libgstvideoconvert.so</filename>
   <basename>libgstvideoconvert.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package></package>
@@ -20,13 +20,13 @@
           <name>sink</name>
           <direction>sink</direction>
           <presence>always</presence>
-          <details>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, Y800, Y16, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8_PALETTED, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</details>
+          <details>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</details>
         </caps>
         <caps>
           <name>src</name>
           <direction>source</direction>
           <presence>always</presence>
-          <details>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, Y800, Y16, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8_PALETTED, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</details>
+          <details>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</details>
         </caps>
       </pads>
     </element>
diff --git a/docs/plugins/inspect/plugin-videorate.xml b/docs/plugins/inspect/plugin-videorate.xml
index d632306..1c67f07 100644
--- a/docs/plugins/inspect/plugin-videorate.xml
+++ b/docs/plugins/inspect/plugin-videorate.xml
@@ -3,7 +3,7 @@
   <description>Adjusts video frames</description>
   <filename>../../gst/videorate/.libs/libgstvideorate.so</filename>
   <basename>libgstvideorate.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-videoscale.xml b/docs/plugins/inspect/plugin-videoscale.xml
index 3dca9e0..cf3d112 100644
--- a/docs/plugins/inspect/plugin-videoscale.xml
+++ b/docs/plugins/inspect/plugin-videoscale.xml
@@ -3,7 +3,7 @@
   <description>Resizes video</description>
   <filename>../../gst/videoscale/.libs/libgstvideoscale.so</filename>
   <basename>libgstvideoscale.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-videotestsrc.xml b/docs/plugins/inspect/plugin-videotestsrc.xml
index 85ce07f..3fa2a1f 100644
--- a/docs/plugins/inspect/plugin-videotestsrc.xml
+++ b/docs/plugins/inspect/plugin-videotestsrc.xml
@@ -3,7 +3,7 @@
   <description>Creates a test video stream</description>
   <filename>../../gst/videotestsrc/.libs/libgstvideotestsrc.so</filename>
   <basename>libgstvideotestsrc.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
@@ -20,7 +20,7 @@
           <name>src</name>
           <direction>source</direction>
           <presence>always</presence>
-          <details>video/x-raw, format=(string)YUY2, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)UYVY, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)YVYU, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)v308, colorimetry=(string){ bt601, bt709 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)AYUV, colorimetry=(string){ bt601, bt709 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)v210, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)v216, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)UYVP, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)AY64, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)YVU9, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)YUV9, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)YV12, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)I420, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)NV12, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)NV21, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)Y41B, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)Y42B, colorimetry=(string){ bt601, bt709 }, chroma-site=(string){ mpeg2, jpeg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)Y444, colorimetry=(string){ bt601, bt709 }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)Y800, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)GRAY8, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)GRAY16_LE, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)xRGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)xBGR, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)RGBx, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)BGRx, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)ARGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)ABGR, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)RGBA, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)BGRA, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)RGB, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)BGR, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)RGB16, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)RGB15, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-raw, format=(string)ARGB64, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-bayer, format=(string)bggr, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-bayer, format=(string)rggb, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-bayer, format=(string)grbg, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-bayer, format=(string)gbrg, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</details>
+          <details>video/x-raw, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]; video/x-bayer, format=(string){ bggr, rggb, grbg, gbrg }, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)[ 0/1, 2147483647/1 ]</details>
         </caps>
       </pads>
     </element>
diff --git a/docs/plugins/inspect/plugin-volume.xml b/docs/plugins/inspect/plugin-volume.xml
index d2350d9..9ffc50d 100644
--- a/docs/plugins/inspect/plugin-volume.xml
+++ b/docs/plugins/inspect/plugin-volume.xml
@@ -3,7 +3,7 @@
   <description>plugin for controlling audio volume</description>
   <filename>../../gst/volume/.libs/libgstvolume.so</filename>
   <basename>libgstvolume.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-vorbis.xml b/docs/plugins/inspect/plugin-vorbis.xml
index bf843a4..b467aa8 100644
--- a/docs/plugins/inspect/plugin-vorbis.xml
+++ b/docs/plugins/inspect/plugin-vorbis.xml
@@ -3,7 +3,7 @@
   <description>Vorbis plugin library</description>
   <filename>../../ext/vorbis/.libs/libgstvorbis.so</filename>
   <basename>libgstvorbis.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-ximagesink.xml b/docs/plugins/inspect/plugin-ximagesink.xml
index c36e819..dd2b171 100644
--- a/docs/plugins/inspect/plugin-ximagesink.xml
+++ b/docs/plugins/inspect/plugin-ximagesink.xml
@@ -3,7 +3,7 @@
   <description>X11 video output element based on standard Xlib calls</description>
   <filename>../../sys/ximage/.libs/libgstximagesink.so</filename>
   <basename>libgstximagesink.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/docs/plugins/inspect/plugin-xvimagesink.xml b/docs/plugins/inspect/plugin-xvimagesink.xml
index 4f32945..a48a957 100644
--- a/docs/plugins/inspect/plugin-xvimagesink.xml
+++ b/docs/plugins/inspect/plugin-xvimagesink.xml
@@ -3,7 +3,7 @@
   <description>XFree86 video output plugin using Xv extension</description>
   <filename>../../sys/xvimage/.libs/libgstxvimagesink.so</filename>
   <basename>libgstxvimagesink.so</basename>
-  <version>0.11.90</version>
+  <version>0.11.92</version>
   <license>LGPL</license>
   <source>gst-plugins-base</source>
   <package>GStreamer Base Plug-ins source release</package>
diff --git a/ext/Makefile.in b/ext/Makefile.in
index 76df459..7a0af01 100644
--- a/ext/Makefile.in
+++ b/ext/Makefile.in
@@ -55,6 +55,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/parallel-subdirs.mak
 subdir = ext
@@ -256,8 +257,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -428,7 +435,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/alsa/Makefile.in b/ext/alsa/Makefile.in
index 58546bc..e44a10c 100644
--- a/ext/alsa/Makefile.in
+++ b/ext/alsa/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = ext/alsa
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -280,8 +281,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -452,7 +459,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/alsa/gstalsa.c b/ext/alsa/gstalsa.c
index c1529af..e1aed95 100644
--- a/ext/alsa/gstalsa.c
+++ b/ext/alsa/gstalsa.c
@@ -398,7 +398,7 @@
 }
 
 snd_pcm_t *
-gst_alsa_open_iec958_pcm (GstObject * obj)
+gst_alsa_open_iec958_pcm (GstObject * obj, gchar * device)
 {
   char *iec958_pcm_name = NULL;
   snd_pcm_t *pcm = NULL;
@@ -417,7 +417,8 @@
    *    spdif:{AES0 0x2 AES1 0x82 AES2 0x0 AES3 0x2}
    */
   sprintf (devstr,
-      "iec958:{AES0 0x%02x AES1 0x%02x AES2 0x%02x AES3 0x%02x}",
+      "%s:{AES0 0x%02x AES1 0x%02x AES2 0x%02x AES3 0x%02x}",
+      device,
       IEC958_AES0_CON_EMPHASIS_NONE | IEC958_AES0_NONAUDIO,
       IEC958_AES1_CON_ORIGINAL | IEC958_AES1_CON_PCM_CODER,
       0, IEC958_AES3_CON_FS_48000);
@@ -445,8 +446,8 @@
  */
 
 GstCaps *
-gst_alsa_probe_supported_formats (GstObject * obj, snd_pcm_t * handle,
-    const GstCaps * template_caps)
+gst_alsa_probe_supported_formats (GstObject * obj, gchar * device,
+    snd_pcm_t * handle, const GstCaps * template_caps)
 {
   snd_pcm_hw_params_t *hw_params;
   snd_pcm_stream_t stream_type;
@@ -473,7 +474,7 @@
   /* Try opening IEC958 device to see if we can support that format (playback
    * only for now but we could add SPDIF capture later) */
   if (stream_type == SND_PCM_STREAM_PLAYBACK) {
-    snd_pcm_t *pcm = gst_alsa_open_iec958_pcm (obj);
+    snd_pcm_t *pcm = gst_alsa_open_iec958_pcm (obj, device);
 
     if (G_LIKELY (pcm)) {
       gst_caps_append (caps, gst_caps_from_string (PASSTHROUGH_CAPS));
diff --git a/ext/alsa/gstalsa.h b/ext/alsa/gstalsa.h
index 3f4aa87..ff8791b 100644
--- a/ext/alsa/gstalsa.h
+++ b/ext/alsa/gstalsa.h
@@ -51,9 +51,10 @@
 GST_DEBUG_CATEGORY_EXTERN (alsa_debug);
 #define GST_CAT_DEFAULT alsa_debug
 
-snd_pcm_t * gst_alsa_open_iec958_pcm (GstObject * obj);
+snd_pcm_t * gst_alsa_open_iec958_pcm (GstObject * obj, gchar *device);
 
 GstCaps * gst_alsa_probe_supported_formats (GstObject      * obj,
+                                            gchar          * device,
                                             snd_pcm_t      * handle,
                                             const GstCaps  * template_caps);
 
diff --git a/ext/alsa/gstalsasink.c b/ext/alsa/gstalsasink.c
index 97fd6b5..8fb7891 100644
--- a/ext/alsa/gstalsasink.c
+++ b/ext/alsa/gstalsasink.c
@@ -300,8 +300,8 @@
   g_return_val_if_fail (pad_template != NULL, NULL);
 
   templ_caps = gst_pad_template_get_caps (pad_template);
-  caps = gst_alsa_probe_supported_formats (GST_OBJECT (sink), sink->handle,
-      templ_caps);
+  caps = gst_alsa_probe_supported_formats (GST_OBJECT (sink), sink->device,
+      sink->handle, templ_caps);
   gst_caps_unref (templ_caps);
 
   if (caps) {
@@ -852,9 +852,9 @@
 
   alsa = GST_ALSA_SINK (asink);
 
-  if (spec->type == GST_AUDIO_RING_BUFFER_FORMAT_TYPE_IEC958) {
+  if (alsa->iec958) {
     snd_pcm_close (alsa->handle);
-    alsa->handle = gst_alsa_open_iec958_pcm (GST_OBJECT (alsa));
+    alsa->handle = gst_alsa_open_iec958_pcm (GST_OBJECT (alsa), alsa->device);
     if (G_UNLIKELY (!alsa->handle)) {
       goto no_iec958;
     }
diff --git a/ext/alsa/gstalsasrc.c b/ext/alsa/gstalsasrc.c
index 20e6e15..55eaedc 100644
--- a/ext/alsa/gstalsasrc.c
+++ b/ext/alsa/gstalsasrc.c
@@ -267,8 +267,8 @@
   templ_caps = gst_pad_template_get_caps (pad_template);
   GST_INFO_OBJECT (src, "template caps %" GST_PTR_FORMAT, templ_caps);
 
-  caps = gst_alsa_probe_supported_formats (GST_OBJECT (src), src->handle,
-      templ_caps);
+  caps = gst_alsa_probe_supported_formats (GST_OBJECT (src),
+      src->device, src->handle, templ_caps);
   gst_caps_unref (templ_caps);
 
   if (caps) {
diff --git a/ext/cdparanoia/Makefile.in b/ext/cdparanoia/Makefile.in
index 3a44526..63d868a 100644
--- a/ext/cdparanoia/Makefile.in
+++ b/ext/cdparanoia/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = ext/cdparanoia
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -280,8 +281,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -452,7 +459,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/cdparanoia/gstcdparanoiasrc.c b/ext/cdparanoia/gstcdparanoiasrc.c
index f90030b..66a75b2 100644
--- a/ext/cdparanoia/gstcdparanoiasrc.c
+++ b/ext/cdparanoia/gstcdparanoiasrc.c
@@ -26,6 +26,7 @@
 
 #include <string.h>
 #include <errno.h>
+#include <stdio.h>
 
 #include "gstcdparanoiasrc.h"
 #include "gst/gst-i18n-plugin.h"
@@ -142,8 +143,9 @@
           G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
   g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_READ_SPEED,
       g_param_spec_int ("read-speed", "Read speed",
-          "Read from device at specified speed", -1, G_MAXINT,
-          DEFAULT_READ_SPEED, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
+          "Read from device at specified speed (-1 and 0 = full speed)",
+          -1, G_MAXINT, DEFAULT_READ_SPEED,
+          G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
   g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_PARANOIA_MODE,
       g_param_spec_flags ("paranoia-mode", "Paranoia mode",
           "Type of checking to perform", GST_TYPE_CD_PARANOIA_MODE,
@@ -227,9 +229,8 @@
   if (cdda_open (src->d))
     goto open_failed;
 
-  if (src->read_speed != -1) {
-    cdda_speed_set (src->d, src->read_speed);
-  }
+  GST_INFO_OBJECT (src, "set read speed to %d", src->read_speed);
+  cdda_speed_set (src->d, src->read_speed);
 
   for (i = 1; i < src->d->tracks + 1; i++) {
     GstAudioCdSrcTrack track = { 0, };
diff --git a/ext/libvisual/Makefile.in b/ext/libvisual/Makefile.in
index ce06c76..3b0178b 100644
--- a/ext/libvisual/Makefile.in
+++ b/ext/libvisual/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = ext/libvisual
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -276,8 +277,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -448,7 +455,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/libvisual/visual.c b/ext/libvisual/visual.c
index de6aed2..39c7e4d 100644
--- a/ext/libvisual/visual.c
+++ b/ext/libvisual/visual.c
@@ -27,6 +27,7 @@
 #include <gst/video/gstvideopool.h>
 #include <gst/audio/audio.h>
 #include <libvisual/libvisual.h>
+#include <string.h>
 
 #define GST_TYPE_VISUAL (gst_visual_get_type())
 #define GST_IS_VISUAL(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_VISUAL))
diff --git a/ext/ogg/Makefile.in b/ext/ogg/Makefile.in
index f0d16b4..2b574cb 100644
--- a/ext/ogg/Makefile.in
+++ b/ext/ogg/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = ext/ogg
 DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -284,8 +285,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -456,7 +463,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/ogg/gstoggdemux.c b/ext/ogg/gstoggdemux.c
index cc09cf3..031c25d 100644
--- a/ext/ogg/gstoggdemux.c
+++ b/ext/ogg/gstoggdemux.c
@@ -176,8 +176,6 @@
       GST_DEBUG_FUNCPTR (gst_ogg_pad_src_query));
   gst_pad_use_fixed_caps (GST_PAD (pad));
 
-  pad->mode = GST_OGG_PAD_MODE_INIT;
-
   pad->current_granule = -1;
   pad->keyframe_granule = -1;
 
@@ -303,11 +301,23 @@
         gboolean seekable = FALSE;
         gint64 stop = -1;
 
+        GST_CHAIN_LOCK (ogg);
         if (ogg->pullmode) {
           seekable = TRUE;
           stop = ogg->total_time;
         } else if (ogg->push_disable_seeking) {
           seekable = FALSE;
+        } else if (ogg->current_chain == NULL) {
+          GstQuery *squery;
+
+          /* assume we can seek if upstream is seekable in BYTES format */
+          GST_LOG_OBJECT (ogg, "no current chain, check upstream seekability");
+          squery = gst_query_new_seeking (GST_FORMAT_BYTES);
+          if (gst_pad_peer_query (ogg->sinkpad, squery))
+            gst_query_parse_seeking (squery, NULL, &seekable, NULL, NULL);
+          else
+            seekable = FALSE;
+          gst_query_unref (squery);
         } else if (ogg->current_chain->streams->len) {
           gint i;
 
@@ -336,6 +346,7 @@
         }
 
         gst_query_set_seeking (query, GST_FORMAT_TIME, seekable, 0, stop);
+        GST_CHAIN_UNLOCK (ogg);
       } else {
         res = FALSE;
       }
@@ -545,8 +556,15 @@
     out_offset_end = -1;
   } else {
     if (packet->granulepos != -1) {
-      pad->current_granule = gst_ogg_stream_granulepos_to_granule (&pad->map,
+      gint64 granule = gst_ogg_stream_granulepos_to_granule (&pad->map,
           packet->granulepos);
+      if (granule < 0) {
+        GST_ERROR_OBJECT (ogg,
+            "granulepos %" G_GINT64_FORMAT " yielded granule %" G_GINT64_FORMAT,
+            packet->granulepos, granule);
+        return GST_FLOW_ERROR;
+      }
+      pad->current_granule = granule;
       pad->keyframe_granule =
           gst_ogg_stream_granulepos_to_key_granule (&pad->map,
           packet->granulepos);
@@ -767,9 +785,8 @@
   return sync_time;
 }
 
-/* submit a packet to the oggpad, this function will run the
- * typefind code for the pad if this is the first packet for this
- * stream 
+/* submit a packet to the oggpad, this function will run the type detection
+ * code for the pad if this is the first packet for this stream
  */
 static GstFlowReturn
 gst_ogg_pad_submit_packet (GstOggPad * pad, ogg_packet * packet)
@@ -856,6 +873,11 @@
   if (granule != -1) {
     GST_DEBUG_OBJECT (ogg, "%p has granulepos %" G_GINT64_FORMAT, pad, granule);
     pad->current_granule = granule;
+  } else if (granule != -1) {
+    GST_ERROR_OBJECT (ogg,
+        "granulepos %" G_GINT64_FORMAT " yielded granule %" G_GINT64_FORMAT,
+        packet->granulepos, granule);
+    return GST_FLOW_ERROR;
   }
 
   /* restart header packet count when seeing a b_o_s page;
@@ -893,11 +915,23 @@
 
         granule = gst_ogg_stream_granulepos_to_granule (&pad->map,
             packet->granulepos);
+        if (granule < 0) {
+          GST_ERROR_OBJECT (ogg,
+              "granulepos %" G_GINT64_FORMAT " yielded granule %"
+              G_GINT64_FORMAT, packet->granulepos, granule);
+          return GST_FLOW_ERROR;
+        }
 
-        if (granule > pad->map.accumulated_granule)
+        if (granule >= pad->map.accumulated_granule)
           start_granule = granule - pad->map.accumulated_granule;
-        else
-          start_granule = 0;
+        else {
+          if (pad->map.forbid_start_clamping) {
+            GST_ERROR_OBJECT (ogg, "Start of stream maps to negative time");
+            return GST_FLOW_ERROR;
+          } else {
+            start_granule = 0;
+          }
+        }
 
         pad->start_time = gst_ogg_stream_granule_to_time (&pad->map,
             start_granule);
@@ -1915,9 +1949,7 @@
     GST_STATIC_PAD_TEMPLATE ("sink",
     GST_PAD_SINK,
     GST_PAD_ALWAYS,
-    GST_STATIC_CAPS ("application/ogg; audio/ogg; video/ogg; "
-        "application/annodex; audio/annodex; video/annodex; "
-        "application/kate")
+    GST_STATIC_CAPS ("application/ogg; audio/ogg; video/ogg; application/kate")
     );
 
 static void gst_ogg_demux_finalize (GObject * object);
@@ -2552,7 +2584,7 @@
     gst_ogg_pad_mark_discont (pad);
     pad->last_ret = GST_FLOW_OK;
 
-    if (pad->map.is_skeleton || pad->added
+    if (pad->map.is_skeleton || pad->map.is_cmml || pad->added
         || !gst_pad_has_current_caps (GST_PAD_CAST (pad)))
       continue;
 
@@ -2583,7 +2615,7 @@
     gst_ogg_demux_send_event (ogg, event);
 
     tags = gst_tag_list_new (GST_TAG_CONTAINER_FORMAT, "Ogg", NULL);
-    gst_ogg_demux_send_event (ogg, gst_event_new_tag (tags));
+    gst_ogg_demux_send_event (ogg, gst_event_new_tag ("GstDemuxer", tags));
   }
 
   GST_DEBUG_OBJECT (ogg, "starting chain");
@@ -2599,7 +2631,7 @@
     if (pad->map.taglist) {
       GST_DEBUG_OBJECT (ogg, "pushing tags");
       gst_pad_push_event (GST_PAD_CAST (pad),
-          gst_event_new_tag (pad->map.taglist));
+          gst_event_new_tag ("GstDemuxer", pad->map.taglist));
       pad->map.taglist = NULL;
     }
 
@@ -2873,7 +2905,7 @@
     if (pad == NULL)
       continue;
 
-    if (pad->map.is_skeleton)
+    if (pad->map.is_skeleton || pad->map.is_cmml)
       goto next;
 
     granulepos = ogg_page_granulepos (&og);
@@ -3571,9 +3603,8 @@
  * structure with the results. 
  * 
  * This function will also read N pages from each stream in the
- * chain and submit them to the decoders. When the decoder has
- * decoded the first buffer, we know the timestamp of the first
- * page in the chain.
+ * chain and submit them to the internal ogg stream parser/mapper
+ * until we know the timestamp of the first page in the chain.
  */
 static GstFlowReturn
 gst_ogg_demux_read_chain (GstOggDemux * ogg, GstOggChain ** res_chain)
@@ -3587,8 +3618,8 @@
 
   GST_LOG_OBJECT (ogg, "reading chain at %" G_GINT64_FORMAT, offset);
 
-  /* first read the BOS pages, do typefind on them, create
-   * the decoders, send data to the decoders. */
+  /* first read the BOS pages, detect the stream types, create the internal
+   * stream mappers, send data to them. */
   while (TRUE) {
     GstOggPad *pad;
     guint32 serial;
@@ -3647,11 +3678,10 @@
   }
 
   chain->have_bos = TRUE;
-  GST_LOG_OBJECT (ogg, "read bos pages, init decoder now");
+  GST_INFO_OBJECT (ogg, "read bos pages, ");
 
-  /* now read pages until we receive a buffer from each of the
-   * stream decoders, this will tell us the timestamp of the
-   * first packet in the chain then */
+  /* now read pages until each ogg stream mapper has figured out the
+   * timestamp of the first packet in the chain */
 
   /* save the offset to the first non bos page in the chain: if searching for
    * pad->first_time we read past the end of the chain, we'll seek back to this
@@ -3678,7 +3708,7 @@
         known_serial = TRUE;
 
         /* submit the page now, this will fill in the start_time when the
-         * internal decoder finds it */
+         * internal stream mapper finds it */
         gst_ogg_pad_submit_page (pad, &og);
 
         if (!pad->map.is_skeleton && pad->start_time == -1
@@ -3714,15 +3744,6 @@
     }
   }
   GST_LOG_OBJECT (ogg, "done reading chain");
-  /* now we can fill in the missing info using queries */
-  for (i = 0; i < chain->streams->len; i++) {
-    GstOggPad *pad = g_array_index (chain->streams, GstOggPad *, i);
-
-    if (pad->map.is_skeleton)
-      continue;
-
-    pad->mode = GST_OGG_PAD_MODE_STREAMING;
-  }
 
   if (res_chain)
     *res_chain = chain;
diff --git a/ext/ogg/gstoggdemux.h b/ext/ogg/gstoggdemux.h
index 62e678c..017c43f 100644
--- a/ext/ogg/gstoggdemux.h
+++ b/ext/ogg/gstoggdemux.h
@@ -74,20 +74,12 @@
                                    streams. */
 };
 
-/* different modes for the pad */
-typedef enum
-{
-  GST_OGG_PAD_MODE_INIT,        /* we are feeding our internal decoder to get info */
-  GST_OGG_PAD_MODE_STREAMING,   /* we are streaming buffers to the outside */
-} GstOggPadMode;
-
 /* all information needed for one ogg stream */
 struct _GstOggPad
 {
   GstPad pad;                   /* subclass GstPad */
 
   gboolean have_type;
-  GstOggPadMode mode;
 
   GstOggChain *chain;           /* the chain we are part of */
   GstOggDemux *ogg;             /* the ogg demuxer we are part of */
diff --git a/ext/ogg/gstoggstream.c b/ext/ogg/gstoggstream.c
index 460f507..3b9bd3e 100644
--- a/ext/ogg/gstoggstream.c
+++ b/ext/ogg/gstoggstream.c
@@ -1717,6 +1717,7 @@
   pad->caps = gst_caps_new_empty_simple ("text/x-cmml");
   pad->always_flush_page = TRUE;
   pad->is_sparse = TRUE;
+  pad->is_cmml = TRUE;
 
   return TRUE;
 }
@@ -1872,6 +1873,8 @@
   pad->granulerate_d = 1;
   pad->granuleshift = 0;
   pad->n_header_packets = 2;
+  pad->first_granpos = -1;
+  pad->forbid_start_clamping = TRUE;
 
   /* pre-skip is in samples at 48000 Hz, which matches granule one for one */
   pad->granule_offset = -GST_READ_UINT16_LE (packet->packet + 10);
@@ -1890,6 +1893,29 @@
 }
 
 static gint64
+granulepos_to_granule_opus (GstOggStream * pad, gint64 granulepos)
+{
+  if (granulepos == -1)
+    return -1;
+
+  /* We must reject some particular cases for the first granpos */
+
+  if (pad->first_granpos < 0 || granulepos < pad->first_granpos)
+    pad->first_granpos = granulepos;
+
+  if (pad->first_granpos == granulepos) {
+    if (granulepos < -pad->granule_offset) {
+      GST_ERROR ("Invalid Opus stream: first granulepos (%" G_GINT64_FORMAT
+          ") less than preskip (%" G_GINT64_FORMAT ")", granulepos,
+          -pad->granule_offset);
+      return -1;
+    }
+  }
+
+  return granulepos;
+}
+
+static gint64
 packet_duration_opus (GstOggStream * pad, ogg_packet * packet)
 {
   static const guint64 durations[32] = {
@@ -2146,7 +2172,7 @@
     "OpusHead", 8, 0,
     "audio/x-opus",
     setup_opus_mapper,
-    granulepos_to_granule_default,
+    granulepos_to_granule_opus,
     granule_to_granulepos_default,
     NULL,
     NULL,
diff --git a/ext/ogg/gstoggstream.h b/ext/ogg/gstoggstream.h
index c06bc51..19ecb17 100644
--- a/ext/ogg/gstoggstream.h
+++ b/ext/ogg/gstoggstream.h
@@ -70,6 +70,7 @@
   gint bitrate;
   guint64 total_time;
   gboolean is_sparse;
+  gboolean forbid_start_clamping;
 
   GstCaps *caps;
 
@@ -93,9 +94,13 @@
   gboolean theora_has_zero_keyoffset;
   /* VP8 stuff */
   gboolean is_vp8;
+  /* opus stuff */
+  gint64 first_granpos;
   /* OGM stuff */
   gboolean is_ogm;
   gboolean is_ogm_text;
+  /* CMML */
+  gboolean is_cmml;
   /* fishead stuff */
   guint16 skeleton_major, skeleton_minor;
   gint64 prestime;
diff --git a/ext/ogg/gstogmparse.c b/ext/ogg/gstogmparse.c
index b8bd212..0b6024a 100644
--- a/ext/ogg/gstogmparse.c
+++ b/ext/ogg/gstogmparse.c
@@ -659,7 +659,7 @@
       GstTagList *tags;
 
       tags = gst_tag_list_new (GST_TAG_SUBTITLE_CODEC, "Ogm", NULL);
-      gst_pad_push_event (ogm->srcpad, gst_event_new_tag (tags));
+      gst_pad_push_event (ogm->srcpad, gst_event_new_tag ("GstParser", tags));
     }
   }
 
@@ -701,7 +701,7 @@
 
     if (tags) {
       GST_DEBUG_OBJECT (ogm, "tags = %" GST_PTR_FORMAT, tags);
-      gst_pad_push_event (ogm->srcpad, gst_event_new_tag (tags));
+      gst_pad_push_event (ogm->srcpad, gst_event_new_tag ("GstParser", tags));
     } else {
       GST_DEBUG_OBJECT (ogm, "failed to extract tags from vorbis comment");
     }
diff --git a/ext/pango/Makefile.in b/ext/pango/Makefile.in
index e38d6c3..faddfe7 100644
--- a/ext/pango/Makefile.in
+++ b/ext/pango/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = ext/pango
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -283,8 +284,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -455,7 +462,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/pango/gstbasetextoverlay.c b/ext/pango/gstbasetextoverlay.c
index 7788d2c..5e12d50 100644
--- a/ext/pango/gstbasetextoverlay.c
+++ b/ext/pango/gstbasetextoverlay.c
@@ -293,10 +293,13 @@
   return base_text_overlay_line_align_type;
 }
 
-#define GST_BASE_TEXT_OVERLAY_GET_COND(ov) (((GstBaseTextOverlay *)ov)->cond)
-#define GST_BASE_TEXT_OVERLAY_WAIT(ov)     (g_cond_wait (&GST_BASE_TEXT_OVERLAY_GET_COND (ov), GST_OBJECT_GET_LOCK (ov)))
-#define GST_BASE_TEXT_OVERLAY_SIGNAL(ov)   (g_cond_signal (&GST_BASE_TEXT_OVERLAY_GET_COND (ov)))
-#define GST_BASE_TEXT_OVERLAY_BROADCAST(ov)(g_cond_broadcast (&GST_BASE_TEXT_OVERLAY_GET_COND (ov)))
+#define GST_BASE_TEXT_OVERLAY_GET_LOCK(ov) (&GST_BASE_TEXT_OVERLAY (ov)->lock)
+#define GST_BASE_TEXT_OVERLAY_GET_COND(ov) (&GST_BASE_TEXT_OVERLAY (ov)->cond)
+#define GST_BASE_TEXT_OVERLAY_LOCK(ov)     (g_mutex_lock (GST_BASE_TEXT_OVERLAY_GET_LOCK (ov)))
+#define GST_BASE_TEXT_OVERLAY_UNLOCK(ov)   (g_mutex_unlock (GST_BASE_TEXT_OVERLAY_GET_LOCK (ov)))
+#define GST_BASE_TEXT_OVERLAY_WAIT(ov)     (g_cond_wait (GST_BASE_TEXT_OVERLAY_GET_COND (ov), GST_BASE_TEXT_OVERLAY_GET_LOCK (ov)))
+#define GST_BASE_TEXT_OVERLAY_SIGNAL(ov)   (g_cond_signal (GST_BASE_TEXT_OVERLAY_GET_COND (ov)))
+#define GST_BASE_TEXT_OVERLAY_BROADCAST(ov)(g_cond_broadcast (GST_BASE_TEXT_OVERLAY_GET_COND (ov)))
 
 static GstElementClass *parent_class = NULL;
 static void gst_base_text_overlay_base_init (gpointer g_class);
@@ -599,6 +602,7 @@
     overlay->text_buffer = NULL;
   }
 
+  g_mutex_clear (&overlay->lock);
   g_cond_clear (&overlay->cond);
 
   G_OBJECT_CLASS (parent_class)->finalize (object);
@@ -689,6 +693,7 @@
 
   overlay->text_buffer = NULL;
   overlay->text_linked = FALSE;
+  g_mutex_init (&overlay->lock);
   g_cond_init (&overlay->cond);
   gst_segment_init (&overlay->segment, GST_FORMAT_TIME);
   g_mutex_unlock (GST_BASE_TEXT_OVERLAY_GET_CLASS (overlay)->pango_lock);
@@ -771,11 +776,11 @@
   ret = gst_pad_push_event (overlay->srcpad, gst_event_new_caps (caps));
 
   if (ret) {
-    GST_OBJECT_LOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_LOCK (overlay);
     g_mutex_lock (GST_BASE_TEXT_OVERLAY_GET_CLASS (overlay)->pango_lock);
     gst_base_text_overlay_update_wrap_mode (overlay);
     g_mutex_unlock (GST_BASE_TEXT_OVERLAY_GET_CLASS (overlay)->pango_lock);
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
   }
 
   return ret;
@@ -794,7 +799,7 @@
 {
   GstBaseTextOverlay *overlay = GST_BASE_TEXT_OVERLAY (object);
 
-  GST_OBJECT_LOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_LOCK (overlay);
   switch (prop_id) {
     case PROP_TEXT:
       g_free (overlay->default_text);
@@ -918,7 +923,7 @@
   }
 
   overlay->need_render = TRUE;
-  GST_OBJECT_UNLOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
 }
 
 static void
@@ -927,7 +932,7 @@
 {
   GstBaseTextOverlay *overlay = GST_BASE_TEXT_OVERLAY (object);
 
-  GST_OBJECT_LOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_LOCK (overlay);
   switch (prop_id) {
     case PROP_TEXT:
       g_value_set_string (value, overlay->default_text);
@@ -989,7 +994,7 @@
   }
 
   overlay->need_render = TRUE;
-  GST_OBJECT_UNLOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
 }
 
 static gboolean
@@ -1050,11 +1055,11 @@
         gst_pad_push_event (overlay->srcpad, gst_event_new_flush_start ());
 
       /* Mark ourself as flushing, unblock chains */
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       overlay->video_flushing = TRUE;
       overlay->text_flushing = TRUE;
       gst_base_text_overlay_pop_text (overlay);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
 
       /* Seek on each sink pad */
       gst_event_ref (event);
@@ -2173,11 +2178,11 @@
       gst_event_parse_segment (event, &segment);
 
       if (segment->format == GST_FORMAT_TIME) {
-        GST_OBJECT_LOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_LOCK (overlay);
         gst_segment_copy_into (segment, &overlay->text_segment);
         GST_DEBUG_OBJECT (overlay, "TEXT SEGMENT now: %" GST_SEGMENT_FORMAT,
             &overlay->text_segment);
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       } else {
         GST_ELEMENT_WARNING (overlay, STREAM, MUX, (NULL),
             ("received non-TIME newsegment event on text input"));
@@ -2188,39 +2193,39 @@
 
       /* wake up the video chain, it might be waiting for a text buffer or
        * a text segment update */
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       GST_BASE_TEXT_OVERLAY_BROADCAST (overlay);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       break;
     }
     case GST_EVENT_FLUSH_STOP:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       GST_INFO_OBJECT (overlay, "text flush stop");
       overlay->text_flushing = FALSE;
       overlay->text_eos = FALSE;
       gst_base_text_overlay_pop_text (overlay);
       gst_segment_init (&overlay->text_segment, GST_FORMAT_TIME);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       gst_event_unref (event);
       ret = TRUE;
       break;
     case GST_EVENT_FLUSH_START:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       GST_INFO_OBJECT (overlay, "text flush start");
       overlay->text_flushing = TRUE;
       GST_BASE_TEXT_OVERLAY_BROADCAST (overlay);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       gst_event_unref (event);
       ret = TRUE;
       break;
     case GST_EVENT_EOS:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       overlay->text_eos = TRUE;
       GST_INFO_OBJECT (overlay, "text EOS");
       /* wake up the video chain, it might be waiting for a text buffer or
        * a text segment update */
       GST_BASE_TEXT_OVERLAY_BROADCAST (overlay);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       gst_event_unref (event);
       ret = TRUE;
       break;
@@ -2275,27 +2280,27 @@
       break;
     }
     case GST_EVENT_EOS:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       GST_INFO_OBJECT (overlay, "video EOS");
       overlay->video_eos = TRUE;
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       ret = gst_pad_event_default (pad, parent, event);
       break;
     case GST_EVENT_FLUSH_START:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       GST_INFO_OBJECT (overlay, "video flush start");
       overlay->video_flushing = TRUE;
       GST_BASE_TEXT_OVERLAY_BROADCAST (overlay);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       ret = gst_pad_event_default (pad, parent, event);
       break;
     case GST_EVENT_FLUSH_STOP:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       GST_INFO_OBJECT (overlay, "video flush stop");
       overlay->video_flushing = FALSE;
       overlay->video_eos = FALSE;
       gst_segment_init (&overlay->segment, GST_FORMAT_TIME);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       ret = gst_pad_event_default (pad, parent, event);
       break;
     default:
@@ -2366,17 +2371,17 @@
 
   overlay = GST_BASE_TEXT_OVERLAY (parent);
 
-  GST_OBJECT_LOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_LOCK (overlay);
 
   if (overlay->text_flushing) {
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
     ret = GST_FLOW_FLUSHING;
     GST_LOG_OBJECT (overlay, "text flushing");
     goto beach;
   }
 
   if (overlay->text_eos) {
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
     ret = GST_FLOW_EOS;
     GST_LOG_OBJECT (overlay, "text EOS");
     goto beach;
@@ -2415,7 +2420,7 @@
       GST_BASE_TEXT_OVERLAY_WAIT (overlay);
       GST_DEBUG ("Pad %s:%s resuming", GST_DEBUG_PAD_NAME (pad));
       if (overlay->text_flushing) {
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
         ret = GST_FLOW_FLUSHING;
         goto beach;
       }
@@ -2432,7 +2437,7 @@
     GST_BASE_TEXT_OVERLAY_BROADCAST (overlay);
   }
 
-  GST_OBJECT_UNLOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
 
 beach:
 
@@ -2515,7 +2520,7 @@
 
 wait_for_text_buf:
 
-  GST_OBJECT_LOCK (overlay);
+  GST_BASE_TEXT_OVERLAY_LOCK (overlay);
 
   if (overlay->video_flushing)
     goto flushing;
@@ -2524,7 +2529,7 @@
     goto have_eos;
 
   if (overlay->silent) {
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
     ret = gst_pad_push (overlay->srcpad, buffer);
 
     /* Update position */
@@ -2544,7 +2549,7 @@
     GST_LOG_OBJECT (overlay, "Text pad not linked, rendering default "
         "text: '%s'", GST_STR_NULL (text));
 
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
 
     if (text != NULL && *text != '\0') {
       /* Render and push */
@@ -2607,11 +2612,11 @@
         GST_LOG_OBJECT (overlay, "text buffer too old, popping");
         pop_text = FALSE;
         gst_base_text_overlay_pop_text (overlay);
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
         goto wait_for_text_buf;
       } else if (valid_text_time && vid_running_time_end <= text_running_time) {
         GST_LOG_OBJECT (overlay, "text in future, pushing video buf");
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
         /* Push the video frame */
         ret = gst_pad_push (overlay->srcpad, buffer);
       } else {
@@ -2660,7 +2665,7 @@
 
         gst_buffer_unmap (overlay->text_buffer, &map);
 
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
         ret = gst_base_text_overlay_push_frame (overlay, buffer);
 
         if (valid_text_time && text_running_time_end <= vid_running_time_end) {
@@ -2669,9 +2674,9 @@
         }
       }
       if (pop_text) {
-        GST_OBJECT_LOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_LOCK (overlay);
         gst_base_text_overlay_pop_text (overlay);
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       }
     } else {
       gboolean wait_for_text_buf = TRUE;
@@ -2709,10 +2714,10 @@
         GST_DEBUG_OBJECT (overlay, "no text buffer, need to wait for one");
         GST_BASE_TEXT_OVERLAY_WAIT (overlay);
         GST_DEBUG_OBJECT (overlay, "resuming");
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
         goto wait_for_text_buf;
       } else {
-        GST_OBJECT_UNLOCK (overlay);
+        GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
         GST_LOG_OBJECT (overlay, "no need to wait for a text buffer");
         ret = gst_pad_push (overlay->srcpad, buffer);
       }
@@ -2735,14 +2740,14 @@
 
 flushing:
   {
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
     GST_DEBUG_OBJECT (overlay, "flushing, discarding buffer");
     gst_buffer_unref (buffer);
     return GST_FLOW_FLUSHING;
   }
 have_eos:
   {
-    GST_OBJECT_UNLOCK (overlay);
+    GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
     GST_DEBUG_OBJECT (overlay, "eos, discarding buffer");
     gst_buffer_unref (buffer);
     return GST_FLOW_EOS;
@@ -2764,13 +2769,13 @@
 
   switch (transition) {
     case GST_STATE_CHANGE_PAUSED_TO_READY:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       overlay->text_flushing = TRUE;
       overlay->video_flushing = TRUE;
       /* pop_text will broadcast on the GCond and thus also make the video
        * chain exit if it's waiting for a text buffer */
       gst_base_text_overlay_pop_text (overlay);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       break;
     default:
       break;
@@ -2782,14 +2787,14 @@
 
   switch (transition) {
     case GST_STATE_CHANGE_READY_TO_PAUSED:
-      GST_OBJECT_LOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_LOCK (overlay);
       overlay->text_flushing = FALSE;
       overlay->video_flushing = FALSE;
       overlay->video_eos = FALSE;
       overlay->text_eos = FALSE;
       gst_segment_init (&overlay->segment, GST_FORMAT_TIME);
       gst_segment_init (&overlay->text_segment, GST_FORMAT_TIME);
-      GST_OBJECT_UNLOCK (overlay);
+      GST_BASE_TEXT_OVERLAY_UNLOCK (overlay);
       break;
     default:
       break;
diff --git a/ext/pango/gstbasetextoverlay.h b/ext/pango/gstbasetextoverlay.h
index d756615..0107165 100644
--- a/ext/pango/gstbasetextoverlay.h
+++ b/ext/pango/gstbasetextoverlay.h
@@ -109,6 +109,7 @@
     gboolean                text_flushing;
     gboolean                text_eos;
 
+    GMutex                   lock;
     GCond                    cond;  /* to signal removal of a queued text
                                      * buffer, arrival of a text buffer,
                                      * a text segment update, or a change
diff --git a/ext/theora/Makefile.in b/ext/theora/Makefile.in
index 4077176..1734223 100644
--- a/ext/theora/Makefile.in
+++ b/ext/theora/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = ext/theora
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -283,8 +284,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -455,7 +462,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/theora/gsttheoradec.c b/ext/theora/gsttheoradec.c
index 1d4925f..317d05a 100644
--- a/ext/theora/gsttheoradec.c
+++ b/ext/theora/gsttheoradec.c
@@ -59,6 +59,11 @@
 #define THEORA_DEF_TELEMETRY_QI 0
 #define THEORA_DEF_TELEMETRY_BITS 0
 
+/* This was removed from the base class, this is used as a
+   temporary return to signal the need to call _drop_frame,
+   and does not leave theoraenc. */
+#define GST_CUSTOM_FLOW_DROP GST_FLOW_CUSTOM_SUCCESS_1
+
 enum
 {
   PROP_0,
@@ -201,6 +206,7 @@
 
   /* input is packetized,
    * but is not marked that way so data gets parsed and keyframes marked */
+  gst_video_decoder_set_packetized (GST_VIDEO_DECODER (dec), FALSE);
 }
 
 static void
@@ -242,6 +248,10 @@
     gst_tag_list_free (dec->tags);
     dec->tags = NULL;
   }
+  if (dec->input_state)
+    gst_video_codec_state_unref (dec->input_state);
+  if (dec->output_state)
+    gst_video_codec_state_unref (dec->output_state);
 
   return TRUE;
 }
@@ -378,7 +388,7 @@
 }
 
 static GstFlowReturn
-theora_handle_type_packet (GstTheoraDec * dec, ogg_packet * packet)
+theora_handle_type_packet (GstTheoraDec * dec)
 {
   gint par_num, par_den;
   GstFlowReturn ret = GST_FLOW_OK;
@@ -500,7 +510,7 @@
   /* FIXME :  */
   if (dec->tags) {
     gst_pad_push_event (GST_VIDEO_DECODER (dec)->srcpad,
-        gst_event_new_tag (dec->tags));
+        gst_event_new_tag ("GstDecoder", dec->tags));
     dec->tags = NULL;
   }
 
@@ -531,7 +541,7 @@
       res = theora_handle_comment_packet (dec, packet);
       break;
     case 0x82:
-      res = theora_handle_type_packet (dec, packet);
+      res = theora_handle_type_packet (dec);
       break;
     default:
       /* ignore */
@@ -710,8 +720,6 @@
     goto wrong_dimensions;
 
   result = theora_handle_image (dec, buf, frame);
-  if (result != GST_FLOW_OK)
-    return result;
 
   return result;
 
@@ -730,7 +738,7 @@
 dropping_qos:
   {
     GST_WARNING_OBJECT (dec, "dropping frame because of QoS");
-    return GST_VIDEO_DECODER_FLOW_NEED_DATA;
+    return GST_CUSTOM_FLOW_DROP;
   }
 decode_error:
   {
@@ -806,8 +814,17 @@
   dec = GST_THEORA_DEC (bdec);
 
   res = theora_dec_decode_buffer (dec, frame->input_buffer, frame);
-  if (res == GST_FLOW_OK)
-    res = gst_video_decoder_finish_frame (bdec, frame);
+  switch (res) {
+    case GST_FLOW_OK:
+      res = gst_video_decoder_finish_frame (bdec, frame);
+      break;
+    case GST_CUSTOM_FLOW_DROP:
+      res = gst_video_decoder_drop_frame (bdec, frame);
+      break;
+    default:
+      gst_video_codec_frame_unref (frame);
+      break;
+  }
 
   return res;
 }
diff --git a/ext/theora/gsttheoraenc.c b/ext/theora/gsttheoraenc.c
index 92965dd..31ff235 100644
--- a/ext/theora/gsttheoraenc.c
+++ b/ext/theora/gsttheoraenc.c
@@ -851,8 +851,8 @@
   GST_BUFFER_TIMESTAMP (outbuf) = GST_CLOCK_TIME_NONE;
   GST_BUFFER_DURATION (outbuf) = GST_CLOCK_TIME_NONE;
 
-  GST_DEBUG ("created header packet buffer, %d bytes",
-      gst_buffer_get_size (outbuf));
+  GST_DEBUG ("created header packet buffer, %u bytes",
+      (guint) gst_buffer_get_size (outbuf));
   return outbuf;
 }
 
@@ -993,27 +993,28 @@
     while (th_encode_packetout (enc->encoder, 0, &op)) {
       ret = theora_push_packet (enc, &op);
       if (ret != GST_FLOW_OK)
-        goto data_push;
+        goto beach;
     }
   }
 
+beach:
+  gst_video_codec_frame_unref (frame);
   return ret;
 
   /* ERRORS */
 multipass_read_failed:
   {
+    gst_video_codec_frame_unref (frame);
     return ret;
   }
 multipass_write_failed:
   {
-    return ret;
-  }
-data_push:
-  {
+    gst_video_codec_frame_unref (frame);
     return ret;
   }
 encoder_disabled:
   {
+    gst_video_codec_frame_unref (frame);
     GST_ELEMENT_ERROR (enc, STREAM, ENCODE, (NULL),
         ("libtheora has been compiled with the encoder disabled"));
     return GST_FLOW_ERROR;
diff --git a/ext/vorbis/Makefile.in b/ext/vorbis/Makefile.in
index f5fddbb..56dbe81 100644
--- a/ext/vorbis/Makefile.in
+++ b/ext/vorbis/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 @USE_VORBIS_TRUE@am__append_1 = libgstvorbis.la
 @USE_IVORBIS_TRUE@am__append_2 = libgstivorbisdec.la
 subdir = ext/vorbis
@@ -310,8 +311,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -482,7 +489,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/ext/vorbis/gstvorbisdec.c b/ext/vorbis/gstvorbisdec.c
index cb4f725..b14d2d2 100644
--- a/ext/vorbis/gstvorbisdec.c
+++ b/ext/vorbis/gstvorbisdec.c
@@ -585,8 +585,10 @@
       goto done;
     }
     result = vorbis_handle_header_packet (vd, packet);
+    if (result != GST_FLOW_OK)
+      goto done;
     /* consumer header packet/frame */
-    gst_audio_decoder_finish_frame (GST_AUDIO_DECODER (vd), NULL, 1);
+    result = gst_audio_decoder_finish_frame (GST_AUDIO_DECODER (vd), NULL, 1);
   } else {
     GstClockTime timestamp, duration;
 
diff --git a/ext/vorbis/gstvorbisdeclib.h b/ext/vorbis/gstvorbisdeclib.h
index caefa40..8f69bda 100644
--- a/ext/vorbis/gstvorbisdeclib.h
+++ b/ext/vorbis/gstvorbisdeclib.h
@@ -43,8 +43,6 @@
 
 #define GST_VORBIS_DEC_DEFAULT_SAMPLE_WIDTH           (32)
 
-#define GST_VORBIS_DEC_GLIB_TYPE_NAME      GstVorbisDec
-
 #else /* TREMOR */
 
 #define GST_VORBIS_DEC_DESCRIPTION "decode raw vorbis streams to integer audio"
@@ -61,11 +59,8 @@
 #define GST_VORBIS_DEC_DEFAULT_SAMPLE_WIDTH           (16)
 
 /* we need a different type name here */
-#define GST_VORBIS_DEC_GLIB_TYPE_NAME      GstIVorbisDec
-
-/* and still have it compile */
-typedef struct _GstVorbisDec               GstIVorbisDec;
-typedef struct _GstVorbisDecClass          GstIVorbisDecClass;
+#define GstVorbisDec GstIVorbisDec
+#define GstVorbisDecClass GstIVorbisDecClass
 
 #endif /* TREMOR */
 
diff --git a/gst-libs/Makefile.in b/gst-libs/Makefile.in
index 31fa5c9..cca2f24 100644
--- a/gst-libs/Makefile.in
+++ b/gst-libs/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst-libs
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -251,8 +252,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -423,7 +430,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/Makefile.in b/gst-libs/gst/Makefile.in
index c498578..024169e 100644
--- a/gst-libs/gst/Makefile.in
+++ b/gst-libs/gst/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst-libs/gst
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -254,8 +255,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -426,7 +433,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/app/Makefile.in b/gst-libs/gst/app/Makefile.in
index 4665783..73eaff1 100644
--- a/gst-libs/gst/app/Makefile.in
+++ b/gst-libs/gst/app/Makefile.in
@@ -61,6 +61,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(libgstapp_@GST_API_VERSION@include_HEADERS) \
 	$(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/gst-glib-gen.mak
@@ -299,8 +300,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -471,7 +478,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/app/gstappsrc.c b/gst-libs/gst/app/gstappsrc.c
index c814412..9da35fc 100644
--- a/gst-libs/gst/app/gstappsrc.c
+++ b/gst-libs/gst/app/gstappsrc.c
@@ -557,7 +557,27 @@
 static GstCaps *
 gst_app_src_internal_get_caps (GstBaseSrc * bsrc, GstCaps * filter)
 {
-  return gst_app_src_get_caps (GST_APP_SRC_CAST (bsrc), filter);
+  GstAppSrc *appsrc = GST_APP_SRC (bsrc);
+  GstCaps *caps;
+
+  GST_OBJECT_LOCK (appsrc);
+  if ((caps = appsrc->priv->caps))
+    gst_caps_ref (caps);
+  GST_OBJECT_UNLOCK (appsrc);
+
+  if (filter) {
+    if (caps) {
+      GstCaps *intersection =
+          gst_caps_intersect_full (filter, caps, GST_CAPS_INTERSECT_FIRST);
+      gst_caps_unref (caps);
+      caps = intersection;
+    } else {
+      caps = gst_caps_ref (filter);
+    }
+  }
+
+  GST_DEBUG_OBJECT (appsrc, "caps: %" GST_PTR_FORMAT, caps);
+  return caps;
 }
 
 static void
@@ -619,16 +639,8 @@
 
   switch (prop_id) {
     case PROP_CAPS:
-    {
-      GstCaps *caps;
-
-      /* we're missing a _take_caps() function to transfer ownership */
-      caps = gst_app_src_get_caps (appsrc, NULL);
-      gst_value_set_caps (value, caps);
-      if (caps)
-        gst_caps_unref (caps);
+      g_value_take_boxed (value, gst_app_src_get_caps (appsrc));
       break;
-    }
     case PROP_SIZE:
       g_value_set_int64 (value, gst_app_src_get_size (appsrc));
       break;
@@ -1107,33 +1119,11 @@
  * Since: 0.10.22
  */
 GstCaps *
-gst_app_src_get_caps (GstAppSrc * appsrc, GstCaps * filter)
+gst_app_src_get_caps (GstAppSrc * appsrc)
 {
-  GstCaps *caps;
-  GstAppSrcPrivate *priv;
-
   g_return_val_if_fail (GST_IS_APP_SRC (appsrc), NULL);
 
-  priv = appsrc->priv;
-
-  GST_OBJECT_LOCK (appsrc);
-  if ((caps = priv->caps))
-    gst_caps_ref (caps);
-
-  if (filter) {
-    if (caps) {
-      GstCaps *intersection =
-          gst_caps_intersect_full (filter, caps, GST_CAPS_INTERSECT_FIRST);
-      gst_caps_unref (caps);
-      caps = intersection;
-    } else {
-      caps = gst_caps_ref (filter);
-    }
-  }
-  GST_DEBUG_OBJECT (appsrc, "getting caps of %" GST_PTR_FORMAT, caps);
-  GST_OBJECT_UNLOCK (appsrc);
-
-  return caps;
+  return gst_app_src_internal_get_caps (GST_BASE_SRC_CAST (appsrc), NULL);
 }
 
 /**
diff --git a/gst-libs/gst/app/gstappsrc.h b/gst-libs/gst/app/gstappsrc.h
index cafc7cc..79a66fd 100644
--- a/gst-libs/gst/app/gstappsrc.h
+++ b/gst-libs/gst/app/gstappsrc.h
@@ -122,7 +122,7 @@
 GType gst_app_stream_type_get_type (void);
 
 void             gst_app_src_set_caps         (GstAppSrc *appsrc, const GstCaps *caps);
-GstCaps*         gst_app_src_get_caps         (GstAppSrc *appsrc, GstCaps * filter);
+GstCaps*         gst_app_src_get_caps         (GstAppSrc *appsrc);
 
 void             gst_app_src_set_size         (GstAppSrc *appsrc, gint64 size);
 gint64           gst_app_src_get_size         (GstAppSrc *appsrc);
diff --git a/gst-libs/gst/audio/Makefile.in b/gst-libs/gst/audio/Makefile.in
index 4fc8bea..da62b58 100644
--- a/gst-libs/gst/audio/Makefile.in
+++ b/gst-libs/gst/audio/Makefile.in
@@ -61,6 +61,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(libgstaudio_@GST_API_VERSION@include_HEADERS) \
 	$(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/gst-glib-gen.mak TODO
@@ -317,8 +318,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -489,7 +496,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/audio/audio.h b/gst-libs/gst/audio/audio.h
index 8cd5af3..5e34eae 100644
--- a/gst-libs/gst/audio/audio.h
+++ b/gst-libs/gst/audio/audio.h
@@ -163,6 +163,17 @@
 } GstAudioFormatFlags;
 
 /**
+ * GstAudioPackFlags:
+ * @GST_AUDIO_PACK_FLAG_NONE: No flag
+ *
+ * The different flags that can be used when packing and unpacking.
+ */
+typedef enum
+{
+  GST_AUDIO_PACK_FLAG_NONE       = 0
+} GstAudioPackFlags;
+
+/**
  * GstAudioFormatUnpack:
  * @info: a #GstAudioFormatInfo
  * @dest: a destination array
@@ -174,7 +185,8 @@
  * interleaved. @dest should at least be big enough to hold @length *
  * channels * size(unpack_format) bytes.
  */
-typedef void (*GstAudioFormatUnpack)         (const GstAudioFormatInfo *info, gpointer dest,
+typedef void (*GstAudioFormatUnpack)         (const GstAudioFormatInfo *info,
+                                              GstAudioPackFlags flags, gpointer dest,
                                               const gpointer data, gint length);
 /**
  * GstAudioFormatPack:
@@ -187,7 +199,8 @@
  * The samples from source have each channel interleaved
  * and will be packed into @data.
  */
-typedef void (*GstAudioFormatPack)           (const GstAudioFormatInfo *info, const gpointer src,
+typedef void (*GstAudioFormatPack)           (const GstAudioFormatInfo *info,
+                                              GstAudioPackFlags flags, const gpointer src,
                                               gpointer data, gint length);
 
 /**
diff --git a/gst-libs/gst/audio/gstaudiocdsrc.c b/gst-libs/gst/audio/gstaudiocdsrc.c
index 93b417b..c8f8b40 100644
--- a/gst-libs/gst/audio/gstaudiocdsrc.c
+++ b/gst-libs/gst/audio/gstaudiocdsrc.c
@@ -1651,7 +1651,8 @@
         gst_tag_list_merge (src->tags,
         src->priv->tracks[src->priv->cur_track].tags, GST_TAG_MERGE_REPLACE);
     GST_LOG_OBJECT (src, "announcing tags: %" GST_PTR_FORMAT, tags);
-    gst_pad_push_event (GST_BASE_SRC_PAD (src), gst_event_new_tag (tags));
+    gst_pad_push_event (GST_BASE_SRC_PAD (src), gst_event_new_tag ("GstSrc",
+            tags));
     src->priv->prev_track = src->priv->cur_track;
 
     gst_audio_cd_src_update_duration (src);
diff --git a/gst-libs/gst/audio/gstaudiodecoder.c b/gst-libs/gst/audio/gstaudiodecoder.c
index a7bcf97..00f879b 100644
--- a/gst-libs/gst/audio/gstaudiodecoder.c
+++ b/gst-libs/gst/audio/gstaudiodecoder.c
@@ -952,7 +952,8 @@
     if (gst_tag_list_is_empty (priv->taglist)) {
       gst_tag_list_free (priv->taglist);
     } else {
-      gst_audio_decoder_push_event (dec, gst_event_new_tag (priv->taglist));
+      gst_audio_decoder_push_event (dec, gst_event_new_tag ("GstDecoder",
+              priv->taglist));
     }
     priv->taglist = NULL;
   }
@@ -1622,9 +1623,8 @@
       GstCaps *caps;
 
       gst_event_parse_caps (event, &caps);
-      gst_audio_decoder_sink_setcaps (dec, caps);
+      ret = gst_audio_decoder_sink_setcaps (dec, caps);
       gst_event_unref (event);
-      ret = TRUE;
       break;
     }
     default:
diff --git a/gst-libs/gst/audio/gstaudioencoder.c b/gst-libs/gst/audio/gstaudioencoder.c
index add902e..2e7ae07 100644
--- a/gst-libs/gst/audio/gstaudioencoder.c
+++ b/gst-libs/gst/audio/gstaudioencoder.c
@@ -632,7 +632,7 @@
         caps);
 #endif
     GST_DEBUG_OBJECT (enc, "sending tags %" GST_PTR_FORMAT, tags);
-    gst_audio_encoder_push_event (enc, gst_event_new_tag (tags));
+    gst_audio_encoder_push_event (enc, gst_event_new_tag ("GstEncoder", tags));
   }
 
   /* remove corresponding samples from input */
@@ -1465,7 +1465,7 @@
       gst_tag_list_remove_tag (tags, GST_TAG_MINIMUM_BITRATE);
       gst_tag_list_remove_tag (tags, GST_TAG_ENCODER);
       gst_tag_list_remove_tag (tags, GST_TAG_ENCODER_VERSION);
-      event = gst_event_new_tag (tags);
+      event = gst_event_new_tag ("GstEncoder", tags);
 
       GST_AUDIO_ENCODER_STREAM_LOCK (enc);
       enc->priv->pending_events =
diff --git a/gst-libs/gst/audio/gstaudioiec61937.c b/gst-libs/gst/audio/gstaudioiec61937.c
index 983d58e..48837f5 100644
--- a/gst-libs/gst/audio/gstaudioiec61937.c
+++ b/gst-libs/gst/audio/gstaudioiec61937.c
@@ -236,9 +236,10 @@
        *     bit  0-4  - data type (11 = type I, 12 = type II,
        *                            13 = type III) */
       dst[five] = 11 + (blocksize / 1024);
-      /* Pd: bit 15-0  - frame size in bytes */
-      dst[six] = ((guint16) src_n) >> 8;
-      dst[seven] = ((guint16) src_n) & 0xff;
+      /* Pd: bit 15-0  - frame size, in bits (for type I-III) */
+      tmp = src_n * 8;
+      dst[six] = ((guint16) tmp) >> 8;
+      dst[seven] = ((guint16) tmp) & 0xff;
       break;
     }
 
diff --git a/gst-libs/gst/fft/Makefile.in b/gst-libs/gst/fft/Makefile.in
index f3c0cde..d55862e 100644
--- a/gst-libs/gst/fft/Makefile.in
+++ b/gst-libs/gst/fft/Makefile.in
@@ -53,6 +53,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst-libs/gst/fft
 DIST_COMMON = $(libgstfft_@GST_API_VERSION@_include_HEADERS) \
 	$(noinst_HEADERS) $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -297,8 +298,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -469,7 +476,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/pbutils/Makefile.in b/gst-libs/gst/pbutils/Makefile.in
index 811edc9..52f6f3b 100644
--- a/gst-libs/gst/pbutils/Makefile.in
+++ b/gst-libs/gst/pbutils/Makefile.in
@@ -61,6 +61,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(libgstpbutils_@GST_API_VERSION@include_HEADERS) \
 	$(noinst_HEADERS) $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(srcdir)/gstpluginsbaseversion.h.in \
@@ -313,8 +314,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -485,7 +492,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/pbutils/descriptions.c b/gst-libs/gst/pbutils/descriptions.c
index e0b6fb9..486ac3b 100644
--- a/gst-libs/gst/pbutils/descriptions.c
+++ b/gst-libs/gst/pbutils/descriptions.c
@@ -65,11 +65,9 @@
 
 static const FormatInfo formats[] = {
   /* container/tag formats with static descriptions */
-  {"audio/annodex", "Ogg", FLAG_CONTAINER},
   {"audio/ogg", "Ogg", FLAG_CONTAINER},
   {"audio/webm", "WebM", FLAG_CONTAINER},
   {"audio/x-matroska", "Matroska", FLAG_CONTAINER},
-  {"application/annodex", "Ogg", FLAG_CONTAINER},
   {"application/gxf", "General Exchange Format (GXF)", FLAG_CONTAINER},
   {"application/ogg", "Ogg", FLAG_CONTAINER},
   {"application/kate", "Ogg", FLAG_CONTAINER},
@@ -83,7 +81,6 @@
   {"application/x-pn-realaudio", "RealAudio", FLAG_CONTAINER},
   {"application/x-yuv4mpeg", "Y4M", FLAG_CONTAINER},
   {"multipart/x-mixed-replace", "Multipart", FLAG_CONTAINER},
-  {"video/annodex", "Ogg", FLAG_CONTAINER},
   {"video/ogg", "Ogg", FLAG_CONTAINER},
   {"video/x-fli", "FLI/FLC/FLX Animation", FLAG_CONTAINER},
   {"video/x-flv", "Flash", FLAG_CONTAINER},
@@ -120,6 +117,7 @@
   {"audio/x-dts", "DTS", 0},
   {"audio/x-private1-dts", "DTS", 0},
   {"audio/x-dv", "DV Audio", 0},
+  {"audio/x-eac3", "E-AC-3 (ATSC A/52B)", 0},
   {"audio/x-flac", N_("Free Lossless Audio Codec (FLAC)"), 0},
   {"audio/x-gsm", "GSM", 0},
   {"audio/x-iec958", "S/PDIF IEC958", 0},       /* TODO: check description */
@@ -256,6 +254,7 @@
   {"application/x-kate", "Kate", 0},
   {"subtitle/x-kate", N_("Kate subtitle format"), 0},
   {"subpicture/x-dvb", "DVB subtitles", 0},
+  {"subpicture/x-pgs", "PGS subtitles", 0},
 
   /* non-audio/video/container formats */
   {"hdv/aux-v", "HDV AUX-V", 0},
diff --git a/gst-libs/gst/pbutils/gstdiscoverer-types.c b/gst-libs/gst/pbutils/gstdiscoverer-types.c
index 5b63305..098899f 100644
--- a/gst-libs/gst/pbutils/gstdiscoverer-types.c
+++ b/gst-libs/gst/pbutils/gstdiscoverer-types.c
@@ -67,6 +67,9 @@
   if (info->tags)
     gst_tag_list_free (info->tags);
 
+  if (info->toc)
+    gst_toc_free (info->toc);
+
   if (info->misc)
     gst_structure_free (info->misc);
 }
@@ -126,6 +129,9 @@
   if (info->tags)
     ret->tags = gst_tag_list_copy (info->tags);
 
+  if (info->toc)
+    ret->toc = gst_toc_copy (info->toc);
+
   if (info->misc)
     ret->misc = gst_structure_copy (info->misc);
 
@@ -361,6 +367,9 @@
 
   if (info->tags)
     gst_tag_list_free (info->tags);
+
+  if (info->toc)
+    gst_toc_free (info->toc);
 }
 
 static GstDiscovererInfo *
@@ -412,6 +421,9 @@
   if (ptr->tags)
     ret->tags = gst_tag_list_copy (ptr->tags);
 
+  if (ptr->toc)
+    ret->toc = gst_toc_copy (ptr->toc);
+
   g_hash_table_destroy (stream_map);
   return ret;
 }
@@ -648,7 +660,6 @@
  *
  * Since: 0.10.31
  */
-
 const GstTagList *
 gst_discoverer_stream_info_get_tags (GstDiscovererStreamInfo * info)
 {
@@ -658,6 +669,23 @@
 }
 
 /**
+ * gst_discoverer_stream_info_get_toc:
+ * @info: a #GstDiscovererStreamInfo
+ *
+ * Returns: (transfer none): the TOC contained in this stream. If you wish to
+ * use the TOC after the life-time of @info you will need to copy it.
+ *
+ * Since: 0.11.92
+ */
+const GstToc *
+gst_discoverer_stream_info_get_toc (GstDiscovererStreamInfo * info)
+{
+  g_return_val_if_fail (GST_IS_DISCOVERER_STREAM_INFO (info), NULL);
+
+  return info->toc;
+}
+
+/**
  * gst_discoverer_stream_info_get_misc:
  * @info: a #GstDiscovererStreamInfo
  *
@@ -1058,6 +1086,18 @@
 DISCOVERER_INFO_ACCESSOR_CODE (tags, const GstTagList *, NULL);
 
 /**
+ * gst_discoverer_info_get_toc:
+ * @info: a #GstDiscovererInfo
+ *
+ * Returns: (transfer none): TOC contained in the URI. If you wish to use
+ * the TOC after the life-time of @info, you will need to copy it.
+ *
+ * Since: 0.11.92
+ */
+
+DISCOVERER_INFO_ACCESSOR_CODE (toc, const GstToc *, NULL);
+
+/**
  * gst_discoverer_info_ref:
  * @info: a #GstDiscovererInfo
  *
diff --git a/gst-libs/gst/pbutils/gstdiscoverer.c b/gst-libs/gst/pbutils/gstdiscoverer.c
index 94d1823..16e8089 100644
--- a/gst-libs/gst/pbutils/gstdiscoverer.c
+++ b/gst-libs/gst/pbutils/gstdiscoverer.c
@@ -57,6 +57,7 @@
 
 static GQuark _CAPS_QUARK;
 static GQuark _TAGS_QUARK;
+static GQuark _TOC_QUARK;
 static GQuark _MISSING_PLUGIN_QUARK;
 static GQuark _STREAM_TOPOLOGY_QUARK;
 static GQuark _TOPOLOGY_PAD_QUARK;
@@ -69,6 +70,7 @@
   GstElement *queue;
   GstElement *sink;
   GstTagList *tags;
+  GstToc *toc;
 } PrivateStream;
 
 struct _GstDiscovererPrivate
@@ -135,6 +137,7 @@
 
   _CAPS_QUARK = g_quark_from_static_string ("caps");
   _TAGS_QUARK = g_quark_from_static_string ("tags");
+  _TOC_QUARK = g_quark_from_static_string ("toc");
   _MISSING_PLUGIN_QUARK = g_quark_from_static_string ("missing-plugin");
   _STREAM_TOPOLOGY_QUARK = g_quark_from_static_string ("stream-topology");
   _TOPOLOGY_PAD_QUARK = g_quark_from_static_string ("pad");
@@ -449,6 +452,20 @@
     DISCO_UNLOCK (ps->dc);
   }
 
+  if (GST_EVENT_TYPE (event) == GST_EVENT_TOC) {
+    GstToc *tmp;
+
+    gst_event_parse_toc (event, &tmp, NULL);
+    GST_DEBUG_OBJECT (pad, "toc %" GST_PTR_FORMAT, tmp);
+    DISCO_LOCK (ps->dc);
+    ps->toc = tmp;
+    if (G_LIKELY (ps->dc->priv->processing)) {
+      GST_DEBUG_OBJECT (pad, "private stream %p toc %" GST_PTR_FORMAT, ps, tmp);
+    } else
+      GST_DEBUG_OBJECT (pad, "Dropping toc since preroll is done");
+    DISCO_UNLOCK (ps->dc);
+  }
+
   return GST_PAD_PROBE_OK;
 }
 
@@ -616,6 +633,9 @@
   if (ps->tags) {
     gst_tag_list_free (ps->tags);
   }
+  if (ps->toc) {
+    gst_toc_free (ps->toc);
+  }
 
   g_slice_free (PrivateStream, ps);
 
@@ -648,6 +668,8 @@
   }
   if (ps->tags)
     gst_structure_id_set (st, _TAGS_QUARK, GST_TYPE_TAG_LIST, ps->tags, NULL);
+  if (ps->toc)
+    gst_structure_id_set (st, _TOC_QUARK, GST_TYPE_TOC, ps->toc, NULL);
 
   return st;
 }
@@ -679,6 +701,7 @@
   GstCaps *caps;
   GstStructure *caps_st;
   GstTagList *tags_st;
+  GstToc *toc_st;
   const gchar *name;
   int tmp;
   guint utmp;
@@ -729,6 +752,11 @@
       gst_discoverer_merge_and_replace_tags (&info->parent.tags, tags_st);
     }
 
+    if (gst_structure_id_has_field (st, _TOC_QUARK)) {
+      gst_structure_id_get (st, _TOC_QUARK, GST_TYPE_TOC, &toc_st, NULL);
+      info->parent.toc = toc_st;
+    }
+
     if (!info->language && ((GstDiscovererStreamInfo *) info)->tags) {
       gchar *language;
       if (gst_tag_list_get_string (((GstDiscovererStreamInfo *) info)->tags,
@@ -787,6 +815,11 @@
           (GstTagList *) tags_st);
     }
 
+    if (gst_structure_id_has_field (st, _TOC_QUARK)) {
+      gst_structure_id_get (st, _TOC_QUARK, GST_TYPE_TOC, &toc_st, NULL);
+      info->parent.toc = toc_st;
+    }
+
     gst_caps_unref (caps);
     return (GstDiscovererStreamInfo *) info;
 
@@ -815,6 +848,11 @@
       gst_discoverer_merge_and_replace_tags (&info->parent.tags, tags_st);
     }
 
+    if (gst_structure_id_has_field (st, _TOC_QUARK)) {
+      gst_structure_id_get (st, _TOC_QUARK, GST_TYPE_TOC, &toc_st, NULL);
+      info->parent.toc = toc_st;
+    }
+
     if (!info->language && ((GstDiscovererStreamInfo *) info)->tags) {
       gchar *language;
       if (gst_tag_list_get_string (((GstDiscovererStreamInfo *) info)->tags,
@@ -843,6 +881,10 @@
       gst_discoverer_merge_and_replace_tags (&info->tags, tags_st);
     }
 
+    if (gst_structure_id_get (st, _TOC_QUARK, GST_TYPE_TOC, &toc_st, NULL)) {
+      info->toc = toc_st;
+    }
+
     gst_caps_unref (caps);
     return info;
   }
@@ -1285,6 +1327,18 @@
     }
       break;
 
+    case GST_MESSAGE_TOC:
+    {
+      GstToc *tmp;
+
+      gst_message_parse_toc (msg, &tmp, NULL);
+      GST_DEBUG_OBJECT (GST_MESSAGE_SRC (msg), "Got toc %" GST_PTR_FORMAT, tmp);
+      dc->priv->current_info->toc = tmp;
+      GST_DEBUG_OBJECT (GST_MESSAGE_SRC (msg), "Current info %p, toc %"
+          GST_PTR_FORMAT, dc->priv->current_info, tmp);
+    }
+      break;
+
     default:
       break;
   }
diff --git a/gst-libs/gst/pbutils/gstdiscoverer.h b/gst-libs/gst/pbutils/gstdiscoverer.h
index 611bc89..e11bc17 100644
--- a/gst-libs/gst/pbutils/gstdiscoverer.h
+++ b/gst-libs/gst/pbutils/gstdiscoverer.h
@@ -63,6 +63,7 @@
 GstDiscovererStreamInfo* gst_discoverer_stream_info_get_next(GstDiscovererStreamInfo* info);
 GstCaps*                 gst_discoverer_stream_info_get_caps(GstDiscovererStreamInfo* info);
 const GstTagList*        gst_discoverer_stream_info_get_tags(GstDiscovererStreamInfo* info);
+const GstToc*            gst_discoverer_stream_info_get_toc(GstDiscovererStreamInfo* info);
 const GstStructure*      gst_discoverer_stream_info_get_misc(GstDiscovererStreamInfo* info);
 const gchar *            gst_discoverer_stream_info_get_stream_type_nick(GstDiscovererStreamInfo* info);
 
@@ -214,7 +215,8 @@
 GstClockTime              gst_discoverer_info_get_duration(const GstDiscovererInfo* info);
 gboolean                  gst_discoverer_info_get_seekable(const GstDiscovererInfo* info);
 const GstStructure*       gst_discoverer_info_get_misc(const GstDiscovererInfo* info);
-const GstTagList*         gst_discoverer_info_get_tags(const GstDiscovererInfo* info);
+const GstTagList*         gst_discoverer_info_get_tags(const GstDiscovererInfo* info); 
+const GstToc*             gst_discoverer_info_get_toc(const GstDiscovererInfo* info);
 
 GList *                   gst_discoverer_info_get_streams (GstDiscovererInfo *info,
 							   GType streamtype);
diff --git a/gst-libs/gst/pbutils/pbutils-private.h b/gst-libs/gst/pbutils/pbutils-private.h
index 7efa6ab..48eea55 100644
--- a/gst-libs/gst/pbutils/pbutils-private.h
+++ b/gst-libs/gst/pbutils/pbutils-private.h
@@ -26,6 +26,7 @@
 
   GstCaps               *caps;
   GstTagList            *tags;
+  GstToc                *toc;
   GstStructure          *misc;
 
   gpointer _gst_reserved[GST_PADDING];
@@ -96,6 +97,7 @@
   GstClockTime duration;
   GstStructure *misc;
   GstTagList *tags;
+  GstToc *toc;
   gboolean seekable;
 
   gpointer _gst_reserved[GST_PADDING];
diff --git a/gst-libs/gst/riff/Makefile.in b/gst-libs/gst/riff/Makefile.in
index c6297e2..a092bc3 100644
--- a/gst-libs/gst/riff/Makefile.in
+++ b/gst-libs/gst/riff/Makefile.in
@@ -53,6 +53,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst-libs/gst/riff
 DIST_COMMON = $(libgstriff_@GST_API_VERSION@include_HEADERS) \
 	$(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -287,8 +288,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -459,7 +466,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/rtp/Makefile.in b/gst-libs/gst/rtp/Makefile.in
index 615b6f3..8233324 100644
--- a/gst-libs/gst/rtp/Makefile.in
+++ b/gst-libs/gst/rtp/Makefile.in
@@ -53,6 +53,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst-libs/gst/rtp
 DIST_COMMON = README $(libgstrtpinclude_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -288,8 +289,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -460,7 +467,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/rtp/gstrtpbaseaudiopayload.c b/gst-libs/gst/rtp/gstrtpbaseaudiopayload.c
index 1991ca9..a595a86 100644
--- a/gst-libs/gst/rtp/gstrtpbaseaudiopayload.c
+++ b/gst-libs/gst/rtp/gstrtpbaseaudiopayload.c
@@ -234,7 +234,10 @@
 
   switch (prop_id) {
     case PROP_BUFFER_LIST:
+#if 0
       payload->priv->buffer_list = g_value_get_boolean (value);
+#endif
+      payload->priv->buffer_list = FALSE;
       break;
     default:
       G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
diff --git a/gst-libs/gst/rtsp/Makefile.in b/gst-libs/gst/rtsp/Makefile.in
index d5f1c16..3e2ff98 100644
--- a/gst-libs/gst/rtsp/Makefile.in
+++ b/gst-libs/gst/rtsp/Makefile.in
@@ -61,6 +61,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(libgstrtspinclude_HEADERS) $(noinst_HEADERS) \
 	$(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/gst-glib-gen.mak
@@ -306,8 +307,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -478,7 +485,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/rtsp/gstrtspconnection.c b/gst-libs/gst/rtsp/gstrtspconnection.c
index cfa3c00..2041259 100644
--- a/gst-libs/gst/rtsp/gstrtspconnection.c
+++ b/gst-libs/gst/rtsp/gstrtspconnection.c
@@ -322,10 +322,12 @@
   ip = g_inet_address_to_string (g_inet_socket_address_get_address
       (G_INET_SOCKET_ADDRESS (addr)));
   port = g_inet_socket_address_get_port (G_INET_SOCKET_ADDRESS (addr));
+  g_object_unref (addr);
 
   ret =
       gst_rtsp_connection_create_from_socket (client_sock, ip, port, NULL,
       conn);
+  g_object_unref (client_sock);
   g_free (ip);
 
   return ret;
@@ -426,6 +428,7 @@
   if (!g_socket_connect (socket, saddr, cancellable, &err)) {
     if (!g_error_matches (err, G_IO_ERROR, G_IO_ERROR_PENDING))
       goto sys_error;
+    g_clear_error (&err);
   } else {
     goto done;
   }
@@ -2093,7 +2096,7 @@
             G_IO_IN | G_IO_PRI | G_IO_ERR | G_IO_HUP, conn->cancellable,
             &err)) {
       g_socket_set_timeout (conn->read_socket, 0);
-      if (g_error_matches (err, G_IO_ERROR, G_IO_ERROR_BUSY)) {
+      if (g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CANCELLED)) {
         g_clear_error (&err);
         goto stopped;
       } else if (g_error_matches (err, G_IO_ERROR, G_IO_ERROR_TIMED_OUT)) {
@@ -2155,6 +2158,17 @@
 {
   g_return_val_if_fail (conn != NULL, GST_RTSP_EINVAL);
 
+  /* last unref closes the connection we don't want to explicitly close here
+   * because these sockets might have been provided at construction */
+  if (conn->socket0) {
+    g_object_unref (conn->socket0);
+    conn->socket0 = NULL;
+  }
+  if (conn->socket1) {
+    g_object_unref (conn->socket1);
+    conn->socket1 = NULL;
+  }
+
   g_free (conn->ip);
   conn->ip = NULL;
 
@@ -2197,10 +2211,6 @@
   g_return_val_if_fail (conn != NULL, GST_RTSP_EINVAL);
 
   res = gst_rtsp_connection_close (conn);
-  if (conn->socket0)
-    g_object_unref (conn->socket0);
-  if (conn->socket1)
-    g_object_unref (conn->socket1);
 
   if (conn->cancellable)
     g_object_unref (conn->cancellable);
diff --git a/gst-libs/gst/sdp/Makefile.in b/gst-libs/gst/sdp/Makefile.in
index 7e9d066..e4107c7 100644
--- a/gst-libs/gst/sdp/Makefile.in
+++ b/gst-libs/gst/sdp/Makefile.in
@@ -53,6 +53,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst-libs/gst/sdp
 DIST_COMMON = $(libgstsdpinclude_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -283,8 +284,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -455,7 +462,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/tag/Makefile.in b/gst-libs/gst/tag/Makefile.in
index 92b4879..38f5fda 100644
--- a/gst-libs/gst/tag/Makefile.in
+++ b/gst-libs/gst/tag/Makefile.in
@@ -53,6 +53,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 EXTRA_PROGRAMS = mklangtables$(EXEEXT) mklicensestables$(EXEEXT)
 subdir = gst-libs/gst/tag
 DIST_COMMON = $(libgsttaginclude_HEADERS) $(noinst_HEADERS) \
@@ -314,8 +315,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -486,7 +493,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst-libs/gst/tag/gsttagdemux.c b/gst-libs/gst/tag/gsttagdemux.c
index f28924f..daf3e7a 100644
--- a/gst-libs/gst/tag/gsttagdemux.c
+++ b/gst-libs/gst/tag/gsttagdemux.c
@@ -1522,7 +1522,7 @@
             gst_tag_list_copy (demux->priv->parsed_tags)));
 
   if (merged) {
-    GstEvent *event = gst_event_new_tag (merged);
+    GstEvent *event = gst_event_new_tag ("GstTagDemuxer", merged);
 
     GST_EVENT_TIMESTAMP (event) = 0;
     GST_DEBUG_OBJECT (demux, "Sending tag event on src pad");
diff --git a/gst-libs/gst/tag/gsttagmux.c b/gst-libs/gst/tag/gsttagmux.c
index cf49707..e67fbe7 100644
--- a/gst-libs/gst/tag/gsttagmux.c
+++ b/gst-libs/gst/tag/gsttagmux.c
@@ -266,7 +266,7 @@
 
   /* Send an event about the new tags to downstream elements */
   /* gst_event_new_tag takes ownership of the list, so use a copy */
-  event = gst_event_new_tag (gst_tag_list_copy (taglist));
+  event = gst_event_new_tag ("GstTagMuxer", gst_tag_list_copy (taglist));
   gst_pad_push_event (mux->priv->srcpad, event);
 
   GST_BUFFER_OFFSET (buffer) = 0;
diff --git a/gst-libs/gst/tag/gstxmptag.c b/gst-libs/gst/tag/gstxmptag.c
index 8bbaf3b..dd8e66b 100644
--- a/gst-libs/gst/tag/gstxmptag.c
+++ b/gst-libs/gst/tag/gstxmptag.c
@@ -1572,8 +1572,7 @@
     g_slice_free (PendingXmpTag, ptag);
   }
 
-  GST_INFO ("xmp packet parsed, %d entries",
-      gst_structure_n_fields ((GstStructure *) list));
+  GST_INFO ("xmp packet parsed, %d entries", gst_tag_list_n_tags (list));
 
   /* free resources */
   i = 0;
diff --git a/gst-libs/gst/tag/id3v2.c b/gst-libs/gst/tag/id3v2.c
index aaf7fb8..8775902 100644
--- a/gst-libs/gst/tag/id3v2.c
+++ b/gst-libs/gst/tag/id3v2.c
@@ -594,7 +594,7 @@
     work->hdr.frame_data_size -= frame_size;
   }
 
-  if (gst_structure_n_fields (GST_STRUCTURE (work->tags)) == 0) {
+  if (gst_tag_list_n_tags (work->tags) == 0) {
     GST_DEBUG ("Could not extract any frames from tag. Broken or empty tag");
     gst_tag_list_free (work->tags);
     work->tags = NULL;
diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am
index 8799952..8d5b850 100644
--- a/gst-libs/gst/video/Makefile.am
+++ b/gst-libs/gst/video/Makefile.am
@@ -1,12 +1,16 @@
 # variables used for enum generation
-glib_enum_headers = video.h colorbalance.h navigation.h
+ORC_SOURCE=videoblendorc
+include $(top_srcdir)/common/orc.mak
+
+glib_enum_headers = video.h video-format.h video-color.h video-info.h \
+			colorbalance.h navigation.h
 glib_enum_define = GST_VIDEO
 glib_gen_prefix = gst_video
 glib_gen_basename = video
 
 built_sources = video-enumtypes.c
 built_headers = video-enumtypes.h
-BUILT_SOURCES = $(built_sources) $(built_headers)
+BUILT_SOURCES += $(built_sources) $(built_headers)
 
 lib_LTLIBRARIES = libgstvideo-@GST_API_VERSION@.la
 
@@ -17,6 +21,11 @@
 	colorbalancechannel.c   \
 	navigation.c            \
 	video.c          	\
+	video-event.c          	\
+	video-format.c         	\
+	video-color.c         	\
+	video-info.c         	\
+	video-frame.c         	\
 	gstvideosink.c   	\
 	gstvideofilter.c 	\
 	convertframe.c   	\
@@ -36,6 +45,11 @@
 	colorbalancechannel.h	\
 	navigation.h            \
 	video.h			\
+	video-event.h          	\
+	video-format.h         	\
+	video-color.h         	\
+	video-info.h         	\
+	video-frame.h         	\
 	gstvideosink.h 		\
 	gstvideofilter.h	\
 	gstvideometa.h		\
@@ -47,8 +61,9 @@
 	gstvideoutils.h
 nodist_libgstvideo_@GST_API_VERSION@include_HEADERS = $(built_headers)
 
-libgstvideo_@GST_API_VERSION@_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS)
-libgstvideo_@GST_API_VERSION@_la_LIBADD = $(GST_BASE_LIBS) $(GST_LIBS)
+libgstvideo_@GST_API_VERSION@_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS) \
+					$(ORC_CFLAGS)
+libgstvideo_@GST_API_VERSION@_la_LIBADD = $(GST_BASE_LIBS) $(GST_LIBS) $(ORC_LIBS)
 libgstvideo_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS) $(GST_LT_LDFLAGS)
 
 include $(top_srcdir)/common/gst-glib-gen.mak
diff --git a/gst-libs/gst/video/Makefile.in b/gst-libs/gst/video/Makefile.in
index 56def4f..f5d21d2 100644
--- a/gst-libs/gst/video/Makefile.in
+++ b/gst-libs/gst/video/Makefile.in
@@ -15,6 +15,28 @@
 
 @SET_MAKE@
 
+#
+# This is a makefile.am fragment to build Orc code.
+#
+# Define ORC_SOURCE and then include this file, such as:
+#
+#  ORC_SOURCE=gstadderorc
+#  include $(top_srcdir)/common/orc.mak
+#
+# This fragment will create tmp-orc.c and gstadderorc.h from
+# gstadderorc.orc.
+#
+# When 'make dist' is run at the top level, or 'make orc-update'
+# in a directory including this fragment, the generated source 
+# files will be copied to $(ORC_SOURCE)-dist.[ch].  These files
+# should be checked in to git, since they are used if Orc is
+# disabled.
+# 
+# Note that this file defines BUILT_SOURCES, so any later usage
+# of BUILT_SOURCES in the Makefile.am that includes this file
+# must use '+='.
+#
+
 # these are the variables your Makefile.am should set
 # the example is based on the colorbalance interface
 
@@ -61,9 +83,11 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(libgstvideo_@GST_API_VERSION@include_HEADERS) \
 	$(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/common/gst-glib-gen.mak TODO
+	$(top_srcdir)/common/gst-glib-gen.mak \
+	$(top_srcdir)/common/orc.mak TODO
 @HAVE_INTROSPECTION_TRUE@am__append_1 = $(BUILT_GIRSOURCES) $(typelibs_DATA)
 subdir = gst-libs/gst/video
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -144,12 +168,17 @@
 LTLIBRARIES = $(lib_LTLIBRARIES)
 am__DEPENDENCIES_1 =
 libgstvideo_@GST_API_VERSION@_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \
-	$(am__DEPENDENCIES_1)
+	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
 am_libgstvideo_@GST_API_VERSION@_la_OBJECTS =  \
 	libgstvideo_@GST_API_VERSION@_la-colorbalance.lo \
 	libgstvideo_@GST_API_VERSION@_la-colorbalancechannel.lo \
 	libgstvideo_@GST_API_VERSION@_la-navigation.lo \
 	libgstvideo_@GST_API_VERSION@_la-video.lo \
+	libgstvideo_@GST_API_VERSION@_la-video-event.lo \
+	libgstvideo_@GST_API_VERSION@_la-video-format.lo \
+	libgstvideo_@GST_API_VERSION@_la-video-color.lo \
+	libgstvideo_@GST_API_VERSION@_la-video-info.lo \
+	libgstvideo_@GST_API_VERSION@_la-video-frame.lo \
 	libgstvideo_@GST_API_VERSION@_la-gstvideosink.lo \
 	libgstvideo_@GST_API_VERSION@_la-gstvideofilter.lo \
 	libgstvideo_@GST_API_VERSION@_la-convertframe.lo \
@@ -162,7 +191,8 @@
 	libgstvideo_@GST_API_VERSION@_la-gstvideoutils.lo
 am__objects_1 = libgstvideo_@GST_API_VERSION@_la-video-enumtypes.lo
 am__objects_2 =
-am__objects_3 = $(am__objects_1) $(am__objects_2)
+am__objects_3 = libgstvideo_@GST_API_VERSION@_la-tmp-orc.lo \
+	$(am__objects_1) $(am__objects_2)
 nodist_libgstvideo_@GST_API_VERSION@_la_OBJECTS = $(am__objects_3)
 libgstvideo_@GST_API_VERSION@_la_OBJECTS =  \
 	$(am_libgstvideo_@GST_API_VERSION@_la_OBJECTS) \
@@ -315,8 +345,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -487,19 +523,35 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 
 # variables used for enum generation
-glib_enum_headers = video.h colorbalance.h navigation.h
+ORC_SOURCE = videoblendorc
+EXTRA_DIST = $(ORC_SOURCE).orc
+ORC_NODIST_SOURCES = tmp-orc.c $(ORC_SOURCE).h
+BUILT_SOURCES = tmp-orc.c $(ORC_SOURCE).h $(built_sources) \
+	$(built_headers)
+orcc_v_gen = $(orcc_v_gen_$(V))
+orcc_v_gen_ = $(orcc_v_gen_$(AM_DEFAULT_VERBOSITY))
+orcc_v_gen_0 = @echo "  ORCC   $@";
+cp_v_gen = $(cp_v_gen_$(V))
+cp_v_gen_ = $(cp_v_gen_$(AM_DEFAULT_VERBOSITY))
+cp_v_gen_0 = @echo "  CP     $@";
+glib_enum_headers = video.h video-format.h video-color.h video-info.h \
+			colorbalance.h navigation.h
+
 glib_enum_define = GST_VIDEO
 glib_gen_prefix = gst_video
 glib_gen_basename = video
 built_sources = video-enumtypes.c
 built_headers = video-enumtypes.h
-BUILT_SOURCES = $(built_sources) $(built_headers)
 lib_LTLIBRARIES = libgstvideo-@GST_API_VERSION@.la
 CLEANFILES = $(BUILT_SOURCES) $(am__append_1)
 libgstvideo_@GST_API_VERSION@_la_SOURCES = \
@@ -507,6 +559,11 @@
 	colorbalancechannel.c   \
 	navigation.c            \
 	video.c          	\
+	video-event.c          	\
+	video-format.c         	\
+	video-color.c         	\
+	video-info.c         	\
+	video-frame.c         	\
 	gstvideosink.c   	\
 	gstvideofilter.c 	\
 	convertframe.c   	\
@@ -525,6 +582,11 @@
 	colorbalancechannel.h	\
 	navigation.h            \
 	video.h			\
+	video-event.h          	\
+	video-format.h         	\
+	video-color.h         	\
+	video-info.h         	\
+	video-frame.h         	\
 	gstvideosink.h 		\
 	gstvideofilter.h	\
 	gstvideometa.h		\
@@ -536,8 +598,10 @@
 	gstvideoutils.h
 
 nodist_libgstvideo_@GST_API_VERSION@include_HEADERS = $(built_headers)
-libgstvideo_@GST_API_VERSION@_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS)
-libgstvideo_@GST_API_VERSION@_la_LIBADD = $(GST_BASE_LIBS) $(GST_LIBS)
+libgstvideo_@GST_API_VERSION@_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS) \
+					$(ORC_CFLAGS)
+
+libgstvideo_@GST_API_VERSION@_la_LIBADD = $(GST_BASE_LIBS) $(GST_LIBS) $(ORC_LIBS)
 libgstvideo_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS) $(GST_LT_LDFLAGS)
 enum_headers = $(foreach h,$(glib_enum_headers),\n\#include \"$(h)\")
 @HAVE_INTROSPECTION_TRUE@BUILT_GIRSOURCES = GstVideo-@GST_API_VERSION@.gir
@@ -565,7 +629,7 @@
 
 .SUFFIXES:
 .SUFFIXES: .c .lo .o .obj
-$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/common/gst-glib-gen.mak $(am__configure_deps)
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/common/orc.mak $(top_srcdir)/common/gst-glib-gen.mak $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
 	    *$$dep*) \
@@ -586,7 +650,7 @@
 	    echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
 	    cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
 	esac;
-$(top_srcdir)/common/gst-glib-gen.mak:
+$(top_srcdir)/common/orc.mak $(top_srcdir)/common/gst-glib-gen.mak:
 
 $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
@@ -648,7 +712,13 @@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-gstvideosink.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-gstvideoutils.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-navigation.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-tmp-orc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-color.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-enumtypes.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-event.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-format.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-frame.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-info.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-videoorientation.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-videooverlay.Plo@am__quote@
@@ -702,6 +772,41 @@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-video.lo `test -f 'video.c' || echo '$(srcdir)/'`video.c
 
+libgstvideo_@GST_API_VERSION@_la-video-event.lo: video-event.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-video-event.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-event.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-video-event.lo `test -f 'video-event.c' || echo '$(srcdir)/'`video-event.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-event.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-event.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='video-event.c' object='libgstvideo_@GST_API_VERSION@_la-video-event.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-video-event.lo `test -f 'video-event.c' || echo '$(srcdir)/'`video-event.c
+
+libgstvideo_@GST_API_VERSION@_la-video-format.lo: video-format.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-video-format.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-format.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-video-format.lo `test -f 'video-format.c' || echo '$(srcdir)/'`video-format.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-format.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-format.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='video-format.c' object='libgstvideo_@GST_API_VERSION@_la-video-format.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-video-format.lo `test -f 'video-format.c' || echo '$(srcdir)/'`video-format.c
+
+libgstvideo_@GST_API_VERSION@_la-video-color.lo: video-color.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-video-color.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-color.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-video-color.lo `test -f 'video-color.c' || echo '$(srcdir)/'`video-color.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-color.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-color.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='video-color.c' object='libgstvideo_@GST_API_VERSION@_la-video-color.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-video-color.lo `test -f 'video-color.c' || echo '$(srcdir)/'`video-color.c
+
+libgstvideo_@GST_API_VERSION@_la-video-info.lo: video-info.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-video-info.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-info.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-video-info.lo `test -f 'video-info.c' || echo '$(srcdir)/'`video-info.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-info.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-info.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='video-info.c' object='libgstvideo_@GST_API_VERSION@_la-video-info.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-video-info.lo `test -f 'video-info.c' || echo '$(srcdir)/'`video-info.c
+
+libgstvideo_@GST_API_VERSION@_la-video-frame.lo: video-frame.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-video-frame.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-frame.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-video-frame.lo `test -f 'video-frame.c' || echo '$(srcdir)/'`video-frame.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-frame.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-frame.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='video-frame.c' object='libgstvideo_@GST_API_VERSION@_la-video-frame.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-video-frame.lo `test -f 'video-frame.c' || echo '$(srcdir)/'`video-frame.c
+
 libgstvideo_@GST_API_VERSION@_la-gstvideosink.lo: gstvideosink.c
 @am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-gstvideosink.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-gstvideosink.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-gstvideosink.lo `test -f 'gstvideosink.c' || echo '$(srcdir)/'`gstvideosink.c
 @am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-gstvideosink.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-gstvideosink.Plo
@@ -772,6 +877,13 @@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-gstvideoutils.lo `test -f 'gstvideoutils.c' || echo '$(srcdir)/'`gstvideoutils.c
 
+libgstvideo_@GST_API_VERSION@_la-tmp-orc.lo: tmp-orc.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-tmp-orc.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-tmp-orc.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-tmp-orc.lo `test -f 'tmp-orc.c' || echo '$(srcdir)/'`tmp-orc.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-tmp-orc.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-tmp-orc.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='tmp-orc.c' object='libgstvideo_@GST_API_VERSION@_la-tmp-orc.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -c -o libgstvideo_@GST_API_VERSION@_la-tmp-orc.lo `test -f 'tmp-orc.c' || echo '$(srcdir)/'`tmp-orc.c
+
 libgstvideo_@GST_API_VERSION@_la-video-enumtypes.lo: video-enumtypes.c
 @am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideo_@GST_API_VERSION@_la_CFLAGS) $(CFLAGS) -MT libgstvideo_@GST_API_VERSION@_la-video-enumtypes.lo -MD -MP -MF $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-enumtypes.Tpo -c -o libgstvideo_@GST_API_VERSION@_la-video-enumtypes.lo `test -f 'video-enumtypes.c' || echo '$(srcdir)/'`video-enumtypes.c
 @am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-enumtypes.Tpo $(DEPDIR)/libgstvideo_@GST_API_VERSION@_la-video-enumtypes.Plo
@@ -951,6 +1063,9 @@
 	    || exit 1; \
 	  fi; \
 	done
+	$(MAKE) $(AM_MAKEFLAGS) \
+	  top_distdir="$(top_distdir)" distdir="$(distdir)" \
+	  dist-hook
 check-am: all-am
 check: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) check-am
@@ -994,7 +1109,7 @@
 	-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
 clean: clean-am
 
-clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
+clean-am: clean-generic clean-libLTLIBRARIES clean-libtool clean-local \
 	mostlyclean-am
 
 distclean: distclean-am
@@ -1072,13 +1187,13 @@
 .MAKE: all check install install-am install-strip
 
 .PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
-	clean-libLTLIBRARIES clean-libtool ctags distclean \
-	distclean-compile distclean-generic distclean-libtool \
-	distclean-tags distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-girDATA \
-	install-html install-html-am install-info install-info-am \
-	install-libLTLIBRARIES \
+	clean-libLTLIBRARIES clean-libtool clean-local ctags dist-hook \
+	distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-girDATA install-html install-html-am \
+	install-info install-info-am install-libLTLIBRARIES \
 	install-libgstvideo_@GST_API_VERSION@includeHEADERS \
 	install-man \
 	install-nodist_libgstvideo_@GST_API_VERSION@includeHEADERS \
@@ -1094,6 +1209,42 @@
 	uninstall-typelibsDATA
 
 
+orc-update: tmp-orc.c $(ORC_SOURCE).h
+	$(top_srcdir)/common/gst-indent tmp-orc.c
+	cp tmp-orc.c $(srcdir)/$(ORC_SOURCE)-dist.c
+	cp $(ORC_SOURCE).h $(srcdir)/$(ORC_SOURCE)-dist.h
+
+@HAVE_ORCC_TRUE@tmp-orc.c: $(srcdir)/$(ORC_SOURCE).orc
+@HAVE_ORCC_TRUE@	$(orcc_v_gen)$(ORCC) $(ORCC_FLAGS) --implementation --include glib.h -o tmp-orc.c $(srcdir)/$(ORC_SOURCE).orc
+
+@HAVE_ORCC_TRUE@$(ORC_SOURCE).h: $(srcdir)/$(ORC_SOURCE).orc
+@HAVE_ORCC_TRUE@	$(orcc_v_gen)$(ORCC) $(ORCC_FLAGS) --header --include glib.h -o $(ORC_SOURCE).h $(srcdir)/$(ORC_SOURCE).orc
+@HAVE_ORCC_FALSE@tmp-orc.c: $(srcdir)/$(ORC_SOURCE).orc $(srcdir)/$(ORC_SOURCE)-dist.c
+@HAVE_ORCC_FALSE@	$(cp_v_gen)cp $(srcdir)/$(ORC_SOURCE)-dist.c tmp-orc.c
+
+@HAVE_ORCC_FALSE@$(ORC_SOURCE).h: $(srcdir)/$(ORC_SOURCE).orc $(srcdir)/$(ORC_SOURCE)-dist.c
+@HAVE_ORCC_FALSE@	$(cp_v_gen)cp $(srcdir)/$(ORC_SOURCE)-dist.h $(ORC_SOURCE).h
+
+clean-local: clean-orc
+.PHONY: clean-orc
+clean-orc:
+	rm -f tmp-orc.c $(ORC_SOURCE).h
+
+dist-hook: dist-hook-orc
+.PHONY: dist-hook-orc
+
+# we try and copy updated orc -dist files below, but don't fail if it
+# doesn't work as the srcdir might not be writable
+dist-hook-orc: tmp-orc.c $(ORC_SOURCE).h
+	$(top_srcdir)/common/gst-indent tmp-orc.c
+	rm -f tmp-orc.c~
+	cmp -s tmp-orc.c $(srcdir)/$(ORC_SOURCE)-dist.c || \
+	  cp tmp-orc.c $(srcdir)/$(ORC_SOURCE)-dist.c || true
+	cmp -s $(ORC_SOURCE).h $(srcdir)/$(ORC_SOURCE)-dist.h || \
+	  cp $(ORC_SOURCE).h $(srcdir)/$(ORC_SOURCE)-dist.h || true
+	cp -p tmp-orc.c $(distdir)/$(ORC_SOURCE)-dist.c
+	cp -p $(ORC_SOURCE).h $(distdir)/$(ORC_SOURCE)-dist.h
+
 # these are all the rules generating the relevant files
 $(glib_gen_basename)-marshal.h: $(glib_gen_basename)-marshal.list
 	$(AM_V_GEN)glib-genmarshal --header --prefix=$(glib_gen_prefix)_marshal $^ > $(glib_gen_basename)-marshal.h.tmp && \
diff --git a/gst-libs/gst/video/gstvideodecoder.c b/gst-libs/gst/video/gstvideodecoder.c
index 0778ca7..fb3c8d6 100644
--- a/gst-libs/gst/video/gstvideodecoder.c
+++ b/gst-libs/gst/video/gstvideodecoder.c
@@ -550,7 +550,16 @@
     tgt->interlace_mode = ref->interlace_mode;
     tgt->flags = ref->flags;
     tgt->chroma_site = ref->chroma_site;
-    tgt->colorimetry = ref->colorimetry;
+    /* only copy values that are not unknown so that we don't override the
+     * defaults. subclasses should really fill these in when they know. */
+    if (ref->colorimetry.range)
+      tgt->colorimetry.range = ref->colorimetry.range;
+    if (ref->colorimetry.matrix)
+      tgt->colorimetry.matrix = ref->colorimetry.matrix;
+    if (ref->colorimetry.transfer)
+      tgt->colorimetry.transfer = ref->colorimetry.transfer;
+    if (ref->colorimetry.primaries)
+      tgt->colorimetry.primaries = ref->colorimetry.primaries;
     GST_DEBUG ("reference par %d/%d fps %d/%d",
         ref->par_n, ref->par_d, ref->fps_n, ref->fps_d);
     tgt->par_n = ref->par_n;
@@ -1771,7 +1780,7 @@
   GList *l, *events = NULL;
 
 #ifndef GST_DISABLE_GST_DEBUG
-  GST_LOG_OBJECT (decoder, "n %d in %d out %d",
+  GST_LOG_OBJECT (decoder, "n %d in %" G_GSIZE_FORMAT " out %" G_GSIZE_FORMAT,
       g_list_length (priv->frames),
       gst_adapter_available (priv->input_adapter),
       gst_adapter_available (priv->output_adapter));
@@ -1865,9 +1874,14 @@
 gst_video_decoder_do_finish_frame (GstVideoDecoder * dec,
     GstVideoCodecFrame * frame)
 {
+  GList *link;
+
   /* unref once from the list */
-  dec->priv->frames = g_list_remove (dec->priv->frames, frame);
-  gst_video_codec_frame_unref (frame);
+  link = g_list_find (dec->priv->frames, frame);
+  if (link) {
+    gst_video_codec_frame_unref (frame);
+    dec->priv->frames = g_list_delete_link (dec->priv->frames, link);
+  }
 
   /* unref because this function takes ownership */
   gst_video_codec_frame_unref (frame);
@@ -2056,7 +2070,7 @@
 /**
  * gst_video_decoder_add_to_frame:
  * @decoder: a #GstVideoDecoder
- * @n_bytes: an encoded #GstVideoCodecFrame
+ * @n_bytes: the number of bytes to add
  *
  * Removes next @n_bytes of input data and adds it to currently parsed frame.
  *
@@ -2541,8 +2555,7 @@
  * gst_video_decoder_alloc_output_buffer:
  * @decoder: a #GstVideoDecoder
  *
- * Helper function that uses @gst_pad_alloc_buffer_and_set_caps()
- * to allocate a buffer to hold a video frame for @decoder's
+ * Helper function that allocates a buffer to hold a video frame for @decoder's
  * current #GstVideoCodecState.
  *
  * Returns: (transfer full): allocated buffer
@@ -2574,12 +2587,11 @@
  * @decoder: a #GstVideoDecoder
  * @frame: a #GstVideoCodecFrame
  *
- * Helper function that uses @gst_pad_alloc_buffer_and_set_caps()
- * to allocate a buffer to hold a video frame for @decoder's
- * current #GstVideoCodecState.  Subclass should already have configured video state
- * and set src pad caps.
+ * Helper function that allocates a buffer to hold a video frame for @decoder's
+ * current #GstVideoCodecState.  Subclass should already have configured video
+ * state and set src pad caps.
  *
- * Returns: result from pad alloc call
+ * Returns: %GST_FLOW_OK if an output buffer could be allocated
  *
  * Since: 0.10.36
  */
@@ -2775,7 +2787,9 @@
  * @min_latency: minimum latency
  * @max_latency: maximum latency
  *
- * Informs baseclass of encoding latency.
+ * Lets #GstVideoDecoder sub-classes tell the baseclass what the decoder
+ * latency is. Will also post a LATENCY message on the bus so the pipeline
+ * can reconfigure its global latency.
  *
  * Since: 0.10.36
  */
@@ -2798,10 +2812,13 @@
 /**
  * gst_video_decoder_get_latency:
  * @decoder: a #GstVideoDecoder
- * @min_latency: (out) (allow-none): the configured minimum latency
- * @max_latency: (out) (allow-none): the configured maximum latency
+ * @min_latency: (out) (allow-none): address of variable in which to store the
+ *     configured minimum latency, or %NULL
+ * @max_latency: (out) (allow-none): address of variable in which to store the
+ *     configured mximum latency, or %NULL
  *
- * Returns the configured encoding latency.
+ * Query the configured decoder latency. Results will be returned via
+ * @min_latency and @max_latency.
  *
  * Since: 0.10.36
  */
diff --git a/gst-libs/gst/video/gstvideoencoder.c b/gst-libs/gst/video/gstvideoencoder.c
index 1f05f9d..0405f04 100644
--- a/gst-libs/gst/video/gstvideoencoder.c
+++ b/gst-libs/gst/video/gstvideoencoder.c
@@ -1116,7 +1116,7 @@
     stop = start + GST_BUFFER_DURATION (buf);
 
   GST_LOG_OBJECT (encoder,
-      "received buffer of size %d with ts %" GST_TIME_FORMAT
+      "received buffer of size %" G_GSIZE_FORMAT " with ts %" GST_TIME_FORMAT
       ", duration %" GST_TIME_FORMAT, gst_buffer_get_size (buf),
       GST_TIME_ARGS (start), GST_TIME_ARGS (GST_BUFFER_DURATION (buf)));
 
@@ -1496,10 +1496,14 @@
 
 done:
   /* handed out */
-  priv->frames = g_list_remove (priv->frames, frame);
-  /* Remove the reference from the list and the reference that
-   * was provided to us */
-  gst_video_codec_frame_unref (frame);
+
+  /* unref once from the list */
+  l = g_list_find (priv->frames, frame);
+  if (l) {
+    gst_video_codec_frame_unref (frame);
+    priv->frames = g_list_delete_link (priv->frames, l);
+  }
+  /* unref because this function takes ownership */
   gst_video_codec_frame_unref (frame);
 
   GST_VIDEO_ENCODER_STREAM_UNLOCK (encoder);
@@ -1617,10 +1621,13 @@
 /**
  * gst_video_encoder_get_latency:
  * @encoder: a #GstVideoEncoder
- * @min_latency: (out) (allow-none): the configured minimum latency
- * @max_latency: (out) (allow-none): the configured maximum latency
+ * @min_latency: (out) (allow-none): address of variable in which to store the
+ *     configured minimum latency, or %NULL
+ * @max_latency: (out) (allow-none): address of variable in which to store the
+ *     configured maximum latency, or %NULL
  *
- * Returns the configured encoding latency.
+ * Query the configured encoding latency. Results will be returned via
+ * @min_latency and @max_latency.
  *
  * Since: 0.10.36
  */
diff --git a/gst-libs/gst/video/gstvideopool.c b/gst-libs/gst/video/gstvideopool.c
index 485decc..80219cb 100644
--- a/gst-libs/gst/video/gstvideopool.c
+++ b/gst-libs/gst/video/gstvideopool.c
@@ -101,7 +101,7 @@
   const GstVideoFormatInfo *vinfo = info->finfo;
   gint width, height;
   gint padded_width, padded_height;
-  gint i;
+  gint i, n_comp;
 
   width = GST_VIDEO_INFO_WIDTH (info);
   height = GST_VIDEO_INFO_HEIGHT (info);
@@ -119,19 +119,24 @@
   info->width = width;
   info->height = height;
 
+  n_comp = GST_VIDEO_INFO_N_COMPONENTS (info);
+  if (GST_VIDEO_FORMAT_INFO_HAS_PALETTE (vinfo))
+    n_comp--;
+
   /* FIXME, not quite correct, NV12 would apply the vedge twice on the second
    * plane */
-  for (i = 0; i < GST_VIDEO_INFO_N_COMPONENTS (info); i++) {
+  for (i = 0; i < n_comp; i++) {
     gint vedge, hedge, plane;
 
     hedge = GST_VIDEO_FORMAT_INFO_SCALE_WIDTH (vinfo, i, align->padding_left);
     vedge = GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT (vinfo, i, align->padding_top);
     plane = GST_VIDEO_FORMAT_INFO_PLANE (vinfo, i);
 
-    GST_DEBUG ("plane %d: hedge %d vedge %d align %d", plane, hedge, vedge,
-        align->stride_align[i]);
+    GST_DEBUG ("plane %d: hedge %d vedge %d align %d stride %d", plane, hedge,
+        vedge, align->stride_align[i], info->stride[plane]);
 
-    info->offset[plane] += (vedge * info->stride[plane]) + hedge;
+    info->offset[plane] += (vedge * info->stride[plane]) +
+        (hedge * GST_VIDEO_FORMAT_INFO_PSTRIDE (vinfo, i));
   }
 }
 
diff --git a/gst-libs/gst/video/gstvideoutils.c b/gst-libs/gst/video/gstvideoutils.c
index a47a6ef..91e5b96 100644
--- a/gst-libs/gst/video/gstvideoutils.c
+++ b/gst-libs/gst/video/gstvideoutils.c
@@ -49,33 +49,48 @@
   g_list_foreach (frame->events, (GFunc) gst_event_unref, NULL);
   g_list_free (frame->events);
 
-  if (frame->coder_hook_destroy_notify && frame->coder_hook)
-    frame->coder_hook_destroy_notify (frame->coder_hook);
+  if (frame->user_data_destroy_notify)
+    frame->user_data_destroy_notify (frame->user_data);
 
   g_slice_free (GstVideoCodecFrame, frame);
 }
 
 /**
- * gst_video_codec_frame_set_hook:
+ * gst_video_codec_frame_set_user_data:
  * @frame: a #GstVideoCodecFrame
- * @hook: private data
- * @notify: (closure hook): a #GDestroyNotify
+ * @user_data: private data
+ * @notify: (closure user_data): a #GDestroyNotify
  *
- * Sets the #GDestroyNotify that will be called (along with the @hook) when
- * the frame is freed.
+ * Sets @user_data on the frame and the #GDestroyNotify that will be called when
+ * the frame is freed. Allows to attach private data by the subclass to frames.
  *
- * If a @hook was previously set, then the previous set @notify will be called
- * before the @hook is replaced.
+ * If a @user_data was previously set, then the previous set @notify will be called
+ * before the @user_data is replaced.
  */
 void
-gst_video_codec_frame_set_hook (GstVideoCodecFrame * frame, void *hook,
-    GDestroyNotify notify)
+gst_video_codec_frame_set_user_data (GstVideoCodecFrame * frame,
+    gpointer user_data, GDestroyNotify notify)
 {
-  if (frame->coder_hook_destroy_notify && frame->coder_hook)
-    frame->coder_hook_destroy_notify (frame->coder_hook);
+  if (frame->user_data_destroy_notify)
+    frame->user_data_destroy_notify (frame->user_data);
 
-  frame->coder_hook = hook;
-  frame->coder_hook_destroy_notify = notify;
+  frame->user_data = user_data;
+  frame->user_data_destroy_notify = notify;
+}
+
+/**
+ * gst_video_codec_frame_get_user_data:
+ * @frame: a #GstVideoCodecFrame
+ *
+ * Gets private data set on the frame by the subclass via
+ * gst_video_codec_frame_set_user_data() previously.
+ *
+ * Returns: (transfer none): The previously set user_data
+ */
+gpointer
+gst_video_codec_frame_get_user_data (GstVideoCodecFrame * frame)
+{
+  return frame->user_data;
 }
 
 /**
@@ -140,6 +155,7 @@
     gst_caps_unref (state->caps);
   if (state->codec_data)
     gst_buffer_unref (state->codec_data);
+  g_slice_free (GstVideoCodecState, state);
 }
 
 /**
diff --git a/gst-libs/gst/video/gstvideoutils.h b/gst-libs/gst/video/gstvideoutils.h
index 7495faa..0628afd 100644
--- a/gst-libs/gst/video/gstvideoutils.h
+++ b/gst-libs/gst/video/gstvideoutils.h
@@ -205,9 +205,6 @@
  * @output_buffer: the output #GstBuffer. Implementations should set this either
  *           directly, or by using the @gst_video_decoder_alloc_output_frame() or
  *           @gst_video_decoder_alloc_output_buffer() methods.
- * @field_index:
- * @n_fields: number of fields in the frame (default 2). Decoders can change
- *       this if the frame contains a different number of fields. 
  * @deadline: Running time when the frame will be used.
  * @events: Events that will be pushed downstream before this frame is pushed.
  *
@@ -237,14 +234,14 @@
 
   GstClockTime deadline;	/* D */
 
+  /*< private >*/
+
   /* Events that should be pushed downstream *before*
    * the next output_buffer */
   GList *events;		/* ED */
 
-  /*< private >*/
-
-  void *coder_hook;
-  GDestroyNotify coder_hook_destroy_notify;
+  gpointer       user_data;
+  GDestroyNotify user_data_destroy_notify;
 
   void         *padding[GST_PADDING_LARGE];
 };
@@ -262,9 +259,10 @@
 
 GstVideoCodecFrame  *gst_video_codec_frame_ref (GstVideoCodecFrame * frame);
 void                 gst_video_codec_frame_unref (GstVideoCodecFrame * frame);
-void                 gst_video_codec_frame_set_hook (GstVideoCodecFrame *frame,
-						     void *hook,
-						     GDestroyNotify notify);
+void                 gst_video_codec_frame_set_user_data (GstVideoCodecFrame *frame,
+						          gpointer user_data,
+				                          GDestroyNotify notify);
+gpointer             gst_video_codec_frame_get_user_data (GstVideoCodecFrame *frame);
 
 G_END_DECLS
 
diff --git a/gst-libs/gst/video/video-color.c b/gst-libs/gst/video/video-color.c
new file mode 100644
index 0000000..37e470c
--- /dev/null
+++ b/gst-libs/gst/video/video-color.c
@@ -0,0 +1,181 @@
+/* GStreamer
+ * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
+ * Library       <2002> Ronald Bultje <rbultje@ronald.bitfreak.net>
+ * Copyright (C) 2007 David A. Schleef <ds@schleef.org>
+ *
+ * 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 <stdio.h>
+
+#include "video-color.h"
+
+typedef struct
+{
+  const gchar *name;
+  GstVideoColorimetry color;
+} ColorimetryInfo;
+
+#define MAKE_COLORIMETRY(n,r,m,t,p) { GST_VIDEO_COLORIMETRY_ ##n, \
+  { GST_VIDEO_COLOR_RANGE ##r, GST_VIDEO_COLOR_MATRIX_ ##m, \
+  GST_VIDEO_TRANSFER_ ##t, GST_VIDEO_COLOR_PRIMARIES_ ##p } }
+
+#define GST_VIDEO_COLORIMETRY_NONAME  NULL
+
+#define DEFAULT_YUV_SD  0
+#define DEFAULT_YUV_HD  1
+#define DEFAULT_RGB     3
+#define DEFAULT_GRAY    4
+#define DEFAULT_UNKNOWN 5
+
+static const ColorimetryInfo colorimetry[] = {
+  MAKE_COLORIMETRY (BT601, _16_235, BT601, BT709, BT470M),
+  MAKE_COLORIMETRY (BT709, _16_235, BT709, BT709, BT709),
+  MAKE_COLORIMETRY (SMPTE240M, _16_235, SMPTE240M, SMPTE240M, SMPTE240M),
+  MAKE_COLORIMETRY (NONAME, _0_255, RGB, UNKNOWN, UNKNOWN),
+  MAKE_COLORIMETRY (NONAME, _0_255, BT601, UNKNOWN, UNKNOWN),
+  MAKE_COLORIMETRY (NONAME, _UNKNOWN, UNKNOWN, UNKNOWN, UNKNOWN),
+};
+
+static const ColorimetryInfo *
+gst_video_get_colorimetry (const gchar * s)
+{
+  gint i;
+
+  for (i = 0; colorimetry[i].name; i++) {
+    if (g_str_equal (colorimetry[i].name, s))
+      return &colorimetry[i];
+  }
+  return NULL;
+}
+
+#define IS_EQUAL(ci,i) (((ci)->color.range == (i)->range) && \
+                        ((ci)->color.matrix == (i)->matrix) && \
+                        ((ci)->color.transfer == (i)->transfer) && \
+                        ((ci)->color.primaries == (i)->primaries))
+
+#define IS_UNKNOWN(ci) (IS_EQUAL (&colorimetry[DEFAULT_UNKNOWN], ci))
+
+/**
+ * gst_video_colorimetry_from_string
+ * @cinfo: a #GstVideoColorimetry
+ * @color: a colorimetry string
+ *
+ * Parse the colorimetry string and update @cinfo with the parsed
+ * values.
+ *
+ * Returns: #TRUE if @color points to valid colorimetry info.
+ */
+gboolean
+gst_video_colorimetry_from_string (GstVideoColorimetry * cinfo,
+    const gchar * color)
+{
+  const ColorimetryInfo *ci;
+
+  if ((ci = gst_video_get_colorimetry (color))) {
+    *cinfo = ci->color;
+  } else {
+    gint r, m, t, p;
+
+    if (sscanf (color, "%d:%d:%d:%d", &r, &m, &t, &p) == 4) {
+      cinfo->range = r;
+      cinfo->matrix = m;
+      cinfo->transfer = t;
+      cinfo->primaries = p;
+    }
+  }
+  return TRUE;
+}
+
+/**
+ * gst_video_colorimetry_to_string
+ * @cinfo: a #GstVideoColorimetry
+ *
+ * Make a string representation of @cinfo.
+ *
+ * Returns: a string representation of @cinfo.
+ */
+gchar *
+gst_video_colorimetry_to_string (GstVideoColorimetry * cinfo)
+{
+  gint i;
+
+  for (i = 0; colorimetry[i].name; i++) {
+    if (IS_EQUAL (&colorimetry[i], cinfo)) {
+      return g_strdup (colorimetry[i].name);
+    }
+  }
+  if (!IS_UNKNOWN (cinfo)) {
+    return g_strdup_printf ("%d:%d:%d:%d", cinfo->range, cinfo->matrix,
+        cinfo->transfer, cinfo->primaries);
+  }
+  return NULL;
+}
+
+/**
+ * gst_video_colorimetry_matches:
+ * @info: a #GstVideoInfo
+ * @color: a colorimetry string
+ *
+ * Check if the colorimetry information in @info matches that of the
+ * string @color.
+ *
+ * Returns: #TRUE if @color conveys the same colorimetry info as the color
+ * information in @info.
+ */
+gboolean
+gst_video_colorimetry_matches (GstVideoColorimetry * cinfo, const gchar * color)
+{
+  const ColorimetryInfo *ci;
+
+  if ((ci = gst_video_get_colorimetry (color)))
+    return IS_EQUAL (ci, cinfo);
+
+  return FALSE;
+}
+
+#if 0
+typedef struct
+{
+  GstVideoColorPrimaries primaries;
+  gdouble xW, yW;
+  gdouble xR, yR;
+  gdouble xG, yG;
+  gdouble xB, yB;
+} PrimariesInfo;
+
+#define WP_C    0.31006, 0.31616
+#define WP_D65  0.31271, 0.32902
+
+static const PrimariesInfo primaries[] = {
+  {GST_VIDEO_COLOR_PRIMARIES_UNKNOWN, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0},
+  {GST_VIDEO_COLOR_PRIMARIES_BT709, WP_D65, 0.64, 0.33, 0.30, 0.60, 0.15, 0.06},
+  {GST_VIDEO_COLOR_PRIMARIES_BT470M, WP_C, 0.67, 0.33, 0.21, 0.71, 0.14, 0.08},
+  {GST_VIDEO_COLOR_PRIMARIES_BT470BG, WP_D65, 0.64, 0.33, 0.29, 0.60, 0.15,
+      0.06},
+  {GST_VIDEO_COLOR_PRIMARIES_SMPTE170M, WP_D65, 0.63, 0.34, 0.31, 0.595, 0.155,
+      0.07},
+  {GST_VIDEO_COLOR_PRIMARIES_SMPTE240M, WP_D65, 0.63, 0.34, 0.31, 0.595, 0.155,
+      0.07},
+  {GST_VIDEO_COLOR_PRIMARIES_FILM, WP_C, 0.681, 0.319, 0.243, 0.692, 0.145,
+      0.049}
+};
+#endif
diff --git a/gst-libs/gst/video/video-color.h b/gst-libs/gst/video/video-color.h
new file mode 100644
index 0000000..b574935
--- /dev/null
+++ b/gst-libs/gst/video/video-color.h
@@ -0,0 +1,152 @@
+/* GStreamer
+ * Copyright (C) <2011> Wim Taymans <wim.taymans@gmail.com>
+ *
+ * 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_VIDEO_COLOR_H__
+#define __GST_VIDEO_COLOR_H__
+
+#include <gst/gst.h>
+
+G_BEGIN_DECLS
+
+/**
+ * GstVideoColorRange:
+ * @GST_VIDEO_COLOR_RANGE_UNKNOWN: unknown range
+ * @GST_VIDEO_COLOR_RANGE_0_255: [0..255] for 8 bit components
+ * @GST_VIDEO_COLOR_RANGE_16_235: [16..235] for 8 bit components. Chroma has
+ *                 [16..240] range.
+ *
+ * Possible color range values. These constants are defined for 8 bit color
+ * values and can be scaled for other bit depths.
+ */
+typedef enum {
+  GST_VIDEO_COLOR_RANGE_UNKNOWN = 0,
+  GST_VIDEO_COLOR_RANGE_0_255,
+  GST_VIDEO_COLOR_RANGE_16_235
+} GstVideoColorRange;
+
+/**
+ * GstVideoColorMatrix:
+ * @GST_VIDEO_COLOR_MATRIX_UNKNOWN: unknown matrix
+ * @GST_VIDEO_COLOR_MATRIX_RGB: identity matrix
+ * @GST_VIDEO_COLOR_MATRIX_FCC: FCC color matrix
+ * @GST_VIDEO_COLOR_MATRIX_BT709: ITU-R BT.709 color matrix
+ * @GST_VIDEO_COLOR_MATRIX_BT601: ITU-R BT.601 color matrix
+ * @GST_VIDEO_COLOR_MATRIX_SMPTE240M: SMPTE 240M color matrix
+ *
+ * The color matrix is used to convert between Y'PbPr and
+ * non-linear RGB (R'G'B')
+ */
+typedef enum {
+  GST_VIDEO_COLOR_MATRIX_UNKNOWN = 0,
+  GST_VIDEO_COLOR_MATRIX_RGB,
+  GST_VIDEO_COLOR_MATRIX_FCC,
+  GST_VIDEO_COLOR_MATRIX_BT709,
+  GST_VIDEO_COLOR_MATRIX_BT601,
+  GST_VIDEO_COLOR_MATRIX_SMPTE240M
+} GstVideoColorMatrix;
+
+/**
+ * GstVideoTransferFunction:
+ * @GST_VIDEO_TRANSFER_UNKNOWN: unknown transfer function
+ * @GST_VIDEO_TRANSFER_GAMMA10: linear RGB, gamma 1.0 curve
+ * @GST_VIDEO_TRANSFER_GAMMA18: Gamma 1.8 curve
+ * @GST_VIDEO_TRANSFER_GAMMA20: Gamma 2.0 curve
+ * @GST_VIDEO_TRANSFER_GAMMA22: Gamma 2.2 curve
+ * @GST_VIDEO_TRANSFER_BT709: Gamma 2.2 curve with a linear segment in the lower
+ *                           range
+ * @GST_VIDEO_TRANSFER_SMPTE240M: Gamma 2.2 curve with a linear segment in the
+ *                               lower range
+ * @GST_VIDEO_TRANSFER_SRGB: Gamma 2.4 curve with a linear segment in the lower
+ *                          range
+ * @GST_VIDEO_TRANSFER_GAMMA28: Gamma 2.8 curve
+ * @GST_VIDEO_TRANSFER_LOG100: Logarithmic transfer characteristic
+ *                             100:1 range
+ * @GST_VIDEO_TRANSFER_LOG316: Logarithmic transfer characteristic
+ *                             316.22777:1 range
+ *
+ * The video transfer function defines the formula for converting between
+ * non-linear RGB (R'G'B') and linear RGB
+ */
+typedef enum {
+  GST_VIDEO_TRANSFER_UNKNOWN = 0,
+  GST_VIDEO_TRANSFER_GAMMA10,
+  GST_VIDEO_TRANSFER_GAMMA18,
+  GST_VIDEO_TRANSFER_GAMMA20,
+  GST_VIDEO_TRANSFER_GAMMA22,
+  GST_VIDEO_TRANSFER_BT709,
+  GST_VIDEO_TRANSFER_SMPTE240M,
+  GST_VIDEO_TRANSFER_SRGB,
+  GST_VIDEO_TRANSFER_GAMMA28,
+  GST_VIDEO_TRANSFER_LOG100,
+  GST_VIDEO_TRANSFER_LOG316
+} GstVideoTransferFunction;
+
+/**
+ * GstVideoColorPrimaries:
+ * @GST_VIDEO_COLOR_PRIMARIES_UNKNOWN: unknown color primaries
+ * @GST_VIDEO_COLOR_PRIMARIES_BT709: BT709 primaries
+ * @GST_VIDEO_COLOR_PRIMARIES_BT470M: BT470M primaries
+ * @GST_VIDEO_COLOR_PRIMARIES_BT470BG: BT470BG primaries
+ * @GST_VIDEO_COLOR_PRIMARIES_SMPTE170M: SMPTE170M primaries
+ * @GST_VIDEO_COLOR_PRIMARIES_SMPTE240M: SMPTE240M primaries
+ * @GST_VIDEO_COLOR_PRIMARIES_FILM: Generic film
+ *
+ * The color primaries define the how to transform linear RGB values to and from
+ * the CIE XYZ colorspace.
+ */
+typedef enum {
+  GST_VIDEO_COLOR_PRIMARIES_UNKNOWN = 0,
+  GST_VIDEO_COLOR_PRIMARIES_BT709,
+  GST_VIDEO_COLOR_PRIMARIES_BT470M,
+  GST_VIDEO_COLOR_PRIMARIES_BT470BG,
+  GST_VIDEO_COLOR_PRIMARIES_SMPTE170M,
+  GST_VIDEO_COLOR_PRIMARIES_SMPTE240M,
+  GST_VIDEO_COLOR_PRIMARIES_FILM
+} GstVideoColorPrimaries;
+
+/**
+ * GstVideoColorimetry:
+ * @range: the color range. This is the valid range for the samples.
+ *         It is used to convert the samples to Y'PbPr values.
+ * @matrix: the color matrix. Used to convert between Y'PbPr and
+ *          non-linear RGB (R'G'B')
+ * @transfer: the transfer function. used to convert between R'G'B' and RGB
+ * @primaries: color primaries. used to convert between R'G'B' and CIE XYZ
+ *
+ * Structure describing the color info.
+ */
+typedef struct {
+  GstVideoColorRange        range;
+  GstVideoColorMatrix       matrix;
+  GstVideoTransferFunction  transfer;
+  GstVideoColorPrimaries    primaries;
+} GstVideoColorimetry;
+
+/* predefined colorimetry */
+#define GST_VIDEO_COLORIMETRY_BT601       "bt601"
+#define GST_VIDEO_COLORIMETRY_BT709       "bt709"
+#define GST_VIDEO_COLORIMETRY_SMPTE240M   "smpte240m"
+
+gboolean     gst_video_colorimetry_matches     (GstVideoColorimetry *cinfo, const gchar *color);
+gboolean     gst_video_colorimetry_from_string (GstVideoColorimetry *cinfo, const gchar *color);
+gchar *      gst_video_colorimetry_to_string   (GstVideoColorimetry *cinfo);
+
+G_END_DECLS
+
+#endif /* __GST_VIDEO_COLOR_H__ */
diff --git a/gst-libs/gst/video/video-event.c b/gst-libs/gst/video/video-event.c
new file mode 100644
index 0000000..0402a63
--- /dev/null
+++ b/gst-libs/gst/video/video-event.c
@@ -0,0 +1,314 @@
+/* GStreamer
+ * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
+ * Library       <2002> Ronald Bultje <rbultje@ronald.bitfreak.net>
+ * Copyright (C) 2007 David A. Schleef <ds@schleef.org>
+ *
+ * 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.
+ */
+
+#include "video-event.h"
+
+#define GST_VIDEO_EVENT_STILL_STATE_NAME "GstEventStillFrame"
+
+/**
+ * gst_video_event_new_still_frame:
+ * @in_still: boolean value for the still-frame state of the event.
+ *
+ * Creates a new Still Frame event. If @in_still is %TRUE, then the event
+ * represents the start of a still frame sequence. If it is %FALSE, then
+ * the event ends a still frame sequence.
+ *
+ * To parse an event created by gst_video_event_new_still_frame() use
+ * gst_video_event_parse_still_frame().
+ *
+ * Returns: The new GstEvent
+ * Since: 0.10.26
+ */
+GstEvent *
+gst_video_event_new_still_frame (gboolean in_still)
+{
+  GstEvent *still_event;
+  GstStructure *s;
+
+  s = gst_structure_new (GST_VIDEO_EVENT_STILL_STATE_NAME,
+      "still-state", G_TYPE_BOOLEAN, in_still, NULL);
+  still_event = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM, s);
+
+  return still_event;
+}
+
+/**
+ * gst_video_event_parse_still_frame:
+ * @event: A #GstEvent to parse
+ * @in_still: A boolean to receive the still-frame status from the event, or NULL
+ *
+ * Parse a #GstEvent, identify if it is a Still Frame event, and
+ * return the still-frame state from the event if it is.
+ * If the event represents the start of a still frame, the in_still
+ * variable will be set to TRUE, otherwise FALSE. It is OK to pass NULL for the
+ * in_still variable order to just check whether the event is a valid still-frame
+ * event.
+ *
+ * Create a still frame event using gst_video_event_new_still_frame()
+ *
+ * Returns: %TRUE if the event is a valid still-frame event. %FALSE if not
+ * Since: 0.10.26
+ */
+gboolean
+gst_video_event_parse_still_frame (GstEvent * event, gboolean * in_still)
+{
+  const GstStructure *s;
+  gboolean ev_still_state;
+
+  g_return_val_if_fail (event != NULL, FALSE);
+
+  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_DOWNSTREAM)
+    return FALSE;               /* Not a still frame event */
+
+  s = gst_event_get_structure (event);
+  if (s == NULL
+      || !gst_structure_has_name (s, GST_VIDEO_EVENT_STILL_STATE_NAME))
+    return FALSE;               /* Not a still frame event */
+  if (!gst_structure_get_boolean (s, "still-state", &ev_still_state))
+    return FALSE;               /* Not a still frame event */
+  if (in_still)
+    *in_still = ev_still_state;
+  return TRUE;
+}
+
+#define GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME "GstForceKeyUnit"
+
+/**
+ * gst_video_event_new_downstream_force_key_unit:
+ * @timestamp: the timestamp of the buffer that starts a new key unit
+ * @stream_time: the stream_time of the buffer that starts a new key unit
+ * @running_time: the running_time of the buffer that starts a new key unit
+ * @all_headers: %TRUE to produce headers when starting a new key unit
+ * @count: integer that can be used to number key units
+ *
+ * Creates a new downstream force key unit event. A downstream force key unit
+ * event can be sent down the pipeline to request downstream elements to produce
+ * a key unit. A downstream force key unit event must also be sent when handling
+ * an upstream force key unit event to notify downstream that the latter has been
+ * handled.
+ *
+ * To parse an event created by gst_video_event_new_downstream_force_key_unit() use
+ * gst_video_event_parse_downstream_force_key_unit().
+ *
+ * Returns: The new GstEvent
+ * Since: 0.10.36
+ */
+GstEvent *
+gst_video_event_new_downstream_force_key_unit (GstClockTime timestamp,
+    GstClockTime stream_time, GstClockTime running_time, gboolean all_headers,
+    guint count)
+{
+  GstEvent *force_key_unit_event;
+  GstStructure *s;
+
+  s = gst_structure_new (GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME,
+      "timestamp", G_TYPE_UINT64, timestamp,
+      "stream-time", G_TYPE_UINT64, stream_time,
+      "running-time", G_TYPE_UINT64, running_time,
+      "all-headers", G_TYPE_BOOLEAN, all_headers,
+      "count", G_TYPE_UINT, count, NULL);
+  force_key_unit_event = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM, s);
+
+  return force_key_unit_event;
+}
+
+/**
+ * gst_video_event_new_upstream_force_key_unit:
+ * @running_time: the running_time at which a new key unit should be produced
+ * @all_headers: %TRUE to produce headers when starting a new key unit
+ * @count: integer that can be used to number key units
+ *
+ * Creates a new upstream force key unit event. An upstream force key unit event
+ * can be sent to request upstream elements to produce a key unit. 
+ *
+ * @running_time can be set to request a new key unit at a specific
+ * running_time. If set to GST_CLOCK_TIME_NONE, upstream elements will produce a
+ * new key unit as soon as possible.
+ *
+ * To parse an event created by gst_video_event_new_downstream_force_key_unit() use
+ * gst_video_event_parse_downstream_force_key_unit().
+ *
+ * Returns: The new GstEvent
+ * Since: 0.10.36
+ */
+GstEvent *
+gst_video_event_new_upstream_force_key_unit (GstClockTime running_time,
+    gboolean all_headers, guint count)
+{
+  GstEvent *force_key_unit_event;
+  GstStructure *s;
+
+  s = gst_structure_new (GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME,
+      "running-time", GST_TYPE_CLOCK_TIME, running_time,
+      "all-headers", G_TYPE_BOOLEAN, all_headers,
+      "count", G_TYPE_UINT, count, NULL);
+  force_key_unit_event = gst_event_new_custom (GST_EVENT_CUSTOM_UPSTREAM, s);
+
+  return force_key_unit_event;
+}
+
+/**
+ * gst_video_event_is_force_key_unit:
+ * @event: A #GstEvent to check
+ *
+ * Checks if an event is a force key unit event. Returns true for both upstream
+ * and downstream force key unit events.
+ *
+ * Returns: %TRUE if the event is a valid force key unit event
+ * Since: 0.10.36
+ */
+gboolean
+gst_video_event_is_force_key_unit (GstEvent * event)
+{
+  const GstStructure *s;
+
+  g_return_val_if_fail (event != NULL, FALSE);
+
+  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_DOWNSTREAM &&
+      GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_UPSTREAM)
+    return FALSE;               /* Not a force key unit event */
+
+  s = gst_event_get_structure (event);
+  if (s == NULL
+      || !gst_structure_has_name (s, GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME))
+    return FALSE;
+
+  return TRUE;
+}
+
+/**
+ * gst_video_event_parse_downstream_force_key_unit:
+ * @event: A #GstEvent to parse
+ * @timestamp: (out): A pointer to the timestamp in the event
+ * @stream_time: (out): A pointer to the stream-time in the event
+ * @running_time: (out): A pointer to the running-time in the event
+ * @all_headers: (out): A pointer to the all_headers flag in the event
+ * @count: (out): A pointer to the count field of the event
+ *
+ * Get timestamp, stream-time, running-time, all-headers and count in the force
+ * key unit event. See gst_video_event_new_downstream_force_key_unit() for a
+ * full description of the downstream force key unit event.
+ *
+ * Returns: %TRUE if the event is a valid downstream force key unit event.
+ * Since: 0.10.36
+ */
+gboolean
+gst_video_event_parse_downstream_force_key_unit (GstEvent * event,
+    GstClockTime * timestamp, GstClockTime * stream_time,
+    GstClockTime * running_time, gboolean * all_headers, guint * count)
+{
+  const GstStructure *s;
+  GstClockTime ev_timestamp, ev_stream_time, ev_running_time;
+  gboolean ev_all_headers;
+  guint ev_count;
+
+  g_return_val_if_fail (event != NULL, FALSE);
+
+  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_DOWNSTREAM)
+    return FALSE;               /* Not a force key unit event */
+
+  s = gst_event_get_structure (event);
+  if (s == NULL
+      || !gst_structure_has_name (s, GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME))
+    return FALSE;
+
+  if (!gst_structure_get_clock_time (s, "timestamp", &ev_timestamp))
+    ev_timestamp = GST_CLOCK_TIME_NONE;
+  if (!gst_structure_get_clock_time (s, "stream-time", &ev_stream_time))
+    ev_stream_time = GST_CLOCK_TIME_NONE;
+  if (!gst_structure_get_clock_time (s, "running-time", &ev_running_time))
+    ev_running_time = GST_CLOCK_TIME_NONE;
+  if (!gst_structure_get_boolean (s, "all-headers", &ev_all_headers))
+    ev_all_headers = FALSE;
+  if (!gst_structure_get_uint (s, "count", &ev_count))
+    ev_count = 0;
+
+  if (timestamp)
+    *timestamp = ev_timestamp;
+
+  if (stream_time)
+    *stream_time = ev_stream_time;
+
+  if (running_time)
+    *running_time = ev_running_time;
+
+  if (all_headers)
+    *all_headers = ev_all_headers;
+
+  if (count)
+    *count = ev_count;
+
+  return TRUE;
+}
+
+/**
+ * gst_video_event_parse_upstream_force_key_unit:
+ * @event: A #GstEvent to parse
+ * @running_time: (out): A pointer to the running_time in the event
+ * @all_headers: (out): A pointer to the all_headers flag in the event
+ * @count: (out): A pointer to the count field in the event
+ *
+ * Get running-time, all-headers and count in the force key unit event. See
+ * gst_video_event_new_upstream_force_key_unit() for a full description of the
+ * upstream force key unit event.
+ *
+ * Create an upstream force key unit event using  gst_video_event_new_upstream_force_key_unit()
+ *
+ * Returns: %TRUE if the event is a valid upstream force-key-unit event. %FALSE if not
+ * Since: 0.10.36
+ */
+gboolean
+gst_video_event_parse_upstream_force_key_unit (GstEvent * event,
+    GstClockTime * running_time, gboolean * all_headers, guint * count)
+{
+  const GstStructure *s;
+  GstClockTime ev_running_time;
+  gboolean ev_all_headers;
+  guint ev_count;
+
+  g_return_val_if_fail (event != NULL, FALSE);
+
+  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_UPSTREAM)
+    return FALSE;               /* Not a force key unit event */
+
+  s = gst_event_get_structure (event);
+  if (s == NULL
+      || !gst_structure_has_name (s, GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME))
+    return FALSE;
+
+  if (!gst_structure_get_clock_time (s, "running-time", &ev_running_time))
+    ev_running_time = GST_CLOCK_TIME_NONE;
+  if (!gst_structure_get_boolean (s, "all-headers", &ev_all_headers))
+    ev_all_headers = FALSE;
+  if (!gst_structure_get_uint (s, "count", &ev_count))
+    ev_count = 0;
+
+  if (running_time)
+    *running_time = ev_running_time;
+
+  if (all_headers)
+    *all_headers = ev_all_headers;
+
+  if (count)
+    *count = ev_count;
+
+  return TRUE;
+}
diff --git a/gst-libs/gst/video/video-event.h b/gst-libs/gst/video/video-event.h
new file mode 100644
index 0000000..78559f6
--- /dev/null
+++ b/gst-libs/gst/video/video-event.h
@@ -0,0 +1,61 @@
+/* GStreamer
+ * Copyright (C) <2011> Wim Taymans <wim.taymans@gmail.com>
+ *
+ * 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_VIDEO_EVENT_H__
+#define __GST_VIDEO_EVENT_H__
+
+#include <gst/gst.h>
+
+G_BEGIN_DECLS
+
+/* video still frame event creation and parsing */
+
+GstEvent *     gst_video_event_new_still_frame   (gboolean in_still);
+
+gboolean       gst_video_event_parse_still_frame (GstEvent * event, gboolean * in_still);
+
+/* video force key unit event creation and parsing */
+
+GstEvent * gst_video_event_new_downstream_force_key_unit (GstClockTime timestamp,
+                                                          GstClockTime stream_time,
+                                                          GstClockTime running_time,
+                                                          gboolean all_headers,
+                                                          guint count);
+
+gboolean gst_video_event_parse_downstream_force_key_unit (GstEvent * event,
+                                                          GstClockTime * timestamp,
+                                                          GstClockTime * stream_time,
+                                                          GstClockTime * running_time,
+                                                          gboolean * all_headers,
+                                                          guint * count);
+
+GstEvent * gst_video_event_new_upstream_force_key_unit (GstClockTime running_time,
+                                                        gboolean all_headers,
+                                                        guint count);
+
+gboolean gst_video_event_parse_upstream_force_key_unit (GstEvent * event,
+                                                        GstClockTime * running_time,
+                                                        gboolean * all_headers,
+                                                        guint * count);
+
+gboolean gst_video_event_is_force_key_unit(GstEvent *event);
+
+G_END_DECLS
+
+#endif /* __GST_VIDEO_EVENT_H__ */
diff --git a/gst-libs/gst/video/video-format.c b/gst-libs/gst/video/video-format.c
new file mode 100644
index 0000000..aa74cba
--- /dev/null
+++ b/gst-libs/gst/video/video-format.c
@@ -0,0 +1,1837 @@
+/* GStreamer
+ * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
+ * Library       <2002> Ronald Bultje <rbultje@ronald.bitfreak.net>
+ * Copyright (C) 2007 David A. Schleef <ds@schleef.org>
+ *
+ * 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 <stdio.h>
+
+#include "video-format.h"
+
+/**
+ * SECTION:gstvideo
+ * @short_description: Support library for video operations
+ *
+ * <refsect2>
+ * <para>
+ * This library contains some helper functions and includes the
+ * videosink and videofilter base classes.
+ * </para>
+ * </refsect2>
+ */
+
+#include "videoblendorc.h"
+
+/* Line conversion to AYUV */
+
+#define GET_PLANE_STRIDE(plane) (stride(plane))
+#define GET_PLANE_LINE(plane, line) \
+  (gpointer)(((guint8*)(data[plane])) + stride[plane] * (line))
+
+#define GET_COMP_STRIDE(comp) \
+  GST_VIDEO_FORMAT_INFO_STRIDE (info, stride, comp)
+#define GET_COMP_DATA(comp) \
+  GST_VIDEO_FORMAT_INFO_DATA (info, data, comp)
+
+#define GET_COMP_LINE(comp, line) \
+  (gpointer)(((guint8*)GET_COMP_DATA (comp)) + \
+      GET_COMP_STRIDE(comp) * (line))
+
+#define GET_STRIDE()                 GET_PLANE_STRIDE (0)
+#define GET_LINE(line)               GET_PLANE_LINE (0, line)
+
+#define GET_Y_LINE(line)             GET_COMP_LINE(GST_VIDEO_COMP_Y, line)
+#define GET_U_LINE(line)             GET_COMP_LINE(GST_VIDEO_COMP_U, line)
+#define GET_V_LINE(line)             GET_COMP_LINE(GST_VIDEO_COMP_V, line)
+#define GET_A_LINE(line)             GET_COMP_LINE(GST_VIDEO_COMP_A, line)
+
+#define GET_Y_STRIDE()               GET_COMP_STRIDE(GST_VIDEO_COMP_Y)
+#define GET_U_STRIDE()               GET_COMP_STRIDE(GST_VIDEO_COMP_U)
+#define GET_V_STRIDE()               GET_COMP_STRIDE(GST_VIDEO_COMP_V)
+#define GET_A_STRIDE()               GET_COMP_STRIDE(GST_VIDEO_COMP_A)
+
+#define PACK_420 GST_VIDEO_FORMAT_AYUV, unpack_planar_420, 1, pack_planar_420
+static void
+unpack_planar_420 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_I420 (dest,
+      GET_Y_LINE (y), GET_U_LINE (y >> 1), GET_V_LINE (y >> 1), width);
+}
+
+static void
+pack_planar_420 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_I420 (GET_Y_LINE (y),
+      GET_U_LINE (y >> 1), GET_V_LINE (y >> 1), src, width / 2);
+}
+
+#define PACK_YUY2 GST_VIDEO_FORMAT_AYUV, unpack_YUY2, 1, pack_YUY2
+static void
+unpack_YUY2 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_YUY2 (dest, GET_LINE (y), width / 2);
+}
+
+static void
+pack_YUY2 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_YUY2 (GET_LINE (y), src, width / 2);
+}
+
+#define PACK_UYVY GST_VIDEO_FORMAT_AYUV, unpack_UYVY, 1, pack_UYVY
+static void
+unpack_UYVY (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_UYVY (dest, GET_LINE (y), width / 2);
+}
+
+static void
+pack_UYVY (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_UYVY (GET_LINE (y), src, width / 2);
+}
+
+#define PACK_YVYU GST_VIDEO_FORMAT_AYUV, unpack_YVYU, 1, pack_YVYU
+static void
+unpack_YVYU (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_YVYU (dest, GET_LINE (y), width / 2);
+}
+
+static void
+pack_YVYU (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_YVYU (GET_LINE (y), src, width / 2);
+}
+
+#define PACK_v308 GST_VIDEO_FORMAT_AYUV, unpack_v308, 1, pack_v308
+static void
+unpack_v308 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 1] = s[i * 3 + 0];
+    d[i * 4 + 2] = s[i * 3 + 1];
+    d[i * 4 + 3] = s[i * 3 + 2];
+  }
+}
+
+static void
+pack_v308 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i * 3 + 0] = s[i * 4 + 1];
+    d[i * 3 + 1] = s[i * 4 + 2];
+    d[i * 3 + 2] = s[i * 4 + 3];
+  }
+}
+
+#define PACK_AYUV GST_VIDEO_FORMAT_AYUV, unpack_copy4, 1, pack_copy4
+#define PACK_ARGB GST_VIDEO_FORMAT_ARGB, unpack_copy4, 1, pack_copy4
+static void
+unpack_copy4 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  memcpy (dest, GET_LINE (y), width * 4);
+}
+
+static void
+pack_copy4 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  memcpy (GET_LINE (y), src, width * 4);
+}
+
+#define PACK_v210 GST_VIDEO_FORMAT_AYUV64, unpack_v210, 1, pack_v210
+static void
+unpack_v210 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i += 6) {
+    guint32 a0, a1, a2, a3;
+    guint16 y0, y1, y2, y3, y4, y5;
+    guint16 u0, u2, u4;
+    guint16 v0, v2, v4;
+
+    a0 = GST_READ_UINT32_LE (s + (i / 6) * 16 + 0);
+    a1 = GST_READ_UINT32_LE (s + (i / 6) * 16 + 4);
+    a2 = GST_READ_UINT32_LE (s + (i / 6) * 16 + 8);
+    a3 = GST_READ_UINT32_LE (s + (i / 6) * 16 + 12);
+
+    u0 = ((a0 >> 0) & 0x3ff) << 6;
+    y0 = ((a0 >> 10) & 0x3ff) << 6;
+    v0 = ((a0 >> 20) & 0x3ff) << 6;
+    y1 = ((a1 >> 0) & 0x3ff) << 6;
+
+    u2 = ((a1 >> 10) & 0x3ff) << 6;
+    y2 = ((a1 >> 20) & 0x3ff) << 6;
+    v2 = ((a2 >> 0) & 0x3ff) << 6;
+    y3 = ((a2 >> 10) & 0x3ff) << 6;
+
+    u4 = ((a2 >> 20) & 0x3ff) << 6;
+    y4 = ((a3 >> 0) & 0x3ff) << 6;
+    v4 = ((a3 >> 10) & 0x3ff) << 6;
+    y5 = ((a3 >> 20) & 0x3ff) << 6;
+
+    d[4 * (i + 0) + 0] = 0xffff;
+    d[4 * (i + 0) + 1] = y0;
+    d[4 * (i + 0) + 2] = u0;
+    d[4 * (i + 0) + 3] = v0;
+
+    d[4 * (i + 1) + 0] = 0xffff;
+    d[4 * (i + 1) + 1] = y1;
+    d[4 * (i + 1) + 2] = u0;
+    d[4 * (i + 1) + 3] = v0;
+
+    d[4 * (i + 2) + 0] = 0xffff;
+    d[4 * (i + 2) + 1] = y2;
+    d[4 * (i + 2) + 2] = u2;
+    d[4 * (i + 2) + 3] = v2;
+
+    d[4 * (i + 3) + 0] = 0xffff;
+    d[4 * (i + 3) + 1] = y3;
+    d[4 * (i + 3) + 2] = u2;
+    d[4 * (i + 3) + 3] = v2;
+
+    d[4 * (i + 4) + 0] = 0xffff;
+    d[4 * (i + 4) + 1] = y4;
+    d[4 * (i + 4) + 2] = u4;
+    d[4 * (i + 4) + 3] = v4;
+
+    d[4 * (i + 5) + 0] = 0xffff;
+    d[4 * (i + 5) + 1] = y5;
+    d[4 * (i + 5) + 2] = u4;
+    d[4 * (i + 5) + 3] = v4;
+  }
+}
+
+static void
+pack_v210 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint16 *s = src;
+
+  for (i = 0; i < width; i += 6) {
+    guint32 a0, a1, a2, a3;
+    guint16 y0, y1, y2, y3, y4, y5;
+    guint16 u0, u1, u2;
+    guint16 v0, v1, v2;
+
+    y0 = s[4 * (i + 0) + 1] >> 6;
+    y1 = s[4 * (i + 1) + 1] >> 6;
+    y2 = s[4 * (i + 2) + 1] >> 6;
+    y3 = s[4 * (i + 3) + 1] >> 6;
+    y4 = s[4 * (i + 4) + 1] >> 6;
+    y5 = s[4 * (i + 5) + 1] >> 6;
+
+    u0 = (s[4 * (i + 0) + 2] + s[4 * (i + 1) + 2] + 1) >> 7;
+    u1 = (s[4 * (i + 2) + 2] + s[4 * (i + 3) + 2] + 1) >> 7;
+    u2 = (s[4 * (i + 4) + 2] + s[4 * (i + 5) + 2] + 1) >> 7;
+
+    v0 = (s[4 * (i + 0) + 3] + s[4 * (i + 1) + 3] + 1) >> 7;
+    v1 = (s[4 * (i + 2) + 3] + s[4 * (i + 3) + 3] + 1) >> 7;
+    v2 = (s[4 * (i + 4) + 3] + s[4 * (i + 5) + 3] + 1) >> 7;
+
+    a0 = u0 | (y0 << 10) | (v0 << 20);
+    a1 = y1 | (u1 << 10) | (y2 << 20);
+    a2 = v1 | (y3 << 10) | (u2 << 20);
+    a3 = y4 | (v2 << 10) | (y5 << 20);
+
+    GST_WRITE_UINT32_LE (d + (i / 6) * 16 + 0, a0);
+    GST_WRITE_UINT32_LE (d + (i / 6) * 16 + 4, a1);
+    GST_WRITE_UINT32_LE (d + (i / 6) * 16 + 8, a2);
+    GST_WRITE_UINT32_LE (d + (i / 6) * 16 + 12, a3);
+  }
+}
+
+#define PACK_v216 GST_VIDEO_FORMAT_AYUV64, unpack_v216, 1, pack_v216
+static void
+unpack_v216 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xffff;
+    d[i * 4 + 1] = GST_READ_UINT16_LE (s + i * 4 + 2);
+    d[i * 4 + 2] = GST_READ_UINT16_LE (s + (i >> 1) * 8 + 0);
+    d[i * 4 + 3] = GST_READ_UINT16_LE (s + (i >> 1) * 8 + 4);
+  }
+}
+
+static void
+pack_v216 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint16 *s = src;
+
+  for (i = 0; i < width / 2; i++) {
+    GST_WRITE_UINT16_LE (d + i * 8 + 0, s[(i * 2 + 0) * 4 + 2]);
+    GST_WRITE_UINT16_LE (d + i * 8 + 2, s[(i * 2 + 0) * 4 + 1]);
+    GST_WRITE_UINT16_LE (d + i * 8 + 4, s[(i * 2 + 0) * 4 + 3]);
+    GST_WRITE_UINT16_LE (d + i * 8 + 6, s[(i * 2 + 1) * 4 + 1]);
+  }
+}
+
+#define PACK_Y41B GST_VIDEO_FORMAT_AYUV, unpack_Y41B, 1, pack_Y41B
+static void
+unpack_Y41B (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_YUV9 (dest,
+      GET_Y_LINE (y), GET_U_LINE (y), GET_V_LINE (y), width / 2);
+}
+
+static void
+pack_Y41B (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *destY = GET_Y_LINE (y);
+  guint8 *destU = GET_U_LINE (y);
+  guint8 *destV = GET_V_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width - 3; i += 4) {
+    destY[i] = s[i * 4 + 1];
+    destY[i + 1] = s[i * 4 + 5];
+    destY[i + 2] = s[i * 4 + 9];
+    destY[i + 3] = s[i * 4 + 13];
+
+    destU[i >> 2] =
+        (s[i * 4 + 2] + s[i * 4 + 6] + s[i * 4 + 10] + s[i * 4 + 14] + 2) >> 2;
+    destV[i >> 2] =
+        (s[i * 4 + 3] + s[i * 4 + 7] + s[i * 4 + 11] + s[i * 4 + 15] + 2) >> 2;
+  }
+
+  if (i == width - 3) {
+    destY[i] = s[i * 4 + 1];
+    destY[i + 1] = s[i * 4 + 5];
+    destY[i + 2] = s[i * 4 + 9];
+
+    destU[i >> 2] = (s[i * 4 + 2] + s[i * 4 + 6] + s[i * 4 + 10] + 1) / 3;
+    destV[i >> 2] = (s[i * 4 + 3] + s[i * 4 + 7] + s[i * 4 + 11] + 1) / 3;
+  } else if (i == width - 2) {
+    destY[i] = s[i * 4 + 1];
+    destY[i + 1] = s[i * 4 + 5];
+
+    destU[i >> 2] = (s[i * 4 + 2] + s[i * 4 + 6] + 1) >> 1;
+    destV[i >> 2] = (s[i * 4 + 3] + s[i * 4 + 7] + 1) >> 1;
+  } else if (i == width - 1) {
+    destY[i + 1] = s[i * 4 + 5];
+
+    destU[i >> 2] = s[i * 4 + 2];
+    destV[i >> 2] = s[i * 4 + 3];
+  }
+}
+
+#define PACK_Y42B GST_VIDEO_FORMAT_AYUV, unpack_Y42B, 1, pack_Y42B
+static void
+unpack_Y42B (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_Y42B (dest,
+      GET_Y_LINE (y), GET_U_LINE (y), GET_V_LINE (y), width / 2);
+}
+
+static void
+pack_Y42B (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_Y42B (GET_Y_LINE (y),
+      GET_U_LINE (y), GET_V_LINE (y), src, width / 2);
+}
+
+#define PACK_Y444 GST_VIDEO_FORMAT_AYUV, unpack_Y444, 1, pack_Y444
+static void
+unpack_Y444 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_Y444 (dest, GET_Y_LINE (y), GET_U_LINE (y), GET_V_LINE (y), width);
+}
+
+static void
+pack_Y444 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_Y444 (GET_Y_LINE (y), GET_U_LINE (y), GET_V_LINE (y), src, width);
+}
+
+#define PACK_GRAY8 GST_VIDEO_FORMAT_AYUV, unpack_GRAY8, 1, pack_GRAY8
+static void
+unpack_GRAY8 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_GRAY8 (dest, GET_LINE (y), width);
+}
+
+static void
+pack_GRAY8 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_GRAY8 (GET_LINE (y), src, width);
+}
+
+#define PACK_GRAY16_BE GST_VIDEO_FORMAT_AYUV64, unpack_GRAY16_BE, 1, pack_GRAY16_BE
+static void
+unpack_GRAY16_BE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint16 *s = GET_LINE (y);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xffff;
+    d[i * 4 + 1] = GST_READ_UINT16_BE (s + i);
+    d[i * 4 + 2] = 0x8000;
+    d[i * 4 + 3] = 0x8000;
+  }
+}
+
+static void
+pack_GRAY16_BE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *d = GET_LINE (y);
+  const guint16 *s = src;
+
+  for (i = 0; i < width; i++) {
+    GST_WRITE_UINT16_BE (d + i, s[i * 4 + 1]);
+  }
+}
+
+#define PACK_GRAY16_LE GST_VIDEO_FORMAT_AYUV64, unpack_GRAY16_LE, 1, pack_GRAY16_LE
+static void
+unpack_GRAY16_LE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint16 *s = GET_LINE (y);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xffff;
+    d[i * 4 + 1] = GST_READ_UINT16_LE (s + i);
+    d[i * 4 + 2] = 0x8000;
+    d[i * 4 + 3] = 0x8000;
+  }
+}
+
+static void
+pack_GRAY16_LE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *d = GET_LINE (y);
+  const guint16 *s = src;
+
+  for (i = 0; i < width; i++) {
+    GST_WRITE_UINT16_LE (d + i, s[i * 4 + 1]);
+  }
+}
+
+#define PACK_RGB16 GST_VIDEO_FORMAT_ARGB, unpack_RGB16, 1, pack_RGB16
+static void
+unpack_RGB16 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint16 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 1] = ((s[i] >> 11) & 0x1f) << 3;
+    d[i * 4 + 2] = ((s[i] >> 5) & 0x3f) << 2;
+    d[i * 4 + 3] = ((s[i]) & 0x1f) << 3;
+  }
+}
+
+static void
+pack_RGB16 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i] = ((s[i * 4 + 1] >> 3) << 11) |
+        ((s[i * 4 + 2] >> 2) << 5) | (s[i * 4 + 3] >> 3);
+  }
+}
+
+#define PACK_BGR16 GST_VIDEO_FORMAT_ARGB, unpack_BGR16, 1, pack_BGR16
+static void
+unpack_BGR16 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint16 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 3] = ((s[i] >> 11) & 0x1f) << 3;
+    d[i * 4 + 2] = ((s[i] >> 5) & 0x3f) << 2;
+    d[i * 4 + 1] = ((s[i]) & 0x1f) << 3;
+  }
+}
+
+static void
+pack_BGR16 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i] = ((s[i * 4 + 3] >> 3) << 11) |
+        ((s[i * 4 + 2] >> 2) << 5) | (s[i * 4 + 1] >> 3);
+  }
+}
+
+#define PACK_RGB15 GST_VIDEO_FORMAT_ARGB, unpack_RGB15, 1, pack_RGB15
+static void
+unpack_RGB15 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint16 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 1] = ((s[i] >> 10) & 0x1f) << 3;
+    d[i * 4 + 2] = ((s[i] >> 5) & 0x1f) << 3;
+    d[i * 4 + 3] = ((s[i]) & 0x1f) << 3;
+  }
+}
+
+static void
+pack_RGB15 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i] = ((s[i * 4 + 1] >> 3) << 10) |
+        ((s[i * 4 + 2] >> 3) << 5) | (s[i * 4 + 3] >> 3);
+  }
+}
+
+#define PACK_BGR15 GST_VIDEO_FORMAT_ARGB, unpack_BGR15, 1, pack_BGR15
+static void
+unpack_BGR15 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint16 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 3] = ((s[i] >> 10) & 0x1f) << 3;
+    d[i * 4 + 2] = ((s[i] >> 5) & 0x1f) << 3;
+    d[i * 4 + 1] = ((s[i]) & 0x1f) << 3;
+  }
+}
+
+static void
+pack_BGR15 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i] = ((s[i * 4 + 3] >> 3) << 10) |
+        ((s[i * 4 + 2] >> 3) << 5) | (s[i * 4 + 1] >> 3);
+  }
+}
+
+#define PACK_BGRA GST_VIDEO_FORMAT_ARGB, unpack_BGRA, 1, pack_BGRA
+static void
+unpack_BGRA (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_BGRA (dest, GET_LINE (y), width);
+}
+
+static void
+pack_BGRA (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_BGRA (GET_LINE (y), src, width);
+}
+
+#define PACK_ABGR GST_VIDEO_FORMAT_ARGB, unpack_ABGR, 1, pack_ABGR
+static void
+unpack_ABGR (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_ABGR (dest, GET_LINE (y), width);
+}
+
+static void
+pack_ABGR (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_ABGR (GET_LINE (y), src, width);
+}
+
+#define PACK_RGBA GST_VIDEO_FORMAT_ARGB, unpack_RGBA, 1, pack_RGBA
+static void
+unpack_RGBA (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_RGBA (dest, GET_LINE (y), width);
+}
+
+static void
+pack_RGBA (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_RGBA (GET_LINE (y), src, width);
+}
+
+#define PACK_RGB GST_VIDEO_FORMAT_ARGB, unpack_RGB, 1, pack_RGB
+static void
+unpack_RGB (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 1] = s[i * 3 + 0];
+    d[i * 4 + 2] = s[i * 3 + 1];
+    d[i * 4 + 3] = s[i * 3 + 2];
+  }
+}
+
+static void
+pack_RGB (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i * 3 + 0] = s[i * 4 + 1];
+    d[i * 3 + 1] = s[i * 4 + 2];
+    d[i * 3 + 2] = s[i * 4 + 3];
+  }
+}
+
+#define PACK_BGR GST_VIDEO_FORMAT_ARGB, unpack_BGR, 1, pack_BGR
+static void
+unpack_BGR (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 1] = s[i * 3 + 2];
+    d[i * 4 + 2] = s[i * 3 + 1];
+    d[i * 4 + 3] = s[i * 3 + 0];
+  }
+}
+
+static void
+pack_BGR (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width; i++) {
+    d[i * 3 + 0] = s[i * 4 + 3];
+    d[i * 3 + 1] = s[i * 4 + 2];
+    d[i * 3 + 2] = s[i * 4 + 1];
+  }
+}
+
+#define PACK_NV12 GST_VIDEO_FORMAT_AYUV, unpack_NV12, 1, pack_NV12
+static void
+unpack_NV12 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_NV12 (dest,
+      GET_PLANE_LINE (0, y), GET_PLANE_LINE (1, y >> 1), width / 2);
+}
+
+static void
+pack_NV12 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_NV12 (GET_PLANE_LINE (0, y),
+      GET_PLANE_LINE (1, y >> 1), src, width / 2);
+}
+
+#define PACK_NV21 GST_VIDEO_FORMAT_AYUV, unpack_NV21, 1, pack_NV21
+static void
+unpack_NV21 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_NV21 (dest,
+      GET_PLANE_LINE (0, y), GET_PLANE_LINE (1, y >> 1), width / 2);
+}
+
+static void
+pack_NV21 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_NV21 (GET_PLANE_LINE (0, y),
+      GET_PLANE_LINE (1, y >> 1), src, width / 2);
+}
+
+#define PACK_UYVP GST_VIDEO_FORMAT_AYUV64, unpack_UYVP, 1, pack_UYVP
+static void
+unpack_UYVP (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i += 2) {
+    guint16 y0, y1;
+    guint16 u0;
+    guint16 v0;
+
+    u0 = (s[(i / 2) * 5 + 0] << 2) | (s[(i / 2) * 5 + 1] >> 6);
+    y0 = ((s[(i / 2) * 5 + 1] & 0x3f) << 4) | (s[(i / 2) * 5 + 2] >> 4);
+    v0 = ((s[(i / 2) * 5 + 2] & 0x0f) << 6) | (s[(i / 2) * 5 + 3] >> 2);
+    y1 = ((s[(i / 2) * 5 + 3] & 0x03) << 8) | s[(i / 2) * 5 + 4];
+
+    d[i * 4 + 0] = 0xffff;
+    d[i * 4 + 1] = y0 << 6;
+    d[i * 4 + 2] = u0 << 6;
+    d[i * 4 + 3] = v0 << 6;
+    d[i * 4 + 4] = 0xffff;
+    d[i * 4 + 5] = y1 << 6;
+    d[i * 4 + 6] = u0 << 6;
+    d[i * 4 + 7] = v0 << 6;
+  }
+}
+
+static void
+pack_UYVP (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint16 *s = src;
+
+  for (i = 0; i < width; i += 2) {
+    guint16 y0, y1;
+    guint16 u0;
+    guint16 v0;
+
+    y0 = s[4 * (i + 0) + 1];
+    y1 = s[4 * (i + 1) + 1];
+    u0 = (s[4 * (i + 0) + 2] + s[4 * (i + 1) + 2] + 1) >> 1;
+    v0 = (s[4 * (i + 0) + 3] + s[4 * (i + 1) + 3] + 1) >> 1;
+
+    d[(i / 2) * 5 + 0] = u0 >> 8;
+    d[(i / 2) * 5 + 1] = (u0 & 0xc0) | y0 >> 10;
+    d[(i / 2) * 5 + 2] = ((y0 & 0x3c0) >> 2) | (v0 >> 12);
+    d[(i / 2) * 5 + 3] = ((v0 & 0xfc0) >> 4) | (y1 >> 14);
+    d[(i / 2) * 5 + 4] = (y1 >> 6);
+  }
+}
+
+#define PACK_A420 GST_VIDEO_FORMAT_AYUV, unpack_A420, 1, pack_A420
+static void
+unpack_A420 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_A420 (dest,
+      GET_Y_LINE (y), GET_U_LINE (y >> 1), GET_V_LINE (y >> 1), GET_A_LINE (y),
+      width);
+}
+
+static void
+pack_A420 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  orc_pack_A420 (GET_Y_LINE (y),
+      GET_U_LINE (y >> 1), GET_V_LINE (y >> 1), GET_A_LINE (y), src, width / 2);
+}
+
+#define PACK_RGB8P GST_VIDEO_FORMAT_ARGB, unpack_RGB8P, 1, pack_RGB8P
+static void
+unpack_RGB8P (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  const guint32 *p = data[1];
+  guint8 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    guint32 v = p[s[i]];
+    d[i * 4 + 0] = (v >> 24) & 0xff;
+    d[i * 4 + 1] = (v >> 16) & 0xff;
+    d[i * 4 + 2] = (v >> 8) & 0xff;
+    d[i * 4 + 3] = (v) & 0xff;
+  }
+}
+
+static void
+pack_RGB8P (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  /* Use our poor man's palette, taken from ffmpegcolorspace too */
+  for (i = 0; i < width; i++) {
+    /* crude approximation for alpha ! */
+    if (s[i * 4 + 0] < 0x80)
+      d[i] = 6 * 6 * 6;
+    else
+      d[i] =
+          ((((s[i * 4 + 1]) / 47) % 6) * 6 * 6 + (((s[i * 4 +
+                          2]) / 47) % 6) * 6 + (((s[i * 4 + 3]) / 47) % 6));
+  }
+}
+
+#define PACK_410 GST_VIDEO_FORMAT_AYUV, unpack_410, 1, pack_410
+static void
+unpack_410 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  orc_unpack_YUV9 (dest,
+      GET_Y_LINE (y), GET_U_LINE (y >> 2), GET_V_LINE (y >> 2), width / 2);
+}
+
+static void
+pack_410 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *destY = GET_Y_LINE (y);
+  guint8 *destU = GET_U_LINE (y >> 2);
+  guint8 *destV = GET_V_LINE (y >> 2);
+  const guint8 *s = src;
+
+  for (i = 0; i < width - 3; i += 4) {
+    destY[i] = s[i * 4 + 1];
+    destY[i + 1] = s[i * 4 + 5];
+    destY[i + 2] = s[i * 4 + 9];
+    destY[i + 3] = s[i * 4 + 13];
+    if (y % 4 == 0) {
+      destU[i >> 2] =
+          (s[i * 4 + 2] + s[i * 4 + 6] + s[i * 4 + 10] + s[i * 4 + 14]) >> 2;
+      destV[i >> 2] =
+          (s[i * 4 + 3] + s[i * 4 + 7] + s[i * 4 + 11] + s[i * 4 + 15]) >> 2;
+    }
+  }
+
+  if (i == width - 3) {
+    destY[i] = s[i * 4 + 1];
+    destY[i + 1] = s[i * 4 + 5];
+    destY[i + 2] = s[i * 4 + 9];
+    if (y % 4 == 0) {
+      destU[i >> 2] = (s[i * 4 + 2] + s[i * 4 + 6] + s[i * 4 + 10]) / 3;
+      destV[i >> 2] = (s[i * 4 + 3] + s[i * 4 + 7] + s[i * 4 + 11]) / 3;
+    }
+  } else if (i == width - 2) {
+    destY[i] = s[i * 4 + 1];
+    destY[i + 1] = s[i * 4 + 5];
+    if (y % 4 == 0) {
+      destU[i >> 2] = (s[i * 4 + 2] + s[i * 4 + 6]) >> 1;
+      destV[i >> 2] = (s[i * 4 + 3] + s[i * 4 + 7]) >> 1;
+    }
+  } else if (i == width - 1) {
+    destY[i] = s[i * 4 + 1];
+    destU[i >> 2] = s[i * 4 + 2];
+    destV[i >> 2] = s[i * 4 + 3];
+  }
+}
+
+#define PACK_IYU1 GST_VIDEO_FORMAT_AYUV, unpack_IYU1, 1, pack_IYU1
+static void
+unpack_IYU1 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint8 *d = dest;
+
+  for (i = 0; i < width - 3; i += 4) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 4] = 0xff;
+    d[i * 4 + 8] = 0xff;
+    d[i * 4 + 12] = 0xff;
+    d[i * 4 + 1] = s[(i >> 2) * 6 + 1];
+    d[i * 4 + 5] = s[(i >> 2) * 6 + 2];
+    d[i * 4 + 9] = s[(i >> 2) * 6 + 4];
+    d[i * 4 + 13] = s[(i >> 2) * 6 + 5];
+    d[i * 4 + 2] = d[i * 4 + 6] = d[i * 4 + 10] = d[i * 4 + 14] =
+        s[(i >> 2) * 6 + 0];
+    d[i * 4 + 3] = d[i * 4 + 7] = d[i * 4 + 11] = d[i * 4 + 15] =
+        s[(i >> 2) * 6 + 3];
+  }
+
+  if (i == width - 3) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 4] = 0xff;
+    d[i * 4 + 8] = 0xff;
+    d[i * 4 + 1] = s[(i >> 2) * 6 + 1];
+    d[i * 4 + 5] = s[(i >> 2) * 6 + 2];
+    d[i * 4 + 9] = s[(i >> 2) * 6 + 4];
+    d[i * 4 + 2] = d[i * 4 + 6] = d[i * 4 + 10] = s[(i >> 2) * 6 + 0];
+    d[i * 4 + 3] = d[i * 4 + 7] = d[i * 4 + 11] = s[(i >> 2) * 6 + 3];
+  } else if (i == width - 2) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 4] = 0xff;
+    d[i * 4 + 1] = s[(i >> 2) * 6 + 1];
+    d[i * 4 + 5] = s[(i >> 2) * 6 + 2];
+    d[i * 4 + 2] = d[i * 4 + 6] = s[(i >> 2) * 6 + 0];
+    d[i * 4 + 3] = d[i * 4 + 7] = s[(i >> 2) * 6 + 3];
+  } else if (i == width - 1) {
+    d[i * 4 + 0] = 0xff;
+    d[i * 4 + 1] = s[(i >> 2) * 6 + 1];
+    d[i * 4 + 2] = s[(i >> 2) * 6 + 0];
+    d[i * 4 + 3] = s[(i >> 2) * 6 + 3];
+  }
+}
+
+static void
+pack_IYU1 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint8 *s = src;
+
+  for (i = 0; i < width - 3; i += 4) {
+    d[(i >> 2) * 6 + 1] = s[i * 4 + 1];
+    d[(i >> 2) * 6 + 2] = s[i * 4 + 5];
+    d[(i >> 2) * 6 + 4] = s[i * 4 + 9];
+    d[(i >> 2) * 6 + 5] = s[i * 4 + 13];
+    d[(i >> 2) * 6 + 0] =
+        (s[i * 4 + 2] + s[i * 4 + 6] + s[i * 4 + 10] + s[i * 4 + 14]) >> 2;
+    d[(i >> 2) * 6 + 3] =
+        (s[i * 4 + 3] + s[i * 4 + 7] + s[i * 4 + 11] + s[i * 4 + 15]) >> 2;
+  }
+
+  if (i == width - 3) {
+    d[(i >> 2) * 6 + 1] = s[i * 4 + 1];
+    d[(i >> 2) * 6 + 2] = s[i * 4 + 5];
+    d[(i >> 2) * 6 + 4] = s[i * 4 + 9];
+    d[(i >> 2) * 6 + 0] = (s[i * 4 + 2] + s[i * 4 + 6] + s[i * 4 + 10]) / 3;
+    d[(i >> 2) * 6 + 3] = (s[i * 4 + 3] + s[i * 4 + 7] + s[i * 4 + 11]) / 3;
+  } else if (i == width - 2) {
+    d[(i >> 2) * 6 + 1] = s[i * 4 + 1];
+    d[(i >> 2) * 6 + 2] = s[i * 4 + 5];
+    d[(i >> 2) * 6 + 0] = (s[i * 4 + 2] + s[i * 4 + 6]) >> 1;
+    d[(i >> 2) * 6 + 3] = (s[i * 4 + 3] + s[i * 4 + 7]) >> 1;
+  } else if (i == width - 1) {
+    d[(i >> 2) * 6 + 1] = s[i * 4 + 1];
+    d[(i >> 2) * 6 + 0] = s[i * 4 + 2];
+    d[(i >> 2) * 6 + 3] = s[i * 4 + 3];
+  }
+}
+
+#define PACK_ARGB64 GST_VIDEO_FORMAT_ARGB64, unpack_copy8, 1, pack_copy8
+#define PACK_AYUV64 GST_VIDEO_FORMAT_AYUV64, unpack_copy8, 1, pack_copy8
+static void
+unpack_copy8 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  memcpy (dest, GET_LINE (y), width * 8);
+}
+
+static void
+pack_copy8 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  memcpy (GET_LINE (y), src, width * 8);
+}
+
+#define PACK_r210 GST_VIDEO_FORMAT_AYUV64, unpack_r210, 1, pack_r210
+static void
+unpack_r210 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  const guint8 *s = GET_LINE (y);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    guint32 x;
+    d[i * 4 + 0] = 0xffff;
+    x = GST_READ_UINT32_BE (s + i * 4);
+    d[i * 4 + 1] = ((x >> 14) & 0xffc0) | (x >> 24);
+    d[i * 4 + 2] = ((x >> 4) & 0xffc0) | ((x >> 14) & 0x3f);
+    d[i * 4 + 3] = ((x << 6) & 0xffc0) | ((x >> 4) & 0x3f);
+  }
+}
+
+static void
+pack_r210 (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint8 *d = GET_LINE (y);
+  const guint16 *s = src;
+
+  for (i = 0; i < width; i++) {
+    guint32 x = 0;
+    x |= (s[i * 4 + 1] & 0xffc0) << 14;
+    x |= (s[i * 4 + 2] & 0xffc0) << 4;
+    x |= (s[i * 4 + 3] & 0xffc0) >> 6;
+    GST_WRITE_UINT32_BE (d + i * 4, x);
+  }
+}
+
+#define PACK_I420_10LE GST_VIDEO_FORMAT_AYUV64, unpack_I420_10LE, 1, pack_I420_10LE
+static void
+unpack_I420_10LE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  guint16 *srcY = GET_Y_LINE (y);
+  guint16 *srcU = GET_U_LINE (y >> 1);
+  guint16 *srcV = GET_V_LINE (y >> 1);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xffff;
+    d[i * 4 + 1] = GST_READ_UINT16_LE (srcY + i) << 6;
+    d[i * 4 + 2] = GST_READ_UINT16_LE (srcU + (i >> 1)) << 6;
+    d[i * 4 + 3] = GST_READ_UINT16_LE (srcV + (i >> 1)) << 6;
+  }
+}
+
+static void
+pack_I420_10LE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *destY = GET_Y_LINE (y);
+  guint16 *destU = GET_U_LINE (y >> 1);
+  guint16 *destV = GET_V_LINE (y >> 1);
+  guint16 Y0, Y1, U, V;
+  const guint16 *s = src;
+
+  for (i = 0; i < width - 1; i += 2) {
+    Y0 = (s[i * 4 + 1]) >> 6;
+    Y1 = (s[i * 4 + 5]) >> 6;
+    U = ((s[i * 4 + 2] + s[i * 4 + 6] + 1) >> 1) >> 6;
+    V = ((s[i * 4 + 3] + s[i * 4 + 7] + 1) >> 1) >> 6;
+
+    GST_WRITE_UINT16_LE (destY + i + 0, Y0);
+    GST_WRITE_UINT16_LE (destY + i + 1, Y1);
+    GST_WRITE_UINT16_LE (destU + (i >> 1), U);
+    GST_WRITE_UINT16_LE (destV + (i >> 1), V);
+  }
+  if (i == width - 1) {
+    Y0 = s[i * 4 + 1] >> 6;
+    U = s[i * 4 + 2] >> 6;
+    V = s[i * 4 + 3] >> 6;
+
+    GST_WRITE_UINT16_LE (destY + i, Y0);
+    GST_WRITE_UINT16_LE (destU + (i >> 1), U);
+    GST_WRITE_UINT16_LE (destV + (i >> 1), V);
+  }
+}
+
+#define PACK_I420_10BE GST_VIDEO_FORMAT_AYUV64, unpack_I420_10BE, 1, pack_I420_10BE
+static void
+unpack_I420_10BE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    gpointer dest, const gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], gint x, gint y, gint width)
+{
+  int i;
+  guint16 *srcY = GET_Y_LINE (y);
+  guint16 *srcU = GET_U_LINE (y >> 1);
+  guint16 *srcV = GET_V_LINE (y >> 1);
+  guint16 *d = dest;
+
+  for (i = 0; i < width; i++) {
+    d[i * 4 + 0] = 0xffff;
+    d[i * 4 + 1] = GST_READ_UINT16_BE (srcY + i) << 6;
+    d[i * 4 + 2] = GST_READ_UINT16_BE (srcU + (i >> 1)) << 6;
+    d[i * 4 + 3] = GST_READ_UINT16_BE (srcV + (i >> 1)) << 6;
+  }
+}
+
+static void
+pack_I420_10BE (const GstVideoFormatInfo * info, GstVideoPackFlags flags,
+    const gpointer src, gint sstride, gpointer data[GST_VIDEO_MAX_PLANES],
+    const gint stride[GST_VIDEO_MAX_PLANES], GstVideoChromaSite chroma_site,
+    gint y, gint width)
+{
+  int i;
+  guint16 *destY = GET_Y_LINE (y);
+  guint16 *destU = GET_U_LINE (y >> 1);
+  guint16 *destV = GET_V_LINE (y >> 1);
+  guint16 Y0, Y1, U, V;
+  const guint16 *s = src;
+
+  for (i = 0; i < width - 1; i += 2) {
+    Y0 = s[i * 4 + 1] >> 6;
+    Y1 = s[i * 4 + 5] >> 6;
+    U = ((s[i * 4 + 2] + s[i * 4 + 6] + 1) >> 1) >> 6;
+    V = ((s[i * 4 + 3] + s[i * 4 + 7] + 1) >> 1) >> 6;
+
+    GST_WRITE_UINT16_BE (destY + i + 0, Y0);
+    GST_WRITE_UINT16_BE (destY + i + 1, Y1);
+    GST_WRITE_UINT16_BE (destU + (i >> 1), U);
+    GST_WRITE_UINT16_BE (destV + (i >> 1), V);
+  }
+  if (i == width - 1) {
+    Y0 = s[i * 4 + 1] >> 6;
+    U = s[i * 4 + 2] >> 6;
+    V = s[i * 4 + 3] >> 6;
+
+    GST_WRITE_UINT16_BE (destY + i, Y0);
+    GST_WRITE_UINT16_BE (destU + (i >> 1), U);
+    GST_WRITE_UINT16_BE (destV + (i >> 1), V);
+  }
+}
+
+typedef struct
+{
+  guint32 fourcc;
+  GstVideoFormatInfo info;
+} VideoFormat;
+
+/* depths: bits, n_components, shift, depth */
+#define DPTH0            0, 0, { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
+#define DPTH8            8, 1, { 0, 0, 0, 0 }, { 8, 0, 0, 0 }
+#define DPTH8_32         8, 2, { 0, 0, 0, 0 }, { 8, 32, 0, 0 }
+#define DPTH888          8, 3, { 0, 0, 0, 0 }, { 8, 8, 8, 0 }
+#define DPTH8888         8, 4, { 0, 0, 0, 0 }, { 8, 8, 8, 8 }
+#define DPTH10_10_10     10, 3, { 0, 0, 0, 0 }, { 10, 10, 10, 0 }
+#define DPTH16           16, 1, { 0, 0, 0, 0 }, { 16, 0, 0, 0 }
+#define DPTH16_16_16     16, 3, { 0, 0, 0, 0 }, { 16, 16, 16, 0 }
+#define DPTH16_16_16_16  16, 4, { 0, 0, 0, 0 }, { 16, 16, 16, 16 }
+#define DPTH555          16, 3, { 10, 5, 0, 0 }, { 5, 5, 5, 0 }
+#define DPTH565          16, 3, { 11, 5, 0, 0 }, { 5, 6, 5, 0 }
+
+/* pixel strides */
+#define PSTR0             { 0, 0, 0, 0 }
+#define PSTR1             { 1, 0, 0, 0 }
+#define PSTR14            { 1, 4, 0, 0 }
+#define PSTR111           { 1, 1, 1, 0 }
+#define PSTR1111          { 1, 1, 1, 1 }
+#define PSTR122           { 1, 2, 2, 0 }
+#define PSTR2             { 2, 0, 0, 0 }
+#define PSTR222           { 2, 2, 2, 0 }
+#define PSTR244           { 2, 4, 4, 0 }
+#define PSTR444           { 4, 4, 4, 0 }
+#define PSTR4444          { 4, 4, 4, 4 }
+#define PSTR333           { 3, 3, 3, 0 }
+#define PSTR488           { 4, 8, 8, 0 }
+#define PSTR8888          { 8, 8, 8, 8 }
+
+/* planes */
+#define PLANE_NA          0, { 0, 0, 0, 0 }
+#define PLANE0            1, { 0, 0, 0, 0 }
+#define PLANE01           2, { 0, 1, 0, 0 }
+#define PLANE011          2, { 0, 1, 1, 0 }
+#define PLANE012          3, { 0, 1, 2, 0 }
+#define PLANE0123         4, { 0, 1, 2, 3 }
+#define PLANE021          3, { 0, 2, 1, 0 }
+
+/* offsets */
+#define OFFS0             { 0, 0, 0, 0 }
+#define OFFS013           { 0, 1, 3, 0 }
+#define OFFS102           { 1, 0, 2, 0 }
+#define OFFS1230          { 1, 2, 3, 0 }
+#define OFFS012           { 0, 1, 2, 0 }
+#define OFFS210           { 2, 1, 0, 0 }
+#define OFFS123           { 1, 2, 3, 0 }
+#define OFFS321           { 3, 2, 1, 0 }
+#define OFFS0123          { 0, 1, 2, 3 }
+#define OFFS2103          { 2, 1, 0, 3 }
+#define OFFS3210          { 3, 2, 1, 0 }
+#define OFFS031           { 0, 3, 1, 0 }
+#define OFFS204           { 2, 0, 4, 0 }
+#define OFFS001           { 0, 0, 1, 0 }
+#define OFFS010           { 0, 1, 0, 0 }
+#define OFFS104           { 1, 0, 4, 0 }
+#define OFFS2460          { 2, 4, 6, 0 }
+
+/* subsampling */
+#define SUB410            { 0, 2, 2, 0 }, { 0, 2, 2, 0 }
+#define SUB411            { 0, 2, 2, 0 }, { 0, 0, 0, 0 }
+#define SUB420            { 0, 1, 1, 0 }, { 0, 1, 1, 0 }
+#define SUB422            { 0, 1, 1, 0 }, { 0, 0, 0, 0 }
+#define SUB4              { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
+#define SUB44             { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
+#define SUB444            { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
+#define SUB4444           { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
+#define SUB4204           { 0, 1, 1, 0 }, { 0, 1, 1, 0 }
+
+#define MAKE_YUV_FORMAT(name, desc, fourcc, depth, pstride, plane, offs, sub, pack ) \
+ { fourcc, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_YUV, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_YUV_LE_FORMAT(name, desc, fourcc, depth, pstride, plane, offs, sub, pack ) \
+ { fourcc, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_YUV | GST_VIDEO_FORMAT_FLAG_LE, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_YUVA_FORMAT(name, desc, fourcc, depth, pstride, plane, offs, sub, pack) \
+ { fourcc, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_YUV | GST_VIDEO_FORMAT_FLAG_ALPHA, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_YUV_C_FORMAT(name, desc, fourcc, depth, pstride, plane, offs, sub, pack) \
+ { fourcc, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_YUV | GST_VIDEO_FORMAT_FLAG_COMPLEX, depth, pstride, plane, offs, sub, pack } }
+
+#define MAKE_RGB_FORMAT(name, desc, depth, pstride, plane, offs, sub, pack) \
+ { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_RGB_LE_FORMAT(name, desc, depth, pstride, plane, offs, sub, pack) \
+ { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB | GST_VIDEO_FORMAT_FLAG_LE, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_RGBA_FORMAT(name, desc, depth, pstride, plane, offs, sub, pack) \
+ { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB | GST_VIDEO_FORMAT_FLAG_ALPHA, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_RGBAP_FORMAT(name, desc, depth, pstride, plane, offs, sub, pack) \
+ { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB | GST_VIDEO_FORMAT_FLAG_ALPHA | GST_VIDEO_FORMAT_FLAG_PALETTE, depth, pstride, plane, offs, sub, pack } }
+
+#define MAKE_GRAY_FORMAT(name, desc, depth, pstride, plane, offs, sub, pack) \
+ { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_GRAY, depth, pstride, plane, offs, sub, pack } }
+#define MAKE_GRAY_LE_FORMAT(name, desc, depth, pstride, plane, offs, sub, pack) \
+ { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_GRAY | GST_VIDEO_FORMAT_FLAG_LE, depth, pstride, plane, offs, sub, pack } }
+
+static VideoFormat formats[] = {
+  {0x00000000, {GST_VIDEO_FORMAT_UNKNOWN, "UNKNOWN", "unknown video", 0, DPTH0,
+              PSTR0, PLANE_NA,
+          OFFS0}},
+  {0x00000000, {GST_VIDEO_FORMAT_ENCODED, "ENCODED", "encoded video",
+          GST_VIDEO_FORMAT_FLAG_COMPLEX, DPTH0, PSTR0, PLANE_NA, OFFS0}},
+
+  MAKE_YUV_FORMAT (I420, "raw video", GST_MAKE_FOURCC ('I', '4', '2', '0'),
+      DPTH888, PSTR111,
+      PLANE012, OFFS0, SUB420, PACK_420),
+  MAKE_YUV_FORMAT (YV12, "raw video", GST_MAKE_FOURCC ('Y', 'V', '1', '2'),
+      DPTH888, PSTR111,
+      PLANE021, OFFS0, SUB420, PACK_420),
+  MAKE_YUV_FORMAT (YUY2, "raw video", GST_MAKE_FOURCC ('Y', 'U', 'Y', '2'),
+      DPTH888, PSTR244,
+      PLANE0, OFFS013, SUB422, PACK_YUY2),
+  MAKE_YUV_FORMAT (UYVY, "raw video", GST_MAKE_FOURCC ('U', 'Y', 'V', 'Y'),
+      DPTH888, PSTR244,
+      PLANE0, OFFS102, SUB422, PACK_UYVY),
+  MAKE_YUVA_FORMAT (AYUV, "raw video", GST_MAKE_FOURCC ('A', 'Y', 'U', 'V'),
+      DPTH8888,
+      PSTR4444, PLANE0, OFFS1230, SUB4444, PACK_AYUV),
+  MAKE_RGB_FORMAT (RGBx, "raw video", DPTH888, PSTR444, PLANE0, OFFS012,
+      SUB444, PACK_RGBA),
+  MAKE_RGB_FORMAT (BGRx, "raw video", DPTH888, PSTR444, PLANE0, OFFS210,
+      SUB444, PACK_BGRA),
+  MAKE_RGB_FORMAT (xRGB, "raw video", DPTH888, PSTR444, PLANE0, OFFS123,
+      SUB444, PACK_ARGB),
+  MAKE_RGB_FORMAT (xBGR, "raw video", DPTH888, PSTR444, PLANE0, OFFS321,
+      SUB444, PACK_ABGR),
+  MAKE_RGBA_FORMAT (RGBA, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS0123,
+      SUB4444, PACK_RGBA),
+  MAKE_RGBA_FORMAT (BGRA, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS2103,
+      SUB4444, PACK_BGRA),
+  MAKE_RGBA_FORMAT (ARGB, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS1230,
+      SUB4444, PACK_ARGB),
+  MAKE_RGBA_FORMAT (ABGR, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS3210,
+      SUB4444, PACK_ABGR),
+  MAKE_RGB_FORMAT (RGB, "raw video", DPTH888, PSTR333, PLANE0, OFFS012, SUB444,
+      PACK_RGB),
+  MAKE_RGB_FORMAT (BGR, "raw video", DPTH888, PSTR333, PLANE0, OFFS210, SUB444,
+      PACK_BGR),
+
+  MAKE_YUV_FORMAT (Y41B, "raw video", GST_MAKE_FOURCC ('Y', '4', '1', 'B'),
+      DPTH888, PSTR111,
+      PLANE012, OFFS0, SUB411, PACK_Y41B),
+  MAKE_YUV_FORMAT (Y42B, "raw video", GST_MAKE_FOURCC ('Y', '4', '2', 'B'),
+      DPTH888, PSTR111,
+      PLANE012, OFFS0, SUB422, PACK_Y42B),
+  MAKE_YUV_FORMAT (YVYU, "raw video", GST_MAKE_FOURCC ('Y', 'V', 'Y', 'U'),
+      DPTH888, PSTR244,
+      PLANE0, OFFS031, SUB422, PACK_YVYU),
+  MAKE_YUV_FORMAT (Y444, "raw video", GST_MAKE_FOURCC ('Y', '4', '4', '4'),
+      DPTH888, PSTR111,
+      PLANE012, OFFS0, SUB444, PACK_Y444),
+  MAKE_YUV_C_FORMAT (v210, "raw video", GST_MAKE_FOURCC ('v', '2', '1', '0'),
+      DPTH10_10_10,
+      PSTR0, PLANE0, OFFS0, SUB422, PACK_v210),
+  MAKE_YUV_FORMAT (v216, "raw video", GST_MAKE_FOURCC ('v', '2', '1', '6'),
+      DPTH16_16_16,
+      PSTR488, PLANE0, OFFS204, SUB422, PACK_v216),
+  MAKE_YUV_FORMAT (NV12, "raw video", GST_MAKE_FOURCC ('N', 'V', '1', '2'),
+      DPTH888, PSTR122,
+      PLANE011, OFFS001, SUB420, PACK_NV12),
+  MAKE_YUV_FORMAT (NV21, "raw video", GST_MAKE_FOURCC ('N', 'V', '2', '1'),
+      DPTH888, PSTR122,
+      PLANE011, OFFS010, SUB420, PACK_NV21),
+
+  MAKE_GRAY_FORMAT (GRAY8, "raw video", DPTH8, PSTR1, PLANE0, OFFS0, SUB4,
+      PACK_GRAY8),
+  MAKE_GRAY_FORMAT (GRAY16_BE, "raw video", DPTH16, PSTR2, PLANE0, OFFS0, SUB4,
+      PACK_GRAY16_BE),
+  MAKE_GRAY_LE_FORMAT (GRAY16_LE, "raw video", DPTH16, PSTR2, PLANE0, OFFS0,
+      SUB4, PACK_GRAY16_LE),
+
+  MAKE_YUV_FORMAT (v308, "raw video", GST_MAKE_FOURCC ('v', '3', '0', '8'),
+      DPTH888, PSTR333,
+      PLANE0, OFFS012, SUB444, PACK_v308),
+
+#if G_BYTE_ORDER == G_LITTLE_ENDIAN
+  MAKE_RGB_LE_FORMAT (RGB16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0,
+      SUB444, PACK_RGB16),
+  MAKE_RGB_LE_FORMAT (BGR16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0,
+      SUB444, PACK_BGR16),
+  MAKE_RGB_LE_FORMAT (RGB15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0,
+      SUB444, PACK_RGB15),
+  MAKE_RGB_LE_FORMAT (BGR15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0,
+      SUB444, PACK_BGR15),
+#else
+  MAKE_RGB_FORMAT (RGB16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0, SUB444,
+      PACK_RGB16),
+  MAKE_RGB_FORMAT (BGR16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0, SUB444,
+      PACK_BGR16),
+  MAKE_RGB_FORMAT (RGB15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0, SUB444,
+      PACK_RGB15),
+  MAKE_RGB_FORMAT (BGR15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0, SUB444,
+      PACK_BGR15),
+#endif
+
+  MAKE_YUV_C_FORMAT (UYVP, "raw video", GST_MAKE_FOURCC ('U', 'Y', 'V', 'P'),
+      DPTH10_10_10,
+      PSTR0, PLANE0, OFFS0, SUB422, PACK_UYVP),
+  MAKE_YUVA_FORMAT (A420, "raw video", GST_MAKE_FOURCC ('A', '4', '2', '0'),
+      DPTH8888,
+      PSTR1111, PLANE0123, OFFS0, SUB4204, PACK_A420),
+  MAKE_RGBAP_FORMAT (RGB8P, "raw video", DPTH8_32, PSTR14, PLANE01,
+      OFFS0, SUB44, PACK_RGB8P),
+  MAKE_YUV_FORMAT (YUV9, "raw video", GST_MAKE_FOURCC ('Y', 'U', 'V', '9'),
+      DPTH888, PSTR111,
+      PLANE012, OFFS0, SUB410, PACK_410),
+  MAKE_YUV_FORMAT (YVU9, "raw video", GST_MAKE_FOURCC ('Y', 'V', 'U', '9'),
+      DPTH888, PSTR111,
+      PLANE021, OFFS0, SUB410, PACK_410),
+  MAKE_YUV_FORMAT (IYU1, "raw video", GST_MAKE_FOURCC ('I', 'Y', 'U', '1'),
+      DPTH888, PSTR0,
+      PLANE0, OFFS104, SUB411, PACK_IYU1),
+  MAKE_RGBA_FORMAT (ARGB64, "raw video", DPTH16_16_16_16, PSTR8888, PLANE0,
+      OFFS2460,
+      SUB444, PACK_ARGB64),
+  MAKE_YUVA_FORMAT (AYUV64, "raw video", 0x00000000, DPTH16_16_16_16, PSTR8888,
+      PLANE0,
+      OFFS2460, SUB444, PACK_AYUV64),
+  MAKE_YUV_FORMAT (r210, "raw video", GST_MAKE_FOURCC ('r', '2', '1', '0'),
+      DPTH10_10_10,
+      PSTR444, PLANE0, OFFS0, SUB444, PACK_r210),
+  MAKE_YUV_FORMAT (I420_10BE, "raw video", 0x00000000, DPTH10_10_10,
+      PSTR222, PLANE012, OFFS0, SUB420, PACK_I420_10BE),
+  MAKE_YUV_LE_FORMAT (I420_10LE, "raw video", 0x00000000, DPTH10_10_10,
+      PSTR222, PLANE012, OFFS0, SUB420, PACK_I420_10LE),
+};
+
+static GstVideoFormat
+gst_video_format_from_rgb32_masks (int red_mask, int green_mask, int blue_mask)
+{
+  if (red_mask == 0xff000000 && green_mask == 0x00ff0000 &&
+      blue_mask == 0x0000ff00) {
+    return GST_VIDEO_FORMAT_RGBx;
+  }
+  if (red_mask == 0x0000ff00 && green_mask == 0x00ff0000 &&
+      blue_mask == 0xff000000) {
+    return GST_VIDEO_FORMAT_BGRx;
+  }
+  if (red_mask == 0x00ff0000 && green_mask == 0x0000ff00 &&
+      blue_mask == 0x000000ff) {
+    return GST_VIDEO_FORMAT_xRGB;
+  }
+  if (red_mask == 0x000000ff && green_mask == 0x0000ff00 &&
+      blue_mask == 0x00ff0000) {
+    return GST_VIDEO_FORMAT_xBGR;
+  }
+
+  return GST_VIDEO_FORMAT_UNKNOWN;
+}
+
+static GstVideoFormat
+gst_video_format_from_rgba32_masks (int red_mask, int green_mask,
+    int blue_mask, int alpha_mask)
+{
+  if (red_mask == 0xff000000 && green_mask == 0x00ff0000 &&
+      blue_mask == 0x0000ff00 && alpha_mask == 0x000000ff) {
+    return GST_VIDEO_FORMAT_RGBA;
+  }
+  if (red_mask == 0x0000ff00 && green_mask == 0x00ff0000 &&
+      blue_mask == 0xff000000 && alpha_mask == 0x000000ff) {
+    return GST_VIDEO_FORMAT_BGRA;
+  }
+  if (red_mask == 0x00ff0000 && green_mask == 0x0000ff00 &&
+      blue_mask == 0x000000ff && alpha_mask == 0xff000000) {
+    return GST_VIDEO_FORMAT_ARGB;
+  }
+  if (red_mask == 0x000000ff && green_mask == 0x0000ff00 &&
+      blue_mask == 0x00ff0000 && alpha_mask == 0xff000000) {
+    return GST_VIDEO_FORMAT_ABGR;
+  }
+  return GST_VIDEO_FORMAT_UNKNOWN;
+}
+
+static GstVideoFormat
+gst_video_format_from_rgb24_masks (int red_mask, int green_mask, int blue_mask)
+{
+  if (red_mask == 0xff0000 && green_mask == 0x00ff00 && blue_mask == 0x0000ff) {
+    return GST_VIDEO_FORMAT_RGB;
+  }
+  if (red_mask == 0x0000ff && green_mask == 0x00ff00 && blue_mask == 0xff0000) {
+    return GST_VIDEO_FORMAT_BGR;
+  }
+
+  return GST_VIDEO_FORMAT_UNKNOWN;
+}
+
+#define GST_VIDEO_COMP1_MASK_16_INT 0xf800
+#define GST_VIDEO_COMP2_MASK_16_INT 0x07e0
+#define GST_VIDEO_COMP3_MASK_16_INT 0x001f
+
+#define GST_VIDEO_COMP1_MASK_15_INT 0x7c00
+#define GST_VIDEO_COMP2_MASK_15_INT 0x03e0
+#define GST_VIDEO_COMP3_MASK_15_INT 0x001f
+
+static GstVideoFormat
+gst_video_format_from_rgb16_masks (int red_mask, int green_mask, int blue_mask)
+{
+  if (red_mask == GST_VIDEO_COMP1_MASK_16_INT
+      && green_mask == GST_VIDEO_COMP2_MASK_16_INT
+      && blue_mask == GST_VIDEO_COMP3_MASK_16_INT) {
+    return GST_VIDEO_FORMAT_RGB16;
+  }
+  if (red_mask == GST_VIDEO_COMP3_MASK_16_INT
+      && green_mask == GST_VIDEO_COMP2_MASK_16_INT
+      && blue_mask == GST_VIDEO_COMP1_MASK_16_INT) {
+    return GST_VIDEO_FORMAT_BGR16;
+  }
+  if (red_mask == GST_VIDEO_COMP1_MASK_15_INT
+      && green_mask == GST_VIDEO_COMP2_MASK_15_INT
+      && blue_mask == GST_VIDEO_COMP3_MASK_15_INT) {
+    return GST_VIDEO_FORMAT_RGB15;
+  }
+  if (red_mask == GST_VIDEO_COMP3_MASK_15_INT
+      && green_mask == GST_VIDEO_COMP2_MASK_15_INT
+      && blue_mask == GST_VIDEO_COMP1_MASK_15_INT) {
+    return GST_VIDEO_FORMAT_BGR15;
+  }
+  return GST_VIDEO_FORMAT_UNKNOWN;
+}
+
+/**
+ * gst_video_format_from_masks:
+ * @depth: the amount of bits used for a pixel
+ * @bpp: the amount of bits used to store a pixel. This value is bigger than
+ *   @depth
+ * @endianness: the endianness of the masks
+ * @red_mask: the red mask
+ * @green_mask: the green mask
+ * @blue_mask: the blue mask
+ * @alpha_mask: the optional alpha mask
+ *
+ * Find the #GstVideoFormat for the given parameters.
+ *
+ * Returns: a #GstVideoFormat or GST_VIDEO_FORMAT_UNKNOWN when the parameters to
+ * not specify a known format.
+ */
+GstVideoFormat
+gst_video_format_from_masks (gint depth, gint bpp, gint endianness,
+    gint red_mask, gint green_mask, gint blue_mask, gint alpha_mask)
+{
+  GstVideoFormat format;
+
+  /* our caps system handles 24/32bpp RGB as big-endian. */
+  if ((bpp == 24 || bpp == 32) && endianness == G_LITTLE_ENDIAN) {
+    red_mask = GUINT32_TO_BE (red_mask);
+    green_mask = GUINT32_TO_BE (green_mask);
+    blue_mask = GUINT32_TO_BE (blue_mask);
+    endianness = G_BIG_ENDIAN;
+    if (bpp == 24) {
+      red_mask >>= 8;
+      green_mask >>= 8;
+      blue_mask >>= 8;
+    }
+  }
+
+  if (depth == 30 && bpp == 32) {
+    format = GST_VIDEO_FORMAT_r210;
+  } else if (depth == 24 && bpp == 32) {
+    format = gst_video_format_from_rgb32_masks (red_mask, green_mask,
+        blue_mask);
+  } else if (depth == 32 && bpp == 32 && alpha_mask) {
+    format = gst_video_format_from_rgba32_masks (red_mask, green_mask,
+        blue_mask, alpha_mask);
+  } else if (depth == 24 && bpp == 24) {
+    format = gst_video_format_from_rgb24_masks (red_mask, green_mask,
+        blue_mask);
+  } else if ((depth == 15 || depth == 16) && bpp == 16 &&
+      endianness == G_BYTE_ORDER) {
+    format = gst_video_format_from_rgb16_masks (red_mask, green_mask,
+        blue_mask);
+  } else if (depth == 8 && bpp == 8) {
+    format = GST_VIDEO_FORMAT_RGB8P;
+  } else if (depth == 64 && bpp == 64) {
+    format = gst_video_format_from_rgba32_masks (red_mask, green_mask,
+        blue_mask, alpha_mask);
+    if (format == GST_VIDEO_FORMAT_ARGB) {
+      format = GST_VIDEO_FORMAT_ARGB64;
+    } else {
+      format = GST_VIDEO_FORMAT_UNKNOWN;
+    }
+  } else {
+    format = GST_VIDEO_FORMAT_UNKNOWN;
+  }
+  return format;
+}
+
+/**
+ * gst_video_format_from_fourcc:
+ * @fourcc: a FOURCC value representing raw YUV video
+ *
+ * Converts a FOURCC value into the corresponding #GstVideoFormat.
+ * If the FOURCC cannot be represented by #GstVideoFormat,
+ * #GST_VIDEO_FORMAT_UNKNOWN is returned.
+ *
+ * Since: 0.10.16
+ *
+ * Returns: the #GstVideoFormat describing the FOURCC value
+ */
+GstVideoFormat
+gst_video_format_from_fourcc (guint32 fourcc)
+{
+  switch (fourcc) {
+    case GST_MAKE_FOURCC ('I', '4', '2', '0'):
+      return GST_VIDEO_FORMAT_I420;
+    case GST_MAKE_FOURCC ('Y', 'V', '1', '2'):
+      return GST_VIDEO_FORMAT_YV12;
+    case GST_MAKE_FOURCC ('Y', 'U', 'Y', '2'):
+      return GST_VIDEO_FORMAT_YUY2;
+    case GST_MAKE_FOURCC ('Y', 'V', 'Y', 'U'):
+      return GST_VIDEO_FORMAT_YVYU;
+    case GST_MAKE_FOURCC ('U', 'Y', 'V', 'Y'):
+      return GST_VIDEO_FORMAT_UYVY;
+    case GST_MAKE_FOURCC ('A', 'Y', 'U', 'V'):
+      return GST_VIDEO_FORMAT_AYUV;
+    case GST_MAKE_FOURCC ('Y', '4', '1', 'B'):
+      return GST_VIDEO_FORMAT_Y41B;
+    case GST_MAKE_FOURCC ('Y', '4', '2', 'B'):
+      return GST_VIDEO_FORMAT_Y42B;
+    case GST_MAKE_FOURCC ('Y', '4', '4', '4'):
+      return GST_VIDEO_FORMAT_Y444;
+    case GST_MAKE_FOURCC ('v', '2', '1', '0'):
+      return GST_VIDEO_FORMAT_v210;
+    case GST_MAKE_FOURCC ('v', '2', '1', '6'):
+      return GST_VIDEO_FORMAT_v216;
+    case GST_MAKE_FOURCC ('N', 'V', '1', '2'):
+      return GST_VIDEO_FORMAT_NV12;
+    case GST_MAKE_FOURCC ('N', 'V', '2', '1'):
+      return GST_VIDEO_FORMAT_NV21;
+    case GST_MAKE_FOURCC ('v', '3', '0', '8'):
+      return GST_VIDEO_FORMAT_v308;
+    case GST_MAKE_FOURCC ('Y', '8', '0', '0'):
+    case GST_MAKE_FOURCC ('Y', '8', ' ', ' '):
+    case GST_MAKE_FOURCC ('G', 'R', 'E', 'Y'):
+      return GST_VIDEO_FORMAT_GRAY8;
+    case GST_MAKE_FOURCC ('Y', '1', '6', ' '):
+      return GST_VIDEO_FORMAT_GRAY16_LE;
+    case GST_MAKE_FOURCC ('U', 'Y', 'V', 'P'):
+      return GST_VIDEO_FORMAT_UYVP;
+    case GST_MAKE_FOURCC ('A', '4', '2', '0'):
+      return GST_VIDEO_FORMAT_A420;
+    case GST_MAKE_FOURCC ('Y', 'U', 'V', '9'):
+      return GST_VIDEO_FORMAT_YUV9;
+    case GST_MAKE_FOURCC ('Y', 'V', 'U', '9'):
+      return GST_VIDEO_FORMAT_YVU9;
+    case GST_MAKE_FOURCC ('I', 'Y', 'U', '1'):
+      return GST_VIDEO_FORMAT_IYU1;
+    case GST_MAKE_FOURCC ('A', 'Y', '6', '4'):
+      return GST_VIDEO_FORMAT_AYUV64;
+    default:
+      return GST_VIDEO_FORMAT_UNKNOWN;
+  }
+}
+
+/**
+ * gst_video_format_from_string:
+ * @format: a format string
+ *
+ * Convert the @format string to its #GstVideoFormat.
+ *
+ * Returns: the #GstVideoFormat for @format or GST_VIDEO_FORMAT_UNKNOWN when the
+ * string is not a known format.
+ */
+GstVideoFormat
+gst_video_format_from_string (const gchar * format)
+{
+  guint i;
+
+  g_return_val_if_fail (format != NULL, GST_VIDEO_FORMAT_UNKNOWN);
+
+  for (i = 0; i < G_N_ELEMENTS (formats); i++) {
+    if (strcmp (GST_VIDEO_FORMAT_INFO_NAME (&formats[i].info), format) == 0)
+      return GST_VIDEO_FORMAT_INFO_FORMAT (&formats[i].info);
+  }
+  return GST_VIDEO_FORMAT_UNKNOWN;
+}
+
+
+/**
+ * gst_video_format_to_fourcc:
+ * @format: a #GstVideoFormat video format
+ *
+ * Converts a #GstVideoFormat value into the corresponding FOURCC.  Only
+ * a few YUV formats have corresponding FOURCC values.  If @format has
+ * no corresponding FOURCC value, 0 is returned.
+ *
+ * Since: 0.10.16
+ *
+ * Returns: the FOURCC corresponding to @format
+ */
+guint32
+gst_video_format_to_fourcc (GstVideoFormat format)
+{
+  g_return_val_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN, 0);
+
+  if (format >= G_N_ELEMENTS (formats))
+    return 0;
+
+  return formats[format].fourcc;
+}
+
+const gchar *
+gst_video_format_to_string (GstVideoFormat format)
+{
+  g_return_val_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN, NULL);
+
+  if (format >= G_N_ELEMENTS (formats))
+    return NULL;
+
+  return GST_VIDEO_FORMAT_INFO_NAME (&formats[format].info);
+}
+
+/**
+ * gst_video_format_get_info:
+ * @format: a #GstVideoFormat
+ *
+ * Get the #GstVideoFormatInfo for @format
+ *
+ * Returns: The #GstVideoFormatInfo for @format.
+ */
+const GstVideoFormatInfo *
+gst_video_format_get_info (GstVideoFormat format)
+{
+  g_return_val_if_fail (format < G_N_ELEMENTS (formats), NULL);
+
+  return &formats[format].info;
+}
+
+typedef struct
+{
+  const gchar *name;
+  GstVideoChromaSite site;
+} ChromaSiteInfo;
+
+static const ChromaSiteInfo chromasite[] = {
+  {"jpeg", GST_VIDEO_CHROMA_SITE_JPEG},
+  {"mpeg2", GST_VIDEO_CHROMA_SITE_MPEG2},
+  {"dv", GST_VIDEO_CHROMA_SITE_DV}
+};
+
+/**
+ * gst_video_chroma_from_string:
+ * @s: a chromasite string
+ *
+ * Convert @s to a #GstVideoChromaSite
+ *
+ * Returns: a #GstVideoChromaSite or %GST_VIDEO_CHROMA_SITE_UNKNOWN when @s does
+ * not contain a valid chroma description.
+ */
+GstVideoChromaSite
+gst_video_chroma_from_string (const gchar * s)
+{
+  gint i;
+  for (i = 0; i < G_N_ELEMENTS (chromasite); i++) {
+    if (g_str_equal (chromasite[i].name, s))
+      return chromasite[i].site;
+  }
+  return GST_VIDEO_CHROMA_SITE_UNKNOWN;
+}
+
+/**
+ * gst_video_chroma_to_string:
+ * @site: a #GstVideoChromaSite
+ *
+ * Converts @site to its string representation.
+ *
+ * Returns: a string describing @site.
+ */
+const gchar *
+gst_video_chroma_to_string (GstVideoChromaSite site)
+{
+  gint i;
+  for (i = 0; i < G_N_ELEMENTS (chromasite); i++) {
+    if (chromasite[i].site == site)
+      return chromasite[i].name;
+  }
+  return NULL;
+}
diff --git a/gst-libs/gst/video/video-format.h b/gst-libs/gst/video/video-format.h
new file mode 100644
index 0000000..3679448
--- /dev/null
+++ b/gst-libs/gst/video/video-format.h
@@ -0,0 +1,406 @@
+/* GStreamer
+ * Copyright (C) <2011> Wim Taymans <wim.taymans@gmail.com>
+ *
+ * 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_VIDEO_FORMAT_H__
+#define __GST_VIDEO_FORMAT_H__
+
+#include <gst/gst.h>
+
+G_BEGIN_DECLS
+
+#include <gst/video/video-enumtypes.h>
+
+/**
+ * GstVideoFormat:
+ * @GST_VIDEO_FORMAT_UNKNOWN: Unknown or unset video format id
+ * @GST_VIDEO_FORMAT_ENCODED: Encoded video format
+ * @GST_VIDEO_FORMAT_I420: planar 4:2:0 YUV
+ * @GST_VIDEO_FORMAT_YV12: planar 4:2:0 YVU (like I420 but UV planes swapped)
+ * @GST_VIDEO_FORMAT_YUY2: packed 4:2:2 YUV (Y0-U0-Y1-V0 Y2-U2-Y3-V2 Y4 ...)
+ * @GST_VIDEO_FORMAT_UYVY: packed 4:2:2 YUV (U0-Y0-V0-Y1 U2-Y2-V2-Y3 U4 ...)
+ * @GST_VIDEO_FORMAT_AYUV: packed 4:4:4 YUV with alpha channel (A0-Y0-U0-V0 ...)
+ * @GST_VIDEO_FORMAT_RGBx: sparse rgb packed into 32 bit, space last
+ * @GST_VIDEO_FORMAT_BGRx: sparse reverse rgb packed into 32 bit, space last
+ * @GST_VIDEO_FORMAT_xRGB: sparse rgb packed into 32 bit, space first
+ * @GST_VIDEO_FORMAT_xBGR: sparse reverse rgb packed into 32 bit, space first
+ * @GST_VIDEO_FORMAT_RGBA: rgb with alpha channel last
+ * @GST_VIDEO_FORMAT_BGRA: reverse rgb with alpha channel last
+ * @GST_VIDEO_FORMAT_ARGB: rgb with alpha channel first
+ * @GST_VIDEO_FORMAT_ABGR: reverse rgb with alpha channel first
+ * @GST_VIDEO_FORMAT_RGB: rgb
+ * @GST_VIDEO_FORMAT_BGR: reverse rgb
+ * @GST_VIDEO_FORMAT_Y41B: planar 4:1:1 YUV (Since: 0.10.18)
+ * @GST_VIDEO_FORMAT_Y42B: planar 4:2:2 YUV (Since: 0.10.18)
+ * @GST_VIDEO_FORMAT_YVYU: packed 4:2:2 YUV (Y0-V0-Y1-U0 Y2-V2-Y3-U2 Y4 ...) (Since: 0.10.23)
+ * @GST_VIDEO_FORMAT_Y444: planar 4:4:4 YUV (Since: 0.10.24)
+ * @GST_VIDEO_FORMAT_v210: packed 4:2:2 10-bit YUV, complex format (Since: 0.10.24)
+ * @GST_VIDEO_FORMAT_v216: packed 4:2:2 16-bit YUV, Y0-U0-Y1-V1 order (Since: 0.10.24)
+ * @GST_VIDEO_FORMAT_NV12: planar 4:2:0 YUV with interleaved UV plane (Since: 0.10.26)
+ * @GST_VIDEO_FORMAT_NV21: planar 4:2:0 YUV with interleaved VU plane (Since: 0.10.26)
+ * @GST_VIDEO_FORMAT_GRAY8: 8-bit grayscale (Since: 0.10.29)
+ * @GST_VIDEO_FORMAT_GRAY16_BE: 16-bit grayscale, most significant byte first (Since: 0.10.29)
+ * @GST_VIDEO_FORMAT_GRAY16_LE: 16-bit grayscale, least significant byte first (Since: 0.10.29)
+ * @GST_VIDEO_FORMAT_v308: packed 4:4:4 YUV (Since: 0.10.29)
+ * @GST_VIDEO_FORMAT_RGB16: rgb 5-6-5 bits per component (Since: 0.10.30)
+ * @GST_VIDEO_FORMAT_BGR16: reverse rgb 5-6-5 bits per component (Since: 0.10.30)
+ * @GST_VIDEO_FORMAT_RGB15: rgb 5-5-5 bits per component (Since: 0.10.30)
+ * @GST_VIDEO_FORMAT_BGR15: reverse rgb 5-5-5 bits per component (Since: 0.10.30)
+ * @GST_VIDEO_FORMAT_UYVP: packed 10-bit 4:2:2 YUV (U0-Y0-V0-Y1 U2-Y2-V2-Y3 U4 ...) (Since: 0.10.31)
+ * @GST_VIDEO_FORMAT_A420: planar 4:4:2:0 AYUV (Since: 0.10.31)
+ * @GST_VIDEO_FORMAT_RGB8P: 8-bit paletted RGB (Since: 0.10.32)
+ * @GST_VIDEO_FORMAT_YUV9: planar 4:1:0 YUV (Since: 0.10.32)
+ * @GST_VIDEO_FORMAT_YVU9: planar 4:1:0 YUV (like YUV9 but UV planes swapped) (Since: 0.10.32)
+ * @GST_VIDEO_FORMAT_IYU1: packed 4:1:1 YUV (Cb-Y0-Y1-Cr-Y2-Y3 ...) (Since: 0.10.32)
+ * @GST_VIDEO_FORMAT_ARGB64: rgb with alpha channel first, 16 bits per channel (Since: 0.10.33)
+ * @GST_VIDEO_FORMAT_AYUV64: packed 4:4:4 YUV with alpha channel, 16 bits per channel (A0-Y0-U0-V0 ...) (Since: 0.10.33)
+ * @GST_VIDEO_FORMAT_r210: packed 4:4:4 RGB, 10 bits per channel (Since: 0.10.33)
+ * @GST_VIDEO_FORMAT_I420_10BE: planar 4:2:0 YUV, 10 bits per channel
+ * @GST_VIDEO_FORMAT_I420_10LE: planar 4:2:0 YUV, 10 bits per channel
+ *
+ * Enum value describing the most common video formats.
+ */
+typedef enum {
+  GST_VIDEO_FORMAT_UNKNOWN,
+  GST_VIDEO_FORMAT_ENCODED,
+  GST_VIDEO_FORMAT_I420,
+  GST_VIDEO_FORMAT_YV12,
+  GST_VIDEO_FORMAT_YUY2,
+  GST_VIDEO_FORMAT_UYVY,
+  GST_VIDEO_FORMAT_AYUV,
+  GST_VIDEO_FORMAT_RGBx,
+  GST_VIDEO_FORMAT_BGRx,
+  GST_VIDEO_FORMAT_xRGB,
+  GST_VIDEO_FORMAT_xBGR,
+  GST_VIDEO_FORMAT_RGBA,
+  GST_VIDEO_FORMAT_BGRA,
+  GST_VIDEO_FORMAT_ARGB,
+  GST_VIDEO_FORMAT_ABGR,
+  GST_VIDEO_FORMAT_RGB,
+  GST_VIDEO_FORMAT_BGR,
+  GST_VIDEO_FORMAT_Y41B,
+  GST_VIDEO_FORMAT_Y42B,
+  GST_VIDEO_FORMAT_YVYU,
+  GST_VIDEO_FORMAT_Y444,
+  GST_VIDEO_FORMAT_v210,
+  GST_VIDEO_FORMAT_v216,
+  GST_VIDEO_FORMAT_NV12,
+  GST_VIDEO_FORMAT_NV21,
+  GST_VIDEO_FORMAT_GRAY8,
+  GST_VIDEO_FORMAT_GRAY16_BE,
+  GST_VIDEO_FORMAT_GRAY16_LE,
+  GST_VIDEO_FORMAT_v308,
+  GST_VIDEO_FORMAT_RGB16,
+  GST_VIDEO_FORMAT_BGR16,
+  GST_VIDEO_FORMAT_RGB15,
+  GST_VIDEO_FORMAT_BGR15,
+  GST_VIDEO_FORMAT_UYVP,
+  GST_VIDEO_FORMAT_A420,
+  GST_VIDEO_FORMAT_RGB8P,
+  GST_VIDEO_FORMAT_YUV9,
+  GST_VIDEO_FORMAT_YVU9,
+  GST_VIDEO_FORMAT_IYU1,
+  GST_VIDEO_FORMAT_ARGB64,
+  GST_VIDEO_FORMAT_AYUV64,
+  GST_VIDEO_FORMAT_r210,
+  GST_VIDEO_FORMAT_I420_10BE,
+  GST_VIDEO_FORMAT_I420_10LE
+} GstVideoFormat;
+
+#define GST_VIDEO_MAX_PLANES 4
+#define GST_VIDEO_MAX_COMPONENTS 4
+
+typedef struct _GstVideoFormatInfo GstVideoFormatInfo;
+
+/**
+ * GstVideoChromaSite:
+ * @GST_VIDEO_CHROMA_SITE_UNKNOWN: unknown cositing
+ * @GST_VIDEO_CHROMA_SITE_NONE: no cositing
+ * @GST_VIDEO_CHROMA_SITE_H_COSITED: chroma is horizontally cosited
+ * @GST_VIDEO_CHROMA_SITE_V_COSITED: chroma is vertically cosited
+ * @GST_VIDEO_CHROMA_SITE_ALT_LINE: choma samples are sited on alternate lines
+ * @GST_VIDEO_CHROMA_SITE_COSITED: chroma samples cosited with luma samples
+ * @GST_VIDEO_CHROMA_SITE_JPEG: jpeg style cositing, also for mpeg1 and mjpeg
+ * @GST_VIDEO_CHROMA_SITE_MPEG2: mpeg2 style cositing
+ * @GST_VIDEO_CHROMA_SITE_DV: DV style cositing
+ *
+ * Various Chroma sitings.
+ */
+typedef enum {
+  GST_VIDEO_CHROMA_SITE_UNKNOWN   =  0,
+  GST_VIDEO_CHROMA_SITE_NONE      = (1 << 0),
+  GST_VIDEO_CHROMA_SITE_H_COSITED = (1 << 1),
+  GST_VIDEO_CHROMA_SITE_V_COSITED = (1 << 2),
+  GST_VIDEO_CHROMA_SITE_ALT_LINE  = (1 << 3),
+  /* some common chroma cositing */
+  GST_VIDEO_CHROMA_SITE_COSITED   = (GST_VIDEO_CHROMA_SITE_H_COSITED | GST_VIDEO_CHROMA_SITE_V_COSITED),
+  GST_VIDEO_CHROMA_SITE_JPEG      = (GST_VIDEO_CHROMA_SITE_NONE),
+  GST_VIDEO_CHROMA_SITE_MPEG2     = (GST_VIDEO_CHROMA_SITE_H_COSITED),
+  GST_VIDEO_CHROMA_SITE_DV        = (GST_VIDEO_CHROMA_SITE_COSITED | GST_VIDEO_CHROMA_SITE_ALT_LINE),
+} GstVideoChromaSite;
+
+GstVideoChromaSite    gst_video_chroma_from_string   (const gchar * s);
+const gchar *         gst_video_chroma_to_string     (GstVideoChromaSite site);
+
+/**
+ * GstVideoFormatFlags:
+ * @GST_VIDEO_FORMAT_FLAG_YUV: The video format is YUV, components are numbered
+ *   0=Y, 1=U, 2=V.
+ * @GST_VIDEO_FORMAT_FLAG_RGB: The video format is RGB, components are numbered
+ *   0=R, 1=G, 2=B.
+ * @GST_VIDEO_FORMAT_FLAG_GRAY: The video is gray, there is one gray component
+ *   with index 0.
+ * @GST_VIDEO_FORMAT_FLAG_ALPHA: The video format has an alpha components with
+ *   the number 3.
+ * @GST_VIDEO_FORMAT_FLAG_LE: The video format has data stored in little
+ *   endianness.
+ * @GST_VIDEO_FORMAT_FLAG_PALETTE: The video format has a palette. The palette
+ *   is stored in the second plane and indexes are stored in the first plane.
+ * @GST_VIDEO_FORMAT_FLAG_COMPLEX: The video format has a complex layout that
+ *   can't be described with the usual information in the #GstVideoFormatInfo.
+ *
+ * The different video flags that a format info can have.
+ */
+typedef enum
+{
+  GST_VIDEO_FORMAT_FLAG_YUV      = (1 << 0),
+  GST_VIDEO_FORMAT_FLAG_RGB      = (1 << 1),
+  GST_VIDEO_FORMAT_FLAG_GRAY     = (1 << 2),
+  GST_VIDEO_FORMAT_FLAG_ALPHA    = (1 << 3),
+  GST_VIDEO_FORMAT_FLAG_LE       = (1 << 4),
+  GST_VIDEO_FORMAT_FLAG_PALETTE  = (1 << 5),
+  GST_VIDEO_FORMAT_FLAG_COMPLEX  = (1 << 6)
+} GstVideoFormatFlags;
+
+/* YUV components */
+#define GST_VIDEO_COMP_Y  0
+#define GST_VIDEO_COMP_U  1
+#define GST_VIDEO_COMP_V  2
+
+/* RGB components */
+#define GST_VIDEO_COMP_R  0
+#define GST_VIDEO_COMP_G  1
+#define GST_VIDEO_COMP_B  2
+
+/* alpha component */
+#define GST_VIDEO_COMP_A  3
+
+/* palette components */
+#define GST_VIDEO_COMP_INDEX    0
+#define GST_VIDEO_COMP_PALETTE  1
+
+/**
+ * GstVideoPackFlags:
+ * @GST_VIDEO_PACK_FLAG_NONE: No flag
+ *
+ * The different flags that can be used when packing and unpacking.
+ */
+typedef enum
+{
+  GST_VIDEO_PACK_FLAG_NONE       = 0
+} GstVideoPackFlags;
+
+/**
+ * GstVideoFormatUnpack:
+ * @info: a #GstVideoFormatInfo
+ * @flags: flags to control the unpacking
+ * @dest: a destination array
+ * @data: pointers to the data planes
+ * @stride: strides of the planes
+ * @x: the x position in the image to start from
+ * @y: the y position in the image to start from
+ * @width: the amount of pixels to unpack.
+ *
+ * Unpacks @width pixels from the given planes and strides containing data of
+ * format @info. The pixels will be unpacked into @dest which each component
+ * interleaved. @dest should at least be big enough to hold @width *
+ * n_components * size(unpack_format) bytes.
+ */
+typedef void (*GstVideoFormatUnpack)         (const GstVideoFormatInfo *info,
+                                              GstVideoPackFlags flags, gpointer dest,
+                                              const gpointer data[GST_VIDEO_MAX_PLANES],
+                                              const gint stride[GST_VIDEO_MAX_PLANES],
+                                              gint x, gint y, gint width);
+/**
+ * GstVideoFormatPack:
+ * @info: a #GstVideoFormatInfo
+ * @flags: flags to control the packing
+ * @src: a source array
+ * @sstride: the source array stride
+ * @data: pointers to the destination data planes
+ * @stride: strides of the destination planes
+ * @chroma_site: the chroma siting of the target when subsampled
+ * @y: the y position in the image to pack to
+ * @width: the amount of pixels to pack.
+ *
+ * Packs @width pixels from @src to the given planes and strides in the
+ * format @info. The pixels from source have each component interleaved
+ * and will be packed into the planes in @data.
+ *
+ * This function operates on pack_lines lines, meaning that @src should
+ * contain at least pack_lines lines with a stride of @sstride and @y
+ * should be a multiple of pack_lines.
+ */
+typedef void (*GstVideoFormatPack)           (const GstVideoFormatInfo *info,
+                                              GstVideoPackFlags flags,
+                                              const gpointer src, gint sstride,
+                                              gpointer data[GST_VIDEO_MAX_PLANES],
+                                              const gint stride[GST_VIDEO_MAX_PLANES],
+                                              GstVideoChromaSite chroma_site,
+                                              gint y, gint width);
+
+/**
+ * GstVideoFormatInfo:
+ * @format: #GstVideoFormat
+ * @name: string representation of the format
+ * @description: use readable description of the format
+ * @flags: #GstVideoFormatFlags
+ * @bits: The number of bits used to pack data items. This can be less than 8
+ *    when multiple pixels are stored in a byte. for values > 8 multiple bytes
+ *    should be read according to the endianness flag before applying the shift
+ *    and mask.
+ * @n_components: the number of components in the video format.
+ * @shift: the number of bits to shift away to get the component data
+ * @depth: the depth in bits for each component
+ * @pixel_stride: the pixel stride of each component. This is the amount of
+ *    bytes to the pixel immediately to the right. When bits < 8, the stride is
+ *    expressed in bits.
+ * @n_planes: the number of planes for this format. The number of planes can be
+ *    less than the amount of components when multiple components are packed into
+ *    one plane.
+ * @plane: the plane number where a component can be found
+ * @poffset: the offset in the plane where the first pixel of the components
+ *    can be found. If bits < 8 the amount is specified in bits.
+ * @w_sub: subsampling factor of the width for the component. Use
+ *     GST_VIDEO_SUB_SCALE to scale a width.
+ * @h_sub: subsampling factor of the height for the component. Use
+ *     GST_VIDEO_SUB_SCALE to scale a height.
+ * @unpack_format: the format of the unpacked pixels.
+ * @unpack_func: an unpack function for this format
+ * @pack_lines: the amount of lines that will be packed
+ * @pack_func: an pack function for this format
+ *
+ * Information for a video format.
+ */
+struct _GstVideoFormatInfo {
+  GstVideoFormat format;
+  const gchar *name;
+  const gchar *description;
+  GstVideoFormatFlags flags;
+  guint bits;
+  guint n_components;
+  guint shift[GST_VIDEO_MAX_COMPONENTS];
+  guint depth[GST_VIDEO_MAX_COMPONENTS];
+  gint  pixel_stride[GST_VIDEO_MAX_COMPONENTS];
+  guint n_planes;
+  guint plane[GST_VIDEO_MAX_COMPONENTS];
+  guint poffset[GST_VIDEO_MAX_COMPONENTS];
+  guint w_sub[GST_VIDEO_MAX_COMPONENTS];
+  guint h_sub[GST_VIDEO_MAX_COMPONENTS];
+
+  GstVideoFormat unpack_format;
+  GstVideoFormatUnpack unpack_func;
+  gint pack_lines;
+  GstVideoFormatPack pack_func;
+
+  gpointer _gst_reserved[GST_PADDING];
+};
+
+#define GST_VIDEO_FORMAT_INFO_FORMAT(info)       ((info)->format)
+#define GST_VIDEO_FORMAT_INFO_NAME(info)         ((info)->name)
+#define GST_VIDEO_FORMAT_INFO_FLAGS(info)        ((info)->flags)
+
+#define GST_VIDEO_FORMAT_INFO_IS_YUV(info)       ((info)->flags & GST_VIDEO_FORMAT_FLAG_YUV)
+#define GST_VIDEO_FORMAT_INFO_IS_RGB(info)       ((info)->flags & GST_VIDEO_FORMAT_FLAG_RGB)
+#define GST_VIDEO_FORMAT_INFO_IS_GRAY(info)      ((info)->flags & GST_VIDEO_FORMAT_FLAG_GRAY)
+#define GST_VIDEO_FORMAT_INFO_HAS_ALPHA(info)    ((info)->flags & GST_VIDEO_FORMAT_FLAG_ALPHA)
+#define GST_VIDEO_FORMAT_INFO_IS_LE(info)        ((info)->flags & GST_VIDEO_FORMAT_FLAG_LE)
+#define GST_VIDEO_FORMAT_INFO_HAS_PALETTE(info)  ((info)->flags & GST_VIDEO_FORMAT_FLAG_PALETTE)
+#define GST_VIDEO_FORMAT_INFO_IS_COMPLEX(info)   ((info)->flags & GST_VIDEO_FORMAT_FLAG_COMPLEX)
+
+#define GST_VIDEO_FORMAT_INFO_BITS(info)         ((info)->bits)
+#define GST_VIDEO_FORMAT_INFO_N_COMPONENTS(info) ((info)->n_components)
+#define GST_VIDEO_FORMAT_INFO_SHIFT(info,c)      ((info)->shift[c])
+#define GST_VIDEO_FORMAT_INFO_DEPTH(info,c)      ((info)->depth[c])
+#define GST_VIDEO_FORMAT_INFO_PSTRIDE(info,c)    ((info)->pixel_stride[c])
+#define GST_VIDEO_FORMAT_INFO_N_PLANES(info)     ((info)->n_planes)
+#define GST_VIDEO_FORMAT_INFO_PLANE(info,c)      ((info)->plane[c])
+#define GST_VIDEO_FORMAT_INFO_POFFSET(info,c)    ((info)->poffset[c])
+#define GST_VIDEO_FORMAT_INFO_W_SUB(info,c)      ((info)->w_sub[c])
+#define GST_VIDEO_FORMAT_INFO_H_SUB(info,c)      ((info)->h_sub[c])
+
+/* rounds up */
+#define GST_VIDEO_SUB_SCALE(scale,val)   (-((-((gint)(val)))>>(scale)))
+
+#define GST_VIDEO_FORMAT_INFO_SCALE_WIDTH(info,c,w)  GST_VIDEO_SUB_SCALE ((info)->w_sub[c],(w))
+#define GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT(info,c,h) GST_VIDEO_SUB_SCALE ((info)->h_sub[c],(h))
+
+#define GST_VIDEO_FORMAT_INFO_DATA(info,planes,comp) \
+  (((guint8*)(planes)[(info)->plane[comp]]) + (info)->poffset[comp])
+#define GST_VIDEO_FORMAT_INFO_STRIDE(info,strides,comp) ((strides)[(info)->plane[comp]])
+#define GST_VIDEO_FORMAT_INFO_OFFSET(info,offsets,comp) \
+  (((offsets)[(info)->plane[comp]]) + (info)->poffset[comp])
+
+/* format properties */
+GstVideoFormat gst_video_format_from_masks           (gint depth, gint bpp, gint endianness,
+                                                      gint red_mask, gint green_mask,
+                                                      gint blue_mask, gint alpha_mask) G_GNUC_CONST;
+
+GstVideoFormat gst_video_format_from_fourcc          (guint32 fourcc) G_GNUC_CONST;
+GstVideoFormat gst_video_format_from_string          (const gchar *format) G_GNUC_CONST;
+
+guint32        gst_video_format_to_fourcc            (GstVideoFormat format) G_GNUC_CONST;
+const gchar *  gst_video_format_to_string            (GstVideoFormat format) G_GNUC_CONST;
+
+const GstVideoFormatInfo *
+               gst_video_format_get_info             (GstVideoFormat format) G_GNUC_CONST;
+
+#define GST_VIDEO_SIZE_RANGE "(int) [ 1, max ]"
+#define GST_VIDEO_FPS_RANGE "(fraction) [ 0, max ]"
+
+#if G_BYTE_ORDER == G_LITTLE_ENDIAN
+# define GST_VIDEO_NE(s) G_STRINGIFY(s)"_LE"
+# define GST_VIDEO_OE(s) G_STRINGIFY(s)"_BE"
+#else
+# define GST_VIDEO_NE(s) G_STRINGIFY(s)"_BE"
+# define GST_VIDEO_OE(s) G_STRINGIFY(s)"_LE"
+#endif
+
+#define GST_VIDEO_FORMATS_ALL "{ I420, YV12, YUY2, UYVY, AYUV, RGBx, "  \
+    "BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, "  \
+    "YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, " \
+    "v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, " \
+    "IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE }"
+
+/**
+ * GST_VIDEO_CAPS_MAKE:
+ * @format: string format that describes the pixel layout, as string
+ *     (e.g. "I420", "RGB", "YV12", "YUY2", "AYUV", etc.)
+ *
+ * Generic caps string for video, for use in pad templates.
+ */
+#define GST_VIDEO_CAPS_MAKE(format)                                     \
+    "video/x-raw, "                                                     \
+    "format = (string) " format ", "                                    \
+    "width = " GST_VIDEO_SIZE_RANGE ", "                                \
+    "height = " GST_VIDEO_SIZE_RANGE ", "                               \
+    "framerate = " GST_VIDEO_FPS_RANGE
+
+G_END_DECLS
+
+#endif /* __GST_VIDEO_FORMAT_H__ */
diff --git a/gst-libs/gst/video/video-frame.c b/gst-libs/gst/video/video-frame.c
new file mode 100644
index 0000000..20528d3
--- /dev/null
+++ b/gst-libs/gst/video/video-frame.c
@@ -0,0 +1,266 @@
+/* GStreamer
+ * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
+ * Library       <2002> Ronald Bultje <rbultje@ronald.bitfreak.net>
+ * Copyright (C) 2007 David A. Schleef <ds@schleef.org>
+ *
+ * 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 <stdio.h>
+
+#include "video-frame.h"
+#include "gstvideometa.h"
+
+GST_DEBUG_CATEGORY_EXTERN (GST_CAT_PERFORMANCE);
+
+/**
+ * gst_video_frame_map_id:
+ * @frame: pointer to #GstVideoFrame
+ * @info: a #GstVideoInfo
+ * @buffer: the buffer to map
+ * @id: the frame id to map
+ * @flags: #GstMapFlags
+ *
+ * Use @info and @buffer to fill in the values of @frame with the video frame
+ * information of frame @id.
+ *
+ * When @id is -1, the default frame is mapped. When @id != -1, this function
+ * will return %FALSE when there is no GstVideoMeta with that id.
+ *
+ * All video planes of @buffer will be mapped and the pointers will be set in
+ * @frame->data.
+ *
+ * Returns: %TRUE on success.
+ */
+gboolean
+gst_video_frame_map_id (GstVideoFrame * frame, GstVideoInfo * info,
+    GstBuffer * buffer, gint id, GstMapFlags flags)
+{
+  GstVideoMeta *meta;
+  gint i;
+
+  g_return_val_if_fail (frame != NULL, FALSE);
+  g_return_val_if_fail (info != NULL, FALSE);
+  g_return_val_if_fail (GST_IS_BUFFER (buffer), FALSE);
+
+  if (id == -1)
+    meta = gst_buffer_get_video_meta (buffer);
+  else
+    meta = gst_buffer_get_video_meta_id (buffer, id);
+
+  /* copy the info */
+  frame->info = *info;
+
+  if (meta) {
+    frame->info.finfo = gst_video_format_get_info (meta->format);
+    frame->info.width = meta->width;
+    frame->info.height = meta->height;
+    frame->id = meta->id;
+    frame->flags = meta->flags;
+
+    for (i = 0; i < info->finfo->n_planes; i++)
+      gst_video_meta_map (meta, i, &frame->map[i], &frame->data[i],
+          &frame->info.stride[i], flags);
+  } else {
+    /* no metadata, we really need to have the metadata when the id is
+     * specified. */
+    if (id != -1)
+      goto no_metadata;
+
+    frame->id = id;
+    frame->flags = 0;
+
+    if (GST_VIDEO_INFO_IS_INTERLACED (info)) {
+      if (GST_BUFFER_FLAG_IS_SET (buffer, GST_VIDEO_BUFFER_FLAG_TFF))
+        frame->flags |= GST_VIDEO_FRAME_FLAG_TFF;
+      if (GST_BUFFER_FLAG_IS_SET (buffer, GST_VIDEO_BUFFER_FLAG_RFF))
+        frame->flags |= GST_VIDEO_FRAME_FLAG_RFF;
+      if (GST_BUFFER_FLAG_IS_SET (buffer, GST_VIDEO_BUFFER_FLAG_ONEFIELD))
+        frame->flags |= GST_VIDEO_FRAME_FLAG_ONEFIELD;
+    }
+
+    gst_buffer_map (buffer, &frame->map[0], flags);
+
+    /* do some sanity checks */
+    if (frame->map[0].size < info->size)
+      goto invalid_size;
+
+    /* set up pointers */
+    for (i = 0; i < info->finfo->n_planes; i++) {
+      frame->data[i] = frame->map[0].data + info->offset[i];
+    }
+  }
+  frame->buffer = gst_buffer_ref (buffer);
+  frame->meta = meta;
+
+  return TRUE;
+
+  /* ERRORS */
+no_metadata:
+  {
+    GST_ERROR ("no GstVideoMeta for id %d", id);
+    return FALSE;
+  }
+invalid_size:
+  {
+    GST_ERROR ("invalid buffer size %" G_GSIZE_FORMAT " < %" G_GSIZE_FORMAT,
+        frame->map[0].size, info->size);
+    gst_buffer_unmap (buffer, &frame->map[0]);
+    return FALSE;
+  }
+}
+
+/**
+ * gst_video_frame_map:
+ * @frame: pointer to #GstVideoFrame
+ * @info: a #GstVideoInfo
+ * @buffer: the buffer to map
+ * @flags: #GstMapFlags
+ *
+ * Use @info and @buffer to fill in the values of @frame.
+ *
+ * All video planes of @buffer will be mapped and the pointers will be set in
+ * @frame->data.
+ *
+ * Returns: %TRUE on success.
+ */
+gboolean
+gst_video_frame_map (GstVideoFrame * frame, GstVideoInfo * info,
+    GstBuffer * buffer, GstMapFlags flags)
+{
+  return gst_video_frame_map_id (frame, info, buffer, -1, flags);
+}
+
+/**
+ * gst_video_frame_unmap:
+ * @frame: a #GstVideoFrame
+ *
+ * Unmap the memory previously mapped with gst_video_frame_map.
+ */
+void
+gst_video_frame_unmap (GstVideoFrame * frame)
+{
+  GstBuffer *buffer;
+  GstVideoMeta *meta;
+  gint i;
+
+  g_return_if_fail (frame != NULL);
+
+  buffer = frame->buffer;
+  meta = frame->meta;
+
+  if (meta) {
+    for (i = 0; i < frame->info.finfo->n_planes; i++) {
+      gst_video_meta_unmap (meta, i, &frame->map[i]);
+    }
+  } else {
+    gst_buffer_unmap (buffer, &frame->map[0]);
+  }
+  gst_buffer_unref (buffer);
+}
+
+/**
+ * gst_video_frame_copy:
+ * @dest: a #GstVideoFrame
+ * @src: a #GstVideoFrame
+ * @plane: a plane
+ *
+ * Copy the plane with index @plane from @src to @dest.
+ *
+ * Returns: TRUE if the contents could be copied.
+ */
+gboolean
+gst_video_frame_copy_plane (GstVideoFrame * dest, const GstVideoFrame * src,
+    guint plane)
+{
+  const GstVideoInfo *sinfo;
+  GstVideoInfo *dinfo;
+  guint w, h, j;
+  guint8 *sp, *dp;
+  gint ss, ds;
+
+  g_return_val_if_fail (dest != NULL, FALSE);
+  g_return_val_if_fail (src != NULL, FALSE);
+
+  sinfo = &src->info;
+  dinfo = &dest->info;
+
+  g_return_val_if_fail (dinfo->finfo->format == sinfo->finfo->format, FALSE);
+  g_return_val_if_fail (dinfo->width == sinfo->width
+      && dinfo->height == sinfo->height, FALSE);
+  g_return_val_if_fail (dinfo->finfo->n_planes > plane, FALSE);
+
+  sp = src->data[plane];
+  dp = dest->data[plane];
+
+  ss = sinfo->stride[plane];
+  ds = dinfo->stride[plane];
+
+  w = MIN (ABS (ss), ABS (ds));
+  h = GST_VIDEO_FRAME_COMP_HEIGHT (dest, plane);
+
+  GST_CAT_DEBUG (GST_CAT_PERFORMANCE, "copy plane %d, w:%d h:%d ", plane, w, h);
+
+  for (j = 0; j < h; j++) {
+    memcpy (dp, sp, w);
+    dp += ds;
+    sp += ss;
+  }
+  return TRUE;
+}
+
+/**
+ * gst_video_frame_copy:
+ * @dest: a #GstVideoFrame
+ * @src: a #GstVideoFrame
+ *
+ * Copy the contents from @src to @dest.
+ *
+ * Returns: TRUE if the contents could be copied.
+ */
+gboolean
+gst_video_frame_copy (GstVideoFrame * dest, const GstVideoFrame * src)
+{
+  guint i, n_planes;
+  const GstVideoInfo *sinfo;
+  GstVideoInfo *dinfo;
+
+  g_return_val_if_fail (dest != NULL, FALSE);
+  g_return_val_if_fail (src != NULL, FALSE);
+
+  sinfo = &src->info;
+  dinfo = &dest->info;
+
+  g_return_val_if_fail (dinfo->finfo->format == sinfo->finfo->format, FALSE);
+  g_return_val_if_fail (dinfo->width == sinfo->width
+      && dinfo->height == sinfo->height, FALSE);
+
+  n_planes = dinfo->finfo->n_planes;
+  if (GST_VIDEO_FORMAT_INFO_HAS_PALETTE (sinfo->finfo)) {
+    memcpy (dest->data[1], src->data[1], 256 * 4);
+    n_planes = 1;
+  }
+
+  for (i = 0; i < n_planes; i++)
+    gst_video_frame_copy_plane (dest, src, i);
+
+  return TRUE;
+}
diff --git a/gst-libs/gst/video/video-frame.h b/gst-libs/gst/video/video-frame.h
new file mode 100644
index 0000000..a27d77a
--- /dev/null
+++ b/gst-libs/gst/video/video-frame.h
@@ -0,0 +1,132 @@
+/* GStreamer
+ * Copyright (C) <2011> Wim Taymans <wim.taymans@gmail.com>
+ *
+ * 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_VIDEO_FRAME_H__
+#define __GST_VIDEO_FRAME_H__
+
+#include <gst/gst.h>
+#include <gst/video/video-info.h>
+
+G_BEGIN_DECLS
+
+#include <gst/video/video-enumtypes.h>
+
+typedef struct _GstVideoFrame GstVideoFrame;
+
+/**
+ * GstVideoFrameFlags:
+ * @GST_VIDEO_FRAME_FLAG_NONE: no flags
+ * @GST_VIDEO_FRAME_FLAG_TFF: The video frame has the top field first
+ * @GST_VIDEO_FRAME_FLAG_RFF: The video frame has the repeat flag
+ * @GST_VIDEO_FRAME_FLAG_ONEFIELD: The video frame has one field
+ *
+ * Extra video frame flags
+ */
+typedef enum {
+  GST_VIDEO_FRAME_FLAG_NONE         = 0,
+  GST_VIDEO_FRAME_FLAG_TFF          = (1 << 0),
+  GST_VIDEO_FRAME_FLAG_RFF          = (1 << 1),
+  GST_VIDEO_FRAME_FLAG_ONEFIELD     = (1 << 2)
+} GstVideoFrameFlags;
+
+/**
+ * GstVideoFrame:
+ * @info: the #GstVideoInfo
+ * @buffer: the mapped buffer
+ * @meta: pointer to metadata if any
+ * @id: id of the mapped frame. the id can for example be used to
+ *   indentify the frame in case of multiview video.
+ * @data: pointers to the plane data
+ * @map: mappings of the planes
+ *
+ * A video frame obtained from gst_video_frame_map()
+ */
+struct _GstVideoFrame {
+  GstVideoInfo info;
+  GstVideoFrameFlags flags;
+
+  GstBuffer *buffer;
+  gpointer   meta;
+  gint       id;
+
+  gpointer   data[GST_VIDEO_MAX_PLANES];
+  GstMapInfo map[GST_VIDEO_MAX_PLANES];
+};
+
+gboolean    gst_video_frame_map           (GstVideoFrame *frame, GstVideoInfo *info,
+                                           GstBuffer *buffer, GstMapFlags flags);
+gboolean    gst_video_frame_map_id        (GstVideoFrame *frame, GstVideoInfo *info,
+                                           GstBuffer *buffer, gint id, GstMapFlags flags);
+void        gst_video_frame_unmap         (GstVideoFrame *frame);
+
+gboolean    gst_video_frame_copy          (GstVideoFrame *dest, const GstVideoFrame *src);
+gboolean    gst_video_frame_copy_plane    (GstVideoFrame *dest, const GstVideoFrame *src,
+                                           guint plane);
+
+/* general info */
+#define GST_VIDEO_FRAME_FORMAT(f)         (GST_VIDEO_INFO_FORMAT(&(f)->info))
+#define GST_VIDEO_FRAME_WIDTH(f)          (GST_VIDEO_INFO_WIDTH(&(f)->info))
+#define GST_VIDEO_FRAME_HEIGHT(f)         (GST_VIDEO_INFO_HEIGHT(&(f)->info))
+#define GST_VIDEO_FRAME_SIZE(f)           (GST_VIDEO_INFO_SIZE(&(f)->info))
+
+/* dealing with planes */
+#define GST_VIDEO_FRAME_N_PLANES(f)       (GST_VIDEO_INFO_N_PLANES(&(f)->info))
+#define GST_VIDEO_FRAME_PLANE_DATA(f,p)   ((f)->data[p])
+#define GST_VIDEO_FRAME_PLANE_OFFSET(f,p) (GST_VIDEO_INFO_PLANE_OFFSET(&(f)->info,(p)))
+#define GST_VIDEO_FRAME_PLANE_STRIDE(f,p) (GST_VIDEO_INFO_PLANE_STRIDE(&(f)->info,(p)))
+
+/* dealing with components */
+#define GST_VIDEO_FRAME_N_COMPONENTS(f)   GST_VIDEO_INFO_N_COMPONENTS(&(f)->info)
+#define GST_VIDEO_FRAME_COMP_DEPTH(f,c)   GST_VIDEO_INFO_COMP_DEPTH(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_DATA(f,c)    GST_VIDEO_INFO_COMP_DATA(&(f)->info,(f)->data,(c))
+#define GST_VIDEO_FRAME_COMP_STRIDE(f,c)  GST_VIDEO_INFO_COMP_STRIDE(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_OFFSET(f,c)  GST_VIDEO_INFO_COMP_OFFSET(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_WIDTH(f,c)   GST_VIDEO_INFO_COMP_WIDTH(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_HEIGHT(f,c)  GST_VIDEO_INFO_COMP_HEIGHT(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_PLANE(f,c)   GST_VIDEO_INFO_COMP_PLANE(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_PSTRIDE(f,c) GST_VIDEO_INFO_COMP_PSTRIDE(&(f)->info,(c))
+#define GST_VIDEO_FRAME_COMP_POFFSET(f,c) GST_VIDEO_INFO_COMP_POFFSET(&(f)->info,(c))
+
+/* buffer flags */
+
+/**
+ * GstVideoBufferFlags:
+ * @GST_VIDEO_BUFFER_FLAG_TFF:         If the #GstBuffer is interlaced, then the first field
+ *                                     in the video frame is the top field.  If unset, the
+ *                                     bottom field is first.
+ * @GST_VIDEO_BUFFER_FLAG_RFF:         If the #GstBuffer is interlaced, then the first field
+ *                                     (as defined by the %GST_VIDEO_BUFFER_TFF flag setting)
+ *                                     is repeated.
+ * @GST_VIDEO_BUFFER_FLAG_ONEFIELD:    If the #GstBuffer is interlaced, then only the
+ *                                     first field (as defined by the %GST_VIDEO_BUFFER_TFF
+ *                                     flag setting) is to be displayed.
+ *
+ * Additional video buffer flags.
+ */
+typedef enum {
+  GST_VIDEO_BUFFER_FLAG_TFF         = (GST_BUFFER_FLAG_LAST << 0),
+  GST_VIDEO_BUFFER_FLAG_RFF         = (GST_BUFFER_FLAG_LAST << 1),
+  GST_VIDEO_BUFFER_FLAG_ONEFIELD    = (GST_BUFFER_FLAG_LAST << 2),
+
+  GST_VIDEO_BUFFER_FLAG_LAST        = (GST_BUFFER_FLAG_LAST << 8)
+} GstVideoBufferFlags;
+
+G_END_DECLS
+
+#endif /* __GST_VIDEO_FRAME_H__ */
diff --git a/gst-libs/gst/video/video-info.c b/gst-libs/gst/video/video-info.c
new file mode 100644
index 0000000..d4439fc
--- /dev/null
+++ b/gst-libs/gst/video/video-info.c
@@ -0,0 +1,669 @@
+/* GStreamer
+ * Copyright (C) <1999> Erik Walthinsen <omega@cse.ogi.edu>
+ * Library       <2002> Ronald Bultje <rbultje@ronald.bitfreak.net>
+ * Copyright (C) 2007 David A. Schleef <ds@schleef.org>
+ *
+ * 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 <stdio.h>
+
+#include "video-info.h"
+
+static int fill_planes (GstVideoInfo * info);
+
+/**
+ * gst_video_info_init:
+ * @info: a #GstVideoInfo
+ *
+ * Initialize @info with default values.
+ */
+void
+gst_video_info_init (GstVideoInfo * info)
+{
+  g_return_if_fail (info != NULL);
+
+  memset (info, 0, sizeof (GstVideoInfo));
+
+  info->finfo = gst_video_format_get_info (GST_VIDEO_FORMAT_UNKNOWN);
+
+  info->views = 1;
+  /* arrange for sensible defaults, e.g. if turned into caps */
+  info->fps_n = 0;
+  info->fps_d = 1;
+  info->par_n = 1;
+  info->par_d = 1;
+}
+
+#define MAKE_COLORIMETRY(r,m,t,p) {  \
+  GST_VIDEO_COLOR_RANGE ##r, GST_VIDEO_COLOR_MATRIX_ ##m, \
+  GST_VIDEO_TRANSFER_ ##t, GST_VIDEO_COLOR_PRIMARIES_ ##p }
+
+#define DEFAULT_YUV_SD  0
+#define DEFAULT_YUV_HD  1
+#define DEFAULT_RGB     2
+#define DEFAULT_GRAY    3
+#define DEFAULT_UNKNOWN 4
+
+static const GstVideoColorimetry default_color[] = {
+  MAKE_COLORIMETRY (_16_235, BT601, BT709, BT470M),
+  MAKE_COLORIMETRY (_16_235, BT709, BT709, BT709),
+  MAKE_COLORIMETRY (_0_255, RGB, UNKNOWN, UNKNOWN),
+  MAKE_COLORIMETRY (_0_255, BT601, UNKNOWN, UNKNOWN),
+  MAKE_COLORIMETRY (_UNKNOWN, UNKNOWN, UNKNOWN, UNKNOWN),
+};
+
+/**
+ * gst_video_info_set_format:
+ * @info: a #GstVideoInfo
+ * @format: the format
+ * @width: a width
+ * @height: a height
+ *
+ * Set the default info for a video frame of @format and @width and @height.
+ */
+void
+gst_video_info_set_format (GstVideoInfo * info, GstVideoFormat format,
+    guint width, guint height)
+{
+  const GstVideoFormatInfo *finfo;
+
+  g_return_if_fail (info != NULL);
+  g_return_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN);
+
+  finfo = gst_video_format_get_info (format);
+
+  info->flags = 0;
+  info->finfo = finfo;
+  info->width = width;
+  info->height = height;
+
+  if (GST_VIDEO_FORMAT_INFO_IS_YUV (finfo)) {
+    if (height > 576)
+      info->colorimetry = default_color[DEFAULT_YUV_HD];
+    else
+      info->colorimetry = default_color[DEFAULT_YUV_SD];
+  } else if (GST_VIDEO_FORMAT_INFO_IS_GRAY (finfo)) {
+    info->colorimetry = default_color[DEFAULT_GRAY];
+  } else if (GST_VIDEO_FORMAT_INFO_IS_RGB (finfo)) {
+    info->colorimetry = default_color[DEFAULT_RGB];
+  } else {
+    info->colorimetry = default_color[DEFAULT_UNKNOWN];
+  }
+
+  fill_planes (info);
+}
+
+static const gchar *interlace_mode[] = {
+  "progressive",
+  "interleaved",
+  "mixed",
+  "fields"
+};
+
+static const gchar *
+gst_interlace_mode_to_string (GstVideoInterlaceMode mode)
+{
+  if (((guint) mode) >= G_N_ELEMENTS (interlace_mode))
+    return NULL;
+
+  return interlace_mode[mode];
+}
+
+static GstVideoInterlaceMode
+gst_interlace_mode_from_string (const gchar * mode)
+{
+  gint i;
+  for (i = 0; i < G_N_ELEMENTS (interlace_mode); i++) {
+    if (g_str_equal (interlace_mode[i], mode))
+      return i;
+  }
+  return GST_VIDEO_INTERLACE_MODE_PROGRESSIVE;
+}
+
+/**
+ * gst_video_info_from_caps:
+ * @info: a #GstVideoInfo
+ * @caps: a #GstCaps
+ *
+ * Parse @caps and update @info.
+ *
+ * Returns: TRUE if @caps could be parsed
+ */
+gboolean
+gst_video_info_from_caps (GstVideoInfo * info, const GstCaps * caps)
+{
+  GstStructure *structure;
+  const gchar *s;
+  GstVideoFormat format = GST_VIDEO_FORMAT_UNKNOWN;
+  gint width = 0, height = 0, views;
+  gint fps_n, fps_d;
+  gint par_n, par_d;
+
+  g_return_val_if_fail (info != NULL, FALSE);
+  g_return_val_if_fail (caps != NULL, FALSE);
+  g_return_val_if_fail (gst_caps_is_fixed (caps), FALSE);
+
+  GST_DEBUG ("parsing caps %" GST_PTR_FORMAT, caps);
+
+  structure = gst_caps_get_structure (caps, 0);
+
+  if (gst_structure_has_name (structure, "video/x-raw")) {
+    if (!(s = gst_structure_get_string (structure, "format")))
+      goto no_format;
+
+    format = gst_video_format_from_string (s);
+    if (format == GST_VIDEO_FORMAT_UNKNOWN)
+      goto unknown_format;
+
+  } else if (g_str_has_prefix (gst_structure_get_name (structure), "video/") ||
+      g_str_has_prefix (gst_structure_get_name (structure), "image/")) {
+    format = GST_VIDEO_FORMAT_ENCODED;
+  } else {
+    goto wrong_name;
+  }
+
+  /* width and height are mandatory, except for non-raw-formats */
+  if (!gst_structure_get_int (structure, "width", &width) &&
+      format != GST_VIDEO_FORMAT_ENCODED)
+    goto no_width;
+  if (!gst_structure_get_int (structure, "height", &height) &&
+      format != GST_VIDEO_FORMAT_ENCODED)
+    goto no_height;
+
+  gst_video_info_set_format (info, format, width, height);
+
+  if (gst_structure_get_fraction (structure, "framerate", &fps_n, &fps_d)) {
+    if (fps_n == 0) {
+      /* variable framerate */
+      info->flags |= GST_VIDEO_FLAG_VARIABLE_FPS;
+      /* see if we have a max-framerate */
+      gst_structure_get_fraction (structure, "max-framerate", &fps_n, &fps_d);
+    }
+    info->fps_n = fps_n;
+    info->fps_d = fps_d;
+  } else {
+    /* unspecified is variable framerate */
+    info->fps_n = 0;
+    info->fps_d = 1;
+  }
+
+  if ((s = gst_structure_get_string (structure, "interlace-mode")))
+    info->interlace_mode = gst_interlace_mode_from_string (s);
+  else
+    info->interlace_mode = GST_VIDEO_INTERLACE_MODE_PROGRESSIVE;
+
+  if (gst_structure_get_int (structure, "views", &views))
+    info->views = views;
+  else
+    info->views = 1;
+
+  if ((s = gst_structure_get_string (structure, "chroma-site")))
+    info->chroma_site = gst_video_chroma_from_string (s);
+  else
+    info->chroma_site = GST_VIDEO_CHROMA_SITE_UNKNOWN;
+
+  if ((s = gst_structure_get_string (structure, "colorimetry")))
+    gst_video_colorimetry_from_string (&info->colorimetry, s);
+
+  if (gst_structure_get_fraction (structure, "pixel-aspect-ratio",
+          &par_n, &par_d)) {
+    info->par_n = par_n;
+    info->par_d = par_d;
+  } else {
+    info->par_n = 1;
+    info->par_d = 1;
+  }
+  return TRUE;
+
+  /* ERROR */
+wrong_name:
+  {
+    GST_ERROR ("wrong name '%s', expected video/ or image/",
+        gst_structure_get_name (structure));
+    return FALSE;
+  }
+no_format:
+  {
+    GST_ERROR ("no format given");
+    return FALSE;
+  }
+unknown_format:
+  {
+    GST_ERROR ("unknown format '%s' given", s);
+    return FALSE;
+  }
+no_width:
+  {
+    GST_ERROR ("no width property given");
+    return FALSE;
+  }
+no_height:
+  {
+    GST_ERROR ("no height property given");
+    return FALSE;
+  }
+}
+
+/**
+ * gst_video_info_is_equal:
+ * @info: a #GstVideoInfo
+ * @other: a #GstVideoInfo
+ *
+ * Compares two #GstVideoInfo and returns whether they are equal or not
+ *
+ * Returns: %TRUE if @info and @other are equal, else %FALSE.
+ */
+gboolean
+gst_video_info_is_equal (const GstVideoInfo * info, const GstVideoInfo * other)
+{
+  if (GST_VIDEO_INFO_FORMAT (info) != GST_VIDEO_INFO_FORMAT (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_INTERLACE_MODE (info) !=
+      GST_VIDEO_INFO_INTERLACE_MODE (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_FLAGS (info) != GST_VIDEO_INFO_FLAGS (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_WIDTH (info) != GST_VIDEO_INFO_WIDTH (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_HEIGHT (info) != GST_VIDEO_INFO_HEIGHT (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_SIZE (info) != GST_VIDEO_INFO_SIZE (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_PAR_N (info) != GST_VIDEO_INFO_PAR_N (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_PAR_D (info) != GST_VIDEO_INFO_PAR_D (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_FPS_N (info) != GST_VIDEO_INFO_FPS_N (other))
+    return FALSE;
+  if (GST_VIDEO_INFO_FPS_D (info) != GST_VIDEO_INFO_FPS_D (other))
+    return FALSE;
+  return TRUE;
+}
+
+/**
+ * gst_video_info_to_caps:
+ * @info: a #GstVideoInfo
+ *
+ * Convert the values of @info into a #GstCaps.
+ *
+ * Returns: a new #GstCaps containing the info of @info.
+ */
+GstCaps *
+gst_video_info_to_caps (GstVideoInfo * info)
+{
+  GstCaps *caps;
+  const gchar *format;
+  gchar *color;
+
+  g_return_val_if_fail (info != NULL, NULL);
+  g_return_val_if_fail (info->finfo != NULL, NULL);
+  g_return_val_if_fail (info->finfo->format != GST_VIDEO_FORMAT_UNKNOWN, NULL);
+
+  format = gst_video_format_to_string (info->finfo->format);
+  g_return_val_if_fail (format != NULL, NULL);
+
+  caps = gst_caps_new_simple ("video/x-raw",
+      "format", G_TYPE_STRING, format,
+      "width", G_TYPE_INT, info->width,
+      "height", G_TYPE_INT, info->height,
+      "pixel-aspect-ratio", GST_TYPE_FRACTION, info->par_n, info->par_d, NULL);
+
+  gst_caps_set_simple (caps, "interlace-mode", G_TYPE_STRING,
+      gst_interlace_mode_to_string (info->interlace_mode), NULL);
+
+  if (info->chroma_site != GST_VIDEO_CHROMA_SITE_UNKNOWN)
+    gst_caps_set_simple (caps, "chroma-site", G_TYPE_STRING,
+        gst_video_chroma_to_string (info->chroma_site), NULL);
+
+  if ((color = gst_video_colorimetry_to_string (&info->colorimetry))) {
+    gst_caps_set_simple (caps, "colorimetry", G_TYPE_STRING, color, NULL);
+    g_free (color);
+  }
+
+  if (info->views > 1)
+    gst_caps_set_simple (caps, "views", G_TYPE_INT, info->views, NULL);
+
+  if (info->flags & GST_VIDEO_FLAG_VARIABLE_FPS && info->fps_n != 0) {
+    /* variable fps with a max-framerate */
+    gst_caps_set_simple (caps, "framerate", GST_TYPE_FRACTION, 0, 1,
+        "max-framerate", GST_TYPE_FRACTION, info->fps_n, info->fps_d, NULL);
+  } else {
+    /* no variable fps or no max-framerate */
+    gst_caps_set_simple (caps, "framerate", GST_TYPE_FRACTION,
+        info->fps_n, info->fps_d, NULL);
+  }
+
+  return caps;
+}
+
+static int
+fill_planes (GstVideoInfo * info)
+{
+  gint width, height;
+
+  width = info->width;
+  height = info->height;
+
+  switch (info->finfo->format) {
+    case GST_VIDEO_FORMAT_YUY2:
+    case GST_VIDEO_FORMAT_YVYU:
+    case GST_VIDEO_FORMAT_UYVY:
+      info->stride[0] = GST_ROUND_UP_4 (width * 2);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_AYUV:
+    case GST_VIDEO_FORMAT_RGBx:
+    case GST_VIDEO_FORMAT_RGBA:
+    case GST_VIDEO_FORMAT_BGRx:
+    case GST_VIDEO_FORMAT_BGRA:
+    case GST_VIDEO_FORMAT_xRGB:
+    case GST_VIDEO_FORMAT_ARGB:
+    case GST_VIDEO_FORMAT_xBGR:
+    case GST_VIDEO_FORMAT_ABGR:
+    case GST_VIDEO_FORMAT_r210:
+      info->stride[0] = width * 4;
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_RGB16:
+    case GST_VIDEO_FORMAT_BGR16:
+    case GST_VIDEO_FORMAT_RGB15:
+    case GST_VIDEO_FORMAT_BGR15:
+      info->stride[0] = GST_ROUND_UP_4 (width * 2);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_RGB:
+    case GST_VIDEO_FORMAT_BGR:
+    case GST_VIDEO_FORMAT_v308:
+      info->stride[0] = GST_ROUND_UP_4 (width * 3);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_v210:
+      info->stride[0] = ((width + 47) / 48) * 128;
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_v216:
+      info->stride[0] = GST_ROUND_UP_8 (width * 4);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_GRAY8:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_GRAY16_BE:
+    case GST_VIDEO_FORMAT_GRAY16_LE:
+      info->stride[0] = GST_ROUND_UP_4 (width * 2);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_UYVP:
+      info->stride[0] = GST_ROUND_UP_4 ((width * 2 * 5 + 3) / 4);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_RGB8P:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = 4;
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * height;
+      info->size = info->offset[1] + (4 * 256);
+      break;
+    case GST_VIDEO_FORMAT_IYU1:
+      info->stride[0] = GST_ROUND_UP_4 (GST_ROUND_UP_4 (width) +
+          GST_ROUND_UP_4 (width) / 2);
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_ARGB64:
+    case GST_VIDEO_FORMAT_AYUV64:
+      info->stride[0] = width * 8;
+      info->offset[0] = 0;
+      info->size = info->stride[0] * height;
+      break;
+    case GST_VIDEO_FORMAT_I420:
+    case GST_VIDEO_FORMAT_YV12:        /* same as I420, but plane 1+2 swapped */
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = GST_ROUND_UP_4 (GST_ROUND_UP_2 (width) / 2);
+      info->stride[2] = info->stride[1];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
+      info->offset[2] = info->offset[1] +
+          info->stride[1] * (GST_ROUND_UP_2 (height) / 2);
+      info->size = info->offset[2] +
+          info->stride[2] * (GST_ROUND_UP_2 (height) / 2);
+      break;
+    case GST_VIDEO_FORMAT_Y41B:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = GST_ROUND_UP_16 (width) / 4;
+      info->stride[2] = info->stride[1];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * height;
+      info->offset[2] = info->offset[1] + info->stride[1] * height;
+      /* simplification of ROUNDUP4(w)*h + 2*((ROUNDUP16(w)/4)*h */
+      info->size = (info->stride[0] + (GST_ROUND_UP_16 (width) / 2)) * height;
+      break;
+    case GST_VIDEO_FORMAT_Y42B:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = GST_ROUND_UP_8 (width) / 2;
+      info->stride[2] = info->stride[1];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * height;
+      info->offset[2] = info->offset[1] + info->stride[1] * height;
+      /* simplification of ROUNDUP4(w)*h + 2*(ROUNDUP8(w)/2)*h */
+      info->size = (info->stride[0] + GST_ROUND_UP_8 (width)) * height;
+      break;
+    case GST_VIDEO_FORMAT_Y444:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = info->stride[0];
+      info->stride[2] = info->stride[0];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * height;
+      info->offset[2] = info->offset[1] * 2;
+      info->size = info->stride[0] * height * 3;
+      break;
+    case GST_VIDEO_FORMAT_NV12:
+    case GST_VIDEO_FORMAT_NV21:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = info->stride[0];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
+      info->size = info->stride[0] * GST_ROUND_UP_2 (height) * 3 / 2;
+      break;
+    case GST_VIDEO_FORMAT_A420:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = GST_ROUND_UP_4 (GST_ROUND_UP_2 (width) / 2);
+      info->stride[2] = info->stride[1];
+      info->stride[3] = info->stride[0];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
+      info->offset[2] = info->offset[1] +
+          info->stride[1] * (GST_ROUND_UP_2 (height) / 2);
+      info->offset[3] = info->offset[2] +
+          info->stride[2] * (GST_ROUND_UP_2 (height) / 2);
+      info->size = info->offset[3] + info->stride[0];
+      break;
+    case GST_VIDEO_FORMAT_YUV9:
+    case GST_VIDEO_FORMAT_YVU9:
+      info->stride[0] = GST_ROUND_UP_4 (width);
+      info->stride[1] = GST_ROUND_UP_4 (GST_ROUND_UP_4 (width) / 4);
+      info->stride[2] = info->stride[1];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * height;
+      info->offset[2] = info->offset[1] +
+          info->stride[1] * (GST_ROUND_UP_4 (height) / 4);
+      info->size = info->offset[2] +
+          info->stride[2] * (GST_ROUND_UP_4 (height) / 4);
+      break;
+    case GST_VIDEO_FORMAT_I420_10LE:
+    case GST_VIDEO_FORMAT_I420_10BE:
+      info->stride[0] = GST_ROUND_UP_4 (width * 2);
+      info->stride[1] = GST_ROUND_UP_4 (width);
+      info->stride[2] = info->stride[1];
+      info->offset[0] = 0;
+      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
+      info->offset[2] = info->offset[1] +
+          info->stride[1] * (GST_ROUND_UP_2 (height) / 2);
+      info->size = info->offset[2] +
+          info->stride[2] * (GST_ROUND_UP_2 (height) / 2);
+      break;
+    case GST_VIDEO_FORMAT_ENCODED:
+      break;
+    case GST_VIDEO_FORMAT_UNKNOWN:
+      GST_ERROR ("invalid format");
+      g_warning ("invalid format");
+      break;
+  }
+  return 0;
+}
+
+/**
+ * gst_video_info_convert:
+ * @info: a #GstVideoInfo
+ * @src_format: #GstFormat of the @src_value
+ * @src_value: value to convert
+ * @dest_format: #GstFormat of the @dest_value
+ * @dest_value: pointer to destination value
+ *
+ * Converts among various #GstFormat types.  This function handles
+ * GST_FORMAT_BYTES, GST_FORMAT_TIME, and GST_FORMAT_DEFAULT.  For
+ * raw video, GST_FORMAT_DEFAULT corresponds to video frames.  This
+ * function can be used to handle pad queries of the type GST_QUERY_CONVERT.
+ *
+ * Since: 0.10.16
+ *
+ * Returns: TRUE if the conversion was successful.
+ */
+gboolean
+gst_video_info_convert (GstVideoInfo * info,
+    GstFormat src_format, gint64 src_value,
+    GstFormat dest_format, gint64 * dest_value)
+{
+  gboolean ret = FALSE;
+  int size, fps_n, fps_d;
+
+  g_return_val_if_fail (info != NULL, 0);
+  g_return_val_if_fail (info->finfo != NULL, 0);
+  g_return_val_if_fail (info->finfo->format != GST_VIDEO_FORMAT_UNKNOWN, 0);
+  g_return_val_if_fail (info->size > 0, 0);
+
+  size = info->size;
+  fps_n = info->fps_n;
+  fps_d = info->fps_d;
+
+  GST_DEBUG ("converting value %" G_GINT64_FORMAT " from %s to %s",
+      src_value, gst_format_get_name (src_format),
+      gst_format_get_name (dest_format));
+
+  if (src_format == dest_format) {
+    *dest_value = src_value;
+    ret = TRUE;
+    goto done;
+  }
+
+  if (src_value == -1) {
+    *dest_value = -1;
+    ret = TRUE;
+    goto done;
+  }
+
+  /* bytes to frames */
+  if (src_format == GST_FORMAT_BYTES && dest_format == GST_FORMAT_DEFAULT) {
+    if (size != 0) {
+      *dest_value = gst_util_uint64_scale_int (src_value, 1, size);
+    } else {
+      GST_ERROR ("blocksize is 0");
+      *dest_value = 0;
+    }
+    ret = TRUE;
+    goto done;
+  }
+
+  /* frames to bytes */
+  if (src_format == GST_FORMAT_DEFAULT && dest_format == GST_FORMAT_BYTES) {
+    *dest_value = gst_util_uint64_scale_int (src_value, size, 1);
+    ret = TRUE;
+    goto done;
+  }
+
+  /* time to frames */
+  if (src_format == GST_FORMAT_TIME && dest_format == GST_FORMAT_DEFAULT) {
+    if (fps_d != 0) {
+      *dest_value = gst_util_uint64_scale (src_value,
+          fps_n, GST_SECOND * fps_d);
+    } else {
+      GST_ERROR ("framerate denominator is 0");
+      *dest_value = 0;
+    }
+    ret = TRUE;
+    goto done;
+  }
+
+  /* frames to time */
+  if (src_format == GST_FORMAT_DEFAULT && dest_format == GST_FORMAT_TIME) {
+    if (fps_n != 0) {
+      *dest_value = gst_util_uint64_scale (src_value,
+          GST_SECOND * fps_d, fps_n);
+    } else {
+      GST_ERROR ("framerate numerator is 0");
+      *dest_value = 0;
+    }
+    ret = TRUE;
+    goto done;
+  }
+
+  /* time to bytes */
+  if (src_format == GST_FORMAT_TIME && dest_format == GST_FORMAT_BYTES) {
+    if (fps_d != 0) {
+      *dest_value = gst_util_uint64_scale (src_value,
+          fps_n * size, GST_SECOND * fps_d);
+    } else {
+      GST_ERROR ("framerate denominator is 0");
+      *dest_value = 0;
+    }
+    ret = TRUE;
+    goto done;
+  }
+
+  /* bytes to time */
+  if (src_format == GST_FORMAT_BYTES && dest_format == GST_FORMAT_TIME) {
+    if (fps_n != 0 && size != 0) {
+      *dest_value = gst_util_uint64_scale (src_value,
+          GST_SECOND * fps_d, fps_n * size);
+    } else {
+      GST_ERROR ("framerate denominator and/or blocksize is 0");
+      *dest_value = 0;
+    }
+    ret = TRUE;
+  }
+
+done:
+
+  GST_DEBUG ("ret=%d result %" G_GINT64_FORMAT, ret, *dest_value);
+
+  return ret;
+}
diff --git a/gst-libs/gst/video/video-info.h b/gst-libs/gst/video/video-info.h
new file mode 100644
index 0000000..b4b3e42
--- /dev/null
+++ b/gst-libs/gst/video/video-info.h
@@ -0,0 +1,182 @@
+/* GStreamer
+ * Copyright (C) <2011> Wim Taymans <wim.taymans@gmail.com>
+ *
+ * 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_VIDEO_INFO_H__
+#define __GST_VIDEO_INFO_H__
+
+#include <gst/gst.h>
+#include <gst/video/video-format.h>
+#include <gst/video/video-color.h>
+
+G_BEGIN_DECLS
+
+#include <gst/video/video-enumtypes.h>
+
+typedef struct _GstVideoInfo GstVideoInfo;
+
+/**
+ * GstVideoInterlaceMode:
+ * @GST_VIDEO_INTERLACE_MODE_PROGRESSIVE: all frames are progressive
+ * @GST_VIDEO_INTERLACE_MODE_INTERLEAVED: 2 fields are interleaved in one video
+ *     frame. Extra buffer flags describe the field order.
+ * @GST_VIDEO_INTERLACE_MODE_MIXED: frames contains both interlaced and
+ *     progressive video, the buffer flags describe the frame and fields.
+ * @GST_VIDEO_INTERLACE_MODE_FIELDS: 2 fields are stored in one buffer, use the
+ *     frame ID to get access to the required field. For multiview (the
+ *     'views' property > 1) the fields of view N can be found at frame ID
+ *     (N * 2) and (N * 2) + 1.
+ *     Each field has only half the amount of lines as noted in the
+ *     height property. This mode requires multiple GstVideoMeta metadata
+ *     to describe the fields.
+ *
+ * The possible values of the #GstVideoInterlaceMode describing the interlace
+ * mode of the stream.
+ */
+typedef enum {
+  GST_VIDEO_INTERLACE_MODE_PROGRESSIVE = 0,
+  GST_VIDEO_INTERLACE_MODE_INTERLEAVED,
+  GST_VIDEO_INTERLACE_MODE_MIXED,
+  GST_VIDEO_INTERLACE_MODE_FIELDS
+} GstVideoInterlaceMode;
+
+/**
+ * GstVideoFlags:
+ * @GST_VIDEO_FLAG_NONE: no flags
+ * @GST_VIDEO_FLAG_VARIABLE_FPS: a variable fps is selected, fps_n and fps_d
+ *     denote the maximum fps of the video
+ * @GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA: Each color has been scaled by the alpha
+ *     value.
+ *
+ * Extra video flags
+ */
+typedef enum {
+  GST_VIDEO_FLAG_NONE                = 0,
+  GST_VIDEO_FLAG_VARIABLE_FPS        = (1 << 0),
+  GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA = (1 << 1)
+} GstVideoFlags;
+
+/**
+ * GstVideoInfo:
+ * @finfo: the format info of the video
+ * @interlace_mode: the interlace mode
+ * @flags: additional video flags
+ * @width: the width of the video
+ * @height: the height of the video
+ * @views: the number of views for multiview video
+ * @size: the default size of one frame
+ * @chroma_site: a #GstVideoChromaSite.
+ * @colorimetry: the colorimetry info
+ * @par_n: the pixel-aspect-ratio numerator
+ * @par_d: the pixel-aspect-ratio demnominator
+ * @fps_n: the framerate numerator
+ * @fps_d: the framerate demnominator
+ * @offset: offsets of the planes
+ * @stride: strides of the planes
+ *
+ * Information describing image properties. This information can be filled
+ * in from GstCaps with gst_video_info_from_caps(). The information is also used
+ * to store the specific video info when mapping a video frame with
+ * gst_video_frame_map().
+ *
+ * Use the provided macros to access the info in this structure.
+ */
+struct _GstVideoInfo {
+  const GstVideoFormatInfo *finfo;
+
+  GstVideoInterlaceMode     interlace_mode;
+  GstVideoFlags             flags;
+  gint                      width;
+  gint                      height;
+  gsize                     size;
+  gint                      views;
+
+  GstVideoChromaSite        chroma_site;
+  GstVideoColorimetry       colorimetry;
+
+  gint                      par_n;
+  gint                      par_d;
+  gint                      fps_n;
+  gint                      fps_d;
+
+  gsize                     offset[GST_VIDEO_MAX_PLANES];
+  gint                      stride[GST_VIDEO_MAX_PLANES];
+};
+
+/* general info */
+#define GST_VIDEO_INFO_FORMAT(i)         (GST_VIDEO_FORMAT_INFO_FORMAT((i)->finfo))
+#define GST_VIDEO_INFO_NAME(i)           (GST_VIDEO_FORMAT_INFO_NAME((i)->finfo))
+#define GST_VIDEO_INFO_IS_YUV(i)         (GST_VIDEO_FORMAT_INFO_IS_YUV((i)->finfo))
+#define GST_VIDEO_INFO_IS_RGB(i)         (GST_VIDEO_FORMAT_INFO_IS_RGB((i)->finfo))
+#define GST_VIDEO_INFO_IS_GRAY(i)        (GST_VIDEO_FORMAT_INFO_IS_GRAY((i)->finfo))
+#define GST_VIDEO_INFO_HAS_ALPHA(i)      (GST_VIDEO_FORMAT_INFO_HAS_ALPHA((i)->finfo))
+
+#define GST_VIDEO_INFO_INTERLACE_MODE(i) ((i)->interlace_mode)
+#define GST_VIDEO_INFO_IS_INTERLACED(i)  ((i)->interlace_mode != GST_VIDEO_INTERLACE_MODE_PROGRESSIVE)
+#define GST_VIDEO_INFO_FLAGS(i)          ((i)->flags)
+#define GST_VIDEO_INFO_WIDTH(i)          ((i)->width)
+#define GST_VIDEO_INFO_HEIGHT(i)         ((i)->height)
+#define GST_VIDEO_INFO_SIZE(i)           ((i)->size)
+#define GST_VIDEO_INFO_VIEWS(i)          ((i)->views)
+#define GST_VIDEO_INFO_PAR_N(i)          ((i)->par_n)
+#define GST_VIDEO_INFO_PAR_D(i)          ((i)->par_d)
+#define GST_VIDEO_INFO_FPS_N(i)          ((i)->fps_n)
+#define GST_VIDEO_INFO_FPS_D(i)          ((i)->fps_d)
+
+/* dealing with GstVideoInfo flags */
+#define GST_VIDEO_INFO_FLAG_IS_SET(i,flag) ((GST_VIDEO_INFO_FLAGS(i) & (flag)) == (flag))
+#define GST_VIDEO_INFO_FLAG_SET(i,flag)    (GST_VIDEO_INFO_FLAGS(i) |= (flag))
+#define GST_VIDEO_INFO_FLAG_UNSET(i,flag)  (GST_VIDEO_INFO_FLAGS(i) &= ~(flag))
+
+/* dealing with planes */
+#define GST_VIDEO_INFO_N_PLANES(i)       (GST_VIDEO_FORMAT_INFO_N_PLANES((i)->finfo))
+#define GST_VIDEO_INFO_PLANE_OFFSET(i,p) ((i)->offset[p])
+#define GST_VIDEO_INFO_PLANE_STRIDE(i,p) ((i)->stride[p])
+
+/* dealing with components */
+#define GST_VIDEO_INFO_N_COMPONENTS(i)   GST_VIDEO_FORMAT_INFO_N_COMPONENTS((i)->finfo)
+#define GST_VIDEO_INFO_COMP_DEPTH(i,c)   GST_VIDEO_FORMAT_INFO_DEPTH((i)->finfo,(c))
+#define GST_VIDEO_INFO_COMP_DATA(i,d,c)  GST_VIDEO_FORMAT_INFO_DATA((i)->finfo,d,(c))
+#define GST_VIDEO_INFO_COMP_OFFSET(i,c)  GST_VIDEO_FORMAT_INFO_OFFSET((i)->finfo,(i)->offset,(c))
+#define GST_VIDEO_INFO_COMP_STRIDE(i,c)  GST_VIDEO_FORMAT_INFO_STRIDE((i)->finfo,(i)->stride,(c))
+#define GST_VIDEO_INFO_COMP_WIDTH(i,c)   GST_VIDEO_FORMAT_INFO_SCALE_WIDTH((i)->finfo,(c),(i)->width)
+#define GST_VIDEO_INFO_COMP_HEIGHT(i,c)  GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT((i)->finfo,(c),(i)->height)
+#define GST_VIDEO_INFO_COMP_PLANE(i,c)   GST_VIDEO_FORMAT_INFO_PLANE((i)->finfo,(c))
+#define GST_VIDEO_INFO_COMP_PSTRIDE(i,c) GST_VIDEO_FORMAT_INFO_PSTRIDE((i)->finfo,(c))
+#define GST_VIDEO_INFO_COMP_POFFSET(i,c) GST_VIDEO_FORMAT_INFO_POFFSET((i)->finfo,(c))
+
+void         gst_video_info_init        (GstVideoInfo *info);
+
+void         gst_video_info_set_format  (GstVideoInfo *info, GstVideoFormat format,
+                                         guint width, guint height);
+
+gboolean     gst_video_info_from_caps   (GstVideoInfo *info, const GstCaps  * caps);
+
+GstCaps *    gst_video_info_to_caps     (GstVideoInfo *info);
+
+gboolean     gst_video_info_convert     (GstVideoInfo *info,
+                                         GstFormat     src_format,
+                                         gint64        src_value,
+                                         GstFormat     dest_format,
+                                         gint64       *dest_value);
+gboolean     gst_video_info_is_equal    (const GstVideoInfo *info,
+					 const GstVideoInfo *other);
+
+G_END_DECLS
+
+#endif /* __GST_VIDEO_INFO_H__ */
diff --git a/gst-libs/gst/video/video.c b/gst-libs/gst/video/video.c
index 9227c52..e2d40e2 100644
--- a/gst-libs/gst/video/video.c
+++ b/gst-libs/gst/video/video.c
@@ -24,225 +24,11 @@
 #endif
 
 #include <string.h>
+#include <stdio.h>
 
 #include "video.h"
 #include "gstvideometa.h"
 
-GST_DEBUG_CATEGORY_EXTERN (GST_CAT_PERFORMANCE);
-
-static int fill_planes (GstVideoInfo * info);
-
-typedef struct
-{
-  guint32 fourcc;
-  GstVideoFormatInfo info;
-} VideoFormat;
-
-/* depths: bits, n_components, shift, depth */
-#define DPTH0            0, 0, { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
-#define DPTH8            8, 1, { 0, 0, 0, 0 }, { 8, 0, 0, 0 }
-#define DPTH888          8, 3, { 0, 0, 0, 0 }, { 8, 8, 8, 0 }
-#define DPTH8888         8, 4, { 0, 0, 0, 0 }, { 8, 8, 8, 8 }
-#define DPTH10_10_10     10, 3, { 0, 0, 0, 0 }, { 10, 10, 10, 0 }
-#define DPTH16           16, 1, { 0, 0, 0, 0 }, { 16, 0, 0, 0 }
-#define DPTH16_16_16     16, 3, { 0, 0, 0, 0 }, { 16, 16, 16, 0 }
-#define DPTH16_16_16_16  16, 4, { 0, 0, 0, 0 }, { 16, 16, 16, 16 }
-#define DPTH555          16, 3, { 10, 5, 0, 0 }, { 5, 5, 5, 0 }
-#define DPTH565          16, 3, { 11, 5, 0, 0 }, { 5, 6, 5, 0 }
-
-/* pixel strides */
-#define PSTR0             { 0, 0, 0, 0 }
-#define PSTR1             { 1, 0, 0, 0 }
-#define PSTR111           { 1, 1, 1, 0 }
-#define PSTR1111          { 1, 1, 1, 1 }
-#define PSTR122           { 1, 2, 2, 0 }
-#define PSTR2             { 2, 0, 0, 0 }
-#define PSTR222           { 2, 2, 2, 0 }
-#define PSTR244           { 2, 4, 4, 0 }
-#define PSTR444           { 4, 4, 4, 0 }
-#define PSTR4444          { 4, 4, 4, 4 }
-#define PSTR333           { 3, 3, 3, 0 }
-#define PSTR488           { 4, 8, 8, 0 }
-#define PSTR8888          { 8, 8, 8, 8 }
-
-/* planes */
-#define PLANE_NA          0, { 0, 0, 0, 0 }
-#define PLANE0            1, { 0, 0, 0, 0 }
-#define PLANE011          2, { 0, 1, 1, 0 }
-#define PLANE012          3, { 0, 1, 2, 0 }
-#define PLANE0123         4, { 0, 1, 2, 3 }
-#define PLANE021          3, { 0, 2, 1, 0 }
-
-/* offsets */
-#define OFFS0             { 0, 0, 0, 0 }
-#define OFFS013           { 0, 1, 3, 0 }
-#define OFFS102           { 1, 0, 2, 0 }
-#define OFFS1230          { 1, 2, 3, 0 }
-#define OFFS012           { 0, 1, 2, 0 }
-#define OFFS210           { 2, 1, 0, 0 }
-#define OFFS123           { 1, 2, 3, 0 }
-#define OFFS321           { 3, 2, 1, 0 }
-#define OFFS0123          { 0, 1, 2, 3 }
-#define OFFS2103          { 2, 1, 0, 3 }
-#define OFFS3210          { 3, 2, 1, 0 }
-#define OFFS031           { 0, 3, 1, 0 }
-#define OFFS026           { 0, 2, 6, 0 }
-#define OFFS001           { 0, 0, 1, 0 }
-#define OFFS010           { 0, 1, 0, 0 }
-#define OFFS104           { 1, 0, 4, 0 }
-#define OFFS2460          { 2, 4, 6, 0 }
-
-/* subsampling */
-#define SUB410            { 0, 2, 2, 0 }, { 0, 2, 2, 0 }
-#define SUB411            { 0, 2, 2, 0 }, { 0, 0, 0, 0 }
-#define SUB420            { 0, 1, 1, 0 }, { 0, 1, 1, 0 }
-#define SUB422            { 0, 1, 1, 0 }, { 0, 0, 0, 0 }
-#define SUB4              { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
-#define SUB444            { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
-#define SUB4444           { 0, 0, 0, 0 }, { 0, 0, 0, 0 }
-#define SUB4204           { 0, 1, 1, 0 }, { 0, 1, 1, 0 }
-
-#define MAKE_YUV_FORMAT(name, desc, fourcc, depth, pstride, plane, offs, sub ) \
- { fourcc, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_YUV, depth, pstride, plane, offs, sub } }
-#define MAKE_YUVA_FORMAT(name, desc, fourcc, depth, pstride, plane, offs, sub) \
- { fourcc, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_YUV | GST_VIDEO_FORMAT_FLAG_ALPHA, depth, pstride, plane, offs, sub } }
-
-#define MAKE_RGB_FORMAT(name, desc, depth, pstride, plane, offs, sub) \
- { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB, depth, pstride, plane, offs, sub } }
-#define MAKE_RGB_LE_FORMAT(name, desc, depth, pstride, plane, offs, sub) \
- { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB | GST_VIDEO_FORMAT_FLAG_LE, depth, pstride, plane, offs, sub } }
-#define MAKE_RGBA_FORMAT(name, desc, depth, pstride, plane, offs, sub) \
- { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_RGB | GST_VIDEO_FORMAT_FLAG_ALPHA, depth, pstride, plane, offs, sub } }
-
-#define MAKE_GRAY_FORMAT(name, desc, depth, pstride, plane, offs, sub) \
- { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_GRAY, depth, pstride, plane, offs, sub } }
-#define MAKE_GRAY_LE_FORMAT(name, desc, depth, pstride, plane, offs, sub) \
- { 0x00000000, {GST_VIDEO_FORMAT_ ##name, G_STRINGIFY(name), desc, GST_VIDEO_FORMAT_FLAG_GRAY | GST_VIDEO_FORMAT_FLAG_LE, depth, pstride, plane, offs, sub } }
-
-static VideoFormat formats[] = {
-  {0x00000000, {GST_VIDEO_FORMAT_UNKNOWN, "UNKNOWN", "unknown video", 0, DPTH0,
-              PSTR0, PLANE_NA,
-          OFFS0}},
-  MAKE_YUV_FORMAT (I420, "raw video", GST_MAKE_FOURCC ('I', '4', '2', '0'),
-      DPTH888, PSTR111,
-      PLANE012, OFFS0, SUB420),
-  MAKE_YUV_FORMAT (YV12, "raw video", GST_MAKE_FOURCC ('Y', 'V', '1', '2'),
-      DPTH888, PSTR111,
-      PLANE021, OFFS0, SUB420),
-  MAKE_YUV_FORMAT (YUY2, "raw video", GST_MAKE_FOURCC ('Y', 'U', 'Y', '2'),
-      DPTH888, PSTR244,
-      PLANE0, OFFS013, SUB422),
-  MAKE_YUV_FORMAT (UYVY, "raw video", GST_MAKE_FOURCC ('U', 'Y', 'V', 'Y'),
-      DPTH888, PSTR244,
-      PLANE0, OFFS102, SUB422),
-  MAKE_YUVA_FORMAT (AYUV, "raw video", GST_MAKE_FOURCC ('A', 'Y', 'U', 'V'),
-      DPTH8888,
-      PSTR4444, PLANE0, OFFS1230, SUB4444),
-  MAKE_RGB_FORMAT (RGBx, "raw video", DPTH888, PSTR444, PLANE0, OFFS012,
-      SUB444),
-  MAKE_RGB_FORMAT (BGRx, "raw video", DPTH888, PSTR444, PLANE0, OFFS210,
-      SUB444),
-  MAKE_RGB_FORMAT (xRGB, "raw video", DPTH888, PSTR444, PLANE0, OFFS123,
-      SUB444),
-  MAKE_RGB_FORMAT (xBGR, "raw video", DPTH888, PSTR444, PLANE0, OFFS321,
-      SUB444),
-  MAKE_RGBA_FORMAT (RGBA, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS0123,
-      SUB4444),
-  MAKE_RGBA_FORMAT (BGRA, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS2103,
-      SUB4444),
-  MAKE_RGBA_FORMAT (ARGB, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS1230,
-      SUB4444),
-  MAKE_RGBA_FORMAT (ABGR, "raw video", DPTH8888, PSTR4444, PLANE0, OFFS3210,
-      SUB4444),
-  MAKE_RGB_FORMAT (RGB, "raw video", DPTH888, PSTR333, PLANE0, OFFS012, SUB444),
-  MAKE_RGB_FORMAT (BGR, "raw video", DPTH888, PSTR333, PLANE0, OFFS210, SUB444),
-
-  MAKE_YUV_FORMAT (Y41B, "raw video", GST_MAKE_FOURCC ('Y', '4', '1', 'B'),
-      DPTH888, PSTR111,
-      PLANE012, OFFS0, SUB411),
-  MAKE_YUV_FORMAT (Y42B, "raw video", GST_MAKE_FOURCC ('Y', '4', '2', 'B'),
-      DPTH888, PSTR111,
-      PLANE012, OFFS0, SUB422),
-  MAKE_YUV_FORMAT (YVYU, "raw video", GST_MAKE_FOURCC ('Y', 'V', 'Y', 'U'),
-      DPTH888, PSTR244,
-      PLANE0, OFFS031, SUB422),
-  MAKE_YUV_FORMAT (Y444, "raw video", GST_MAKE_FOURCC ('Y', '4', '4', '4'),
-      DPTH888, PSTR111,
-      PLANE012, OFFS0, SUB444),
-  MAKE_YUV_FORMAT (v210, "raw video", GST_MAKE_FOURCC ('v', '2', '1', '0'),
-      DPTH10_10_10,
-      PSTR0, PLANE0, OFFS0, SUB422),
-  MAKE_YUV_FORMAT (v216, "raw video", GST_MAKE_FOURCC ('v', '2', '1', '6'),
-      DPTH16_16_16,
-      PSTR488, PLANE0, OFFS026, SUB422),
-  MAKE_YUV_FORMAT (NV12, "raw video", GST_MAKE_FOURCC ('N', 'V', '1', '2'),
-      DPTH888, PSTR122,
-      PLANE011, OFFS001, SUB420),
-  MAKE_YUV_FORMAT (NV21, "raw video", GST_MAKE_FOURCC ('N', 'V', '2', '1'),
-      DPTH888, PSTR122,
-      PLANE011, OFFS010, SUB420),
-
-  MAKE_GRAY_FORMAT (GRAY8, "raw video", DPTH8, PSTR1, PLANE0, OFFS0, SUB4),
-  MAKE_GRAY_FORMAT (GRAY16_BE, "raw video", DPTH16, PSTR2, PLANE0, OFFS0, SUB4),
-  MAKE_GRAY_LE_FORMAT (GRAY16_LE, "raw video", DPTH16, PSTR2, PLANE0, OFFS0,
-      SUB4),
-
-  MAKE_YUV_FORMAT (v308, "raw video", GST_MAKE_FOURCC ('v', '3', '0', '8'),
-      DPTH888, PSTR333,
-      PLANE0, OFFS012, SUB444),
-  MAKE_YUV_FORMAT (Y800, "raw video", GST_MAKE_FOURCC ('Y', '8', '0', '0'),
-      DPTH8, PSTR1,
-      PLANE0, OFFS0, SUB4),
-  MAKE_YUV_FORMAT (Y16, "raw video", GST_MAKE_FOURCC ('Y', '1', '6', ' '),
-      DPTH16, PSTR2,
-      PLANE0, OFFS0, SUB4),
-
-#if G_BYTE_ORDER == G_LITTLE_ENDIAN
-  MAKE_RGB_LE_FORMAT (RGB16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0,
-      SUB444),
-  MAKE_RGB_LE_FORMAT (BGR16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0,
-      SUB444),
-  MAKE_RGB_LE_FORMAT (RGB15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0,
-      SUB444),
-  MAKE_RGB_LE_FORMAT (BGR15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0,
-      SUB444),
-#else
-  MAKE_RGB_FORMAT (RGB16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0, SUB444),
-  MAKE_RGB_FORMAT (BGR16, "raw video", DPTH565, PSTR222, PLANE0, OFFS0, SUB444),
-  MAKE_RGB_FORMAT (RGB15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0, SUB444),
-  MAKE_RGB_FORMAT (BGR15, "raw video", DPTH555, PSTR222, PLANE0, OFFS0, SUB444),
-#endif
-
-  MAKE_YUV_FORMAT (UYVP, "raw video", GST_MAKE_FOURCC ('U', 'Y', 'V', 'P'),
-      DPTH10_10_10,
-      PSTR0, PLANE0, OFFS0, SUB422),
-  MAKE_YUVA_FORMAT (A420, "raw video", GST_MAKE_FOURCC ('A', '4', '2', '0'),
-      DPTH8888,
-      PSTR1111, PLANE0123, OFFS0, SUB4204),
-  MAKE_RGBA_FORMAT (RGB8_PALETTED, "raw video", DPTH8888, PSTR1111, PLANE0,
-      OFFS0, SUB4444),
-  MAKE_YUV_FORMAT (YUV9, "raw video", GST_MAKE_FOURCC ('Y', 'U', 'V', '9'),
-      DPTH888, PSTR111,
-      PLANE012, OFFS0, SUB410),
-  MAKE_YUV_FORMAT (YVU9, "raw video", GST_MAKE_FOURCC ('Y', 'V', 'U', '9'),
-      DPTH888, PSTR111,
-      PLANE021, OFFS0, SUB410),
-  MAKE_YUV_FORMAT (IYU1, "raw video", GST_MAKE_FOURCC ('I', 'Y', 'U', '1'),
-      DPTH888, PSTR0,
-      PLANE0, OFFS104, SUB411),
-  MAKE_RGBA_FORMAT (ARGB64, "raw video", DPTH16_16_16_16, PSTR8888, PLANE0,
-      OFFS2460,
-      SUB444),
-  MAKE_YUVA_FORMAT (AYUV64, "raw video", 0x00000000, DPTH16_16_16_16, PSTR8888,
-      PLANE0,
-      OFFS2460, SUB444),
-  MAKE_YUV_FORMAT (r210, "raw video", GST_MAKE_FOURCC ('r', '2', '1', '0'),
-      DPTH10_10_10,
-      PSTR444, PLANE0, OFFS0, SUB444),
-  {0x00000000, {GST_VIDEO_FORMAT_ENCODED, "ENCODED", "encoded video",
-          GST_VIDEO_FORMAT_FLAG_COMPLEX, DPTH0, PSTR0, PLANE_NA, OFFS0}},
-};
-
 /**
  * SECTION:gstvideo
  * @short_description: Support library for video operations
@@ -313,1584 +99,3 @@
     return FALSE;
   }
 }
-
-static GstVideoFormat
-gst_video_format_from_rgb32_masks (int red_mask, int green_mask, int blue_mask)
-{
-  if (red_mask == 0xff000000 && green_mask == 0x00ff0000 &&
-      blue_mask == 0x0000ff00) {
-    return GST_VIDEO_FORMAT_RGBx;
-  }
-  if (red_mask == 0x0000ff00 && green_mask == 0x00ff0000 &&
-      blue_mask == 0xff000000) {
-    return GST_VIDEO_FORMAT_BGRx;
-  }
-  if (red_mask == 0x00ff0000 && green_mask == 0x0000ff00 &&
-      blue_mask == 0x000000ff) {
-    return GST_VIDEO_FORMAT_xRGB;
-  }
-  if (red_mask == 0x000000ff && green_mask == 0x0000ff00 &&
-      blue_mask == 0x00ff0000) {
-    return GST_VIDEO_FORMAT_xBGR;
-  }
-
-  return GST_VIDEO_FORMAT_UNKNOWN;
-}
-
-static GstVideoFormat
-gst_video_format_from_rgba32_masks (int red_mask, int green_mask,
-    int blue_mask, int alpha_mask)
-{
-  if (red_mask == 0xff000000 && green_mask == 0x00ff0000 &&
-      blue_mask == 0x0000ff00 && alpha_mask == 0x000000ff) {
-    return GST_VIDEO_FORMAT_RGBA;
-  }
-  if (red_mask == 0x0000ff00 && green_mask == 0x00ff0000 &&
-      blue_mask == 0xff000000 && alpha_mask == 0x000000ff) {
-    return GST_VIDEO_FORMAT_BGRA;
-  }
-  if (red_mask == 0x00ff0000 && green_mask == 0x0000ff00 &&
-      blue_mask == 0x000000ff && alpha_mask == 0xff000000) {
-    return GST_VIDEO_FORMAT_ARGB;
-  }
-  if (red_mask == 0x000000ff && green_mask == 0x0000ff00 &&
-      blue_mask == 0x00ff0000 && alpha_mask == 0xff000000) {
-    return GST_VIDEO_FORMAT_ABGR;
-  }
-  return GST_VIDEO_FORMAT_UNKNOWN;
-}
-
-static GstVideoFormat
-gst_video_format_from_rgb24_masks (int red_mask, int green_mask, int blue_mask)
-{
-  if (red_mask == 0xff0000 && green_mask == 0x00ff00 && blue_mask == 0x0000ff) {
-    return GST_VIDEO_FORMAT_RGB;
-  }
-  if (red_mask == 0x0000ff && green_mask == 0x00ff00 && blue_mask == 0xff0000) {
-    return GST_VIDEO_FORMAT_BGR;
-  }
-
-  return GST_VIDEO_FORMAT_UNKNOWN;
-}
-
-#define GST_VIDEO_COMP1_MASK_16_INT 0xf800
-#define GST_VIDEO_COMP2_MASK_16_INT 0x07e0
-#define GST_VIDEO_COMP3_MASK_16_INT 0x001f
-
-#define GST_VIDEO_COMP1_MASK_15_INT 0x7c00
-#define GST_VIDEO_COMP2_MASK_15_INT 0x03e0
-#define GST_VIDEO_COMP3_MASK_15_INT 0x001f
-
-static GstVideoFormat
-gst_video_format_from_rgb16_masks (int red_mask, int green_mask, int blue_mask)
-{
-  if (red_mask == GST_VIDEO_COMP1_MASK_16_INT
-      && green_mask == GST_VIDEO_COMP2_MASK_16_INT
-      && blue_mask == GST_VIDEO_COMP3_MASK_16_INT) {
-    return GST_VIDEO_FORMAT_RGB16;
-  }
-  if (red_mask == GST_VIDEO_COMP3_MASK_16_INT
-      && green_mask == GST_VIDEO_COMP2_MASK_16_INT
-      && blue_mask == GST_VIDEO_COMP1_MASK_16_INT) {
-    return GST_VIDEO_FORMAT_BGR16;
-  }
-  if (red_mask == GST_VIDEO_COMP1_MASK_15_INT
-      && green_mask == GST_VIDEO_COMP2_MASK_15_INT
-      && blue_mask == GST_VIDEO_COMP3_MASK_15_INT) {
-    return GST_VIDEO_FORMAT_RGB15;
-  }
-  if (red_mask == GST_VIDEO_COMP3_MASK_15_INT
-      && green_mask == GST_VIDEO_COMP2_MASK_15_INT
-      && blue_mask == GST_VIDEO_COMP1_MASK_15_INT) {
-    return GST_VIDEO_FORMAT_BGR15;
-  }
-  return GST_VIDEO_FORMAT_UNKNOWN;
-}
-
-/**
- * gst_video_format_from_masks:
- * @depth: the amount of bits used for a pixel
- * @bpp: the amount of bits used to store a pixel. This value is bigger than
- *   @depth
- * @endianness: the endianness of the masks
- * @red_mask: the red mask
- * @green_mask: the green mask
- * @blue_mask: the blue mask
- * @alpha_mask: the optional alpha mask
- *
- * Find the #GstVideoFormat for the given parameters.
- *
- * Returns: a #GstVideoFormat or GST_VIDEO_FORMAT_UNKNOWN when the parameters to
- * not specify a known format.
- */
-GstVideoFormat
-gst_video_format_from_masks (gint depth, gint bpp, gint endianness,
-    gint red_mask, gint green_mask, gint blue_mask, gint alpha_mask)
-{
-  GstVideoFormat format;
-
-  /* our caps system handles 24/32bpp RGB as big-endian. */
-  if ((bpp == 24 || bpp == 32) && endianness == G_LITTLE_ENDIAN) {
-    red_mask = GUINT32_TO_BE (red_mask);
-    green_mask = GUINT32_TO_BE (green_mask);
-    blue_mask = GUINT32_TO_BE (blue_mask);
-    endianness = G_BIG_ENDIAN;
-    if (bpp == 24) {
-      red_mask >>= 8;
-      green_mask >>= 8;
-      blue_mask >>= 8;
-    }
-  }
-
-  if (depth == 30 && bpp == 32) {
-    format = GST_VIDEO_FORMAT_r210;
-  } else if (depth == 24 && bpp == 32) {
-    format = gst_video_format_from_rgb32_masks (red_mask, green_mask,
-        blue_mask);
-  } else if (depth == 32 && bpp == 32 && alpha_mask) {
-    format = gst_video_format_from_rgba32_masks (red_mask, green_mask,
-        blue_mask, alpha_mask);
-  } else if (depth == 24 && bpp == 24) {
-    format = gst_video_format_from_rgb24_masks (red_mask, green_mask,
-        blue_mask);
-  } else if ((depth == 15 || depth == 16) && bpp == 16 &&
-      endianness == G_BYTE_ORDER) {
-    format = gst_video_format_from_rgb16_masks (red_mask, green_mask,
-        blue_mask);
-  } else if (depth == 8 && bpp == 8) {
-    format = GST_VIDEO_FORMAT_RGB8_PALETTED;
-  } else if (depth == 64 && bpp == 64) {
-    format = gst_video_format_from_rgba32_masks (red_mask, green_mask,
-        blue_mask, alpha_mask);
-    if (format == GST_VIDEO_FORMAT_ARGB) {
-      format = GST_VIDEO_FORMAT_ARGB64;
-    } else {
-      format = GST_VIDEO_FORMAT_UNKNOWN;
-    }
-  } else {
-    format = GST_VIDEO_FORMAT_UNKNOWN;
-  }
-  return format;
-}
-
-/**
- * gst_video_format_from_fourcc:
- * @fourcc: a FOURCC value representing raw YUV video
- *
- * Converts a FOURCC value into the corresponding #GstVideoFormat.
- * If the FOURCC cannot be represented by #GstVideoFormat,
- * #GST_VIDEO_FORMAT_UNKNOWN is returned.
- *
- * Since: 0.10.16
- *
- * Returns: the #GstVideoFormat describing the FOURCC value
- */
-GstVideoFormat
-gst_video_format_from_fourcc (guint32 fourcc)
-{
-  switch (fourcc) {
-    case GST_MAKE_FOURCC ('I', '4', '2', '0'):
-      return GST_VIDEO_FORMAT_I420;
-    case GST_MAKE_FOURCC ('Y', 'V', '1', '2'):
-      return GST_VIDEO_FORMAT_YV12;
-    case GST_MAKE_FOURCC ('Y', 'U', 'Y', '2'):
-      return GST_VIDEO_FORMAT_YUY2;
-    case GST_MAKE_FOURCC ('Y', 'V', 'Y', 'U'):
-      return GST_VIDEO_FORMAT_YVYU;
-    case GST_MAKE_FOURCC ('U', 'Y', 'V', 'Y'):
-      return GST_VIDEO_FORMAT_UYVY;
-    case GST_MAKE_FOURCC ('A', 'Y', 'U', 'V'):
-      return GST_VIDEO_FORMAT_AYUV;
-    case GST_MAKE_FOURCC ('Y', '4', '1', 'B'):
-      return GST_VIDEO_FORMAT_Y41B;
-    case GST_MAKE_FOURCC ('Y', '4', '2', 'B'):
-      return GST_VIDEO_FORMAT_Y42B;
-    case GST_MAKE_FOURCC ('Y', '4', '4', '4'):
-      return GST_VIDEO_FORMAT_Y444;
-    case GST_MAKE_FOURCC ('v', '2', '1', '0'):
-      return GST_VIDEO_FORMAT_v210;
-    case GST_MAKE_FOURCC ('v', '2', '1', '6'):
-      return GST_VIDEO_FORMAT_v216;
-    case GST_MAKE_FOURCC ('N', 'V', '1', '2'):
-      return GST_VIDEO_FORMAT_NV12;
-    case GST_MAKE_FOURCC ('N', 'V', '2', '1'):
-      return GST_VIDEO_FORMAT_NV21;
-    case GST_MAKE_FOURCC ('v', '3', '0', '8'):
-      return GST_VIDEO_FORMAT_v308;
-    case GST_MAKE_FOURCC ('Y', '8', '0', '0'):
-    case GST_MAKE_FOURCC ('Y', '8', ' ', ' '):
-    case GST_MAKE_FOURCC ('G', 'R', 'E', 'Y'):
-      return GST_VIDEO_FORMAT_Y800;
-    case GST_MAKE_FOURCC ('Y', '1', '6', ' '):
-      return GST_VIDEO_FORMAT_Y16;
-    case GST_MAKE_FOURCC ('U', 'Y', 'V', 'P'):
-      return GST_VIDEO_FORMAT_UYVP;
-    case GST_MAKE_FOURCC ('A', '4', '2', '0'):
-      return GST_VIDEO_FORMAT_A420;
-    case GST_MAKE_FOURCC ('Y', 'U', 'V', '9'):
-      return GST_VIDEO_FORMAT_YUV9;
-    case GST_MAKE_FOURCC ('Y', 'V', 'U', '9'):
-      return GST_VIDEO_FORMAT_YVU9;
-    case GST_MAKE_FOURCC ('I', 'Y', 'U', '1'):
-      return GST_VIDEO_FORMAT_IYU1;
-    case GST_MAKE_FOURCC ('A', 'Y', '6', '4'):
-      return GST_VIDEO_FORMAT_AYUV64;
-    default:
-      return GST_VIDEO_FORMAT_UNKNOWN;
-  }
-}
-
-/**
- * gst_video_format_from_string:
- * @format: a format string
- *
- * Convert the @format string to its #GstVideoFormat.
- *
- * Returns: the #GstVideoFormat for @format or GST_VIDEO_FORMAT_UNKNOWN when the
- * string is not a known format.
- */
-GstVideoFormat
-gst_video_format_from_string (const gchar * format)
-{
-  guint i;
-
-  g_return_val_if_fail (format != NULL, GST_VIDEO_FORMAT_UNKNOWN);
-
-  for (i = 0; i < G_N_ELEMENTS (formats); i++) {
-    if (strcmp (GST_VIDEO_FORMAT_INFO_NAME (&formats[i].info), format) == 0)
-      return GST_VIDEO_FORMAT_INFO_FORMAT (&formats[i].info);
-  }
-  return GST_VIDEO_FORMAT_UNKNOWN;
-}
-
-
-/**
- * gst_video_format_to_fourcc:
- * @format: a #GstVideoFormat video format
- *
- * Converts a #GstVideoFormat value into the corresponding FOURCC.  Only
- * a few YUV formats have corresponding FOURCC values.  If @format has
- * no corresponding FOURCC value, 0 is returned.
- *
- * Since: 0.10.16
- *
- * Returns: the FOURCC corresponding to @format
- */
-guint32
-gst_video_format_to_fourcc (GstVideoFormat format)
-{
-  g_return_val_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN, 0);
-
-  if (format >= G_N_ELEMENTS (formats))
-    return 0;
-
-  return formats[format].fourcc;
-}
-
-const gchar *
-gst_video_format_to_string (GstVideoFormat format)
-{
-  g_return_val_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN, NULL);
-
-  if (format >= G_N_ELEMENTS (formats))
-    return NULL;
-
-  return GST_VIDEO_FORMAT_INFO_NAME (&formats[format].info);
-}
-
-/**
- * gst_video_format_get_info:
- * @format: a #GstVideoFormat
- *
- * Get the #GstVideoFormatInfo for @format
- *
- * Returns: The #GstVideoFormatInfo for @format.
- */
-const GstVideoFormatInfo *
-gst_video_format_get_info (GstVideoFormat format)
-{
-  g_return_val_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN, NULL);
-  g_return_val_if_fail (format < G_N_ELEMENTS (formats), NULL);
-
-  return &formats[format].info;
-}
-
-/**
- * gst_video_info_init:
- * @info: a #GstVideoInfo
- *
- * Initialize @info with default values.
- */
-void
-gst_video_info_init (GstVideoInfo * info)
-{
-  g_return_if_fail (info != NULL);
-
-  memset (info, 0, sizeof (GstVideoInfo));
-
-  info->finfo = &formats[GST_VIDEO_FORMAT_UNKNOWN].info;
-
-  info->views = 1;
-  /* arrange for sensible defaults, e.g. if turned into caps */
-  info->fps_n = 0;
-  info->fps_d = 1;
-  info->par_n = 1;
-  info->par_d = 1;
-}
-
-/**
- * gst_video_info_set_format:
- * @info: a #GstVideoInfo
- * @format: the format
- * @width: a width
- * @height: a height
- *
- * Set the default info for a video frame of @format and @width and @height.
- */
-void
-gst_video_info_set_format (GstVideoInfo * info, GstVideoFormat format,
-    guint width, guint height)
-{
-  const GstVideoFormatInfo *finfo;
-
-  g_return_if_fail (info != NULL);
-  g_return_if_fail (format != GST_VIDEO_FORMAT_UNKNOWN);
-
-  finfo = &formats[format].info;
-
-  info->flags = 0;
-  info->finfo = finfo;
-  info->width = width;
-  info->height = height;
-
-  fill_planes (info);
-}
-
-static const gchar *interlace_mode[] = {
-  "progressive",
-  "interleaved",
-  "mixed",
-  "fields"
-};
-
-static const gchar *
-gst_interlace_mode_to_string (GstVideoInterlaceMode mode)
-{
-  if (((guint) mode) >= G_N_ELEMENTS (interlace_mode))
-    return NULL;
-
-  return interlace_mode[mode];
-}
-
-static GstVideoInterlaceMode
-gst_interlace_mode_from_string (const gchar * mode)
-{
-  gint i;
-  for (i = 0; i < G_N_ELEMENTS (interlace_mode); i++) {
-    if (g_str_equal (interlace_mode[i], mode))
-      return i;
-  }
-  return GST_VIDEO_INTERLACE_MODE_PROGRESSIVE;
-}
-
-typedef struct
-{
-  const gchar *name;
-  GstVideoChromaSite site;
-} ChromaSiteInfo;
-
-static const ChromaSiteInfo chromasite[] = {
-  {"jpeg", GST_VIDEO_CHROMA_SITE_JPEG},
-  {"mpeg2", GST_VIDEO_CHROMA_SITE_MPEG2},
-  {"dv", GST_VIDEO_CHROMA_SITE_DV}
-};
-
-static GstVideoChromaSite
-gst_video_chroma_from_string (const gchar * s)
-{
-  gint i;
-  for (i = 0; i < G_N_ELEMENTS (chromasite); i++) {
-    if (g_str_equal (chromasite[i].name, s))
-      return chromasite[i].site;
-  }
-  return GST_VIDEO_CHROMA_SITE_UNKNOWN;
-}
-
-static const gchar *
-gst_video_chroma_to_string (GstVideoChromaSite site)
-{
-  gint i;
-  for (i = 0; i < G_N_ELEMENTS (chromasite); i++) {
-    if (chromasite[i].site == site)
-      return chromasite[i].name;
-  }
-  return NULL;
-}
-
-typedef struct
-{
-  const gchar *name;
-  GstVideoColorimetry color;
-} ColorimetryInfo;
-
-#define MAKE_COLORIMETRY(n,r,m,t,p) { GST_VIDEO_COLORIMETRY_ ##n, \
-  { GST_VIDEO_COLOR_RANGE ##r, GST_VIDEO_COLOR_MATRIX_ ##m, \
-  GST_VIDEO_TRANSFER_ ##t, GST_VIDEO_COLOR_PRIMARIES_ ##p } }
-
-static const ColorimetryInfo colorimetry[] = {
-  MAKE_COLORIMETRY (BT601, _16_235, BT601, BT709, BT470M),
-  MAKE_COLORIMETRY (BT709, _16_235, BT709, BT709, BT709),
-  MAKE_COLORIMETRY (SMPTE240M, _16_235, SMPTE240M, SMPTE240M, SMPTE240M),
-};
-
-static const ColorimetryInfo *
-gst_video_get_colorimetry (const gchar * s)
-{
-  gint i;
-
-  for (i = 0; i < G_N_ELEMENTS (colorimetry); i++) {
-    if (g_str_equal (colorimetry[i].name, s))
-      return &colorimetry[i];
-  }
-  return NULL;
-}
-
-#define IS_EQUAL(ci,i) (((ci)->color.range == (i)->range) && \
-                        ((ci)->color.matrix == (i)->matrix) && \
-                        ((ci)->color.transfer == (i)->transfer) && \
-                        ((ci)->color.primaries == (i)->primaries))
-
-
-/**
- * gst_video_colorimetry_from_string
- * @cinfo: a #GstVideoColorimetry
- * @color: a colorimetry string
- *
- * Parse the colorimetry string and update @cinfo with the parsed
- * values.
- *
- * Returns: #TRUE if @color points to valid colorimetry info.
- */
-gboolean
-gst_video_colorimetry_from_string (GstVideoColorimetry * cinfo,
-    const gchar * color)
-{
-  const ColorimetryInfo *ci;
-
-  if ((ci = gst_video_get_colorimetry (color))) {
-    *cinfo = ci->color;
-  } else {
-    /* FIXME, split and parse */
-    cinfo->range = GST_VIDEO_COLOR_RANGE_16_235;
-    cinfo->matrix = GST_VIDEO_COLOR_MATRIX_BT601;
-    cinfo->transfer = GST_VIDEO_TRANSFER_BT709;
-    cinfo->primaries = GST_VIDEO_COLOR_PRIMARIES_BT709;
-  }
-  return TRUE;
-}
-
-static void
-gst_video_caps_set_colorimetry (GstCaps * caps, GstVideoColorimetry * cinfo)
-{
-  gint i;
-
-  for (i = 0; i < G_N_ELEMENTS (colorimetry); i++) {
-    if (IS_EQUAL (&colorimetry[i], cinfo)) {
-      gst_caps_set_simple (caps, "colorimetry", G_TYPE_STRING,
-          colorimetry[i].name, NULL);
-      return;
-    }
-  }
-  /* FIXME, construct colorimetry */
-}
-
-/**
- * gst_video_colorimetry_matches:
- * @info: a #GstVideoInfo
- * @color: a colorimetry string
- *
- * Check if the colorimetry information in @info matches that of the
- * string @color.
- *
- * Returns: #TRUE if @color conveys the same colorimetry info as the color
- * information in @info.
- */
-gboolean
-gst_video_colorimetry_matches (GstVideoColorimetry * cinfo, const gchar * color)
-{
-  const ColorimetryInfo *ci;
-
-  if ((ci = gst_video_get_colorimetry (color)))
-    return IS_EQUAL (ci, cinfo);
-
-  return FALSE;
-}
-
-/**
- * gst_video_info_from_caps:
- * @info: a #GstVideoInfo
- * @caps: a #GstCaps
- *
- * Parse @caps and update @info.
- *
- * Returns: TRUE if @caps could be parsed
- */
-gboolean
-gst_video_info_from_caps (GstVideoInfo * info, const GstCaps * caps)
-{
-  GstStructure *structure;
-  const gchar *s;
-  GstVideoFormat format = GST_VIDEO_FORMAT_UNKNOWN;
-  gint width = 0, height = 0, views;
-  gint fps_n, fps_d;
-  gint par_n, par_d;
-
-  g_return_val_if_fail (info != NULL, FALSE);
-  g_return_val_if_fail (caps != NULL, FALSE);
-  g_return_val_if_fail (gst_caps_is_fixed (caps), FALSE);
-
-  GST_DEBUG ("parsing caps %" GST_PTR_FORMAT, caps);
-
-  structure = gst_caps_get_structure (caps, 0);
-
-  if (gst_structure_has_name (structure, "video/x-raw")) {
-    if (!(s = gst_structure_get_string (structure, "format")))
-      goto no_format;
-
-    format = gst_video_format_from_string (s);
-    if (format == GST_VIDEO_FORMAT_UNKNOWN)
-      goto unknown_format;
-
-  } else if (g_str_has_prefix (gst_structure_get_name (structure), "video/") ||
-      g_str_has_prefix (gst_structure_get_name (structure), "image/")) {
-    format = GST_VIDEO_FORMAT_ENCODED;
-  } else {
-    goto wrong_name;
-  }
-
-  /* width and height are mandatory, except for non-raw-formats */
-  if (!gst_structure_get_int (structure, "width", &width) &&
-      format != GST_VIDEO_FORMAT_ENCODED)
-    goto no_width;
-  if (!gst_structure_get_int (structure, "height", &height) &&
-      format != GST_VIDEO_FORMAT_ENCODED)
-    goto no_height;
-
-  gst_video_info_set_format (info, format, width, height);
-
-  if (gst_structure_get_fraction (structure, "framerate", &fps_n, &fps_d)) {
-    if (fps_n == 0) {
-      /* variable framerate */
-      info->flags |= GST_VIDEO_FLAG_VARIABLE_FPS;
-      /* see if we have a max-framerate */
-      gst_structure_get_fraction (structure, "max-framerate", &fps_n, &fps_d);
-    }
-    info->fps_n = fps_n;
-    info->fps_d = fps_d;
-  } else {
-    /* unspecified is variable framerate */
-    info->fps_n = 0;
-    info->fps_d = 1;
-  }
-
-  if ((s = gst_structure_get_string (structure, "interlace-mode")))
-    info->interlace_mode = gst_interlace_mode_from_string (s);
-  else
-    info->interlace_mode = GST_VIDEO_INTERLACE_MODE_PROGRESSIVE;
-
-  if (gst_structure_get_int (structure, "views", &views))
-    info->views = views;
-  else
-    info->views = 1;
-
-  if ((s = gst_structure_get_string (structure, "chroma-site")))
-    info->chroma_site = gst_video_chroma_from_string (s);
-  else
-    info->chroma_site = GST_VIDEO_CHROMA_SITE_UNKNOWN;
-
-  if ((s = gst_structure_get_string (structure, "colorimetry")))
-    gst_video_colorimetry_from_string (&info->colorimetry, s);
-  else
-    memset (&info->colorimetry, 0, sizeof (GstVideoColorimetry));
-
-  if (gst_structure_get_fraction (structure, "pixel-aspect-ratio",
-          &par_n, &par_d)) {
-    info->par_n = par_n;
-    info->par_d = par_d;
-  } else {
-    info->par_n = 1;
-    info->par_d = 1;
-  }
-  return TRUE;
-
-  /* ERROR */
-wrong_name:
-  {
-    GST_ERROR ("wrong name '%s', expected video/ or image/",
-        gst_structure_get_name (structure));
-    return FALSE;
-  }
-no_format:
-  {
-    GST_ERROR ("no format given");
-    return FALSE;
-  }
-unknown_format:
-  {
-    GST_ERROR ("unknown format '%s' given", s);
-    return FALSE;
-  }
-no_width:
-  {
-    GST_ERROR ("no width property given");
-    return FALSE;
-  }
-no_height:
-  {
-    GST_ERROR ("no height property given");
-    return FALSE;
-  }
-}
-
-/**
- * gst_video_info_is_equal:
- * @info: a #GstVideoInfo
- * @other: a #GstVideoInfo
- *
- * Compares two #GstVideoInfo and returns whether they are equal or not
- *
- * Returns: %TRUE if @info and @other are equal, else %FALSE.
- */
-gboolean
-gst_video_info_is_equal (const GstVideoInfo * info, const GstVideoInfo * other)
-{
-  if (GST_VIDEO_INFO_FORMAT (info) != GST_VIDEO_INFO_FORMAT (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_INTERLACE_MODE (info) !=
-      GST_VIDEO_INFO_INTERLACE_MODE (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_FLAGS (info) != GST_VIDEO_INFO_FLAGS (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_WIDTH (info) != GST_VIDEO_INFO_WIDTH (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_HEIGHT (info) != GST_VIDEO_INFO_HEIGHT (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_SIZE (info) != GST_VIDEO_INFO_SIZE (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_PAR_N (info) != GST_VIDEO_INFO_PAR_N (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_PAR_D (info) != GST_VIDEO_INFO_PAR_D (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_FPS_N (info) != GST_VIDEO_INFO_FPS_N (other))
-    return FALSE;
-  if (GST_VIDEO_INFO_FPS_D (info) != GST_VIDEO_INFO_FPS_D (other))
-    return FALSE;
-  return TRUE;
-}
-
-/**
- * gst_video_info_to_caps:
- * @info: a #GstVideoInfo
- *
- * Convert the values of @info into a #GstCaps.
- *
- * Returns: a new #GstCaps containing the info of @info.
- */
-GstCaps *
-gst_video_info_to_caps (GstVideoInfo * info)
-{
-  GstCaps *caps;
-  const gchar *format;
-
-  g_return_val_if_fail (info != NULL, NULL);
-  g_return_val_if_fail (info->finfo != NULL, NULL);
-  g_return_val_if_fail (info->finfo->format != GST_VIDEO_FORMAT_UNKNOWN, NULL);
-
-  format = gst_video_format_to_string (info->finfo->format);
-  g_return_val_if_fail (format != NULL, NULL);
-
-  caps = gst_caps_new_simple ("video/x-raw",
-      "format", G_TYPE_STRING, format,
-      "width", G_TYPE_INT, info->width,
-      "height", G_TYPE_INT, info->height,
-      "pixel-aspect-ratio", GST_TYPE_FRACTION, info->par_n, info->par_d, NULL);
-
-  gst_caps_set_simple (caps, "interlace-mode", G_TYPE_STRING,
-      gst_interlace_mode_to_string (info->interlace_mode), NULL);
-
-  if (info->chroma_site != GST_VIDEO_CHROMA_SITE_UNKNOWN)
-    gst_caps_set_simple (caps, "chroma-site", G_TYPE_STRING,
-        gst_video_chroma_to_string (info->chroma_site), NULL);
-
-  gst_video_caps_set_colorimetry (caps, &info->colorimetry);
-
-  if (info->views > 1)
-    gst_caps_set_simple (caps, "views", G_TYPE_INT, info->views, NULL);
-
-  if (info->flags & GST_VIDEO_FLAG_VARIABLE_FPS && info->fps_n != 0) {
-    /* variable fps with a max-framerate */
-    gst_caps_set_simple (caps, "framerate", GST_TYPE_FRACTION, 0, 1,
-        "max-framerate", GST_TYPE_FRACTION, info->fps_n, info->fps_d, NULL);
-  } else {
-    /* no variable fps or no max-framerate */
-    gst_caps_set_simple (caps, "framerate", GST_TYPE_FRACTION,
-        info->fps_n, info->fps_d, NULL);
-  }
-
-  return caps;
-}
-
-/**
- * gst_video_frame_map_id:
- * @frame: pointer to #GstVideoFrame
- * @info: a #GstVideoInfo
- * @buffer: the buffer to map
- * @id: the frame id to map
- * @flags: #GstMapFlags
- *
- * Use @info and @buffer to fill in the values of @frame with the video frame
- * information of frame @id.
- *
- * When @id is -1, the default frame is mapped. When @id != -1, this function
- * will return %FALSE when there is no GstVideoMeta with that id.
- *
- * All video planes of @buffer will be mapped and the pointers will be set in
- * @frame->data.
- *
- * Returns: %TRUE on success.
- */
-gboolean
-gst_video_frame_map_id (GstVideoFrame * frame, GstVideoInfo * info,
-    GstBuffer * buffer, gint id, GstMapFlags flags)
-{
-  GstVideoMeta *meta;
-  gint i;
-
-  g_return_val_if_fail (frame != NULL, FALSE);
-  g_return_val_if_fail (info != NULL, FALSE);
-  g_return_val_if_fail (GST_IS_BUFFER (buffer), FALSE);
-
-  if (id == -1)
-    meta = gst_buffer_get_video_meta (buffer);
-  else
-    meta = gst_buffer_get_video_meta_id (buffer, id);
-
-  /* copy the info */
-  frame->info = *info;
-
-  if (meta) {
-    frame->info.finfo = &formats[meta->format].info;
-    frame->info.width = meta->width;
-    frame->info.height = meta->height;
-    frame->id = meta->id;
-    frame->flags = meta->flags;
-
-    for (i = 0; i < info->finfo->n_planes; i++)
-      gst_video_meta_map (meta, i, &frame->map[i], &frame->data[i],
-          &frame->info.stride[i], flags);
-  } else {
-    /* no metadata, we really need to have the metadata when the id is
-     * specified. */
-    if (id != -1)
-      goto no_metadata;
-
-    frame->id = id;
-    frame->flags = 0;
-
-    if (GST_VIDEO_INFO_IS_INTERLACED (info)) {
-      if (GST_BUFFER_FLAG_IS_SET (buffer, GST_VIDEO_BUFFER_FLAG_TFF))
-        frame->flags |= GST_VIDEO_FRAME_FLAG_TFF;
-      if (GST_BUFFER_FLAG_IS_SET (buffer, GST_VIDEO_BUFFER_FLAG_RFF))
-        frame->flags |= GST_VIDEO_FRAME_FLAG_RFF;
-      if (GST_BUFFER_FLAG_IS_SET (buffer, GST_VIDEO_BUFFER_FLAG_ONEFIELD))
-        frame->flags |= GST_VIDEO_FRAME_FLAG_ONEFIELD;
-    }
-
-    gst_buffer_map (buffer, &frame->map[0], flags);
-
-    /* do some sanity checks */
-    if (frame->map[0].size < info->size)
-      goto invalid_size;
-
-    /* set up pointers */
-    for (i = 0; i < info->finfo->n_planes; i++) {
-      frame->data[i] = frame->map[0].data + info->offset[i];
-    }
-  }
-  frame->buffer = gst_buffer_ref (buffer);
-  frame->meta = meta;
-
-  return TRUE;
-
-  /* ERRORS */
-no_metadata:
-  {
-    GST_ERROR ("no GstVideoMeta for id %d", id);
-    return FALSE;
-  }
-invalid_size:
-  {
-    GST_ERROR ("invalid buffer size %" G_GSIZE_FORMAT " < %" G_GSIZE_FORMAT,
-        frame->map[0].size, info->size);
-    gst_buffer_unmap (buffer, &frame->map[0]);
-    return FALSE;
-  }
-}
-
-/**
- * gst_video_frame_map:
- * @frame: pointer to #GstVideoFrame
- * @info: a #GstVideoInfo
- * @buffer: the buffer to map
- * @flags: #GstMapFlags
- *
- * Use @info and @buffer to fill in the values of @frame.
- *
- * All video planes of @buffer will be mapped and the pointers will be set in
- * @frame->data.
- *
- * Returns: %TRUE on success.
- */
-gboolean
-gst_video_frame_map (GstVideoFrame * frame, GstVideoInfo * info,
-    GstBuffer * buffer, GstMapFlags flags)
-{
-  return gst_video_frame_map_id (frame, info, buffer, -1, flags);
-}
-
-/**
- * gst_video_frame_unmap:
- * @frame: a #GstVideoFrame
- *
- * Unmap the memory previously mapped with gst_video_frame_map.
- */
-void
-gst_video_frame_unmap (GstVideoFrame * frame)
-{
-  GstBuffer *buffer;
-  GstVideoMeta *meta;
-  gint i;
-
-  g_return_if_fail (frame != NULL);
-
-  buffer = frame->buffer;
-  meta = frame->meta;
-
-  if (meta) {
-    for (i = 0; i < frame->info.finfo->n_planes; i++) {
-      gst_video_meta_unmap (meta, i, &frame->map[i]);
-    }
-  } else {
-    gst_buffer_unmap (buffer, &frame->map[0]);
-  }
-  gst_buffer_unref (buffer);
-}
-
-/**
- * gst_video_frame_copy:
- * @dest: a #GstVideoFrame
- * @src: a #GstVideoFrame
- * @plane: a plane
- *
- * Copy the plane with index @plane from @src to @dest.
- *
- * Returns: TRUE if the contents could be copied.
- */
-gboolean
-gst_video_frame_copy_plane (GstVideoFrame * dest, const GstVideoFrame * src,
-    guint plane)
-{
-  const GstVideoInfo *sinfo;
-  GstVideoInfo *dinfo;
-  guint w, h, j;
-  guint8 *sp, *dp;
-  gint ss, ds;
-
-  g_return_val_if_fail (dest != NULL, FALSE);
-  g_return_val_if_fail (src != NULL, FALSE);
-
-  sinfo = &src->info;
-  dinfo = &dest->info;
-
-  g_return_val_if_fail (dinfo->finfo->format == sinfo->finfo->format, FALSE);
-  g_return_val_if_fail (dinfo->width == sinfo->width
-      && dinfo->height == sinfo->height, FALSE);
-  g_return_val_if_fail (dinfo->finfo->n_planes > plane, FALSE);
-
-  sp = src->data[plane];
-  dp = dest->data[plane];
-
-  ss = sinfo->stride[plane];
-  ds = dinfo->stride[plane];
-
-  w = MIN (ABS (ss), ABS (ds));
-  h = GST_VIDEO_FRAME_COMP_HEIGHT (dest, plane);
-
-  GST_CAT_DEBUG (GST_CAT_PERFORMANCE, "copy plane %d, w:%d h:%d ", plane, w, h);
-
-  for (j = 0; j < h; j++) {
-    memcpy (dp, sp, w);
-    dp += ds;
-    sp += ss;
-  }
-  return TRUE;
-}
-
-/**
- * gst_video_frame_copy:
- * @dest: a #GstVideoFrame
- * @src: a #GstVideoFrame
- *
- * Copy the contents from @src to @dest.
- *
- * Returns: TRUE if the contents could be copied.
- */
-gboolean
-gst_video_frame_copy (GstVideoFrame * dest, const GstVideoFrame * src)
-{
-  guint i, n_planes;
-  const GstVideoInfo *sinfo;
-  GstVideoInfo *dinfo;
-
-  g_return_val_if_fail (dest != NULL, FALSE);
-  g_return_val_if_fail (src != NULL, FALSE);
-
-  sinfo = &src->info;
-  dinfo = &dest->info;
-
-  g_return_val_if_fail (dinfo->finfo->format == sinfo->finfo->format, FALSE);
-  g_return_val_if_fail (dinfo->width == sinfo->width
-      && dinfo->height == sinfo->height, FALSE);
-
-  n_planes = dinfo->finfo->n_planes;
-
-  for (i = 0; i < n_planes; i++)
-    gst_video_frame_copy_plane (dest, src, i);
-
-  return TRUE;
-}
-
-static int
-fill_planes (GstVideoInfo * info)
-{
-  gint width, height;
-
-  width = info->width;
-  height = info->height;
-
-  switch (info->finfo->format) {
-    case GST_VIDEO_FORMAT_YUY2:
-    case GST_VIDEO_FORMAT_YVYU:
-    case GST_VIDEO_FORMAT_UYVY:
-      info->stride[0] = GST_ROUND_UP_4 (width * 2);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_AYUV:
-    case GST_VIDEO_FORMAT_RGBx:
-    case GST_VIDEO_FORMAT_RGBA:
-    case GST_VIDEO_FORMAT_BGRx:
-    case GST_VIDEO_FORMAT_BGRA:
-    case GST_VIDEO_FORMAT_xRGB:
-    case GST_VIDEO_FORMAT_ARGB:
-    case GST_VIDEO_FORMAT_xBGR:
-    case GST_VIDEO_FORMAT_ABGR:
-    case GST_VIDEO_FORMAT_r210:
-      info->stride[0] = width * 4;
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_RGB16:
-    case GST_VIDEO_FORMAT_BGR16:
-    case GST_VIDEO_FORMAT_RGB15:
-    case GST_VIDEO_FORMAT_BGR15:
-      info->stride[0] = GST_ROUND_UP_4 (width * 2);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_RGB:
-    case GST_VIDEO_FORMAT_BGR:
-    case GST_VIDEO_FORMAT_v308:
-      info->stride[0] = GST_ROUND_UP_4 (width * 3);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_v210:
-      info->stride[0] = ((width + 47) / 48) * 128;
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_v216:
-      info->stride[0] = GST_ROUND_UP_8 (width * 4);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_GRAY8:
-    case GST_VIDEO_FORMAT_Y800:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_GRAY16_BE:
-    case GST_VIDEO_FORMAT_GRAY16_LE:
-    case GST_VIDEO_FORMAT_Y16:
-      info->stride[0] = GST_ROUND_UP_4 (width * 2);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_UYVP:
-      info->stride[0] = GST_ROUND_UP_4 ((width * 2 * 5 + 3) / 4);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_RGB8_PALETTED:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_IYU1:
-      info->stride[0] = GST_ROUND_UP_4 (GST_ROUND_UP_4 (width) +
-          GST_ROUND_UP_4 (width) / 2);
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_ARGB64:
-    case GST_VIDEO_FORMAT_AYUV64:
-      info->stride[0] = width * 8;
-      info->offset[0] = 0;
-      info->size = info->stride[0] * height;
-      break;
-    case GST_VIDEO_FORMAT_I420:
-    case GST_VIDEO_FORMAT_YV12:        /* same as I420, but plane 1+2 swapped */
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = GST_ROUND_UP_4 (GST_ROUND_UP_2 (width) / 2);
-      info->stride[2] = info->stride[1];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
-      info->offset[2] = info->offset[1] +
-          info->stride[1] * (GST_ROUND_UP_2 (height) / 2);
-      info->size = info->offset[2] +
-          info->stride[2] * (GST_ROUND_UP_2 (height) / 2);
-      break;
-    case GST_VIDEO_FORMAT_Y41B:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = GST_ROUND_UP_16 (width) / 4;
-      info->stride[2] = info->stride[1];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * height;
-      info->offset[2] = info->offset[1] + info->stride[1] * height;
-      /* simplification of ROUNDUP4(w)*h + 2*((ROUNDUP16(w)/4)*h */
-      info->size = (info->stride[0] + (GST_ROUND_UP_16 (width) / 2)) * height;
-      break;
-    case GST_VIDEO_FORMAT_Y42B:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = GST_ROUND_UP_8 (width) / 2;
-      info->stride[2] = info->stride[1];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * height;
-      info->offset[2] = info->offset[1] + info->stride[1] * height;
-      /* simplification of ROUNDUP4(w)*h + 2*(ROUNDUP8(w)/2)*h */
-      info->size = (info->stride[0] + GST_ROUND_UP_8 (width)) * height;
-      break;
-    case GST_VIDEO_FORMAT_Y444:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = info->stride[0];
-      info->stride[2] = info->stride[0];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * height;
-      info->offset[2] = info->offset[1] * 2;
-      info->size = info->stride[0] * height * 3;
-      break;
-    case GST_VIDEO_FORMAT_NV12:
-    case GST_VIDEO_FORMAT_NV21:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = info->stride[0];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
-      info->size = info->stride[0] * GST_ROUND_UP_2 (height) * 3 / 2;
-      break;
-    case GST_VIDEO_FORMAT_A420:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = GST_ROUND_UP_4 (GST_ROUND_UP_2 (width) / 2);
-      info->stride[2] = info->stride[1];
-      info->stride[3] = info->stride[0];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * GST_ROUND_UP_2 (height);
-      info->offset[2] = info->offset[1] +
-          info->stride[1] * (GST_ROUND_UP_2 (height) / 2);
-      info->offset[3] = info->offset[2] +
-          info->stride[2] * (GST_ROUND_UP_2 (height) / 2);
-      info->size = info->offset[3] + info->stride[0];
-      break;
-    case GST_VIDEO_FORMAT_YUV9:
-    case GST_VIDEO_FORMAT_YVU9:
-      info->stride[0] = GST_ROUND_UP_4 (width);
-      info->stride[1] = GST_ROUND_UP_4 (GST_ROUND_UP_4 (width) / 4);
-      info->stride[2] = info->stride[1];
-      info->offset[0] = 0;
-      info->offset[1] = info->stride[0] * height;
-      info->offset[2] = info->offset[1] +
-          info->stride[1] * (GST_ROUND_UP_4 (height) / 4);
-      info->size = info->offset[2] +
-          info->stride[2] * (GST_ROUND_UP_4 (height) / 4);
-      break;
-    case GST_VIDEO_FORMAT_ENCODED:
-      break;
-    case GST_VIDEO_FORMAT_UNKNOWN:
-      GST_ERROR ("invalid format");
-      g_warning ("invalid format");
-      break;
-  }
-  return 0;
-}
-
-/**
- * gst_video_format_convert:
- * @info: a #GstVideoInfo
- * @src_format: #GstFormat of the @src_value
- * @src_value: value to convert
- * @dest_format: #GstFormat of the @dest_value
- * @dest_value: pointer to destination value
- *
- * Converts among various #GstFormat types.  This function handles
- * GST_FORMAT_BYTES, GST_FORMAT_TIME, and GST_FORMAT_DEFAULT.  For
- * raw video, GST_FORMAT_DEFAULT corresponds to video frames.  This
- * function can be used to handle pad queries of the type GST_QUERY_CONVERT.
- *
- * Since: 0.10.16
- *
- * Returns: TRUE if the conversion was successful.
- */
-gboolean
-gst_video_info_convert (GstVideoInfo * info,
-    GstFormat src_format, gint64 src_value,
-    GstFormat dest_format, gint64 * dest_value)
-{
-  gboolean ret = FALSE;
-  int size, fps_n, fps_d;
-
-  g_return_val_if_fail (info != NULL, 0);
-  g_return_val_if_fail (info->finfo != NULL, 0);
-  g_return_val_if_fail (info->finfo->format != GST_VIDEO_FORMAT_UNKNOWN, 0);
-  g_return_val_if_fail (info->size > 0, 0);
-
-  size = info->size;
-  fps_n = info->fps_n;
-  fps_d = info->fps_d;
-
-  GST_DEBUG ("converting value %" G_GINT64_FORMAT " from %s to %s",
-      src_value, gst_format_get_name (src_format),
-      gst_format_get_name (dest_format));
-
-  if (src_format == dest_format) {
-    *dest_value = src_value;
-    ret = TRUE;
-    goto done;
-  }
-
-  if (src_value == -1) {
-    *dest_value = -1;
-    ret = TRUE;
-    goto done;
-  }
-
-  /* bytes to frames */
-  if (src_format == GST_FORMAT_BYTES && dest_format == GST_FORMAT_DEFAULT) {
-    if (size != 0) {
-      *dest_value = gst_util_uint64_scale_int (src_value, 1, size);
-    } else {
-      GST_ERROR ("blocksize is 0");
-      *dest_value = 0;
-    }
-    ret = TRUE;
-    goto done;
-  }
-
-  /* frames to bytes */
-  if (src_format == GST_FORMAT_DEFAULT && dest_format == GST_FORMAT_BYTES) {
-    *dest_value = gst_util_uint64_scale_int (src_value, size, 1);
-    ret = TRUE;
-    goto done;
-  }
-
-  /* time to frames */
-  if (src_format == GST_FORMAT_TIME && dest_format == GST_FORMAT_DEFAULT) {
-    if (fps_d != 0) {
-      *dest_value = gst_util_uint64_scale (src_value,
-          fps_n, GST_SECOND * fps_d);
-    } else {
-      GST_ERROR ("framerate denominator is 0");
-      *dest_value = 0;
-    }
-    ret = TRUE;
-    goto done;
-  }
-
-  /* frames to time */
-  if (src_format == GST_FORMAT_DEFAULT && dest_format == GST_FORMAT_TIME) {
-    if (fps_n != 0) {
-      *dest_value = gst_util_uint64_scale (src_value,
-          GST_SECOND * fps_d, fps_n);
-    } else {
-      GST_ERROR ("framerate numerator is 0");
-      *dest_value = 0;
-    }
-    ret = TRUE;
-    goto done;
-  }
-
-  /* time to bytes */
-  if (src_format == GST_FORMAT_TIME && dest_format == GST_FORMAT_BYTES) {
-    if (fps_d != 0) {
-      *dest_value = gst_util_uint64_scale (src_value,
-          fps_n * size, GST_SECOND * fps_d);
-    } else {
-      GST_ERROR ("framerate denominator is 0");
-      *dest_value = 0;
-    }
-    ret = TRUE;
-    goto done;
-  }
-
-  /* bytes to time */
-  if (src_format == GST_FORMAT_BYTES && dest_format == GST_FORMAT_TIME) {
-    if (fps_n != 0 && size != 0) {
-      *dest_value = gst_util_uint64_scale (src_value,
-          GST_SECOND * fps_d, fps_n * size);
-    } else {
-      GST_ERROR ("framerate denominator and/or blocksize is 0");
-      *dest_value = 0;
-    }
-    ret = TRUE;
-  }
-
-done:
-
-  GST_DEBUG ("ret=%d result %" G_GINT64_FORMAT, ret, *dest_value);
-
-  return ret;
-}
-
-#define GST_VIDEO_EVENT_STILL_STATE_NAME "GstEventStillFrame"
-
-/**
- * gst_video_event_new_still_frame:
- * @in_still: boolean value for the still-frame state of the event.
- *
- * Creates a new Still Frame event. If @in_still is %TRUE, then the event
- * represents the start of a still frame sequence. If it is %FALSE, then
- * the event ends a still frame sequence.
- *
- * To parse an event created by gst_video_event_new_still_frame() use
- * gst_video_event_parse_still_frame().
- *
- * Returns: The new GstEvent
- * Since: 0.10.26
- */
-GstEvent *
-gst_video_event_new_still_frame (gboolean in_still)
-{
-  GstEvent *still_event;
-  GstStructure *s;
-
-  s = gst_structure_new (GST_VIDEO_EVENT_STILL_STATE_NAME,
-      "still-state", G_TYPE_BOOLEAN, in_still, NULL);
-  still_event = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM, s);
-
-  return still_event;
-}
-
-/**
- * gst_video_event_parse_still_frame:
- * @event: A #GstEvent to parse
- * @in_still: A boolean to receive the still-frame status from the event, or NULL
- *
- * Parse a #GstEvent, identify if it is a Still Frame event, and
- * return the still-frame state from the event if it is.
- * If the event represents the start of a still frame, the in_still
- * variable will be set to TRUE, otherwise FALSE. It is OK to pass NULL for the
- * in_still variable order to just check whether the event is a valid still-frame
- * event.
- *
- * Create a still frame event using gst_video_event_new_still_frame()
- *
- * Returns: %TRUE if the event is a valid still-frame event. %FALSE if not
- * Since: 0.10.26
- */
-gboolean
-gst_video_event_parse_still_frame (GstEvent * event, gboolean * in_still)
-{
-  const GstStructure *s;
-  gboolean ev_still_state;
-
-  g_return_val_if_fail (event != NULL, FALSE);
-
-  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_DOWNSTREAM)
-    return FALSE;               /* Not a still frame event */
-
-  s = gst_event_get_structure (event);
-  if (s == NULL
-      || !gst_structure_has_name (s, GST_VIDEO_EVENT_STILL_STATE_NAME))
-    return FALSE;               /* Not a still frame event */
-  if (!gst_structure_get_boolean (s, "still-state", &ev_still_state))
-    return FALSE;               /* Not a still frame event */
-  if (in_still)
-    *in_still = ev_still_state;
-  return TRUE;
-}
-
-/**
- * gst_video_parse_caps_palette:
- * @caps: #GstCaps to parse
- *
- * Returns the palette data from the caps as a #GstBuffer. For
- * #GST_VIDEO_FORMAT_RGB8_PALETTED this is containing 256 #guint32
- * values, each containing ARGB colors in native endianness.
- *
- * Returns: a #GstBuffer containing the palette data. Unref after usage.
- * Since: 0.10.32
- */
-GstBuffer *
-gst_video_parse_caps_palette (GstCaps * caps)
-{
-  GstStructure *s;
-  const GValue *p_v;
-  GstBuffer *p;
-
-  if (!gst_caps_is_fixed (caps))
-    return NULL;
-
-  s = gst_caps_get_structure (caps, 0);
-
-  p_v = gst_structure_get_value (s, "palette_data");
-  if (!p_v || !GST_VALUE_HOLDS_BUFFER (p_v))
-    return NULL;
-
-  p = g_value_dup_boxed (p_v);
-
-  return p;
-}
-
-#define GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME "GstForceKeyUnit"
-
-/**
- * gst_video_event_new_downstream_force_key_unit:
- * @timestamp: the timestamp of the buffer that starts a new key unit
- * @stream_time: the stream_time of the buffer that starts a new key unit
- * @running_time: the running_time of the buffer that starts a new key unit
- * @all_headers: %TRUE to produce headers when starting a new key unit
- * @count: integer that can be used to number key units
- *
- * Creates a new downstream force key unit event. A downstream force key unit
- * event can be sent down the pipeline to request downstream elements to produce
- * a key unit. A downstream force key unit event must also be sent when handling
- * an upstream force key unit event to notify downstream that the latter has been
- * handled.
- *
- * To parse an event created by gst_video_event_new_downstream_force_key_unit() use
- * gst_video_event_parse_downstream_force_key_unit().
- *
- * Returns: The new GstEvent
- * Since: 0.10.36
- */
-GstEvent *
-gst_video_event_new_downstream_force_key_unit (GstClockTime timestamp,
-    GstClockTime stream_time, GstClockTime running_time, gboolean all_headers,
-    guint count)
-{
-  GstEvent *force_key_unit_event;
-  GstStructure *s;
-
-  s = gst_structure_new (GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME,
-      "timestamp", G_TYPE_UINT64, timestamp,
-      "stream-time", G_TYPE_UINT64, stream_time,
-      "running-time", G_TYPE_UINT64, running_time,
-      "all-headers", G_TYPE_BOOLEAN, all_headers,
-      "count", G_TYPE_UINT, count, NULL);
-  force_key_unit_event = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM, s);
-
-  return force_key_unit_event;
-}
-
-/**
- * gst_video_event_new_upstream_force_key_unit:
- * @running_time: the running_time at which a new key unit should be produced
- * @all_headers: %TRUE to produce headers when starting a new key unit
- * @count: integer that can be used to number key units
- *
- * Creates a new upstream force key unit event. An upstream force key unit event
- * can be sent to request upstream elements to produce a key unit. 
- *
- * @running_time can be set to request a new key unit at a specific
- * running_time. If set to GST_CLOCK_TIME_NONE, upstream elements will produce a
- * new key unit as soon as possible.
- *
- * To parse an event created by gst_video_event_new_downstream_force_key_unit() use
- * gst_video_event_parse_downstream_force_key_unit().
- *
- * Returns: The new GstEvent
- * Since: 0.10.36
- */
-GstEvent *
-gst_video_event_new_upstream_force_key_unit (GstClockTime running_time,
-    gboolean all_headers, guint count)
-{
-  GstEvent *force_key_unit_event;
-  GstStructure *s;
-
-  s = gst_structure_new (GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME,
-      "running-time", GST_TYPE_CLOCK_TIME, running_time,
-      "all-headers", G_TYPE_BOOLEAN, all_headers,
-      "count", G_TYPE_UINT, count, NULL);
-  force_key_unit_event = gst_event_new_custom (GST_EVENT_CUSTOM_UPSTREAM, s);
-
-  return force_key_unit_event;
-}
-
-/**
- * gst_video_event_is_force_key_unit:
- * @event: A #GstEvent to check
- *
- * Checks if an event is a force key unit event. Returns true for both upstream
- * and downstream force key unit events.
- *
- * Returns: %TRUE if the event is a valid force key unit event
- * Since: 0.10.36
- */
-gboolean
-gst_video_event_is_force_key_unit (GstEvent * event)
-{
-  const GstStructure *s;
-
-  g_return_val_if_fail (event != NULL, FALSE);
-
-  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_DOWNSTREAM &&
-      GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_UPSTREAM)
-    return FALSE;               /* Not a force key unit event */
-
-  s = gst_event_get_structure (event);
-  if (s == NULL
-      || !gst_structure_has_name (s, GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME))
-    return FALSE;
-
-  return TRUE;
-}
-
-/**
- * gst_video_event_parse_downstream_force_key_unit:
- * @event: A #GstEvent to parse
- * @timestamp: (out): A pointer to the timestamp in the event
- * @stream_time: (out): A pointer to the stream-time in the event
- * @running_time: (out): A pointer to the running-time in the event
- * @all_headers: (out): A pointer to the all_headers flag in the event
- * @count: (out): A pointer to the count field of the event
- *
- * Get timestamp, stream-time, running-time, all-headers and count in the force
- * key unit event. See gst_video_event_new_downstream_force_key_unit() for a
- * full description of the downstream force key unit event.
- *
- * Returns: %TRUE if the event is a valid downstream force key unit event.
- * Since: 0.10.36
- */
-gboolean
-gst_video_event_parse_downstream_force_key_unit (GstEvent * event,
-    GstClockTime * timestamp, GstClockTime * stream_time,
-    GstClockTime * running_time, gboolean * all_headers, guint * count)
-{
-  const GstStructure *s;
-  GstClockTime ev_timestamp, ev_stream_time, ev_running_time;
-  gboolean ev_all_headers;
-  guint ev_count;
-
-  g_return_val_if_fail (event != NULL, FALSE);
-
-  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_DOWNSTREAM)
-    return FALSE;               /* Not a force key unit event */
-
-  s = gst_event_get_structure (event);
-  if (s == NULL
-      || !gst_structure_has_name (s, GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME))
-    return FALSE;
-
-  if (!gst_structure_get_clock_time (s, "timestamp", &ev_timestamp))
-    ev_timestamp = GST_CLOCK_TIME_NONE;
-  if (!gst_structure_get_clock_time (s, "stream-time", &ev_stream_time))
-    ev_stream_time = GST_CLOCK_TIME_NONE;
-  if (!gst_structure_get_clock_time (s, "running-time", &ev_running_time))
-    ev_running_time = GST_CLOCK_TIME_NONE;
-  if (!gst_structure_get_boolean (s, "all-headers", &ev_all_headers))
-    ev_all_headers = FALSE;
-  if (!gst_structure_get_uint (s, "count", &ev_count))
-    ev_count = 0;
-
-  if (timestamp)
-    *timestamp = ev_timestamp;
-
-  if (stream_time)
-    *stream_time = ev_stream_time;
-
-  if (running_time)
-    *running_time = ev_running_time;
-
-  if (all_headers)
-    *all_headers = ev_all_headers;
-
-  if (count)
-    *count = ev_count;
-
-  return TRUE;
-}
-
-/**
- * gst_video_event_parse_upstream_force_key_unit:
- * @event: A #GstEvent to parse
- * @running_time: (out): A pointer to the running_time in the event
- * @all_headers: (out): A pointer to the all_headers flag in the event
- * @count: (out): A pointer to the count field in the event
- *
- * Get running-time, all-headers and count in the force key unit event. See
- * gst_video_event_new_upstream_force_key_unit() for a full description of the
- * upstream force key unit event.
- *
- * Create an upstream force key unit event using  gst_video_event_new_upstream_force_key_unit()
- *
- * Returns: %TRUE if the event is a valid upstream force-key-unit event. %FALSE if not
- * Since: 0.10.36
- */
-gboolean
-gst_video_event_parse_upstream_force_key_unit (GstEvent * event,
-    GstClockTime * running_time, gboolean * all_headers, guint * count)
-{
-  const GstStructure *s;
-  GstClockTime ev_running_time;
-  gboolean ev_all_headers;
-  guint ev_count;
-
-  g_return_val_if_fail (event != NULL, FALSE);
-
-  if (GST_EVENT_TYPE (event) != GST_EVENT_CUSTOM_UPSTREAM)
-    return FALSE;               /* Not a force key unit event */
-
-  s = gst_event_get_structure (event);
-  if (s == NULL
-      || !gst_structure_has_name (s, GST_VIDEO_EVENT_FORCE_KEY_UNIT_NAME))
-    return FALSE;
-
-  if (!gst_structure_get_clock_time (s, "running-time", &ev_running_time))
-    ev_running_time = GST_CLOCK_TIME_NONE;
-  if (!gst_structure_get_boolean (s, "all-headers", &ev_all_headers))
-    ev_all_headers = FALSE;
-  if (!gst_structure_get_uint (s, "count", &ev_count))
-    ev_count = 0;
-
-  if (running_time)
-    *running_time = ev_running_time;
-
-  if (all_headers)
-    *all_headers = ev_all_headers;
-
-  if (count)
-    *count = ev_count;
-
-  return TRUE;
-}
diff --git a/gst-libs/gst/video/video.h b/gst-libs/gst/video/video.h
index 35ec822..4068fc4 100644
--- a/gst-libs/gst/video/video.h
+++ b/gst-libs/gst/video/video.h
@@ -21,716 +21,14 @@
 #define __GST_VIDEO_H__
 
 #include <gst/gst.h>
-
-G_BEGIN_DECLS
-
+#include <gst/video/video-event.h>
+#include <gst/video/video-format.h>
+#include <gst/video/video-color.h>
+#include <gst/video/video-info.h>
+#include <gst/video/video-frame.h>
 #include <gst/video/video-enumtypes.h>
 
-/**
- * GstVideoFormat:
- * @GST_VIDEO_FORMAT_UNKNOWN: Unknown or unset video format id
- * @GST_VIDEO_FORMAT_ENCODED: Encoded video format
- * @GST_VIDEO_FORMAT_I420: planar 4:2:0 YUV
- * @GST_VIDEO_FORMAT_YV12: planar 4:2:0 YVU (like I420 but UV planes swapped)
- * @GST_VIDEO_FORMAT_YUY2: packed 4:2:2 YUV (Y0-U0-Y1-V0 Y2-U2-Y3-V2 Y4 ...)
- * @GST_VIDEO_FORMAT_UYVY: packed 4:2:2 YUV (U0-Y0-V0-Y1 U2-Y2-V2-Y3 U4 ...)
- * @GST_VIDEO_FORMAT_AYUV: packed 4:4:4 YUV with alpha channel (A0-Y0-U0-V0 ...)
- * @GST_VIDEO_FORMAT_RGBx: sparse rgb packed into 32 bit, space last
- * @GST_VIDEO_FORMAT_BGRx: sparse reverse rgb packed into 32 bit, space last
- * @GST_VIDEO_FORMAT_xRGB: sparse rgb packed into 32 bit, space first
- * @GST_VIDEO_FORMAT_xBGR: sparse reverse rgb packed into 32 bit, space first
- * @GST_VIDEO_FORMAT_RGBA: rgb with alpha channel last
- * @GST_VIDEO_FORMAT_BGRA: reverse rgb with alpha channel last
- * @GST_VIDEO_FORMAT_ARGB: rgb with alpha channel first
- * @GST_VIDEO_FORMAT_ABGR: reverse rgb with alpha channel first
- * @GST_VIDEO_FORMAT_RGB: rgb
- * @GST_VIDEO_FORMAT_BGR: reverse rgb
- * @GST_VIDEO_FORMAT_Y41B: planar 4:1:1 YUV (Since: 0.10.18)
- * @GST_VIDEO_FORMAT_Y42B: planar 4:2:2 YUV (Since: 0.10.18)
- * @GST_VIDEO_FORMAT_YVYU: packed 4:2:2 YUV (Y0-V0-Y1-U0 Y2-V2-Y3-U2 Y4 ...) (Since: 0.10.23)
- * @GST_VIDEO_FORMAT_Y444: planar 4:4:4 YUV (Since: 0.10.24)
- * @GST_VIDEO_FORMAT_v210: packed 4:2:2 10-bit YUV, complex format (Since: 0.10.24)
- * @GST_VIDEO_FORMAT_v216: packed 4:2:2 16-bit YUV, Y0-U0-Y1-V1 order (Since: 0.10.24)
- * @GST_VIDEO_FORMAT_NV12: planar 4:2:0 YUV with interleaved UV plane (Since: 0.10.26)
- * @GST_VIDEO_FORMAT_NV21: planar 4:2:0 YUV with interleaved VU plane (Since: 0.10.26)
- * @GST_VIDEO_FORMAT_GRAY8: 8-bit grayscale (Since: 0.10.29)
- * @GST_VIDEO_FORMAT_GRAY16_BE: 16-bit grayscale, most significant byte first (Since: 0.10.29)
- * @GST_VIDEO_FORMAT_GRAY16_LE: 16-bit grayscale, least significant byte first (Since: 0.10.29)
- * @GST_VIDEO_FORMAT_v308: packed 4:4:4 YUV (Since: 0.10.29)
- * @GST_VIDEO_FORMAT_Y800: same as GST_VIDEO_FORMAT_GRAY8 (Since: 0.10.30)
- * @GST_VIDEO_FORMAT_Y16: same as GST_VIDEO_FORMAT_GRAY16_LE (Since: 0.10.30)
- * @GST_VIDEO_FORMAT_RGB16: rgb 5-6-5 bits per component (Since: 0.10.30)
- * @GST_VIDEO_FORMAT_BGR16: reverse rgb 5-6-5 bits per component (Since: 0.10.30)
- * @GST_VIDEO_FORMAT_RGB15: rgb 5-5-5 bits per component (Since: 0.10.30)
- * @GST_VIDEO_FORMAT_BGR15: reverse rgb 5-5-5 bits per component (Since: 0.10.30)
- * @GST_VIDEO_FORMAT_UYVP: packed 10-bit 4:2:2 YUV (U0-Y0-V0-Y1 U2-Y2-V2-Y3 U4 ...) (Since: 0.10.31)
- * @GST_VIDEO_FORMAT_A420: planar 4:4:2:0 AYUV (Since: 0.10.31)
- * @GST_VIDEO_FORMAT_RGB8_PALETTED: 8-bit paletted RGB (Since: 0.10.32)
- * @GST_VIDEO_FORMAT_YUV9: planar 4:1:0 YUV (Since: 0.10.32)
- * @GST_VIDEO_FORMAT_YVU9: planar 4:1:0 YUV (like YUV9 but UV planes swapped) (Since: 0.10.32)
- * @GST_VIDEO_FORMAT_IYU1: packed 4:1:1 YUV (Cb-Y0-Y1-Cr-Y2-Y3 ...) (Since: 0.10.32)
- * @GST_VIDEO_FORMAT_ARGB64: rgb with alpha channel first, 16 bits per channel (Since: 0.10.33)
- * @GST_VIDEO_FORMAT_AYUV64: packed 4:4:4 YUV with alpha channel, 16 bits per channel (A0-Y0-U0-V0 ...) (Since: 0.10.33)
- * @GST_VIDEO_FORMAT_r210: packed 4:4:4 RGB, 10 bits per channel (Since: 0.10.33)
- *
- * Enum value describing the most common video formats.
- */
-typedef enum {
-  GST_VIDEO_FORMAT_UNKNOWN,
-  GST_VIDEO_FORMAT_I420,
-  GST_VIDEO_FORMAT_YV12,
-  GST_VIDEO_FORMAT_YUY2,
-  GST_VIDEO_FORMAT_UYVY,
-  GST_VIDEO_FORMAT_AYUV,
-  GST_VIDEO_FORMAT_RGBx,
-  GST_VIDEO_FORMAT_BGRx,
-  GST_VIDEO_FORMAT_xRGB,
-  GST_VIDEO_FORMAT_xBGR,
-  GST_VIDEO_FORMAT_RGBA,
-  GST_VIDEO_FORMAT_BGRA,
-  GST_VIDEO_FORMAT_ARGB,
-  GST_VIDEO_FORMAT_ABGR,
-  GST_VIDEO_FORMAT_RGB,
-  GST_VIDEO_FORMAT_BGR,
-  GST_VIDEO_FORMAT_Y41B,
-  GST_VIDEO_FORMAT_Y42B,
-  GST_VIDEO_FORMAT_YVYU,
-  GST_VIDEO_FORMAT_Y444,
-  GST_VIDEO_FORMAT_v210,
-  GST_VIDEO_FORMAT_v216,
-  GST_VIDEO_FORMAT_NV12,
-  GST_VIDEO_FORMAT_NV21,
-  GST_VIDEO_FORMAT_GRAY8,
-  GST_VIDEO_FORMAT_GRAY16_BE,
-  GST_VIDEO_FORMAT_GRAY16_LE,
-  GST_VIDEO_FORMAT_v308,
-  GST_VIDEO_FORMAT_Y800,
-  GST_VIDEO_FORMAT_Y16,
-  GST_VIDEO_FORMAT_RGB16,
-  GST_VIDEO_FORMAT_BGR16,
-  GST_VIDEO_FORMAT_RGB15,
-  GST_VIDEO_FORMAT_BGR15,
-  GST_VIDEO_FORMAT_UYVP,
-  GST_VIDEO_FORMAT_A420,
-  GST_VIDEO_FORMAT_RGB8_PALETTED,
-  GST_VIDEO_FORMAT_YUV9,
-  GST_VIDEO_FORMAT_YVU9,
-  GST_VIDEO_FORMAT_IYU1,
-  GST_VIDEO_FORMAT_ARGB64,
-  GST_VIDEO_FORMAT_AYUV64,
-  GST_VIDEO_FORMAT_r210,
-  GST_VIDEO_FORMAT_ENCODED
-} GstVideoFormat;
-
-#define GST_VIDEO_MAX_PLANES 4
-#define GST_VIDEO_MAX_COMPONENTS 4
-
-typedef struct _GstVideoFormatInfo GstVideoFormatInfo;
-
-/**
- * GstVideoFormatFlags:
- * @GST_VIDEO_FORMAT_FLAG_YUV: The video format is YUV, components are numbered
- *   0=Y, 1=U, 2=V.
- * @GST_VIDEO_FORMAT_FLAG_RGB: The video format is RGB, components are numbered
- *   0=R, 1=G, 2=B.
- * @GST_VIDEO_FORMAT_FLAG_GRAY: The video is gray, there is one gray component
- *   with index 0.
- * @GST_VIDEO_FORMAT_FLAG_ALPHA: The video format has an alpha components with
- *   the number 3.
- * @GST_VIDEO_FORMAT_FLAG_LE: The video format has data stored in little
- *   endianness.
- * @GST_VIDEO_FORMAT_FLAG_PALETTE: The video format has a palette.
- * @GST_VIDEO_FORMAT_FLAG_COMPLEX: The video format has a complex layout that
- *   can't be described with the usual information in the #GstVideoFormatInfo.
- *
- * The different video flags that a format info can have.
- */
-typedef enum
-{
-  GST_VIDEO_FORMAT_FLAG_YUV      = (1 << 0),
-  GST_VIDEO_FORMAT_FLAG_RGB      = (1 << 1),
-  GST_VIDEO_FORMAT_FLAG_GRAY     = (1 << 2),
-  GST_VIDEO_FORMAT_FLAG_ALPHA    = (1 << 3),
-  GST_VIDEO_FORMAT_FLAG_LE       = (1 << 4),
-  GST_VIDEO_FORMAT_FLAG_PALETTE  = (1 << 5),
-  GST_VIDEO_FORMAT_FLAG_COMPLEX  = (1 << 6)
-} GstVideoFormatFlags;
-
-#define GST_VIDEO_COMP_Y  0
-#define GST_VIDEO_COMP_U  1
-#define GST_VIDEO_COMP_V  2
-
-#define GST_VIDEO_COMP_R  0
-#define GST_VIDEO_COMP_G  1
-#define GST_VIDEO_COMP_B  2
-
-#define GST_VIDEO_COMP_A  3
-
-/**
- * GstVideoFormatUnpack:
- * @info: a #GstVideoFormatInfo
- * @dest: a destination array
- * @data: pointers to the data planes
- * @stride: strides of the planes
- * @x: the x position in the image to start from
- * @y: the y position in the image to start from
- * @width: the amount of pixels to unpack.
- *
- * Unpacks @width pixels from the given planes and strides containing data of
- * format @info. The pixels will be unpacked into @dest which each component
- * interleaved. @dest should at least be big enough to hold @width *
- * n_components * size(unpack_format) bytes.
- */
-typedef void (*GstVideoFormatUnpack)         (GstVideoFormatInfo *info, gpointer dest,
-                                              const gpointer data[GST_VIDEO_MAX_PLANES],
-                                              const gint stride[GST_VIDEO_MAX_PLANES],
-                                              gint x, gint y, gint width);
-/**
- * GstVideoFormatPack:
- * @info: a #GstVideoFormatInfo
- * @src: a source array
- * @data: pointers to the destination data planes
- * @stride: strides of the destination planes
- * @x: the x position in the image to pack to
- * @y: the y position in the image to pack to
- * @width: the amount of pixels to pack.
- *
- * Packs @width pixels from @src to the given planes and strides in the
- * format @info. The pixels from source have each component interleaved
- * and will be packed into the planes in @data.
- */
-typedef void (*GstVideoFormatPack)           (GstVideoFormatInfo *info, const gpointer src,
-                                              gpointer data[GST_VIDEO_MAX_PLANES],
-                                              const gint stride[GST_VIDEO_MAX_PLANES],
-                                              gint x, gint y, gint width);
-
-/**
- * GstVideoFormatInfo:
- * @format: #GstVideoFormat
- * @name: string representation of the format
- * @description: use readable description of the format
- * @flags: #GstVideoFormatFlags
- * @bits: The number of bits used to pack data items. This can be less than 8
- *    when multiple pixels are stored in a byte. for values > 8 multiple bytes
- *    should be read according to the endianness flag before applying the shift
- *    and mask.
- * @n_components: the number of components in the video format.
- * @shift: the number of bits to shift away to get the component data
- * @depth: the depth in bits for each component
- * @pixel_stride: the pixel stride of each component. This is the amount of
- *    bytes to the pixel immediately to the right. When bits < 8, the stride is
- *    expressed in bits.
- * @n_planes: the number of planes for this format. The number of planes can be
- *    less than the amount of components when multiple components are packed into
- *    one plane.
- * @plane: the plane number where a component can be found
- * @poffset: the offset in the plane where the first pixel of the components
- *    can be found. If bits < 8 the amount is specified in bits.
- * @w_sub: subsampling factor of the width for the component. Use
- *     GST_VIDEO_SUB_SCALE to scale a width.
- * @h_sub: subsampling factor of the height for the component. Use
- *     GST_VIDEO_SUB_SCALE to scale a height.
- * @unpack_format: the format of the unpacked pixels.
- * @unpack_func: an unpack function for this format
- * @pack_func: an pack function for this format
- *
- * Information for a video format.
- */
-struct _GstVideoFormatInfo {
-  GstVideoFormat format;
-  const gchar *name;
-  const gchar *description;
-  GstVideoFormatFlags flags;
-  guint bits;
-  guint n_components;
-  guint shift[GST_VIDEO_MAX_COMPONENTS];
-  guint depth[GST_VIDEO_MAX_COMPONENTS];
-  gint  pixel_stride[GST_VIDEO_MAX_COMPONENTS];
-  guint n_planes;
-  guint plane[GST_VIDEO_MAX_COMPONENTS];
-  guint poffset[GST_VIDEO_MAX_COMPONENTS];
-  guint w_sub[GST_VIDEO_MAX_COMPONENTS];
-  guint h_sub[GST_VIDEO_MAX_COMPONENTS];
-
-  GstVideoFormat unpack_format;
-  GstVideoFormatUnpack unpack_func;
-  GstVideoFormatPack pack_func;
-};
-
-#define GST_VIDEO_FORMAT_INFO_FORMAT(info)       ((info)->format)
-#define GST_VIDEO_FORMAT_INFO_NAME(info)         ((info)->name)
-#define GST_VIDEO_FORMAT_INFO_FLAGS(info)        ((info)->flags)
-
-#define GST_VIDEO_FORMAT_INFO_IS_YUV(info)       ((info)->flags & GST_VIDEO_FORMAT_FLAG_YUV)
-#define GST_VIDEO_FORMAT_INFO_IS_RGB(info)       ((info)->flags & GST_VIDEO_FORMAT_FLAG_RGB)
-#define GST_VIDEO_FORMAT_INFO_IS_GRAY(info)      ((info)->flags & GST_VIDEO_FORMAT_FLAG_GRAY)
-#define GST_VIDEO_FORMAT_INFO_HAS_ALPHA(info)    ((info)->flags & GST_VIDEO_FORMAT_FLAG_ALPHA)
-#define GST_VIDEO_FORMAT_INFO_IS_LE(info)        ((info)->flags & GST_VIDEO_FORMAT_FLAG_LE)
-#define GST_VIDEO_FORMAT_INFO_HAS_PALETTE(info)  ((info)->flags & GST_VIDEO_FORMAT_FLAG_PALETTE)
-#define GST_VIDEO_FORMAT_INFO_IS_COMPLEX(info)   ((info)->flags & GST_VIDEO_FORMAT_FLAG_COMPLEX)
-
-#define GST_VIDEO_FORMAT_INFO_BITS(info)         ((info)->bits)
-#define GST_VIDEO_FORMAT_INFO_N_COMPONENTS(info) ((info)->n_components)
-#define GST_VIDEO_FORMAT_INFO_SHIFT(info,c)      ((info)->shift[c])
-#define GST_VIDEO_FORMAT_INFO_DEPTH(info,c)      ((info)->depth[c])
-#define GST_VIDEO_FORMAT_INFO_PSTRIDE(info,c)    ((info)->pixel_stride[c])
-#define GST_VIDEO_FORMAT_INFO_N_PLANES(info)     ((info)->n_planes)
-#define GST_VIDEO_FORMAT_INFO_PLANE(info,c)      ((info)->plane[c])
-#define GST_VIDEO_FORMAT_INFO_POFFSET(info,c)    ((info)->poffset[c])
-#define GST_VIDEO_FORMAT_INFO_W_SUB(info,c)      ((info)->w_sub[c])
-#define GST_VIDEO_FORMAT_INFO_H_SUB(info,c)      ((info)->h_sub[c])
-
-/* rounds up */
-#define GST_VIDEO_SUB_SCALE(scale,val)   (-((-((gint)(val)))>>(scale)))
-
-#define GST_VIDEO_FORMAT_INFO_SCALE_WIDTH(info,c,w)  GST_VIDEO_SUB_SCALE ((info)->w_sub[c],(w))
-#define GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT(info,c,h) GST_VIDEO_SUB_SCALE ((info)->h_sub[c],(h))
-
-#define GST_VIDEO_FORMAT_INFO_DATA(info,planes,comp) \
-  (((guint8*)(planes)[(info)->plane[comp]]) + (info)->poffset[comp])
-#define GST_VIDEO_FORMAT_INFO_STRIDE(info,strides,comp) ((strides)[(info)->plane[comp]])
-#define GST_VIDEO_FORMAT_INFO_OFFSET(info,offsets,comp) \
-  (((offsets)[(info)->plane[comp]]) + (info)->poffset[comp])
-
-/* format properties */
-GstVideoFormat gst_video_format_from_masks           (gint depth, gint bpp, gint endianness,
-                                                      gint red_mask, gint green_mask,
-                                                      gint blue_mask, gint alpha_mask) G_GNUC_CONST;
-
-GstVideoFormat gst_video_format_from_fourcc          (guint32 fourcc) G_GNUC_CONST;
-GstVideoFormat gst_video_format_from_string          (const gchar *format) G_GNUC_CONST;
-
-guint32        gst_video_format_to_fourcc            (GstVideoFormat format) G_GNUC_CONST;
-const gchar *  gst_video_format_to_string            (GstVideoFormat format) G_GNUC_CONST;
-
-const GstVideoFormatInfo *
-               gst_video_format_get_info             (GstVideoFormat format) G_GNUC_CONST;
-
-typedef struct _GstVideoInfo GstVideoInfo;
-typedef struct _GstVideoFrame GstVideoFrame;
-
-/**
- * GstVideoInterlaceMode:
- * @GST_VIDEO_INTERLACE_MODE_PROGRESSIVE: all frames are progressive
- * @GST_VIDEO_INTERLACE_MODE_INTERLEAVED: 2 fields are interleaved in one video
- *     frame. Extra buffer flags describe the field order.
- * @GST_VIDEO_INTERLACE_MODE_MIXED: frames contains both interlaced and
- *     progressive video, the buffer flags describe the frame and fields.
- * @GST_VIDEO_INTERLACE_MODE_FIELDS: 2 fields are stored in one buffer, use the
- *     frame ID to get access to the required field. For multiview (the
- *     'views' property > 1) the fields of view N can be found at frame ID
- *     (N * 2) and (N * 2) + 1.
- *     Each field has only half the amount of lines as noted in the
- *     height property. This mode requires multiple GstVideoMeta metadata
- *     to describe the fields.
- *
- * The possible values of the #GstVideoInterlaceMode describing the interlace
- * mode of the stream.
- */
-typedef enum {
-  GST_VIDEO_INTERLACE_MODE_PROGRESSIVE = 0,
-  GST_VIDEO_INTERLACE_MODE_INTERLEAVED,
-  GST_VIDEO_INTERLACE_MODE_MIXED,
-  GST_VIDEO_INTERLACE_MODE_FIELDS
-} GstVideoInterlaceMode;
-
-/**
- * GstVideoFlags:
- * @GST_VIDEO_FLAG_NONE: no flags
- * @GST_VIDEO_FLAG_VARIABLE_FPS: a variable fps is selected, fps_n and fps_d
- * denote the maximum fps of the video
- *
- * Extra video flags
- */
-typedef enum {
-  GST_VIDEO_FLAG_NONE         = 0,
-  GST_VIDEO_FLAG_VARIABLE_FPS = (1 << 0)
-} GstVideoFlags;
-
-/**
- * GstVideoChroma:
- * @GST_VIDEO_CHROMA_SITE_UNKNOWN: unknown cositing
- * @GST_VIDEO_CHROMA_SITE_NONE: no cositing
- * @GST_VIDEO_CHROMA_SITE_H_COSITED: chroma is horizontally cosited
- * @GST_VIDEO_CHROMA_SITE_V_COSITED: chroma is vertically cosited
- * @GST_VIDEO_CHROMA_SITE_ALT_LINE: choma samples are sited on alternate lines
- * @GST_VIDEO_CHROMA_SITE_COSITED: chroma samples cosited with luma samples
- * @GST_VIDEO_CHROMA_SITE_JPEG: jpeg style cositing, also for mpeg1 and mjpeg
- * @GST_VIDEO_CHROMA_SITE_MPEG2: mpeg2 style cositing
- * @GST_VIDEO_CHROMA_SITE_DV: DV style cositing
- *
- * Various Chroma sitings.
- */
-typedef enum {
-  GST_VIDEO_CHROMA_SITE_UNKNOWN   =  0,
-  GST_VIDEO_CHROMA_SITE_NONE      = (1 << 0),
-  GST_VIDEO_CHROMA_SITE_H_COSITED = (1 << 1),
-  GST_VIDEO_CHROMA_SITE_V_COSITED = (1 << 2),
-  GST_VIDEO_CHROMA_SITE_ALT_LINE  = (1 << 3),
-  /* some common chroma cositing */
-  GST_VIDEO_CHROMA_SITE_COSITED   = (GST_VIDEO_CHROMA_SITE_H_COSITED | GST_VIDEO_CHROMA_SITE_V_COSITED),
-  GST_VIDEO_CHROMA_SITE_JPEG      = (GST_VIDEO_CHROMA_SITE_NONE),
-  GST_VIDEO_CHROMA_SITE_MPEG2     = (GST_VIDEO_CHROMA_SITE_H_COSITED),
-  GST_VIDEO_CHROMA_SITE_DV        = (GST_VIDEO_CHROMA_SITE_COSITED | GST_VIDEO_CHROMA_SITE_ALT_LINE),
-} GstVideoChromaSite;
-
-/**
- * GstVideoColorRange:
- * @GST_VIDEO_COLOR_RANGE_UNKNOWN: unknown range
- * @GST_VIDEO_COLOR_RANGE_0_255: [0..255] for 8 bit components
- * @GST_VIDEO_COLOR_RANGE_16_235: [16..235] for 8 bit components. Chroma has
- *                 [16..240] range.
- *
- * Possible color range values. These constants are defined for 8 bit color
- * values and can be scaled for other bit depths.
- */
-typedef enum {
-  GST_VIDEO_COLOR_RANGE_UNKNOWN = 0,
-  GST_VIDEO_COLOR_RANGE_0_255,
-  GST_VIDEO_COLOR_RANGE_16_235
-} GstVideoColorRange;
-
-/**
- * GstVideoColorMatrix:
- * @GST_VIDEO_COLOR_MATRIX_UNKNOWN: unknown matrix
- * @GST_VIDEO_COLOR_MATRIX_RGB: identity matrix
- * @GST_VIDEO_COLOR_MATRIX_FCC: FCC color matrix
- * @GST_VIDEO_COLOR_MATRIX_BT709: ITU-R BT.709 color matrix
- * @GST_VIDEO_COLOR_MATRIX_BT601: ITU-R BT.601 color matrix
- * @GST_VIDEO_COLOR_MATRIX_SMPTE240M: SMPTE 240M color matrix
- *
- * The color matrix is used to convert between Y'PbPr and
- * non-linear RGB (R'G'B')
- */
-typedef enum {
-  GST_VIDEO_COLOR_MATRIX_UNKNOWN = 0,
-  GST_VIDEO_COLOR_MATRIX_RGB,
-  GST_VIDEO_COLOR_MATRIX_FCC,
-  GST_VIDEO_COLOR_MATRIX_BT709,
-  GST_VIDEO_COLOR_MATRIX_BT601,
-  GST_VIDEO_COLOR_MATRIX_SMPTE240M
-} GstVideoColorMatrix;
-
-/**
- * GstVideoTransferFunction:
- * @GST_VIDEO_TRANSFER_UNKNOWN: unknown transfer function
- * @GST_VIDEO_TRANSFER_GAMMA10: linear RGB, gamma 1.0 curve
- * @GST_VIDEO_TRANSFER_GAMMA18: Gamma 1.8 curve
- * @GST_VIDEO_TRANSFER_GAMMA20: Gamma 2.0 curve
- * @GST_VIDEO_TRANSFER_GAMMA22: Gamma 2.2 curve
- * @GST_VIDEO_TRANSFER_BT709: Gamma 2.2 curve with a linear segment in the lower
- *                           range
- * @GST_VIDEO_TRANSFER_SMPTE240M: Gamma 2.2 curve with a linear segment in the
- *                               lower range
- * @GST_VIDEO_TRANSFER_SRGB: Gamma 2.4 curve with a linear segment in the lower
- *                          range
- * @GST_VIDEO_TRANSFER_GAMMA28: Gamma 2.8 curve
- * @GST_VIDEO_TRANSFER_LOG100: Logarithmic transfer characteristic
- *                             100:1 range
- * @GST_VIDEO_TRANSFER_LOG316: Logarithmic transfer characteristic
- *                             316.22777:1 range
- *
- * The video transfer function defines the formula for converting between
- * non-linear RGB (R'G'B') and linear RGB
- */
-typedef enum {
-  GST_VIDEO_TRANSFER_UNKNOWN = 0,
-  GST_VIDEO_TRANSFER_GAMMA10,
-  GST_VIDEO_TRANSFER_GAMMA18,
-  GST_VIDEO_TRANSFER_GAMMA20,
-  GST_VIDEO_TRANSFER_GAMMA22,
-  GST_VIDEO_TRANSFER_BT709,
-  GST_VIDEO_TRANSFER_SMPTE240M,
-  GST_VIDEO_TRANSFER_SRGB,
-  GST_VIDEO_TRANSFER_GAMMA28,
-  GST_VIDEO_TRANSFER_LOG100,
-  GST_VIDEO_TRANSFER_LOG316
-} GstVideoTransferFunction;
-
-/**
- * GstVideoColorPrimaries:
- * @GST_VIDEO_COLOR_PRIMARIES_UNKNOWN: unknown color primaries
- * @GST_VIDEO_COLOR_PRIMARIES_BT709: BT709 primaries
- * @GST_VIDEO_COLOR_PRIMARIES_BT470M: BT470M primaries
- * @GST_VIDEO_COLOR_PRIMARIES_BT470BG: BT470BG primaries
- * @GST_VIDEO_COLOR_PRIMARIES_SMPTE170M: SMPTE170M primaries
- * @GST_VIDEO_COLOR_PRIMARIES_SMPTE240M: SMPTE240M primaries
- *
- * The color primaries define the how to transform linear RGB values to and from
- * the CIE XYZ colorspace.
- */
-typedef enum {
-  GST_VIDEO_COLOR_PRIMARIES_UNKNOWN = 0,
-  GST_VIDEO_COLOR_PRIMARIES_BT709,
-  GST_VIDEO_COLOR_PRIMARIES_BT470M,
-  GST_VIDEO_COLOR_PRIMARIES_BT470BG,
-  GST_VIDEO_COLOR_PRIMARIES_SMPTE170M,
-  GST_VIDEO_COLOR_PRIMARIES_SMPTE240M
-} GstVideoColorPrimaries;
-
-/**
- * GstVideoColorimetry:
- * @range: the color range. This is the valid range for the samples.
- *         It is used to convert the samples to Y'PbPr values.
- * @matrix: the color matrix. Used to convert between Y'PbPr and
- *          non-linear RGB (R'G'B')
- * @transfer: the transfer function. used to convert between R'G'B' and RGB
- * @primaries: color primaries. used to convert between R'G'B' and CIE XYZ
- *
- * Structure describing the color info.
- */
-typedef struct {
-  GstVideoColorRange        range;
-  GstVideoColorMatrix       matrix;
-  GstVideoTransferFunction  transfer;
-  GstVideoColorPrimaries    primaries;
-} GstVideoColorimetry;
-
-/* predefined colorimetry */
-#define GST_VIDEO_COLORIMETRY_BT601       "bt601"
-#define GST_VIDEO_COLORIMETRY_BT709       "bt709"
-#define GST_VIDEO_COLORIMETRY_SMPTE240M   "smpte240m"
-
-gboolean     gst_video_colorimetry_matches     (GstVideoColorimetry *cinfo, const gchar *color);
-gboolean     gst_video_colorimetry_from_string (GstVideoColorimetry *cinfo, const gchar *color);
-gchar *      gst_video_colorimetry_to_string   (GstVideoColorimetry *cinfo);
-
-/**
- * GstVideoInfo:
- * @finfo: the format info of the video
- * @interlace_mode: the interlace mode
- * @flags: additional video flags
- * @width: the width of the video
- * @height: the height of the video
- * @views: the number of views for multiview video
- * @size: the default size of one frame
- * @chroma_site: a #GstVideoChromaSite.
- * @colorimetry: the colorimetry info
- * @palette: a buffer with palette data
- * @par_n: the pixel-aspect-ratio numerator
- * @par_d: the pixel-aspect-ratio demnominator
- * @fps_n: the framerate numerator
- * @fps_d: the framerate demnominator
- * @offset: offsets of the planes
- * @stride: strides of the planes
- *
- * Information describing image properties. This information can be filled
- * in from GstCaps with gst_video_info_from_caps(). The information is also used
- * to store the specific video info when mapping a video frame with
- * gst_video_frame_map().
- *
- * Use the provided macros to access the info in this structure.
- */
-struct _GstVideoInfo {
-  const GstVideoFormatInfo *finfo;
-
-  GstVideoInterlaceMode     interlace_mode;
-  GstVideoFlags             flags;
-  gint                      width;
-  gint                      height;
-  gsize                     size;
-  gint                      views;
-
-  GstVideoChromaSite        chroma_site;
-  GstVideoColorimetry       colorimetry;
-
-  GstBuffer                *palette;
-
-  gint                      par_n;
-  gint                      par_d;
-  gint                      fps_n;
-  gint                      fps_d;
-
-  gsize                     offset[GST_VIDEO_MAX_PLANES];
-  gint                      stride[GST_VIDEO_MAX_PLANES];
-};
-
-/* general info */
-#define GST_VIDEO_INFO_FORMAT(i)         (GST_VIDEO_FORMAT_INFO_FORMAT((i)->finfo))
-#define GST_VIDEO_INFO_NAME(i)           (GST_VIDEO_FORMAT_INFO_NAME((i)->finfo))
-#define GST_VIDEO_INFO_IS_YUV(i)         (GST_VIDEO_FORMAT_INFO_IS_YUV((i)->finfo))
-#define GST_VIDEO_INFO_IS_RGB(i)         (GST_VIDEO_FORMAT_INFO_IS_RGB((i)->finfo))
-#define GST_VIDEO_INFO_IS_GRAY(i)        (GST_VIDEO_FORMAT_INFO_IS_GRAY((i)->finfo))
-#define GST_VIDEO_INFO_HAS_ALPHA(i)      (GST_VIDEO_FORMAT_INFO_HAS_ALPHA((i)->finfo))
-
-#define GST_VIDEO_INFO_INTERLACE_MODE(i) ((i)->interlace_mode)
-#define GST_VIDEO_INFO_IS_INTERLACED(i)  ((i)->interlace_mode != GST_VIDEO_INTERLACE_MODE_PROGRESSIVE)
-#define GST_VIDEO_INFO_FLAGS(i)          ((i)->flags)
-#define GST_VIDEO_INFO_WIDTH(i)          ((i)->width)
-#define GST_VIDEO_INFO_HEIGHT(i)         ((i)->height)
-#define GST_VIDEO_INFO_SIZE(i)           ((i)->size)
-#define GST_VIDEO_INFO_VIEWS(i)          ((i)->views)
-#define GST_VIDEO_INFO_PAR_N(i)          ((i)->par_n)
-#define GST_VIDEO_INFO_PAR_D(i)          ((i)->par_d)
-#define GST_VIDEO_INFO_FPS_N(i)          ((i)->fps_n)
-#define GST_VIDEO_INFO_FPS_D(i)          ((i)->fps_d)
-
-/* dealing with GstVideoInfo flags */
-#define GST_VIDEO_INFO_FLAG_IS_SET(i,flag) ((GST_VIDEO_INFO_FLAGS(i) & (flag)) == (flag))
-#define GST_VIDEO_INFO_FLAG_SET(i,flag)    (GST_VIDEO_INFO_FLAGS(i) |= (flag))
-#define GST_VIDEO_INFO_FLAG_UNSET(i,flag)  (GST_VIDEO_INFO_FLAGS(i) &= ~(flag))
-
-/* dealing with planes */
-#define GST_VIDEO_INFO_N_PLANES(i)       (GST_VIDEO_FORMAT_INFO_N_PLANES((i)->finfo))
-#define GST_VIDEO_INFO_PLANE_OFFSET(i,p) ((i)->offset[p])
-#define GST_VIDEO_INFO_PLANE_STRIDE(i,p) ((i)->stride[p])
-
-/* dealing with components */
-#define GST_VIDEO_INFO_N_COMPONENTS(i)   GST_VIDEO_FORMAT_INFO_N_COMPONENTS((i)->finfo)
-#define GST_VIDEO_INFO_COMP_DEPTH(i,c)   GST_VIDEO_FORMAT_INFO_DEPTH((i)->finfo,(c))
-#define GST_VIDEO_INFO_COMP_DATA(i,d,c)  GST_VIDEO_FORMAT_INFO_DATA((i)->finfo,d,(c))
-#define GST_VIDEO_INFO_COMP_OFFSET(i,c)  GST_VIDEO_FORMAT_INFO_OFFSET((i)->finfo,(i)->offset,(c))
-#define GST_VIDEO_INFO_COMP_STRIDE(i,c)  GST_VIDEO_FORMAT_INFO_STRIDE((i)->finfo,(i)->stride,(c))
-#define GST_VIDEO_INFO_COMP_WIDTH(i,c)   GST_VIDEO_FORMAT_INFO_SCALE_WIDTH((i)->finfo,(c),(i)->width)
-#define GST_VIDEO_INFO_COMP_HEIGHT(i,c)  GST_VIDEO_FORMAT_INFO_SCALE_HEIGHT((i)->finfo,(c),(i)->height)
-#define GST_VIDEO_INFO_COMP_PLANE(i,c)   GST_VIDEO_FORMAT_INFO_PLANE((i)->finfo,(c))
-#define GST_VIDEO_INFO_COMP_PSTRIDE(i,c) GST_VIDEO_FORMAT_INFO_PSTRIDE((i)->finfo,(c))
-#define GST_VIDEO_INFO_COMP_POFFSET(i,c) GST_VIDEO_FORMAT_INFO_POFFSET((i)->finfo,(c))
-
-void         gst_video_info_init        (GstVideoInfo *info);
-
-void         gst_video_info_set_format  (GstVideoInfo *info, GstVideoFormat format,
-                                         guint width, guint height);
-
-gboolean     gst_video_info_from_caps   (GstVideoInfo *info, const GstCaps  * caps);
-
-GstCaps *    gst_video_info_to_caps     (GstVideoInfo *info);
-
-gboolean     gst_video_info_convert     (GstVideoInfo *info,
-                                         GstFormat     src_format,
-                                         gint64        src_value,
-                                         GstFormat     dest_format,
-                                         gint64       *dest_value);
-gboolean     gst_video_info_is_equal    (const GstVideoInfo *info,
-					 const GstVideoInfo *other);
-
-/**
- * GstVideoFrameFlags:
- * @GST_VIDEO_FRAME_FLAG_NONE: no flags
- * @GST_VIDEO_FRAME_FLAG_TFF: The video frame has the top field first
- * @GST_VIDEO_FRAME_FLAG_RFF: The video frame has the repeat flag
- * @GST_VIDEO_FRAME_FLAG_ONEFIELD: The video frame has one field
- *
- * Extra video frame flags
- */
-typedef enum {
-  GST_VIDEO_FRAME_FLAG_NONE         = 0,
-  GST_VIDEO_FRAME_FLAG_TFF          = (1 << 0),
-  GST_VIDEO_FRAME_FLAG_RFF          = (1 << 1),
-  GST_VIDEO_FRAME_FLAG_ONEFIELD     = (1 << 2)
-} GstVideoFrameFlags;
-
-/**
- * GstVideoFrame:
- * @info: the #GstVideoInfo
- * @buffer: the mapped buffer
- * @meta: pointer to metadata if any
- * @id: id of the mapped frame. the id can for example be used to
- *   indentify the frame in case of multiview video.
- * @data: pointers to the plane data
- * @map: mappings of the planes
- *
- * A video frame obtained from gst_video_frame_map()
- */
-struct _GstVideoFrame {
-  GstVideoInfo info;
-  GstVideoFrameFlags flags;
-
-  GstBuffer *buffer;
-  gpointer   meta;
-  gint       id;
-
-  gpointer   data[GST_VIDEO_MAX_PLANES];
-  GstMapInfo map[GST_VIDEO_MAX_PLANES];
-};
-
-gboolean    gst_video_frame_map           (GstVideoFrame *frame, GstVideoInfo *info,
-                                           GstBuffer *buffer, GstMapFlags flags);
-gboolean    gst_video_frame_map_id        (GstVideoFrame *frame, GstVideoInfo *info,
-                                           GstBuffer *buffer, gint id, GstMapFlags flags);
-void        gst_video_frame_unmap         (GstVideoFrame *frame);
-
-gboolean    gst_video_frame_copy          (GstVideoFrame *dest, const GstVideoFrame *src);
-gboolean    gst_video_frame_copy_plane    (GstVideoFrame *dest, const GstVideoFrame *src,
-                                           guint plane);
-
-/* general info */
-#define GST_VIDEO_FRAME_FORMAT(f)         (GST_VIDEO_INFO_FORMAT(&(f)->info))
-#define GST_VIDEO_FRAME_WIDTH(f)          (GST_VIDEO_INFO_WIDTH(&(f)->info))
-#define GST_VIDEO_FRAME_HEIGHT(f)         (GST_VIDEO_INFO_HEIGHT(&(f)->info))
-#define GST_VIDEO_FRAME_SIZE(f)           (GST_VIDEO_INFO_SIZE(&(f)->info))
-
-/* dealing with planes */
-#define GST_VIDEO_FRAME_N_PLANES(f)       (GST_VIDEO_INFO_N_PLANES(&(f)->info))
-#define GST_VIDEO_FRAME_PLANE_DATA(f,p)   ((f)->data[p])
-#define GST_VIDEO_FRAME_PLANE_OFFSET(f,p) (GST_VIDEO_INFO_PLANE_OFFSET(&(f)->info,(p)))
-#define GST_VIDEO_FRAME_PLANE_STRIDE(f,p) (GST_VIDEO_INFO_PLANE_STRIDE(&(f)->info,(p)))
-
-/* dealing with components */
-#define GST_VIDEO_FRAME_N_COMPONENTS(f)   GST_VIDEO_INFO_N_COMPONENTS(&(f)->info)
-#define GST_VIDEO_FRAME_COMP_DATA(f,c)    GST_VIDEO_INFO_COMP_DATA(&(f)->info,(f)->data,(c))
-#define GST_VIDEO_FRAME_COMP_STRIDE(f,c)  GST_VIDEO_INFO_COMP_STRIDE(&(f)->info,(c))
-#define GST_VIDEO_FRAME_COMP_OFFSET(f,c)  GST_VIDEO_INFO_COMP_OFFSET(&(f)->info,(c))
-#define GST_VIDEO_FRAME_COMP_WIDTH(f,c)   GST_VIDEO_INFO_COMP_WIDTH(&(f)->info,(c))
-#define GST_VIDEO_FRAME_COMP_HEIGHT(f,c)  GST_VIDEO_INFO_COMP_HEIGHT(&(f)->info,(c))
-#define GST_VIDEO_FRAME_COMP_PLANE(f,c)   GST_VIDEO_INFO_COMP_PLANE(&(f)->info,(c))
-#define GST_VIDEO_FRAME_COMP_PSTRIDE(f,c) GST_VIDEO_INFO_COMP_PSTRIDE(&(f)->info,(c))
-#define GST_VIDEO_FRAME_COMP_POFFSET(f,c) GST_VIDEO_INFO_COMP_POFFSET(&(f)->info,(c))
-
-#define GST_VIDEO_SIZE_RANGE "(int) [ 1, max ]"
-#define GST_VIDEO_FPS_RANGE "(fraction) [ 0, max ]"
-
-#if G_BYTE_ORDER == G_LITTLE_ENDIAN
-# define GST_VIDEO_NE(s) G_STRINGIFY(s)"_LE"
-# define GST_VIDEO_OE(s) G_STRINGIFY(s)"_BE"
-#else
-# define GST_VIDEO_NE(s) G_STRINGIFY(s)"_BE"
-# define GST_VIDEO_OE(s) G_STRINGIFY(s)"_LE"
-#endif
-
-#define GST_VIDEO_FORMATS_ALL "{ I420, YV12, YUY2, UYVY, AYUV, RGBx, "  \
-    "BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, "  \
-    "YVYU, Y444, v210, v216, NV12, NV21, GRAY8, GRAY16_BE, GRAY16_LE, " \
-    "v308, Y800, Y16, RGB16, BGR16, RGB15, BGR15, UYVP, A420, "         \
-    "RGB8_PALETTED, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210 }"
-
-/**
- * GST_VIDEO_CAPS_MAKE:
- * @format: string format that describes the pixel layout, as string
- *     (e.g. "I420", "RGB", "YV12", "YUY2", "AYUV", etc.)
- *
- * Generic caps string for video, for use in pad templates.
- */
-#define GST_VIDEO_CAPS_MAKE(format)                                     \
-    "video/x-raw, "                                                     \
-    "format = (string) " format ", "                                    \
-    "width = " GST_VIDEO_SIZE_RANGE ", "                                \
-    "height = " GST_VIDEO_SIZE_RANGE ", "                               \
-    "framerate = " GST_VIDEO_FPS_RANGE
-
-/* buffer flags */
-
-/**
- * GstVideoBufferFlags:
- * @GST_VIDEO_BUFFER_FLAG_TFF:         If the #GstBuffer is interlaced, then the first field
- *                                     in the video frame is the top field.  If unset, the
- *                                     bottom field is first.
- * @GST_VIDEO_BUFFER_FLAG_RFF:         If the #GstBuffer is interlaced, then the first field
- *                                     (as defined by the %GST_VIDEO_BUFFER_TFF flag setting)
- *                                     is repeated.
- * @GST_VIDEO_BUFFER_FLAG_ONEFIELD:    If the #GstBuffer is interlaced, then only the
- *                                     first field (as defined by the %GST_VIDEO_BUFFER_TFF
- *                                     flag setting) is to be displayed.
- *
- * Additional video buffer flags.
- */
-typedef enum {
-  GST_VIDEO_BUFFER_FLAG_TFF         = (GST_BUFFER_FLAG_LAST << 0),
-  GST_VIDEO_BUFFER_FLAG_RFF         = (GST_BUFFER_FLAG_LAST << 1),
-  GST_VIDEO_BUFFER_FLAG_ONEFIELD    = (GST_BUFFER_FLAG_LAST << 2),
-
-  GST_VIDEO_BUFFER_FLAG_LAST        = (GST_BUFFER_FLAG_LAST << 8)
-} GstVideoBufferFlags;
+G_BEGIN_DECLS
 
 /* some helper functions */
 gboolean       gst_video_calculate_display_ratio (guint * dar_n,
@@ -742,40 +40,6 @@
                                                   guint   display_par_n,
                                                   guint   display_par_d);
 
-GstBuffer *    gst_video_parse_caps_palette      (GstCaps * caps);
-
-/* video still frame event creation and parsing */
-
-GstEvent *     gst_video_event_new_still_frame   (gboolean in_still);
-
-gboolean       gst_video_event_parse_still_frame (GstEvent * event, gboolean * in_still);
-
-/* video force key unit event creation and parsing */
-
-GstEvent * gst_video_event_new_downstream_force_key_unit (GstClockTime timestamp,
-                                                          GstClockTime stream_time,
-                                                          GstClockTime running_time,
-                                                          gboolean all_headers,
-                                                          guint count);
-
-gboolean gst_video_event_parse_downstream_force_key_unit (GstEvent * event,
-                                                          GstClockTime * timestamp,
-                                                          GstClockTime * stream_time,
-                                                          GstClockTime * running_time,
-                                                          gboolean * all_headers,
-                                                          guint * count);
-
-GstEvent * gst_video_event_new_upstream_force_key_unit (GstClockTime running_time,
-                                                        gboolean all_headers,
-                                                        guint count);
-
-gboolean gst_video_event_parse_upstream_force_key_unit (GstEvent * event,
-                                                        GstClockTime * running_time,
-                                                        gboolean * all_headers,
-                                                        guint * count);
-
-gboolean gst_video_event_is_force_key_unit(GstEvent *event);
-
 /* convert/encode video sample from one format to another */
 
 typedef void (*GstVideoConvertSampleCallback) (GstSample * sample, GError *error, gpointer user_data);
diff --git a/gst-libs/gst/video/videoblendorc-dist.c b/gst-libs/gst/video/videoblendorc-dist.c
new file mode 100644
index 0000000..e80d543
--- /dev/null
+++ b/gst-libs/gst/video/videoblendorc-dist.c
@@ -0,0 +1,6251 @@
+
+/* autogenerated from videoblendorc.orc */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+#include <glib.h>
+
+#ifndef _ORC_INTEGER_TYPEDEFS_
+#define _ORC_INTEGER_TYPEDEFS_
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+#include <stdint.h>
+typedef int8_t orc_int8;
+typedef int16_t orc_int16;
+typedef int32_t orc_int32;
+typedef int64_t orc_int64;
+typedef uint8_t orc_uint8;
+typedef uint16_t orc_uint16;
+typedef uint32_t orc_uint32;
+typedef uint64_t orc_uint64;
+#define ORC_UINT64_C(x) UINT64_C(x)
+#elif defined(_MSC_VER)
+typedef signed __int8 orc_int8;
+typedef signed __int16 orc_int16;
+typedef signed __int32 orc_int32;
+typedef signed __int64 orc_int64;
+typedef unsigned __int8 orc_uint8;
+typedef unsigned __int16 orc_uint16;
+typedef unsigned __int32 orc_uint32;
+typedef unsigned __int64 orc_uint64;
+#define ORC_UINT64_C(x) (x##Ui64)
+#define inline __inline
+#else
+#include <limits.h>
+typedef signed char orc_int8;
+typedef short orc_int16;
+typedef int orc_int32;
+typedef unsigned char orc_uint8;
+typedef unsigned short orc_uint16;
+typedef unsigned int orc_uint32;
+#if INT_MAX == LONG_MAX
+typedef long long orc_int64;
+typedef unsigned long long orc_uint64;
+#define ORC_UINT64_C(x) (x##ULL)
+#else
+typedef long orc_int64;
+typedef unsigned long orc_uint64;
+#define ORC_UINT64_C(x) (x##UL)
+#endif
+#endif
+typedef union
+{
+  orc_int16 i;
+  orc_int8 x2[2];
+} orc_union16;
+typedef union
+{
+  orc_int32 i;
+  float f;
+  orc_int16 x2[2];
+  orc_int8 x4[4];
+} orc_union32;
+typedef union
+{
+  orc_int64 i;
+  double f;
+  orc_int32 x2[2];
+  float x2f[2];
+  orc_int16 x4[4];
+} orc_union64;
+#endif
+#ifndef ORC_RESTRICT
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+#define ORC_RESTRICT restrict
+#elif defined(__GNUC__) && __GNUC__ >= 4
+#define ORC_RESTRICT __restrict__
+#else
+#define ORC_RESTRICT
+#endif
+#endif
+
+#ifndef DISABLE_ORC
+#include <orc/orc.h>
+#endif
+void orc_blend_little (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_blend_big (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_I420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_pack_I420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_YUV9 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_unpack_Y42B (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_pack_Y42B (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_Y444 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_pack_Y444 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_pack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n);
+void orc_unpack_NV12 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, int n);
+void orc_pack_NV12 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_NV21 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, int n);
+void orc_pack_NV21 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_A420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3,
+    const guint8 * ORC_RESTRICT s4, int n);
+void orc_pack_A420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, guint8 * ORC_RESTRICT d4,
+    const guint8 * ORC_RESTRICT s1, int n);
+void orc_resample_bilinear_u32 (guint8 * ORC_RESTRICT d1,
+    const guint8 * ORC_RESTRICT s1, int p1, int p2, int n);
+void orc_merge_linear_u8 (orc_uint8 * ORC_RESTRICT d1,
+    const orc_uint8 * ORC_RESTRICT s1, const orc_uint8 * ORC_RESTRICT s2,
+    int p1, int n);
+
+
+/* begin Orc C target preamble */
+#define ORC_CLAMP(x,a,b) ((x)<(a) ? (a) : ((x)>(b) ? (b) : (x)))
+#define ORC_ABS(a) ((a)<0 ? -(a) : (a))
+#define ORC_MIN(a,b) ((a)<(b) ? (a) : (b))
+#define ORC_MAX(a,b) ((a)>(b) ? (a) : (b))
+#define ORC_SB_MAX 127
+#define ORC_SB_MIN (-1-ORC_SB_MAX)
+#define ORC_UB_MAX 255
+#define ORC_UB_MIN 0
+#define ORC_SW_MAX 32767
+#define ORC_SW_MIN (-1-ORC_SW_MAX)
+#define ORC_UW_MAX 65535
+#define ORC_UW_MIN 0
+#define ORC_SL_MAX 2147483647
+#define ORC_SL_MIN (-1-ORC_SL_MAX)
+#define ORC_UL_MAX 4294967295U
+#define ORC_UL_MIN 0
+#define ORC_CLAMP_SB(x) ORC_CLAMP(x,ORC_SB_MIN,ORC_SB_MAX)
+#define ORC_CLAMP_UB(x) ORC_CLAMP(x,ORC_UB_MIN,ORC_UB_MAX)
+#define ORC_CLAMP_SW(x) ORC_CLAMP(x,ORC_SW_MIN,ORC_SW_MAX)
+#define ORC_CLAMP_UW(x) ORC_CLAMP(x,ORC_UW_MIN,ORC_UW_MAX)
+#define ORC_CLAMP_SL(x) ORC_CLAMP(x,ORC_SL_MIN,ORC_SL_MAX)
+#define ORC_CLAMP_UL(x) ORC_CLAMP(x,ORC_UL_MIN,ORC_UL_MAX)
+#define ORC_SWAP_W(x) ((((x)&0xff)<<8) | (((x)&0xff00)>>8))
+#define ORC_SWAP_L(x) ((((x)&0xff)<<24) | (((x)&0xff00)<<8) | (((x)&0xff0000)>>8) | (((x)&0xff000000)>>24))
+#define ORC_SWAP_Q(x) ((((x)&ORC_UINT64_C(0xff))<<56) | (((x)&ORC_UINT64_C(0xff00))<<40) | (((x)&ORC_UINT64_C(0xff0000))<<24) | (((x)&ORC_UINT64_C(0xff000000))<<8) | (((x)&ORC_UINT64_C(0xff00000000))>>8) | (((x)&ORC_UINT64_C(0xff0000000000))>>24) | (((x)&ORC_UINT64_C(0xff000000000000))>>40) | (((x)&ORC_UINT64_C(0xff00000000000000))>>56))
+#define ORC_PTR_OFFSET(ptr,offset) ((void *)(((unsigned char *)(ptr)) + (offset)))
+#define ORC_DENORMAL(x) ((x) & ((((x)&0x7f800000) == 0) ? 0xff800000 : 0xffffffff))
+#define ORC_ISNAN(x) ((((x)&0x7f800000) == 0x7f800000) && (((x)&0x007fffff) != 0))
+#define ORC_DENORMAL_DOUBLE(x) ((x) & ((((x)&ORC_UINT64_C(0x7ff0000000000000)) == 0) ? ORC_UINT64_C(0xfff0000000000000) : ORC_UINT64_C(0xffffffffffffffff)))
+#define ORC_ISNAN_DOUBLE(x) ((((x)&ORC_UINT64_C(0x7ff0000000000000)) == ORC_UINT64_C(0x7ff0000000000000)) && (((x)&ORC_UINT64_C(0x000fffffffffffff)) != 0))
+#ifndef ORC_RESTRICT
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+#define ORC_RESTRICT restrict
+#elif defined(__GNUC__) && __GNUC__ >= 4
+#define ORC_RESTRICT __restrict__
+#else
+#define ORC_RESTRICT
+#endif
+#endif
+/* end Orc C target preamble */
+
+
+
+/* orc_blend_little */
+#ifdef DISABLE_ORC
+void
+orc_blend_little (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_int8 var42;
+  orc_union32 var43;
+  orc_union64 var44;
+  orc_union64 var45;
+  orc_union64 var46;
+  orc_union32 var47;
+  orc_union64 var48;
+  orc_union64 var49;
+  orc_union64 var50;
+  orc_union64 var51;
+  orc_union64 var52;
+  orc_union32 var53;
+  orc_union32 var54;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+  /* 14: loadpl */
+  var39.i = (int) 0x000000ff;   /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: convlw */
+    var41.i = var40.i;
+    /* 2: convwb */
+    var42 = var41.i;
+    /* 3: splatbl */
+    var43.i =
+        ((var42 & 0xff) << 24) | ((var42 & 0xff) << 16) | ((var42 & 0xff) << 8)
+        | (var42 & 0xff);
+    /* 4: convubw */
+    var44.x4[0] = (orc_uint8) var43.x4[0];
+    var44.x4[1] = (orc_uint8) var43.x4[1];
+    var44.x4[2] = (orc_uint8) var43.x4[2];
+    var44.x4[3] = (orc_uint8) var43.x4[3];
+    /* 5: shruw */
+    var45.x4[0] = ((orc_uint16) var44.x4[0]) >> 8;
+    var45.x4[1] = ((orc_uint16) var44.x4[1]) >> 8;
+    var45.x4[2] = ((orc_uint16) var44.x4[2]) >> 8;
+    var45.x4[3] = ((orc_uint16) var44.x4[3]) >> 8;
+    /* 6: convubw */
+    var46.x4[0] = (orc_uint8) var40.x4[0];
+    var46.x4[1] = (orc_uint8) var40.x4[1];
+    var46.x4[2] = (orc_uint8) var40.x4[2];
+    var46.x4[3] = (orc_uint8) var40.x4[3];
+    /* 7: loadl */
+    var47 = ptr0[i];
+    /* 8: convubw */
+    var48.x4[0] = (orc_uint8) var47.x4[0];
+    var48.x4[1] = (orc_uint8) var47.x4[1];
+    var48.x4[2] = (orc_uint8) var47.x4[2];
+    var48.x4[3] = (orc_uint8) var47.x4[3];
+    /* 9: subw */
+    var49.x4[0] = var46.x4[0] - var48.x4[0];
+    var49.x4[1] = var46.x4[1] - var48.x4[1];
+    var49.x4[2] = var46.x4[2] - var48.x4[2];
+    var49.x4[3] = var46.x4[3] - var48.x4[3];
+    /* 10: mullw */
+    var50.x4[0] = (var49.x4[0] * var45.x4[0]) & 0xffff;
+    var50.x4[1] = (var49.x4[1] * var45.x4[1]) & 0xffff;
+    var50.x4[2] = (var49.x4[2] * var45.x4[2]) & 0xffff;
+    var50.x4[3] = (var49.x4[3] * var45.x4[3]) & 0xffff;
+    /* 11: div255w */
+    var51.x4[0] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[0] + 128)) +
+            (((orc_uint16) (var50.x4[0] + 128)) >> 8))) >> 8;
+    var51.x4[1] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[1] + 128)) +
+            (((orc_uint16) (var50.x4[1] + 128)) >> 8))) >> 8;
+    var51.x4[2] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[2] + 128)) +
+            (((orc_uint16) (var50.x4[2] + 128)) >> 8))) >> 8;
+    var51.x4[3] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[3] + 128)) +
+            (((orc_uint16) (var50.x4[3] + 128)) >> 8))) >> 8;
+    /* 12: addw */
+    var52.x4[0] = var48.x4[0] + var51.x4[0];
+    var52.x4[1] = var48.x4[1] + var51.x4[1];
+    var52.x4[2] = var48.x4[2] + var51.x4[2];
+    var52.x4[3] = var48.x4[3] + var51.x4[3];
+    /* 13: convwb */
+    var53.x4[0] = var52.x4[0];
+    var53.x4[1] = var52.x4[1];
+    var53.x4[2] = var52.x4[2];
+    var53.x4[3] = var52.x4[3];
+    /* 15: orl */
+    var54.i = var53.i | var39.i;
+    /* 16: storel */
+    ptr0[i] = var54;
+  }
+
+}
+
+#else
+static void
+_backup_orc_blend_little (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_int8 var42;
+  orc_union32 var43;
+  orc_union64 var44;
+  orc_union64 var45;
+  orc_union64 var46;
+  orc_union32 var47;
+  orc_union64 var48;
+  orc_union64 var49;
+  orc_union64 var50;
+  orc_union64 var51;
+  orc_union64 var52;
+  orc_union32 var53;
+  orc_union32 var54;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+  /* 14: loadpl */
+  var39.i = (int) 0x000000ff;   /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: convlw */
+    var41.i = var40.i;
+    /* 2: convwb */
+    var42 = var41.i;
+    /* 3: splatbl */
+    var43.i =
+        ((var42 & 0xff) << 24) | ((var42 & 0xff) << 16) | ((var42 & 0xff) << 8)
+        | (var42 & 0xff);
+    /* 4: convubw */
+    var44.x4[0] = (orc_uint8) var43.x4[0];
+    var44.x4[1] = (orc_uint8) var43.x4[1];
+    var44.x4[2] = (orc_uint8) var43.x4[2];
+    var44.x4[3] = (orc_uint8) var43.x4[3];
+    /* 5: shruw */
+    var45.x4[0] = ((orc_uint16) var44.x4[0]) >> 8;
+    var45.x4[1] = ((orc_uint16) var44.x4[1]) >> 8;
+    var45.x4[2] = ((orc_uint16) var44.x4[2]) >> 8;
+    var45.x4[3] = ((orc_uint16) var44.x4[3]) >> 8;
+    /* 6: convubw */
+    var46.x4[0] = (orc_uint8) var40.x4[0];
+    var46.x4[1] = (orc_uint8) var40.x4[1];
+    var46.x4[2] = (orc_uint8) var40.x4[2];
+    var46.x4[3] = (orc_uint8) var40.x4[3];
+    /* 7: loadl */
+    var47 = ptr0[i];
+    /* 8: convubw */
+    var48.x4[0] = (orc_uint8) var47.x4[0];
+    var48.x4[1] = (orc_uint8) var47.x4[1];
+    var48.x4[2] = (orc_uint8) var47.x4[2];
+    var48.x4[3] = (orc_uint8) var47.x4[3];
+    /* 9: subw */
+    var49.x4[0] = var46.x4[0] - var48.x4[0];
+    var49.x4[1] = var46.x4[1] - var48.x4[1];
+    var49.x4[2] = var46.x4[2] - var48.x4[2];
+    var49.x4[3] = var46.x4[3] - var48.x4[3];
+    /* 10: mullw */
+    var50.x4[0] = (var49.x4[0] * var45.x4[0]) & 0xffff;
+    var50.x4[1] = (var49.x4[1] * var45.x4[1]) & 0xffff;
+    var50.x4[2] = (var49.x4[2] * var45.x4[2]) & 0xffff;
+    var50.x4[3] = (var49.x4[3] * var45.x4[3]) & 0xffff;
+    /* 11: div255w */
+    var51.x4[0] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[0] + 128)) +
+            (((orc_uint16) (var50.x4[0] + 128)) >> 8))) >> 8;
+    var51.x4[1] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[1] + 128)) +
+            (((orc_uint16) (var50.x4[1] + 128)) >> 8))) >> 8;
+    var51.x4[2] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[2] + 128)) +
+            (((orc_uint16) (var50.x4[2] + 128)) >> 8))) >> 8;
+    var51.x4[3] =
+        ((orc_uint16) (((orc_uint16) (var50.x4[3] + 128)) +
+            (((orc_uint16) (var50.x4[3] + 128)) >> 8))) >> 8;
+    /* 12: addw */
+    var52.x4[0] = var48.x4[0] + var51.x4[0];
+    var52.x4[1] = var48.x4[1] + var51.x4[1];
+    var52.x4[2] = var48.x4[2] + var51.x4[2];
+    var52.x4[3] = var48.x4[3] + var51.x4[3];
+    /* 13: convwb */
+    var53.x4[0] = var52.x4[0];
+    var53.x4[1] = var52.x4[1];
+    var53.x4[2] = var52.x4[2];
+    var53.x4[3] = var52.x4[3];
+    /* 15: orl */
+    var54.i = var53.i | var39.i;
+    /* 16: storel */
+    ptr0[i] = var54;
+  }
+
+}
+
+void
+orc_blend_little (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_blend_little");
+      orc_program_set_backup_function (p, _backup_orc_blend_little);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_constant (p, 4, 0x000000ff, "c1");
+      orc_program_add_constant (p, 4, 0x00000008, "c2");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+      orc_program_add_temporary (p, 8, "t5");
+      orc_program_add_temporary (p, 8, "t6");
+      orc_program_add_temporary (p, 8, "t7");
+
+      orc_program_append_2 (p, "loadl", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlw", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convwb", 0, ORC_VAR_T3, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splatbl", 0, ORC_VAR_T4, ORC_VAR_T3, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 2, ORC_VAR_T7, ORC_VAR_T4, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shruw", 2, ORC_VAR_T7, ORC_VAR_T7, ORC_VAR_C2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 2, ORC_VAR_T6, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "loadl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 2, ORC_VAR_T5, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "subw", 2, ORC_VAR_T6, ORC_VAR_T6, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mullw", 2, ORC_VAR_T6, ORC_VAR_T6, ORC_VAR_T7,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "div255w", 2, ORC_VAR_T6, ORC_VAR_T6, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "addw", 2, ORC_VAR_T5, ORC_VAR_T5, ORC_VAR_T6,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convwb", 2, ORC_VAR_T1, ORC_VAR_T5, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "orl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "storel", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_blend_big */
+#ifdef DISABLE_ORC
+void
+orc_blend_big (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union32 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_union32 var45;
+  orc_union64 var46;
+  orc_union64 var47;
+  orc_union64 var48;
+  orc_union32 var49;
+  orc_union64 var50;
+  orc_union64 var51;
+  orc_union64 var52;
+  orc_union64 var53;
+  orc_union64 var54;
+  orc_union32 var55;
+  orc_union32 var56;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+  /* 15: loadpl */
+  var40.i = (int) 0xff000000;   /* -16777216 or 2.11371e-314f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var41 = ptr4[i];
+    /* 1: shrul */
+    var42.i = ((orc_uint32) var41.i) >> 24;
+    /* 2: convlw */
+    var43.i = var42.i;
+    /* 3: convwb */
+    var44 = var43.i;
+    /* 4: splatbl */
+    var45.i =
+        ((var44 & 0xff) << 24) | ((var44 & 0xff) << 16) | ((var44 & 0xff) << 8)
+        | (var44 & 0xff);
+    /* 5: convubw */
+    var46.x4[0] = (orc_uint8) var45.x4[0];
+    var46.x4[1] = (orc_uint8) var45.x4[1];
+    var46.x4[2] = (orc_uint8) var45.x4[2];
+    var46.x4[3] = (orc_uint8) var45.x4[3];
+    /* 6: shruw */
+    var47.x4[0] = ((orc_uint16) var46.x4[0]) >> 8;
+    var47.x4[1] = ((orc_uint16) var46.x4[1]) >> 8;
+    var47.x4[2] = ((orc_uint16) var46.x4[2]) >> 8;
+    var47.x4[3] = ((orc_uint16) var46.x4[3]) >> 8;
+    /* 7: convubw */
+    var48.x4[0] = (orc_uint8) var41.x4[0];
+    var48.x4[1] = (orc_uint8) var41.x4[1];
+    var48.x4[2] = (orc_uint8) var41.x4[2];
+    var48.x4[3] = (orc_uint8) var41.x4[3];
+    /* 8: loadl */
+    var49 = ptr0[i];
+    /* 9: convubw */
+    var50.x4[0] = (orc_uint8) var49.x4[0];
+    var50.x4[1] = (orc_uint8) var49.x4[1];
+    var50.x4[2] = (orc_uint8) var49.x4[2];
+    var50.x4[3] = (orc_uint8) var49.x4[3];
+    /* 10: subw */
+    var51.x4[0] = var48.x4[0] - var50.x4[0];
+    var51.x4[1] = var48.x4[1] - var50.x4[1];
+    var51.x4[2] = var48.x4[2] - var50.x4[2];
+    var51.x4[3] = var48.x4[3] - var50.x4[3];
+    /* 11: mullw */
+    var52.x4[0] = (var51.x4[0] * var47.x4[0]) & 0xffff;
+    var52.x4[1] = (var51.x4[1] * var47.x4[1]) & 0xffff;
+    var52.x4[2] = (var51.x4[2] * var47.x4[2]) & 0xffff;
+    var52.x4[3] = (var51.x4[3] * var47.x4[3]) & 0xffff;
+    /* 12: div255w */
+    var53.x4[0] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[0] + 128)) +
+            (((orc_uint16) (var52.x4[0] + 128)) >> 8))) >> 8;
+    var53.x4[1] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[1] + 128)) +
+            (((orc_uint16) (var52.x4[1] + 128)) >> 8))) >> 8;
+    var53.x4[2] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[2] + 128)) +
+            (((orc_uint16) (var52.x4[2] + 128)) >> 8))) >> 8;
+    var53.x4[3] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[3] + 128)) +
+            (((orc_uint16) (var52.x4[3] + 128)) >> 8))) >> 8;
+    /* 13: addw */
+    var54.x4[0] = var50.x4[0] + var53.x4[0];
+    var54.x4[1] = var50.x4[1] + var53.x4[1];
+    var54.x4[2] = var50.x4[2] + var53.x4[2];
+    var54.x4[3] = var50.x4[3] + var53.x4[3];
+    /* 14: convwb */
+    var55.x4[0] = var54.x4[0];
+    var55.x4[1] = var54.x4[1];
+    var55.x4[2] = var54.x4[2];
+    var55.x4[3] = var54.x4[3];
+    /* 16: orl */
+    var56.i = var55.i | var40.i;
+    /* 17: storel */
+    ptr0[i] = var56;
+  }
+
+}
+
+#else
+static void
+_backup_orc_blend_big (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union32 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_union32 var45;
+  orc_union64 var46;
+  orc_union64 var47;
+  orc_union64 var48;
+  orc_union32 var49;
+  orc_union64 var50;
+  orc_union64 var51;
+  orc_union64 var52;
+  orc_union64 var53;
+  orc_union64 var54;
+  orc_union32 var55;
+  orc_union32 var56;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+  /* 15: loadpl */
+  var40.i = (int) 0xff000000;   /* -16777216 or 2.11371e-314f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var41 = ptr4[i];
+    /* 1: shrul */
+    var42.i = ((orc_uint32) var41.i) >> 24;
+    /* 2: convlw */
+    var43.i = var42.i;
+    /* 3: convwb */
+    var44 = var43.i;
+    /* 4: splatbl */
+    var45.i =
+        ((var44 & 0xff) << 24) | ((var44 & 0xff) << 16) | ((var44 & 0xff) << 8)
+        | (var44 & 0xff);
+    /* 5: convubw */
+    var46.x4[0] = (orc_uint8) var45.x4[0];
+    var46.x4[1] = (orc_uint8) var45.x4[1];
+    var46.x4[2] = (orc_uint8) var45.x4[2];
+    var46.x4[3] = (orc_uint8) var45.x4[3];
+    /* 6: shruw */
+    var47.x4[0] = ((orc_uint16) var46.x4[0]) >> 8;
+    var47.x4[1] = ((orc_uint16) var46.x4[1]) >> 8;
+    var47.x4[2] = ((orc_uint16) var46.x4[2]) >> 8;
+    var47.x4[3] = ((orc_uint16) var46.x4[3]) >> 8;
+    /* 7: convubw */
+    var48.x4[0] = (orc_uint8) var41.x4[0];
+    var48.x4[1] = (orc_uint8) var41.x4[1];
+    var48.x4[2] = (orc_uint8) var41.x4[2];
+    var48.x4[3] = (orc_uint8) var41.x4[3];
+    /* 8: loadl */
+    var49 = ptr0[i];
+    /* 9: convubw */
+    var50.x4[0] = (orc_uint8) var49.x4[0];
+    var50.x4[1] = (orc_uint8) var49.x4[1];
+    var50.x4[2] = (orc_uint8) var49.x4[2];
+    var50.x4[3] = (orc_uint8) var49.x4[3];
+    /* 10: subw */
+    var51.x4[0] = var48.x4[0] - var50.x4[0];
+    var51.x4[1] = var48.x4[1] - var50.x4[1];
+    var51.x4[2] = var48.x4[2] - var50.x4[2];
+    var51.x4[3] = var48.x4[3] - var50.x4[3];
+    /* 11: mullw */
+    var52.x4[0] = (var51.x4[0] * var47.x4[0]) & 0xffff;
+    var52.x4[1] = (var51.x4[1] * var47.x4[1]) & 0xffff;
+    var52.x4[2] = (var51.x4[2] * var47.x4[2]) & 0xffff;
+    var52.x4[3] = (var51.x4[3] * var47.x4[3]) & 0xffff;
+    /* 12: div255w */
+    var53.x4[0] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[0] + 128)) +
+            (((orc_uint16) (var52.x4[0] + 128)) >> 8))) >> 8;
+    var53.x4[1] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[1] + 128)) +
+            (((orc_uint16) (var52.x4[1] + 128)) >> 8))) >> 8;
+    var53.x4[2] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[2] + 128)) +
+            (((orc_uint16) (var52.x4[2] + 128)) >> 8))) >> 8;
+    var53.x4[3] =
+        ((orc_uint16) (((orc_uint16) (var52.x4[3] + 128)) +
+            (((orc_uint16) (var52.x4[3] + 128)) >> 8))) >> 8;
+    /* 13: addw */
+    var54.x4[0] = var50.x4[0] + var53.x4[0];
+    var54.x4[1] = var50.x4[1] + var53.x4[1];
+    var54.x4[2] = var50.x4[2] + var53.x4[2];
+    var54.x4[3] = var50.x4[3] + var53.x4[3];
+    /* 14: convwb */
+    var55.x4[0] = var54.x4[0];
+    var55.x4[1] = var54.x4[1];
+    var55.x4[2] = var54.x4[2];
+    var55.x4[3] = var54.x4[3];
+    /* 16: orl */
+    var56.i = var55.i | var40.i;
+    /* 17: storel */
+    ptr0[i] = var56;
+  }
+
+}
+
+void
+orc_blend_big (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_blend_big");
+      orc_program_set_backup_function (p, _backup_orc_blend_big);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_constant (p, 4, 0xff000000, "c1");
+      orc_program_add_constant (p, 4, 0x00000018, "c2");
+      orc_program_add_constant (p, 4, 0x00000008, "c3");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+      orc_program_add_temporary (p, 4, "t5");
+      orc_program_add_temporary (p, 8, "t6");
+      orc_program_add_temporary (p, 8, "t7");
+      orc_program_add_temporary (p, 8, "t8");
+
+      orc_program_append_2 (p, "loadl", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shrul", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_C2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convlw", 0, ORC_VAR_T3, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convwb", 0, ORC_VAR_T4, ORC_VAR_T3, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splatbl", 0, ORC_VAR_T5, ORC_VAR_T4, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 2, ORC_VAR_T8, ORC_VAR_T5, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "shruw", 2, ORC_VAR_T8, ORC_VAR_T8, ORC_VAR_C3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 2, ORC_VAR_T7, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "loadl", 0, ORC_VAR_T1, ORC_VAR_D1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 2, ORC_VAR_T6, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "subw", 2, ORC_VAR_T7, ORC_VAR_T7, ORC_VAR_T6,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mullw", 2, ORC_VAR_T7, ORC_VAR_T7, ORC_VAR_T8,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "div255w", 2, ORC_VAR_T7, ORC_VAR_T7, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "addw", 2, ORC_VAR_T6, ORC_VAR_T6, ORC_VAR_T7,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convwb", 2, ORC_VAR_T1, ORC_VAR_T6, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "orl", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "storel", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_I420 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_I420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union32 var38;
+  orc_int8 var39;
+  orc_int8 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_int8 *) s1;
+  ptr5 = (orc_int8 *) s2;
+  ptr6 = (orc_int8 *) s3;
+
+  /* 3: loadpb */
+  var36 = (int) 0x000000ff;     /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadupdb */
+    var39 = ptr5[i >> 1];
+    /* 1: loadupdb */
+    var40 = ptr6[i >> 1];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var39;
+      _dest.x2[1] = var40;
+      var41.i = _dest.i;
+    }
+    /* 4: loadb */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var42.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.i;
+      _dest.x2[1] = var41.i;
+      var38.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_I420 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union32 var38;
+  orc_int8 var39;
+  orc_int8 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_int8 *) ex->arrays[4];
+  ptr5 = (orc_int8 *) ex->arrays[5];
+  ptr6 = (orc_int8 *) ex->arrays[6];
+
+  /* 3: loadpb */
+  var36 = (int) 0x000000ff;     /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadupdb */
+    var39 = ptr5[i >> 1];
+    /* 1: loadupdb */
+    var40 = ptr6[i >> 1];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var39;
+      _dest.x2[1] = var40;
+      var41.i = _dest.i;
+    }
+    /* 4: loadb */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var42.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.i;
+      _dest.x2[1] = var41.i;
+      var38.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_I420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_I420");
+      orc_program_set_backup_function (p, _backup_orc_unpack_I420);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 1, "s1");
+      orc_program_add_source (p, 1, "s2");
+      orc_program_add_source (p, 1, "s3");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+
+      orc_program_append_2 (p, "loadupdb", 0, ORC_VAR_T3, ORC_VAR_S2,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "loadupdb", 0, ORC_VAR_T4, ORC_VAR_S3,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T2, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+  ex->arrays[ORC_VAR_S3] = (void *) s3;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_I420 */
+#ifdef DISABLE_ORC
+void
+orc_pack_I420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_int8 var40;
+  orc_int8 var41;
+  orc_union32 var42;
+  orc_union32 var43;
+  orc_union16 var44;
+  orc_union16 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_int8 var48;
+  orc_int8 var49;
+
+  ptr0 = (orc_union16 *) d1;
+  ptr1 = (orc_int8 *) d2;
+  ptr2 = (orc_int8 *) d3;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var38 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[0];
+      var42.x2[0] = _src.x2[1];
+      var43.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[1];
+      var42.x2[1] = _src.x2[1];
+      var43.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[0];
+      var39.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[1];
+      var39.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var39;
+    /* 4: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.x2[0];
+      var44.x2[0] = _src.x2[1];
+      var45.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var42.x2[1];
+      var44.x2[1] = _src.x2[1];
+      var45.x2[1] = _src.x2[0];
+    }
+    /* 5: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var45.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 6: avgub */
+    var40 = ((orc_uint8) var46 + (orc_uint8) var47 + 1) >> 1;
+    /* 7: storeb */
+    ptr1[i] = var40;
+    /* 8: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var44.i;
+      var48 = _src.x2[1];
+      var49 = _src.x2[0];
+    }
+    /* 9: avgub */
+    var41 = ((orc_uint8) var48 + (orc_uint8) var49 + 1) >> 1;
+    /* 10: storeb */
+    ptr2[i] = var41;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_I420 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_int8 var40;
+  orc_int8 var41;
+  orc_union32 var42;
+  orc_union32 var43;
+  orc_union16 var44;
+  orc_union16 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_int8 var48;
+  orc_int8 var49;
+
+  ptr0 = (orc_union16 *) ex->arrays[0];
+  ptr1 = (orc_int8 *) ex->arrays[1];
+  ptr2 = (orc_int8 *) ex->arrays[2];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var38 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[0];
+      var42.x2[0] = _src.x2[1];
+      var43.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[1];
+      var42.x2[1] = _src.x2[1];
+      var43.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[0];
+      var39.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[1];
+      var39.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var39;
+    /* 4: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.x2[0];
+      var44.x2[0] = _src.x2[1];
+      var45.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var42.x2[1];
+      var44.x2[1] = _src.x2[1];
+      var45.x2[1] = _src.x2[0];
+    }
+    /* 5: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var45.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 6: avgub */
+    var40 = ((orc_uint8) var46 + (orc_uint8) var47 + 1) >> 1;
+    /* 7: storeb */
+    ptr1[i] = var40;
+    /* 8: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var44.i;
+      var48 = _src.x2[1];
+      var49 = _src.x2[0];
+    }
+    /* 9: avgub */
+    var41 = ((orc_uint8) var48 + (orc_uint8) var49 + 1) >> 1;
+    /* 10: storeb */
+    ptr2[i] = var41;
+  }
+
+}
+
+void
+orc_pack_I420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_I420");
+      orc_program_set_backup_function (p, _backup_orc_pack_I420);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_destination (p, 1, "d2");
+      orc_program_add_destination (p, 1, "d3");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 2, "t4");
+      orc_program_add_temporary (p, 1, "t5");
+      orc_program_add_temporary (p, 1, "t6");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 1, ORC_VAR_T4, ORC_VAR_T3, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T5, ORC_VAR_T6, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D2, ORC_VAR_T5, ORC_VAR_T6,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T5, ORC_VAR_T6, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D3, ORC_VAR_T5, ORC_VAR_T6,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_D2] = d2;
+  ex->arrays[ORC_VAR_D3] = d3;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_YUY2 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_union32 var41;
+  orc_union32 var42;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+  /* 2: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var36 = ptr4[i];
+    /* 1: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 3: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var40.x2[0];
+      var41.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var40.x2[1];
+      var41.x2[1] = _dest.i;
+    }
+    /* 4: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var39.i;
+      _dest.x2[1] = var39.i;
+      var42.i = _dest.i;
+    }
+    /* 5: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[0];
+      _dest.x2[1] = var42.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[1];
+      _dest.x2[1] = var42.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_YUY2 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_union32 var41;
+  orc_union32 var42;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+  /* 2: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var36 = ptr4[i];
+    /* 1: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 3: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var40.x2[0];
+      var41.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var40.x2[1];
+      var41.x2[1] = _dest.i;
+    }
+    /* 4: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var39.i;
+      _dest.x2[1] = var39.i;
+      var42.i = _dest.i;
+    }
+    /* 5: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[0];
+      _dest.x2[1] = var42.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[1];
+      _dest.x2[1] = var42.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_YUY2");
+      orc_program_set_backup_function (p, _backup_orc_unpack_YUY2);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_constant (p, 2, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+
+      orc_program_append_2 (p, "splitwb", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T3, ORC_VAR_C1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_YUY2 */
+#ifdef DISABLE_ORC
+void
+orc_pack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union32 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var43.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var43.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 4: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var44.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var44.x2[1] = _src.x2[1];
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_YUY2 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union32 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var43.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var43.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 4: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var44.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var44.x2[1] = _src.x2[1];
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_pack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_YUY2");
+      orc_program_set_backup_function (p, _backup_orc_pack_YUY2);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+      orc_program_add_temporary (p, 4, "t5");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T5, ORC_VAR_T4, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T2, ORC_VAR_T3, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_T1, ORC_VAR_T4,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T2,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_UYVY */
+#ifdef DISABLE_ORC
+void
+orc_pack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union32 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var43.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var43.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 4: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var44.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var44.x2[1] = _src.x2[1];
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var43.x2[0];
+      _dest.x2[1] = var44.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var43.x2[1];
+      _dest.x2[1] = var44.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_UYVY (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union32 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var43.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var43.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 4: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var44.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var44.x2[1] = _src.x2[1];
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var43.x2[0];
+      _dest.x2[1] = var44.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var43.x2[1];
+      _dest.x2[1] = var44.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_pack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_UYVY");
+      orc_program_set_backup_function (p, _backup_orc_pack_UYVY);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+      orc_program_add_temporary (p, 4, "t5");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T5, ORC_VAR_T4, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T2, ORC_VAR_T3, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_T1, ORC_VAR_T4,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_UYVY */
+#ifdef DISABLE_ORC
+void
+orc_unpack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_union32 var41;
+  orc_union32 var42;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+  /* 2: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var36 = ptr4[i];
+    /* 1: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 3: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var39.x2[0];
+      var41.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var39.x2[1];
+      var41.x2[1] = _dest.i;
+    }
+    /* 4: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.i;
+      _dest.x2[1] = var40.i;
+      var42.i = _dest.i;
+    }
+    /* 5: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[0];
+      _dest.x2[1] = var42.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[1];
+      _dest.x2[1] = var42.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_UYVY (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_union32 var41;
+  orc_union32 var42;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+  /* 2: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var36 = ptr4[i];
+    /* 1: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 3: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var39.x2[0];
+      var41.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var39.x2[1];
+      var41.x2[1] = _dest.i;
+    }
+    /* 4: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.i;
+      _dest.x2[1] = var40.i;
+      var42.i = _dest.i;
+    }
+    /* 5: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[0];
+      _dest.x2[1] = var42.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[1];
+      _dest.x2[1] = var42.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 6: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_UYVY");
+      orc_program_set_backup_function (p, _backup_orc_unpack_UYVY);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_constant (p, 2, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+
+      orc_program_append_2 (p, "splitwb", 1, ORC_VAR_T1, ORC_VAR_T2, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T3, ORC_VAR_C1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_YVYU */
+#ifdef DISABLE_ORC
+void
+orc_unpack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_union16 var41;
+  orc_union32 var42;
+  orc_union32 var43;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+  /* 3: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var36 = ptr4[i];
+    /* 1: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: swapw */
+    var41.i = ORC_SWAP_W (var39.i);
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var40.x2[0];
+      var42.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var40.x2[1];
+      var42.x2[1] = _dest.i;
+    }
+    /* 5: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.i;
+      _dest.x2[1] = var41.i;
+      var43.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_YVYU (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_union16 var41;
+  orc_union32 var42;
+  orc_union32 var43;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+  /* 3: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var36 = ptr4[i];
+    /* 1: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: swapw */
+    var41.i = ORC_SWAP_W (var39.i);
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var40.x2[0];
+      var42.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var40.x2[1];
+      var42.x2[1] = _dest.i;
+    }
+    /* 5: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.i;
+      _dest.x2[1] = var41.i;
+      var43.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_YVYU");
+      orc_program_set_backup_function (p, _backup_orc_unpack_YVYU);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_constant (p, 2, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+
+      orc_program_append_2 (p, "splitwb", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "swapw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T3, ORC_VAR_C1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_YVYU */
+#ifdef DISABLE_ORC
+void
+orc_pack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union32 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+  orc_union16 var45;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var43.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var43.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 4: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var44.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var44.x2[1] = _src.x2[1];
+    }
+    /* 5: swapw */
+    var45.i = ORC_SWAP_W (var43.i);
+    /* 6: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[0];
+      _dest.x2[1] = var45.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[1];
+      _dest.x2[1] = var45.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_YVYU (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union32 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+  orc_union16 var45;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var43.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var43.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 4: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var44.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var44.x2[1] = _src.x2[1];
+    }
+    /* 5: swapw */
+    var45.i = ORC_SWAP_W (var43.i);
+    /* 6: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[0];
+      _dest.x2[1] = var45.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44.x2[1];
+      _dest.x2[1] = var45.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_pack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_YVYU");
+      orc_program_set_backup_function (p, _backup_orc_pack_YVYU);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+      orc_program_add_temporary (p, 4, "t5");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T5, ORC_VAR_T4, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T2, ORC_VAR_T3, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 1, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_T1, ORC_VAR_T4,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "swapw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T2,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_YUV9 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_YUV9 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_union16 var37;
+  orc_union16 var38;
+  orc_union64 var39;
+  orc_int8 var40;
+  orc_int8 var41;
+  orc_union16 var42;
+  orc_union32 var43;
+  orc_union32 var44;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union16 *) s1;
+  ptr5 = (orc_int8 *) s2;
+  ptr6 = (orc_int8 *) s3;
+
+  /* 4: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadupdb */
+    var40 = ptr5[i >> 1];
+    /* 1: loadupdb */
+    var41 = ptr6[i >> 1];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var40;
+      _dest.x2[1] = var41;
+      var42.i = _dest.i;
+    }
+    /* 3: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.i;
+      _dest.x2[1] = var42.i;
+      var43.i = _dest.i;
+    }
+    /* 5: loadw */
+    var38 = ptr4[i];
+    /* 6: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var38.x2[0];
+      var44.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var38.x2[1];
+      var44.x2[1] = _dest.i;
+    }
+    /* 7: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var44.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var39.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var44.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var39.x2[1] = _dest.i;
+    }
+    /* 8: storeq */
+    ptr0[i] = var39;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_YUV9 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_union16 var37;
+  orc_union16 var38;
+  orc_union64 var39;
+  orc_int8 var40;
+  orc_int8 var41;
+  orc_union16 var42;
+  orc_union32 var43;
+  orc_union32 var44;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union16 *) ex->arrays[4];
+  ptr5 = (orc_int8 *) ex->arrays[5];
+  ptr6 = (orc_int8 *) ex->arrays[6];
+
+  /* 4: loadpb */
+  var37.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var37.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadupdb */
+    var40 = ptr5[i >> 1];
+    /* 1: loadupdb */
+    var41 = ptr6[i >> 1];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var40;
+      _dest.x2[1] = var41;
+      var42.i = _dest.i;
+    }
+    /* 3: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.i;
+      _dest.x2[1] = var42.i;
+      var43.i = _dest.i;
+    }
+    /* 5: loadw */
+    var38 = ptr4[i];
+    /* 6: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[0];
+      _dest.x2[1] = var38.x2[0];
+      var44.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var37.x2[1];
+      _dest.x2[1] = var38.x2[1];
+      var44.x2[1] = _dest.i;
+    }
+    /* 7: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var44.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var39.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var44.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var39.x2[1] = _dest.i;
+    }
+    /* 8: storeq */
+    ptr0[i] = var39;
+  }
+
+}
+
+void
+orc_unpack_YUV9 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_YUV9");
+      orc_program_set_backup_function (p, _backup_orc_unpack_YUV9);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 2, "s1");
+      orc_program_add_source (p, 1, "s2");
+      orc_program_add_source (p, 1, "s3");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+      orc_program_add_temporary (p, 1, "t5");
+
+      orc_program_append_2 (p, "loadupdb", 0, ORC_VAR_T4, ORC_VAR_S2,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "loadupdb", 0, ORC_VAR_T5, ORC_VAR_S3,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_T4, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T2, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+  ex->arrays[ORC_VAR_S3] = (void *) s3;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_Y42B */
+#ifdef DISABLE_ORC
+void
+orc_unpack_Y42B (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+  orc_union64 var40;
+  orc_union16 var41;
+  orc_union32 var42;
+  orc_union32 var43;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union16 *) s1;
+  ptr5 = (orc_int8 *) s2;
+  ptr6 = (orc_int8 *) s3;
+
+  /* 3: loadpb */
+  var38.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var38.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadb */
+    var36 = ptr5[i];
+    /* 1: loadb */
+    var37 = ptr6[i];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var41.i = _dest.i;
+    }
+    /* 4: loadw */
+    var39 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var38.x2[0];
+      _dest.x2[1] = var39.x2[0];
+      var42.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var38.x2[1];
+      _dest.x2[1] = var39.x2[1];
+      var42.x2[1] = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.i;
+      _dest.x2[1] = var41.i;
+      var43.i = _dest.i;
+    }
+    /* 7: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var40.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var40.x2[1] = _dest.i;
+    }
+    /* 8: storeq */
+    ptr0[i] = var40;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_Y42B (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+  orc_union64 var40;
+  orc_union16 var41;
+  orc_union32 var42;
+  orc_union32 var43;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union16 *) ex->arrays[4];
+  ptr5 = (orc_int8 *) ex->arrays[5];
+  ptr6 = (orc_int8 *) ex->arrays[6];
+
+  /* 3: loadpb */
+  var38.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var38.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadb */
+    var36 = ptr5[i];
+    /* 1: loadb */
+    var37 = ptr6[i];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var41.i = _dest.i;
+    }
+    /* 4: loadw */
+    var39 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var38.x2[0];
+      _dest.x2[1] = var39.x2[0];
+      var42.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var38.x2[1];
+      _dest.x2[1] = var39.x2[1];
+      var42.x2[1] = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.i;
+      _dest.x2[1] = var41.i;
+      var43.i = _dest.i;
+    }
+    /* 7: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[0];
+      _dest.x2[1] = var43.x2[0];
+      var40.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.x2[1];
+      _dest.x2[1] = var43.x2[1];
+      var40.x2[1] = _dest.i;
+    }
+    /* 8: storeq */
+    ptr0[i] = var40;
+  }
+
+}
+
+void
+orc_unpack_Y42B (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_Y42B");
+      orc_program_set_backup_function (p, _backup_orc_unpack_Y42B);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 2, "s1");
+      orc_program_add_source (p, 1, "s2");
+      orc_program_add_source (p, 1, "s3");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+      orc_program_add_temporary (p, 4, "t4");
+
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_S2, ORC_VAR_S3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T4, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T4, ORC_VAR_T3,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+  ex->arrays[ORC_VAR_S3] = (void *) s3;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_Y42B */
+#ifdef DISABLE_ORC
+void
+orc_pack_Y42B (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var36;
+  orc_int8 var37;
+  orc_int8 var38;
+  orc_union16 var39;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union16 *) d1;
+  ptr1 = (orc_int8 *) d2;
+  ptr2 = (orc_int8 *) d3;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var36 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[0];
+      var40.x2[0] = _src.x2[1];
+      var41.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[1];
+      var40.x2[1] = _src.x2[1];
+      var41.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var44.x2[0] = ((orc_uint8) var42.x2[0] + (orc_uint8) var43.x2[0] + 1) >> 1;
+    var44.x2[1] = ((orc_uint8) var42.x2[1] + (orc_uint8) var43.x2[1] + 1) >> 1;
+    /* 4: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var44.i;
+      var37 = _src.x2[1];
+      var38 = _src.x2[0];
+    }
+    /* 5: storeb */
+    ptr2[i] = var37;
+    /* 6: storeb */
+    ptr1[i] = var38;
+    /* 7: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[0];
+      var39.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[1];
+      var39.x2[1] = _src.x2[1];
+    }
+    /* 8: storew */
+    ptr0[i] = var39;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_Y42B (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var36;
+  orc_int8 var37;
+  orc_int8 var38;
+  orc_union16 var39;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union16 *) ex->arrays[0];
+  ptr1 = (orc_int8 *) ex->arrays[1];
+  ptr2 = (orc_int8 *) ex->arrays[2];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var36 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[0];
+      var40.x2[0] = _src.x2[1];
+      var41.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[1];
+      var40.x2[1] = _src.x2[1];
+      var41.x2[1] = _src.x2[0];
+    }
+    /* 2: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 3: avgub */
+    var44.x2[0] = ((orc_uint8) var42.x2[0] + (orc_uint8) var43.x2[0] + 1) >> 1;
+    var44.x2[1] = ((orc_uint8) var42.x2[1] + (orc_uint8) var43.x2[1] + 1) >> 1;
+    /* 4: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var44.i;
+      var37 = _src.x2[1];
+      var38 = _src.x2[0];
+    }
+    /* 5: storeb */
+    ptr2[i] = var37;
+    /* 6: storeb */
+    ptr1[i] = var38;
+    /* 7: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[0];
+      var39.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[1];
+      var39.x2[1] = _src.x2[1];
+    }
+    /* 8: storew */
+    ptr0[i] = var39;
+  }
+
+}
+
+void
+orc_pack_Y42B (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_Y42B");
+      orc_program_set_backup_function (p, _backup_orc_pack_Y42B);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_destination (p, 1, "d2");
+      orc_program_add_destination (p, 1, "d3");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 2, "t4");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T3, ORC_VAR_T4, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 1, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_D3, ORC_VAR_D2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_D2] = d2;
+  ex->arrays[ORC_VAR_D3] = d3;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_Y444 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_Y444 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_int8 var34;
+  orc_int8 var35;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union32 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_int8 *) s1;
+  ptr5 = (orc_int8 *) s2;
+  ptr6 = (orc_int8 *) s3;
+
+  /* 3: loadpb */
+  var36 = (int) 0x000000ff;     /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadb */
+    var34 = ptr5[i];
+    /* 1: loadb */
+    var35 = ptr6[i];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var34;
+      _dest.x2[1] = var35;
+      var39.i = _dest.i;
+    }
+    /* 4: loadb */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var40.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.i;
+      _dest.x2[1] = var39.i;
+      var38.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_Y444 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  orc_int8 var34;
+  orc_int8 var35;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union32 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_int8 *) ex->arrays[4];
+  ptr5 = (orc_int8 *) ex->arrays[5];
+  ptr6 = (orc_int8 *) ex->arrays[6];
+
+  /* 3: loadpb */
+  var36 = (int) 0x000000ff;     /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadb */
+    var34 = ptr5[i];
+    /* 1: loadb */
+    var35 = ptr6[i];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var34;
+      _dest.x2[1] = var35;
+      var39.i = _dest.i;
+    }
+    /* 4: loadb */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var40.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.i;
+      _dest.x2[1] = var39.i;
+      var38.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_Y444 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_Y444");
+      orc_program_set_backup_function (p, _backup_orc_unpack_Y444);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 1, "s1");
+      orc_program_add_source (p, 1, "s2");
+      orc_program_add_source (p, 1, "s3");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_S2, ORC_VAR_S3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T2, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+  ex->arrays[ORC_VAR_S3] = (void *) s3;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_Y444 */
+#ifdef DISABLE_ORC
+void
+orc_pack_Y444 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_int8 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var34;
+  orc_int8 var35;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+
+  ptr0 = (orc_int8 *) d1;
+  ptr1 = (orc_int8 *) d2;
+  ptr2 = (orc_int8 *) d3;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var34 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var34.i;
+      var38.i = _src.x2[1];
+      var39.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var38.i;
+      var35 = _src.x2[1];
+      var36 = _src.x2[0];
+    }
+    /* 3: storeb */
+    ptr2[i] = var35;
+    /* 4: storeb */
+    ptr1[i] = var36;
+    /* 5: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var39.i;
+      var37 = _src.x2[1];
+    }
+    /* 6: storeb */
+    ptr0[i] = var37;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_Y444 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_int8 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var34;
+  orc_int8 var35;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+
+  ptr0 = (orc_int8 *) ex->arrays[0];
+  ptr1 = (orc_int8 *) ex->arrays[1];
+  ptr2 = (orc_int8 *) ex->arrays[2];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var34 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var34.i;
+      var38.i = _src.x2[1];
+      var39.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var38.i;
+      var35 = _src.x2[1];
+      var36 = _src.x2[0];
+    }
+    /* 3: storeb */
+    ptr2[i] = var35;
+    /* 4: storeb */
+    ptr1[i] = var36;
+    /* 5: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var39.i;
+      var37 = _src.x2[1];
+    }
+    /* 6: storeb */
+    ptr0[i] = var37;
+  }
+
+}
+
+void
+orc_pack_Y444 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_Y444");
+      orc_program_set_backup_function (p, _backup_orc_pack_Y444);
+      orc_program_add_destination (p, 1, "d1");
+      orc_program_add_destination (p, 1, "d2");
+      orc_program_add_destination (p, 1, "d3");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_D3, ORC_VAR_D2, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_D2] = d2;
+  ex->arrays[ORC_VAR_D3] = d3;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_GRAY8 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  orc_int8 var33;
+  orc_int8 var34;
+  orc_union16 var35;
+  orc_union32 var36;
+  orc_union16 var37;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_int8 *) s1;
+
+  /* 0: loadpb */
+  var33 = (int) 0x000000ff;     /* 255 or 1.25987e-321f */
+  /* 3: loadpw */
+  var35.i = (int) 0x00008080;   /* 32896 or 1.62528e-319f */
+
+  for (i = 0; i < n; i++) {
+    /* 1: loadb */
+    var34 = ptr4[i];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var33;
+      _dest.x2[1] = var34;
+      var37.i = _dest.i;
+    }
+    /* 4: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var37.i;
+      _dest.x2[1] = var35.i;
+      var36.i = _dest.i;
+    }
+    /* 5: storel */
+    ptr0[i] = var36;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_GRAY8 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  orc_int8 var33;
+  orc_int8 var34;
+  orc_union16 var35;
+  orc_union32 var36;
+  orc_union16 var37;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_int8 *) ex->arrays[4];
+
+  /* 0: loadpb */
+  var33 = (int) 0x000000ff;     /* 255 or 1.25987e-321f */
+  /* 3: loadpw */
+  var35.i = (int) 0x00008080;   /* 32896 or 1.62528e-319f */
+
+  for (i = 0; i < n; i++) {
+    /* 1: loadb */
+    var34 = ptr4[i];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var33;
+      _dest.x2[1] = var34;
+      var37.i = _dest.i;
+    }
+    /* 4: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var37.i;
+      _dest.x2[1] = var35.i;
+      var36.i = _dest.i;
+    }
+    /* 5: storel */
+    ptr0[i] = var36;
+  }
+
+}
+
+void
+orc_unpack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_GRAY8");
+      orc_program_set_backup_function (p, _backup_orc_unpack_GRAY8);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 1, "s1");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_constant (p, 2, 0x00008080, "c2");
+      orc_program_add_temporary (p, 2, "t1");
+
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_C2,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_GRAY8 */
+#ifdef DISABLE_ORC
+void
+orc_pack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_int8 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var33;
+  orc_int8 var34;
+  orc_union16 var35;
+
+  ptr0 = (orc_int8 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var33 = ptr4[i];
+    /* 1: select0lw */
+    {
+      orc_union32 _src;
+      _src.i = var33.i;
+      var35.i = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var35.i;
+      var34 = _src.x2[1];
+    }
+    /* 3: storeb */
+    ptr0[i] = var34;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_GRAY8 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_int8 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var33;
+  orc_int8 var34;
+  orc_union16 var35;
+
+  ptr0 = (orc_int8 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var33 = ptr4[i];
+    /* 1: select0lw */
+    {
+      orc_union32 _src;
+      _src.i = var33.i;
+      var35.i = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var35.i;
+      var34 = _src.x2[1];
+    }
+    /* 3: storeb */
+    ptr0[i] = var34;
+  }
+
+}
+
+void
+orc_pack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_GRAY8");
+      orc_program_set_backup_function (p, _backup_orc_pack_GRAY8);
+      orc_program_add_destination (p, 1, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_temporary (p, 2, "t1");
+
+      orc_program_append_2 (p, "select0lw", 0, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_BGRA */
+#ifdef DISABLE_ORC
+void
+orc_unpack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var32;
+  orc_union32 var33;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var32 = ptr4[i];
+    /* 1: swapl */
+    var33.i = ORC_SWAP_L (var32.i);
+    /* 2: storel */
+    ptr0[i] = var33;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_BGRA (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var32;
+  orc_union32 var33;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var32 = ptr4[i];
+    /* 1: swapl */
+    var33.i = ORC_SWAP_L (var32.i);
+    /* 2: storel */
+    ptr0[i] = var33;
+  }
+
+}
+
+void
+orc_unpack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_BGRA");
+      orc_program_set_backup_function (p, _backup_orc_unpack_BGRA);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+
+      orc_program_append_2 (p, "swapl", 0, ORC_VAR_D1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_BGRA */
+#ifdef DISABLE_ORC
+void
+orc_pack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var32;
+  orc_union32 var33;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var32 = ptr4[i];
+    /* 1: swapl */
+    var33.i = ORC_SWAP_L (var32.i);
+    /* 2: storel */
+    ptr0[i] = var33;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_BGRA (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var32;
+  orc_union32 var33;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var32 = ptr4[i];
+    /* 1: swapl */
+    var33.i = ORC_SWAP_L (var32.i);
+    /* 2: storel */
+    ptr0[i] = var33;
+  }
+
+}
+
+void
+orc_pack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_BGRA");
+      orc_program_set_backup_function (p, _backup_orc_pack_BGRA);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+
+      orc_program_append_2 (p, "swapl", 0, ORC_VAR_D1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_RGBA */
+#ifdef DISABLE_ORC
+void
+orc_pack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44;
+      _dest.x2[1] = var47;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var46;
+      _dest.x2[1] = var45;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var49.i;
+      _dest.x2[1] = var48.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_RGBA (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44;
+      _dest.x2[1] = var47;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var46;
+      _dest.x2[1] = var45;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var49.i;
+      _dest.x2[1] = var48.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+void
+orc_pack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_RGBA");
+      orc_program_set_backup_function (p, _backup_orc_pack_RGBA);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_temporary (p, 1, "t1");
+      orc_program_add_temporary (p, 1, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+      orc_program_add_temporary (p, 2, "t5");
+      orc_program_add_temporary (p, 2, "t6");
+      orc_program_add_temporary (p, 2, "t7");
+      orc_program_add_temporary (p, 2, "t8");
+
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T8, ORC_VAR_T7, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T4, ORC_VAR_T3, ORC_VAR_T8,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_T7,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T6, ORC_VAR_T4, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T5, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T5, ORC_VAR_T6,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_RGBA */
+#ifdef DISABLE_ORC
+void
+orc_unpack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var46;
+      _dest.x2[1] = var45;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44;
+      _dest.x2[1] = var47;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var48.i;
+      _dest.x2[1] = var49.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_RGBA (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var46;
+      _dest.x2[1] = var45;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var44;
+      _dest.x2[1] = var47;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var48.i;
+      _dest.x2[1] = var49.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+void
+orc_unpack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_RGBA");
+      orc_program_set_backup_function (p, _backup_orc_unpack_RGBA);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_temporary (p, 1, "t1");
+      orc_program_add_temporary (p, 1, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+      orc_program_add_temporary (p, 2, "t5");
+      orc_program_add_temporary (p, 2, "t6");
+      orc_program_add_temporary (p, 2, "t7");
+      orc_program_add_temporary (p, 2, "t8");
+
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T6, ORC_VAR_T5, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T3, ORC_VAR_T2, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T1, ORC_VAR_T4, ORC_VAR_T6,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T7, ORC_VAR_T1, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T8, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T7, ORC_VAR_T8,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_ABGR */
+#ifdef DISABLE_ORC
+void
+orc_unpack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var47;
+      _dest.x2[1] = var44;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var45;
+      _dest.x2[1] = var46;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var48.i;
+      _dest.x2[1] = var49.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_ABGR (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var47;
+      _dest.x2[1] = var44;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var45;
+      _dest.x2[1] = var46;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var48.i;
+      _dest.x2[1] = var49.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+void
+orc_unpack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_ABGR");
+      orc_program_set_backup_function (p, _backup_orc_unpack_ABGR);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_temporary (p, 1, "t1");
+      orc_program_add_temporary (p, 1, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+      orc_program_add_temporary (p, 2, "t5");
+      orc_program_add_temporary (p, 2, "t6");
+      orc_program_add_temporary (p, 2, "t7");
+      orc_program_add_temporary (p, 2, "t8");
+
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T5, ORC_VAR_T6, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T2, ORC_VAR_T3, ORC_VAR_T5,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T4, ORC_VAR_T1, ORC_VAR_T6,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T7, ORC_VAR_T1, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T8, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T7, ORC_VAR_T8,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_ABGR */
+#ifdef DISABLE_ORC
+void
+orc_pack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var47;
+      _dest.x2[1] = var44;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var45;
+      _dest.x2[1] = var46;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var48.i;
+      _dest.x2[1] = var49.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_ABGR (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_int8 var44;
+  orc_int8 var45;
+  orc_int8 var46;
+  orc_int8 var47;
+  orc_union16 var48;
+  orc_union16 var49;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadl */
+    var40 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 2: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var42.i;
+      var44 = _src.x2[1];
+      var45 = _src.x2[0];
+    }
+    /* 3: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.i;
+      var46 = _src.x2[1];
+      var47 = _src.x2[0];
+    }
+    /* 4: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var47;
+      _dest.x2[1] = var44;
+      var48.i = _dest.i;
+    }
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var45;
+      _dest.x2[1] = var46;
+      var49.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var48.i;
+      _dest.x2[1] = var49.i;
+      var41.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var41;
+  }
+
+}
+
+void
+orc_pack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_ABGR");
+      orc_program_set_backup_function (p, _backup_orc_pack_ABGR);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_temporary (p, 1, "t1");
+      orc_program_add_temporary (p, 1, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+      orc_program_add_temporary (p, 2, "t5");
+      orc_program_add_temporary (p, 2, "t6");
+      orc_program_add_temporary (p, 2, "t7");
+      orc_program_add_temporary (p, 2, "t8");
+
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T8, ORC_VAR_T7, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T4, ORC_VAR_T3, ORC_VAR_T8,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_T7,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T6, ORC_VAR_T1, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T5, ORC_VAR_T3, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T6, ORC_VAR_T5,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_NV12 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_NV12 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_union16 *ORC_RESTRICT ptr5;
+  orc_union16 var34;
+  orc_union16 var35;
+  orc_union16 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union16 *) s1;
+  ptr5 = (orc_union16 *) s2;
+
+  /* 3: loadpb */
+  var36.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var36.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadw */
+    var34 = ptr5[i];
+    /* 1: loadw */
+    var35 = ptr5[i];
+    /* 2: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var34.i;
+      _dest.x2[1] = var35.i;
+      var39.i = _dest.i;
+    }
+    /* 4: loadw */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[0];
+      _dest.x2[1] = var37.x2[0];
+      var40.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[1];
+      _dest.x2[1] = var37.x2[1];
+      var40.x2[1] = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.x2[0];
+      _dest.x2[1] = var39.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.x2[1];
+      _dest.x2[1] = var39.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_NV12 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_union16 *ORC_RESTRICT ptr5;
+  orc_union16 var34;
+  orc_union16 var35;
+  orc_union16 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union16 *) ex->arrays[4];
+  ptr5 = (orc_union16 *) ex->arrays[5];
+
+  /* 3: loadpb */
+  var36.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var36.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadw */
+    var34 = ptr5[i];
+    /* 1: loadw */
+    var35 = ptr5[i];
+    /* 2: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var34.i;
+      _dest.x2[1] = var35.i;
+      var39.i = _dest.i;
+    }
+    /* 4: loadw */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[0];
+      _dest.x2[1] = var37.x2[0];
+      var40.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[1];
+      _dest.x2[1] = var37.x2[1];
+      var40.x2[1] = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.x2[0];
+      _dest.x2[1] = var39.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var40.x2[1];
+      _dest.x2[1] = var39.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_NV12 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_NV12");
+      orc_program_set_backup_function (p, _backup_orc_unpack_NV12);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 2, "s1");
+      orc_program_add_source (p, 2, "s2");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_S2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T1, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T2,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_NV12 */
+#ifdef DISABLE_ORC
+void
+orc_pack_NV12 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_union16 *ORC_RESTRICT ptr1;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var36;
+  orc_union16 var37;
+  orc_union16 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+
+  ptr0 = (orc_union16 *) d1;
+  ptr1 = (orc_union16 *) d2;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var36 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var37.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var37.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var37;
+    /* 4: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 5: avgub */
+    var38.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var38.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 6: storew */
+    ptr1[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_NV12 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_union16 *ORC_RESTRICT ptr1;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var36;
+  orc_union16 var37;
+  orc_union16 var38;
+  orc_union32 var39;
+  orc_union32 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+
+  ptr0 = (orc_union16 *) ex->arrays[0];
+  ptr1 = (orc_union16 *) ex->arrays[1];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var36 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[0];
+      var39.x2[0] = _src.x2[1];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var36.x2[1];
+      var39.x2[1] = _src.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[0];
+      var37.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var40.x2[1];
+      var37.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var37;
+    /* 4: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var39.i;
+      var41.i = _src.x2[1];
+      var42.i = _src.x2[0];
+    }
+    /* 5: avgub */
+    var38.x2[0] = ((orc_uint8) var41.x2[0] + (orc_uint8) var42.x2[0] + 1) >> 1;
+    var38.x2[1] = ((orc_uint8) var41.x2[1] + (orc_uint8) var42.x2[1] + 1) >> 1;
+    /* 6: storew */
+    ptr1[i] = var38;
+  }
+
+}
+
+void
+orc_pack_NV12 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_NV12");
+      orc_program_set_backup_function (p, _backup_orc_pack_NV12);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_destination (p, 2, "d2");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 2, "t4");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T3, ORC_VAR_T4, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 1, ORC_VAR_D2, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_D2] = d2;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_NV21 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_NV21 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, int n)
+{
+  int i;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_union16 *ORC_RESTRICT ptr5;
+  orc_union16 var35;
+  orc_union16 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union32 var40;
+  orc_union32 var41;
+
+  ptr0 = (orc_union64 *) d1;
+  ptr4 = (orc_union16 *) s1;
+  ptr5 = (orc_union16 *) s2;
+
+  /* 3: loadpb */
+  var36.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var36.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadw */
+    var35 = ptr5[i];
+    /* 1: swapw */
+    var39.i = ORC_SWAP_W (var35.i);
+    /* 2: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var39.i;
+      _dest.x2[1] = var39.i;
+      var40.i = _dest.i;
+    }
+    /* 4: loadw */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[0];
+      _dest.x2[1] = var37.x2[0];
+      var41.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[1];
+      _dest.x2[1] = var37.x2[1];
+      var41.x2[1] = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[0];
+      _dest.x2[1] = var40.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[1];
+      _dest.x2[1] = var40.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_NV21 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union64 *ORC_RESTRICT ptr0;
+  const orc_union16 *ORC_RESTRICT ptr4;
+  const orc_union16 *ORC_RESTRICT ptr5;
+  orc_union16 var35;
+  orc_union16 var36;
+  orc_union16 var37;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union32 var40;
+  orc_union32 var41;
+
+  ptr0 = (orc_union64 *) ex->arrays[0];
+  ptr4 = (orc_union16 *) ex->arrays[4];
+  ptr5 = (orc_union16 *) ex->arrays[5];
+
+  /* 3: loadpb */
+  var36.x2[0] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+  var36.x2[1] = (int) 0x000000ff;       /* 255 or 1.25987e-321f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadw */
+    var35 = ptr5[i];
+    /* 1: swapw */
+    var39.i = ORC_SWAP_W (var35.i);
+    /* 2: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var39.i;
+      _dest.x2[1] = var39.i;
+      var40.i = _dest.i;
+    }
+    /* 4: loadw */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[0];
+      _dest.x2[1] = var37.x2[0];
+      var41.x2[0] = _dest.i;
+    }
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36.x2[1];
+      _dest.x2[1] = var37.x2[1];
+      var41.x2[1] = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[0];
+      _dest.x2[1] = var40.x2[0];
+      var38.x2[0] = _dest.i;
+    }
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var41.x2[1];
+      _dest.x2[1] = var40.x2[1];
+      var38.x2[1] = _dest.i;
+    }
+    /* 7: storeq */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_NV21 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_NV21");
+      orc_program_set_backup_function (p, _backup_orc_unpack_NV21);
+      orc_program_add_destination (p, 8, "d1");
+      orc_program_add_source (p, 2, "s1");
+      orc_program_add_source (p, 2, "s2");
+      orc_program_add_constant (p, 1, 0x000000ff, "c1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 4, "t3");
+
+      orc_program_append_2 (p, "swapw", 0, ORC_VAR_T1, ORC_VAR_S2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 1, ORC_VAR_T2, ORC_VAR_C1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 1, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T3,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_NV21 */
+#ifdef DISABLE_ORC
+void
+orc_pack_NV21 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_union16 *ORC_RESTRICT ptr1;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union16 *) d1;
+  ptr1 = (orc_union16 *) d2;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var40.x2[0] = _src.x2[1];
+      var41.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var40.x2[1] = _src.x2[1];
+      var41.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[0];
+      var38.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[1];
+      var38.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var38;
+    /* 4: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 5: avgub */
+    var44.x2[0] = ((orc_uint8) var42.x2[0] + (orc_uint8) var43.x2[0] + 1) >> 1;
+    var44.x2[1] = ((orc_uint8) var42.x2[1] + (orc_uint8) var43.x2[1] + 1) >> 1;
+    /* 6: swapw */
+    var39.i = ORC_SWAP_W (var44.i);
+    /* 7: storew */
+    ptr1[i] = var39;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_NV21 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_union16 *ORC_RESTRICT ptr1;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+  orc_union32 var40;
+  orc_union32 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+
+  ptr0 = (orc_union16 *) ex->arrays[0];
+  ptr1 = (orc_union16 *) ex->arrays[1];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var37 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[0];
+      var40.x2[0] = _src.x2[1];
+      var41.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var37.x2[1];
+      var40.x2[1] = _src.x2[1];
+      var41.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[0];
+      var38.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var41.x2[1];
+      var38.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var38;
+    /* 4: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var40.i;
+      var42.i = _src.x2[1];
+      var43.i = _src.x2[0];
+    }
+    /* 5: avgub */
+    var44.x2[0] = ((orc_uint8) var42.x2[0] + (orc_uint8) var43.x2[0] + 1) >> 1;
+    var44.x2[1] = ((orc_uint8) var42.x2[1] + (orc_uint8) var43.x2[1] + 1) >> 1;
+    /* 6: swapw */
+    var39.i = ORC_SWAP_W (var44.i);
+    /* 7: storew */
+    ptr1[i] = var39;
+  }
+
+}
+
+void
+orc_pack_NV21 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_NV21");
+      orc_program_set_backup_function (p, _backup_orc_pack_NV21);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_destination (p, 2, "d2");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 2, "t4");
+      orc_program_add_temporary (p, 2, "t5");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "splitlw", 0, ORC_VAR_T3, ORC_VAR_T4, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 1, ORC_VAR_T5, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "swapw", 0, ORC_VAR_D2, ORC_VAR_T5, ORC_VAR_D1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_D2] = d2;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_unpack_A420 */
+#ifdef DISABLE_ORC
+void
+orc_unpack_A420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3,
+    const guint8 * ORC_RESTRICT s4, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  const orc_int8 *ORC_RESTRICT ptr7;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union32 var38;
+  orc_int8 var39;
+  orc_int8 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_int8 *) s1;
+  ptr5 = (orc_int8 *) s2;
+  ptr6 = (orc_int8 *) s3;
+  ptr7 = (orc_int8 *) s4;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadupdb */
+    var39 = ptr5[i >> 1];
+    /* 1: loadupdb */
+    var40 = ptr6[i >> 1];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var39;
+      _dest.x2[1] = var40;
+      var41.i = _dest.i;
+    }
+    /* 3: loadb */
+    var36 = ptr7[i];
+    /* 4: loadb */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var42.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.i;
+      _dest.x2[1] = var41.i;
+      var38.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+#else
+static void
+_backup_orc_unpack_A420 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  const orc_int8 *ORC_RESTRICT ptr6;
+  const orc_int8 *ORC_RESTRICT ptr7;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union32 var38;
+  orc_int8 var39;
+  orc_int8 var40;
+  orc_union16 var41;
+  orc_union16 var42;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_int8 *) ex->arrays[4];
+  ptr5 = (orc_int8 *) ex->arrays[5];
+  ptr6 = (orc_int8 *) ex->arrays[6];
+  ptr7 = (orc_int8 *) ex->arrays[7];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadupdb */
+    var39 = ptr5[i >> 1];
+    /* 1: loadupdb */
+    var40 = ptr6[i >> 1];
+    /* 2: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var39;
+      _dest.x2[1] = var40;
+      var41.i = _dest.i;
+    }
+    /* 3: loadb */
+    var36 = ptr7[i];
+    /* 4: loadb */
+    var37 = ptr4[i];
+    /* 5: mergebw */
+    {
+      orc_union16 _dest;
+      _dest.x2[0] = var36;
+      _dest.x2[1] = var37;
+      var42.i = _dest.i;
+    }
+    /* 6: mergewl */
+    {
+      orc_union32 _dest;
+      _dest.x2[0] = var42.i;
+      _dest.x2[1] = var41.i;
+      var38.i = _dest.i;
+    }
+    /* 7: storel */
+    ptr0[i] = var38;
+  }
+
+}
+
+void
+orc_unpack_A420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
+    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3,
+    const guint8 * ORC_RESTRICT s4, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_unpack_A420");
+      orc_program_set_backup_function (p, _backup_orc_unpack_A420);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 1, "s1");
+      orc_program_add_source (p, 1, "s2");
+      orc_program_add_source (p, 1, "s3");
+      orc_program_add_source (p, 1, "s4");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+
+      orc_program_append_2 (p, "loadupdb", 0, ORC_VAR_T3, ORC_VAR_S2,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "loadupdb", 0, ORC_VAR_T4, ORC_VAR_S3,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_T3, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T2, ORC_VAR_S4, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T1,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+  ex->arrays[ORC_VAR_S3] = (void *) s3;
+  ex->arrays[ORC_VAR_S4] = (void *) s4;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_pack_A420 */
+#ifdef DISABLE_ORC
+void
+orc_pack_A420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, guint8 * ORC_RESTRICT d4,
+    const guint8 * ORC_RESTRICT s1, int n)
+{
+  int i;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  orc_union16 *ORC_RESTRICT ptr3;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_int8 var41;
+  orc_int8 var42;
+  orc_union32 var43;
+  orc_union32 var44;
+  orc_union16 var45;
+  orc_union16 var46;
+  orc_int8 var47;
+  orc_int8 var48;
+  orc_int8 var49;
+  orc_int8 var50;
+
+  ptr0 = (orc_union16 *) d1;
+  ptr1 = (orc_int8 *) d2;
+  ptr2 = (orc_int8 *) d3;
+  ptr3 = (orc_union16 *) d4;
+  ptr4 = (orc_union64 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var38 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[0];
+      var43.x2[0] = _src.x2[1];
+      var44.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[1];
+      var43.x2[1] = _src.x2[1];
+      var44.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[0];
+      var39.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[1];
+      var39.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var39;
+    /* 4: select0wb */
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[0];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 5: storew */
+    ptr3[i] = var40;
+    /* 6: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[0];
+      var45.x2[0] = _src.x2[1];
+      var46.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[1];
+      var45.x2[1] = _src.x2[1];
+      var46.x2[1] = _src.x2[0];
+    }
+    /* 7: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var46.i;
+      var47 = _src.x2[1];
+      var48 = _src.x2[0];
+    }
+    /* 8: avgub */
+    var41 = ((orc_uint8) var47 + (orc_uint8) var48 + 1) >> 1;
+    /* 9: storeb */
+    ptr1[i] = var41;
+    /* 10: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var45.i;
+      var49 = _src.x2[1];
+      var50 = _src.x2[0];
+    }
+    /* 11: avgub */
+    var42 = ((orc_uint8) var49 + (orc_uint8) var50 + 1) >> 1;
+    /* 12: storeb */
+    ptr2[i] = var42;
+  }
+
+}
+
+#else
+static void
+_backup_orc_pack_A420 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union16 *ORC_RESTRICT ptr0;
+  orc_int8 *ORC_RESTRICT ptr1;
+  orc_int8 *ORC_RESTRICT ptr2;
+  orc_union16 *ORC_RESTRICT ptr3;
+  const orc_union64 *ORC_RESTRICT ptr4;
+  orc_union64 var38;
+  orc_union16 var39;
+  orc_union16 var40;
+  orc_int8 var41;
+  orc_int8 var42;
+  orc_union32 var43;
+  orc_union32 var44;
+  orc_union16 var45;
+  orc_union16 var46;
+  orc_int8 var47;
+  orc_int8 var48;
+  orc_int8 var49;
+  orc_int8 var50;
+
+  ptr0 = (orc_union16 *) ex->arrays[0];
+  ptr1 = (orc_int8 *) ex->arrays[1];
+  ptr2 = (orc_int8 *) ex->arrays[2];
+  ptr3 = (orc_union16 *) ex->arrays[3];
+  ptr4 = (orc_union64 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadq */
+    var38 = ptr4[i];
+    /* 1: splitlw */
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[0];
+      var43.x2[0] = _src.x2[1];
+      var44.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union32 _src;
+      _src.i = var38.x2[1];
+      var43.x2[1] = _src.x2[1];
+      var44.x2[1] = _src.x2[0];
+    }
+    /* 2: select1wb */
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[0];
+      var39.x2[0] = _src.x2[1];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[1];
+      var39.x2[1] = _src.x2[1];
+    }
+    /* 3: storew */
+    ptr0[i] = var39;
+    /* 4: select0wb */
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[0];
+      var40.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var44.x2[1];
+      var40.x2[1] = _src.x2[0];
+    }
+    /* 5: storew */
+    ptr3[i] = var40;
+    /* 6: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[0];
+      var45.x2[0] = _src.x2[1];
+      var46.x2[0] = _src.x2[0];
+    }
+    {
+      orc_union16 _src;
+      _src.i = var43.x2[1];
+      var45.x2[1] = _src.x2[1];
+      var46.x2[1] = _src.x2[0];
+    }
+    /* 7: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var46.i;
+      var47 = _src.x2[1];
+      var48 = _src.x2[0];
+    }
+    /* 8: avgub */
+    var41 = ((orc_uint8) var47 + (orc_uint8) var48 + 1) >> 1;
+    /* 9: storeb */
+    ptr1[i] = var41;
+    /* 10: splitwb */
+    {
+      orc_union16 _src;
+      _src.i = var45.i;
+      var49 = _src.x2[1];
+      var50 = _src.x2[0];
+    }
+    /* 11: avgub */
+    var42 = ((orc_uint8) var49 + (orc_uint8) var50 + 1) >> 1;
+    /* 12: storeb */
+    ptr2[i] = var42;
+  }
+
+}
+
+void
+orc_pack_A420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2,
+    guint8 * ORC_RESTRICT d3, guint8 * ORC_RESTRICT d4,
+    const guint8 * ORC_RESTRICT s1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_pack_A420");
+      orc_program_set_backup_function (p, _backup_orc_pack_A420);
+      orc_program_add_destination (p, 2, "d1");
+      orc_program_add_destination (p, 1, "d2");
+      orc_program_add_destination (p, 1, "d3");
+      orc_program_add_destination (p, 2, "d4");
+      orc_program_add_source (p, 8, "s1");
+      orc_program_add_temporary (p, 4, "t1");
+      orc_program_add_temporary (p, 4, "t2");
+      orc_program_add_temporary (p, 2, "t3");
+      orc_program_add_temporary (p, 2, "t4");
+      orc_program_add_temporary (p, 1, "t5");
+      orc_program_add_temporary (p, 1, "t6");
+
+      orc_program_append_2 (p, "splitlw", 1, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "select1wb", 1, ORC_VAR_D1, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "select0wb", 1, ORC_VAR_D4, ORC_VAR_T1,
+          ORC_VAR_D1, ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 1, ORC_VAR_T4, ORC_VAR_T3, ORC_VAR_T2,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T5, ORC_VAR_T6, ORC_VAR_T3,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D2, ORC_VAR_T5, ORC_VAR_T6,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "splitwb", 0, ORC_VAR_T5, ORC_VAR_T6, ORC_VAR_T4,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D3, ORC_VAR_T5, ORC_VAR_T6,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_D2] = d2;
+  ex->arrays[ORC_VAR_D3] = d3;
+  ex->arrays[ORC_VAR_D4] = d4;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_resample_bilinear_u32 */
+#ifdef DISABLE_ORC
+void
+orc_resample_bilinear_u32 (guint8 * ORC_RESTRICT d1,
+    const guint8 * ORC_RESTRICT s1, int p1, int p2, int n)
+{
+  int i;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var32;
+
+  ptr0 = (orc_union32 *) d1;
+  ptr4 = (orc_union32 *) s1;
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: ldreslinl */
+    {
+      int tmp = p1 + i * p2;
+      orc_union32 a = ptr4[tmp >> 16];
+      orc_union32 b = ptr4[(tmp >> 16) + 1];
+      var32.x4[0] =
+          ((orc_uint8) a.x4[0] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[0] * ((tmp >> 8) & 0xff)) >> 8;
+      var32.x4[1] =
+          ((orc_uint8) a.x4[1] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[1] * ((tmp >> 8) & 0xff)) >> 8;
+      var32.x4[2] =
+          ((orc_uint8) a.x4[2] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[2] * ((tmp >> 8) & 0xff)) >> 8;
+      var32.x4[3] =
+          ((orc_uint8) a.x4[3] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[3] * ((tmp >> 8) & 0xff)) >> 8;
+    }
+    /* 1: storel */
+    ptr0[i] = var32;
+  }
+
+}
+
+#else
+static void
+_backup_orc_resample_bilinear_u32 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_union32 *ORC_RESTRICT ptr0;
+  const orc_union32 *ORC_RESTRICT ptr4;
+  orc_union32 var32;
+
+  ptr0 = (orc_union32 *) ex->arrays[0];
+  ptr4 = (orc_union32 *) ex->arrays[4];
+
+
+  for (i = 0; i < n; i++) {
+    /* 0: ldreslinl */
+    {
+      int tmp = ex->params[24] + i * ex->params[25];
+      orc_union32 a = ptr4[tmp >> 16];
+      orc_union32 b = ptr4[(tmp >> 16) + 1];
+      var32.x4[0] =
+          ((orc_uint8) a.x4[0] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[0] * ((tmp >> 8) & 0xff)) >> 8;
+      var32.x4[1] =
+          ((orc_uint8) a.x4[1] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[1] * ((tmp >> 8) & 0xff)) >> 8;
+      var32.x4[2] =
+          ((orc_uint8) a.x4[2] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[2] * ((tmp >> 8) & 0xff)) >> 8;
+      var32.x4[3] =
+          ((orc_uint8) a.x4[3] * (256 - ((tmp >> 8) & 0xff)) +
+          (orc_uint8) b.x4[3] * ((tmp >> 8) & 0xff)) >> 8;
+    }
+    /* 1: storel */
+    ptr0[i] = var32;
+  }
+
+}
+
+void
+orc_resample_bilinear_u32 (guint8 * ORC_RESTRICT d1,
+    const guint8 * ORC_RESTRICT s1, int p1, int p2, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_resample_bilinear_u32");
+      orc_program_set_backup_function (p, _backup_orc_resample_bilinear_u32);
+      orc_program_add_destination (p, 4, "d1");
+      orc_program_add_source (p, 4, "s1");
+      orc_program_add_parameter (p, 4, "p1");
+      orc_program_add_parameter (p, 4, "p2");
+
+      orc_program_append_2 (p, "ldreslinl", 0, ORC_VAR_D1, ORC_VAR_S1,
+          ORC_VAR_P1, ORC_VAR_P2);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->params[ORC_VAR_P1] = p1;
+  ex->params[ORC_VAR_P2] = p2;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
+
+
+/* orc_merge_linear_u8 */
+#ifdef DISABLE_ORC
+void
+orc_merge_linear_u8 (orc_uint8 * ORC_RESTRICT d1,
+    const orc_uint8 * ORC_RESTRICT s1, const orc_uint8 * ORC_RESTRICT s2,
+    int p1, int n)
+{
+  int i;
+  orc_int8 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+  orc_int8 var40;
+  orc_int8 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+  orc_union16 var45;
+  orc_union16 var46;
+  orc_int8 var47;
+
+  ptr0 = (orc_int8 *) d1;
+  ptr4 = (orc_int8 *) s1;
+  ptr5 = (orc_int8 *) s2;
+
+  /* 6: loadpw */
+  var38.i = p1;
+  /* 8: loadpw */
+  var39.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadb */
+    var41 = ptr4[i];
+    /* 1: loadb */
+    var36 = ptr4[i];
+    /* 2: convubw */
+    var42.i = (orc_uint8) var36;
+    /* 3: loadb */
+    var37 = ptr5[i];
+    /* 4: convubw */
+    var43.i = (orc_uint8) var37;
+    /* 5: subw */
+    var44.i = var43.i - var42.i;
+    /* 7: mullw */
+    var45.i = (var44.i * var38.i) & 0xffff;
+    /* 9: addw */
+    var46.i = var45.i + var39.i;
+    /* 10: convhwb */
+    var47 = ((orc_uint16) var46.i) >> 8;
+    /* 11: addb */
+    var40 = var47 + var41;
+    /* 12: storeb */
+    ptr0[i] = var40;
+  }
+
+}
+
+#else
+static void
+_backup_orc_merge_linear_u8 (OrcExecutor * ORC_RESTRICT ex)
+{
+  int i;
+  int n = ex->n;
+  orc_int8 *ORC_RESTRICT ptr0;
+  const orc_int8 *ORC_RESTRICT ptr4;
+  const orc_int8 *ORC_RESTRICT ptr5;
+  orc_int8 var36;
+  orc_int8 var37;
+  orc_union16 var38;
+  orc_union16 var39;
+  orc_int8 var40;
+  orc_int8 var41;
+  orc_union16 var42;
+  orc_union16 var43;
+  orc_union16 var44;
+  orc_union16 var45;
+  orc_union16 var46;
+  orc_int8 var47;
+
+  ptr0 = (orc_int8 *) ex->arrays[0];
+  ptr4 = (orc_int8 *) ex->arrays[4];
+  ptr5 = (orc_int8 *) ex->arrays[5];
+
+  /* 6: loadpw */
+  var38.i = ex->params[24];
+  /* 8: loadpw */
+  var39.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
+
+  for (i = 0; i < n; i++) {
+    /* 0: loadb */
+    var41 = ptr4[i];
+    /* 1: loadb */
+    var36 = ptr4[i];
+    /* 2: convubw */
+    var42.i = (orc_uint8) var36;
+    /* 3: loadb */
+    var37 = ptr5[i];
+    /* 4: convubw */
+    var43.i = (orc_uint8) var37;
+    /* 5: subw */
+    var44.i = var43.i - var42.i;
+    /* 7: mullw */
+    var45.i = (var44.i * var38.i) & 0xffff;
+    /* 9: addw */
+    var46.i = var45.i + var39.i;
+    /* 10: convhwb */
+    var47 = ((orc_uint16) var46.i) >> 8;
+    /* 11: addb */
+    var40 = var47 + var41;
+    /* 12: storeb */
+    ptr0[i] = var40;
+  }
+
+}
+
+void
+orc_merge_linear_u8 (orc_uint8 * ORC_RESTRICT d1,
+    const orc_uint8 * ORC_RESTRICT s1, const orc_uint8 * ORC_RESTRICT s2,
+    int p1, int n)
+{
+  OrcExecutor _ex, *ex = &_ex;
+  static volatile int p_inited = 0;
+  static OrcProgram *p = 0;
+  void (*func) (OrcExecutor *);
+
+  if (!p_inited) {
+    orc_once_mutex_lock ();
+    if (!p_inited) {
+
+      p = orc_program_new ();
+      orc_program_set_name (p, "orc_merge_linear_u8");
+      orc_program_set_backup_function (p, _backup_orc_merge_linear_u8);
+      orc_program_add_destination (p, 1, "d1");
+      orc_program_add_source (p, 1, "s1");
+      orc_program_add_source (p, 1, "s2");
+      orc_program_add_constant (p, 4, 0x00000080, "c1");
+      orc_program_add_parameter (p, 1, "p1");
+      orc_program_add_temporary (p, 2, "t1");
+      orc_program_add_temporary (p, 2, "t2");
+      orc_program_add_temporary (p, 1, "t3");
+      orc_program_add_temporary (p, 1, "t4");
+
+      orc_program_append_2 (p, "loadb", 0, ORC_VAR_T3, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "subw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "addw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "convhwb", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_D1,
+          ORC_VAR_D1);
+      orc_program_append_2 (p, "addb", 0, ORC_VAR_D1, ORC_VAR_T4, ORC_VAR_T3,
+          ORC_VAR_D1);
+
+      orc_program_compile (p);
+    }
+    p_inited = TRUE;
+    orc_once_mutex_unlock ();
+  }
+  ex->program = p;
+
+  ex->n = n;
+  ex->arrays[ORC_VAR_D1] = d1;
+  ex->arrays[ORC_VAR_S1] = (void *) s1;
+  ex->arrays[ORC_VAR_S2] = (void *) s2;
+  ex->params[ORC_VAR_P1] = p1;
+
+  func = p->code_exec;
+  func (ex);
+}
+#endif
diff --git a/gst-libs/gst/video/videoblendorc-dist.h b/gst-libs/gst/video/videoblendorc-dist.h
new file mode 100644
index 0000000..f6f4637
--- /dev/null
+++ b/gst-libs/gst/video/videoblendorc-dist.h
@@ -0,0 +1,107 @@
+
+/* autogenerated from videoblendorc.orc */
+
+#ifndef _VIDEOBLENDORC_H_
+#define _VIDEOBLENDORC_H_
+
+#include <glib.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+
+#ifndef _ORC_INTEGER_TYPEDEFS_
+#define _ORC_INTEGER_TYPEDEFS_
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+#include <stdint.h>
+typedef int8_t orc_int8;
+typedef int16_t orc_int16;
+typedef int32_t orc_int32;
+typedef int64_t orc_int64;
+typedef uint8_t orc_uint8;
+typedef uint16_t orc_uint16;
+typedef uint32_t orc_uint32;
+typedef uint64_t orc_uint64;
+#define ORC_UINT64_C(x) UINT64_C(x)
+#elif defined(_MSC_VER)
+typedef signed __int8 orc_int8;
+typedef signed __int16 orc_int16;
+typedef signed __int32 orc_int32;
+typedef signed __int64 orc_int64;
+typedef unsigned __int8 orc_uint8;
+typedef unsigned __int16 orc_uint16;
+typedef unsigned __int32 orc_uint32;
+typedef unsigned __int64 orc_uint64;
+#define ORC_UINT64_C(x) (x##Ui64)
+#define inline __inline
+#else
+#include <limits.h>
+typedef signed char orc_int8;
+typedef short orc_int16;
+typedef int orc_int32;
+typedef unsigned char orc_uint8;
+typedef unsigned short orc_uint16;
+typedef unsigned int orc_uint32;
+#if INT_MAX == LONG_MAX
+typedef long long orc_int64;
+typedef unsigned long long orc_uint64;
+#define ORC_UINT64_C(x) (x##ULL)
+#else
+typedef long orc_int64;
+typedef unsigned long orc_uint64;
+#define ORC_UINT64_C(x) (x##UL)
+#endif
+#endif
+typedef union { orc_int16 i; orc_int8 x2[2]; } orc_union16;
+typedef union { orc_int32 i; float f; orc_int16 x2[2]; orc_int8 x4[4]; } orc_union32;
+typedef union { orc_int64 i; double f; orc_int32 x2[2]; float x2f[2]; orc_int16 x4[4]; } orc_union64;
+#endif
+#ifndef ORC_RESTRICT
+#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
+#define ORC_RESTRICT restrict
+#elif defined(__GNUC__) && __GNUC__ >= 4
+#define ORC_RESTRICT __restrict__
+#else
+#define ORC_RESTRICT
+#endif
+#endif
+void orc_blend_little (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_blend_big (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_I420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_pack_I420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_YUY2 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_UYVY (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_YVYU (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_YUV9 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_unpack_Y42B (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_pack_Y42B (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_Y444 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
+void orc_pack_Y444 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, guint8 * ORC_RESTRICT d3, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_GRAY8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_BGRA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_RGBA (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_pack_ABGR (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_NV12 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
+void orc_pack_NV12 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_NV21 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
+void orc_pack_NV21 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, const guint8 * ORC_RESTRICT s1, int n);
+void orc_unpack_A420 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n);
+void orc_pack_A420 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, guint8 * ORC_RESTRICT d3, guint8 * ORC_RESTRICT d4, const guint8 * ORC_RESTRICT s1, int n);
+void orc_resample_bilinear_u32 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int p1, int p2, int n);
+void orc_merge_linear_u8 (orc_uint8 * ORC_RESTRICT d1, const orc_uint8 * ORC_RESTRICT s1, const orc_uint8 * ORC_RESTRICT s2, int p1, int n);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
+
diff --git a/gst-libs/gst/video/videoblendorc.orc b/gst-libs/gst/video/videoblendorc.orc
new file mode 100644
index 0000000..ddaebcb
--- /dev/null
+++ b/gst-libs/gst/video/videoblendorc.orc
@@ -0,0 +1,507 @@
+.function orc_blend_little
+.flags 1d
+.dest 4 d guint8
+.source 4 s guint8
+.temp 4 t
+.temp 2 tw
+.temp 1 tb
+.temp 4 a
+.temp 8 d_wide
+.temp 8 s_wide
+.temp 8 a_wide
+.const 4 a_alpha 0x000000ff
+
+loadl t, s
+convlw tw, t
+convwb tb, tw
+splatbl a, tb
+x4 convubw a_wide, a
+x4 shruw a_wide, a_wide, 8
+x4 convubw s_wide, t
+loadl t, d
+x4 convubw d_wide, t
+x4 subw s_wide, s_wide, d_wide
+x4 mullw s_wide, s_wide, a_wide
+x4 div255w s_wide, s_wide
+x4 addw d_wide, d_wide, s_wide
+x4 convwb t, d_wide
+orl t, t, a_alpha
+storel d, t
+
+.function orc_blend_big
+.flags 1d
+.dest 4 d guint8
+.source 4 s guint8
+.temp 4 t
+.temp 4 t2
+.temp 2 tw
+.temp 1 tb
+.temp 4 a
+.temp 8 d_wide
+.temp 8 s_wide
+.temp 8 a_wide
+.const 4 a_alpha 0xff000000
+
+loadl t, s
+shrul t2, t, 24
+convlw tw, t2
+convwb tb, tw
+splatbl a, tb
+x4 convubw a_wide, a
+x4 shruw a_wide, a_wide, 8
+x4 convubw s_wide, t
+loadl t, d
+x4 convubw d_wide, t
+x4 subw s_wide, s_wide, d_wide
+x4 mullw s_wide, s_wide, a_wide
+x4 div255w s_wide, s_wide
+x4 addw d_wide, d_wide, s_wide
+x4 convwb t, d_wide
+orl t, t, a_alpha
+storel d, t
+
+.function orc_unpack_I420
+.dest 4 d guint8
+.source 1 y guint8
+.source 1 u guint8
+.source 1 v guint8
+.const 1 c255 255
+.temp 2 uv
+.temp 2 ay
+.temp 1 tu
+.temp 1 tv
+
+loadupdb tu, u
+loadupdb tv, v
+mergebw uv, tu, tv
+mergebw ay, c255, y
+mergewl d, ay, uv
+
+
+.function orc_pack_I420
+.dest 2 y guint8
+.dest 1 u guint8
+.dest 1 v guint8
+.source 8 ayuv guint8
+.temp 4 ay
+.temp 4 uv
+.temp 2 uu
+.temp 2 vv
+.temp 1 t1
+.temp 1 t2
+
+x2 splitlw uv, ay, ayuv
+x2 select1wb y, ay
+x2 splitwb vv, uu, uv
+splitwb t1, t2, uu
+avgub u, t1, t2
+splitwb t1, t2, vv
+avgub v, t1, t2
+
+.function orc_unpack_YUY2
+.dest 8 ayuv guint8
+.source 4 yuy2 guint8
+.const 2 c255 0xff
+.temp 2 yy
+.temp 2 uv
+.temp 4 ayay
+.temp 4 uvuv
+
+x2 splitwb uv, yy, yuy2
+x2 mergebw ayay, c255, yy
+mergewl uvuv, uv, uv
+x2 mergewl ayuv, ayay, uvuv
+
+
+.function orc_pack_YUY2
+.dest 4 yuy2 guint8
+.source 8 ayuv guint8
+.temp 2 yy
+.temp 2 uv1
+.temp 2 uv2
+.temp 4 ayay
+.temp 4 uvuv
+
+x2 splitlw uvuv, ayay, ayuv
+splitlw uv1, uv2, uvuv
+x2 avgub uv1, uv1, uv2
+x2 select1wb yy, ayay
+x2 mergebw yuy2, yy, uv1
+
+
+.function orc_pack_UYVY
+.dest 4 yuy2 guint8
+.source 8 ayuv guint8
+.temp 2 yy
+.temp 2 uv1
+.temp 2 uv2
+.temp 4 ayay
+.temp 4 uvuv
+
+x2 splitlw uvuv, ayay, ayuv
+splitlw uv1, uv2, uvuv
+x2 avgub uv1, uv1, uv2
+x2 select1wb yy, ayay
+x2 mergebw yuy2, uv1, yy
+
+
+.function orc_unpack_UYVY
+.dest 8 ayuv guint8
+.source 4 uyvy guint8
+.const 2 c255 0xff
+.temp 2 yy
+.temp 2 uv
+.temp 4 ayay
+.temp 4 uvuv
+
+x2 splitwb yy, uv, uyvy
+x2 mergebw ayay, c255, yy
+mergewl uvuv, uv, uv
+x2 mergewl ayuv, ayay, uvuv
+
+
+.function orc_unpack_YVYU
+.dest 8 ayuv guint8
+.source 4 uyvy guint8
+.const 2 c255 0xff
+.temp 2 yy
+.temp 2 uv
+.temp 4 ayay
+.temp 4 uvuv
+
+x2 splitwb uv, yy, uyvy
+swapw uv, uv
+x2 mergebw ayay, c255, yy
+mergewl uvuv, uv, uv
+x2 mergewl ayuv, ayay, uvuv
+
+
+.function orc_pack_YVYU
+.dest 4 yuy2 guint8
+.source 8 ayuv guint8
+.temp 2 yy
+.temp 2 uv1
+.temp 2 uv2
+.temp 4 ayay
+.temp 4 uvuv
+
+x2 splitlw uvuv, ayay, ayuv
+splitlw uv1, uv2, uvuv
+x2 avgub uv1, uv1, uv2
+x2 select1wb yy, ayay
+swapw uv1, uv1
+x2 mergebw yuy2, yy, uv1
+
+
+.function orc_unpack_YUV9
+.dest 8 d guint8
+.source 2 y guint8
+.source 1 u guint8
+.source 1 v guint8
+.const 1 c255 255
+.temp 2 tuv
+.temp 4 ay
+.temp 4 uv
+.temp 1 tu
+.temp 1 tv
+
+loadupdb tu, u
+loadupdb tv, v
+mergebw tuv, tu, tv
+mergewl uv, tuv, tuv
+x2 mergebw ay, c255, y
+x2 mergewl d, ay, uv
+
+
+.function orc_unpack_Y42B
+.dest 8 ayuv guint8
+.source 2 yy guint8
+.source 1 u guint8
+.source 1 v guint8
+.const 1 c255 255
+.temp 2 uv
+.temp 2 ay
+.temp 4 uvuv
+.temp 4 ayay
+
+mergebw uv, u, v
+x2 mergebw ayay, c255, yy
+mergewl uvuv, uv, uv
+x2 mergewl ayuv, ayay, uvuv
+
+.function orc_pack_Y42B
+.dest 2 y guint8
+.dest 1 u guint8
+.dest 1 v guint8
+.source 8 ayuv guint8
+.temp 4 ayay
+.temp 4 uvuv
+.temp 2 uv1
+.temp 2 uv2
+
+x2 splitlw uvuv, ayay, ayuv
+splitlw uv1, uv2, uvuv
+x2 avgub uv1, uv1, uv2
+splitwb v, u, uv1
+x2 select1wb y, ayay
+
+
+.function orc_unpack_Y444
+.dest 4 ayuv guint8
+.source 1 y guint8
+.source 1 u guint8
+.source 1 v guint8
+.const 1 c255 255
+.temp 2 uv
+.temp 2 ay
+
+mergebw uv, u, v
+mergebw ay, c255, y
+mergewl ayuv, ay, uv
+
+
+.function orc_pack_Y444
+.dest 1 y guint8
+.dest 1 u guint8
+.dest 1 v guint8
+.source 4 ayuv guint8
+.temp 2 ay
+.temp 2 uv
+
+splitlw uv, ay, ayuv
+splitwb v, u, uv
+select1wb y, ay
+
+.function orc_unpack_GRAY8
+.dest 4 ayuv guint8
+.source 1 y guint8
+.const 1 c255 255
+.const 2 c0x8080 0x8080
+.temp 2 ay
+
+mergebw ay, c255, y
+mergewl ayuv, ay, c0x8080
+
+
+.function orc_pack_GRAY8
+.dest 1 y guint8
+.source 4 ayuv guint8
+.temp 2 ay
+
+select0lw ay, ayuv
+select1wb y, ay
+
+
+.function orc_unpack_BGRA
+.dest 4 argb guint8
+.source 4 bgra guint8
+
+swapl argb, bgra
+
+.function orc_pack_BGRA
+.dest 4 bgra guint8
+.source 4 argb guint8
+
+swapl bgra, argb
+
+.function orc_pack_RGBA
+.dest 4 rgba guint8
+.source 4 argb guint8
+.temp 1 a
+.temp 1 r
+.temp 1 g
+.temp 1 b
+.temp 2 rg
+.temp 2 ba
+.temp 2 ar
+.temp 2 gb
+
+splitlw gb, ar, argb
+splitwb b, g, gb
+splitwb r, a, ar
+mergebw ba, b, a
+mergebw rg, r, g
+mergewl rgba, rg, ba
+
+.function orc_unpack_RGBA
+.dest 4 argb guint8
+.source 4 rgba guint8
+.temp 1 a
+.temp 1 r
+.temp 1 g
+.temp 1 b
+.temp 2 rg
+.temp 2 ba
+.temp 2 ar
+.temp 2 gb
+
+splitlw ba, rg, rgba
+splitwb g, r, rg
+splitwb a, b, ba
+mergebw ar, a, r
+mergebw gb, g, b
+mergewl argb, ar, gb
+
+
+.function orc_unpack_ABGR
+.dest 4 argb guint8
+.source 4 abgr guint8
+.temp 1 a
+.temp 1 r
+.temp 1 g
+.temp 1 b
+.temp 2 gr
+.temp 2 ab
+.temp 2 ar
+.temp 2 gb
+
+splitlw gr, ab, abgr
+splitwb r, g, gr
+splitwb b, a, ab
+mergebw ar, a, r
+mergebw gb, g, b
+mergewl argb, ar, gb
+
+
+.function orc_pack_ABGR
+.dest 4 abgr guint8
+.source 4 argb guint8
+.temp 1 a
+.temp 1 r
+.temp 1 g
+.temp 1 b
+.temp 2 gr
+.temp 2 ab
+.temp 2 ar
+.temp 2 gb
+
+splitlw gb, ar, argb
+splitwb b, g, gb
+splitwb r, a, ar
+mergebw ab, a, b
+mergebw gr, g, r
+mergewl abgr, ab, gr
+
+.function orc_unpack_NV12
+.dest 8 d guint8
+.source 2 y guint8
+.source 2 uv guint8
+.const 1 c255 255
+.temp 4 ay
+.temp 4 uvuv
+
+mergewl uvuv, uv, uv
+x2 mergebw ay, c255, y
+x2 mergewl d, ay, uvuv
+
+.function orc_pack_NV12
+.dest 2 y guint8
+.dest 2 uv guint8
+.source 8 ayuv guint8
+.temp 4 ay
+.temp 4 uvuv
+.temp 2 uv1
+.temp 2 uv2
+
+x2 splitlw uvuv, ay, ayuv
+x2 select1wb y, ay
+splitlw uv1, uv2, uvuv
+x2 avgub uv, uv1, uv2
+
+.function orc_unpack_NV21
+.dest 8 d guint8
+.source 2 y guint8
+.source 2 vu guint8
+.const 1 c255 255
+.temp 2 uv
+.temp 4 ay
+.temp 4 uvuv
+
+swapw uv, vu
+mergewl uvuv, uv, uv
+x2 mergebw ay, c255, y
+x2 mergewl d, ay, uvuv
+
+
+.function orc_pack_NV21
+.dest 2 y guint8
+.dest 2 vu guint8
+.source 8 ayuv guint8
+.temp 4 ay
+.temp 4 uvuv
+.temp 2 uv1
+.temp 2 uv2
+.temp 2 uv
+
+x2 splitlw uvuv, ay, ayuv
+x2 select1wb y, ay
+splitlw uv1, uv2, uvuv
+x2 avgub uv, uv1, uv2
+swapw vu, uv
+
+
+.function orc_unpack_A420
+.dest 4 d guint8
+.source 1 y guint8
+.source 1 u guint8
+.source 1 v guint8
+.source 1 a guint8
+.temp 2 uv
+.temp 2 ay
+.temp 1 tu
+.temp 1 tv
+
+loadupdb tu, u
+loadupdb tv, v
+mergebw uv, tu, tv
+mergebw ay, a, y
+mergewl d, ay, uv
+
+.function orc_pack_A420
+.dest 2 y guint8
+.dest 1 u guint8
+.dest 1 v guint8
+.dest 2 a guint8
+.source 8 ayuv guint8
+.temp 4 ay
+.temp 4 uv
+.temp 2 uu
+.temp 2 vv
+.temp 1 t1
+.temp 1 t2
+
+x2 splitlw uv, ay, ayuv
+x2 select1wb y, ay
+x2 select0wb a, ay
+x2 splitwb vv, uu, uv
+splitwb t1, t2, uu
+avgub u, t1, t2
+splitwb t1, t2, vv
+avgub v, t1, t2
+
+.function orc_resample_bilinear_u32
+.dest 4 d1 guint8
+.source 4 s1 guint8
+.param 4 p1
+.param 4 p2
+
+ldreslinl d1, s1, p1, p2
+
+.function orc_merge_linear_u8
+.dest 1 d1
+.source 1 s1
+.source 1 s2
+.param 1 p1
+.temp 2 t1
+.temp 2 t2
+.temp 1 a
+.temp 1 t
+
+loadb a, s1
+convubw t1, s1
+convubw t2, s2
+subw t2, t2, t1
+mullw t2, t2, p1
+addw t2, t2, 128
+convhwb t, t2
+addb d1, t, a
diff --git a/gst-plugins-base.doap b/gst-plugins-base.doap
index 0f8c471..c3af8f7 100644
--- a/gst-plugins-base.doap
+++ b/gst-plugins-base.doap
@@ -36,6 +36,16 @@
 
  <release>
   <Version>
+   <revision>0.11.92</revision>
+   <branch>0.11</branch>
+   <name>Comfortably Numb</name>
+   <created>2012-06-07</created>
+   <file-release rdf:resource="http://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-0.11.92.tar.xz" />
+  </Version>
+ </release>
+
+ <release>
+  <Version>
    <revision>0.11.91</revision>
    <branch>0.11</branch>
    <name>Fee-fi-fo-fum</name>
diff --git a/gst-plugins-base.spec b/gst-plugins-base.spec
index 835143f..9a4df6a 100644
--- a/gst-plugins-base.spec
+++ b/gst-plugins-base.spec
@@ -4,7 +4,7 @@
 %define gst_minver  0.11.0
 
 Name: 		%{gstreamer}-plugins-base
-Version: 	0.11.91
+Version: 	0.11.92
 Release: 	1.gst
 Summary: 	GStreamer streaming media framework plug-ins
 
diff --git a/gst/Makefile.in b/gst/Makefile.in
index 6c49e6b..e8d0658 100644
--- a/gst/Makefile.in
+++ b/gst/Makefile.in
@@ -55,6 +55,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/parallel-subdirs.mak
 subdir = gst
@@ -256,8 +257,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -428,7 +435,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/adder/Makefile.in b/gst/adder/Makefile.in
index 43c04e0..c7060b5 100644
--- a/gst/adder/Makefile.in
+++ b/gst/adder/Makefile.in
@@ -74,6 +74,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/orc.mak
 subdir = gst/adder
@@ -304,8 +305,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -476,7 +483,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/app/Makefile.in b/gst/app/Makefile.in
index 2e68d9a..dbde35e 100644
--- a/gst/app/Makefile.in
+++ b/gst/app/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/app
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -275,8 +276,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -447,7 +454,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/audioconvert/Makefile.in b/gst/audioconvert/Makefile.in
index 1b68d54..bd64891 100644
--- a/gst/audioconvert/Makefile.in
+++ b/gst/audioconvert/Makefile.in
@@ -74,6 +74,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/orc.mak
 subdir = gst/audioconvert
@@ -310,8 +311,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -482,7 +489,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/audiorate/Makefile.in b/gst/audiorate/Makefile.in
index 6cbaa9e..b4ff7a4 100644
--- a/gst/audiorate/Makefile.in
+++ b/gst/audiorate/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/audiorate
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -278,8 +279,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -450,7 +457,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/audioresample/Makefile.in b/gst/audioresample/Makefile.in
index ba0b193..20e1cae 100644
--- a/gst/audioresample/Makefile.in
+++ b/gst/audioresample/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/audioresample
 DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -284,8 +285,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -456,7 +463,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/audioresample/gstaudioresample.c b/gst/audioresample/gstaudioresample.c
index 22fb7da..cc95bfc 100644
--- a/gst/audioresample/gstaudioresample.c
+++ b/gst/audioresample/gstaudioresample.c
@@ -58,6 +58,9 @@
 
 GST_DEBUG_CATEGORY (audio_resample_debug);
 #define GST_CAT_DEFAULT audio_resample_debug
+#if !defined(AUDIORESAMPLE_FORMAT_AUTO) || defined(DISABLE_ORC)
+GST_DEBUG_CATEGORY_STATIC (GST_CAT_PERFORMANCE);
+#endif
 
 enum
 {
@@ -1429,7 +1432,6 @@
 #else
   GST_WARNING ("Orc disabled, can't benchmark int vs. float resampler");
   {
-    GST_DEBUG_CATEGORY_STATIC (GST_CAT_PERFORMANCE);
     GST_DEBUG_CATEGORY_GET (GST_CAT_PERFORMANCE, "GST_PERFORMANCE");
     GST_CAT_WARNING (GST_CAT_PERFORMANCE, "orc disabled, no benchmarking done");
   }
diff --git a/gst/audiotestsrc/Makefile.in b/gst/audiotestsrc/Makefile.in
index 5b207ad..9b91100 100644
--- a/gst/audiotestsrc/Makefile.in
+++ b/gst/audiotestsrc/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/audiotestsrc
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -280,8 +281,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -452,7 +459,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/audiotestsrc/gstaudiotestsrc.c b/gst/audiotestsrc/gstaudiotestsrc.c
index ae9ca10..2c7cf98 100644
--- a/gst/audiotestsrc/gstaudiotestsrc.c
+++ b/gst/audiotestsrc/gstaudiotestsrc.c
@@ -1131,7 +1131,7 @@
     eclass = GST_ELEMENT_CLASS (parent_class);
     if (eclass->send_event)
       eclass->send_event (GST_ELEMENT_CAST (basesrc),
-          gst_event_new_tag (taglist));
+          gst_event_new_tag ("GstSrc", taglist));
     else
       gst_tag_list_free (taglist);
     src->tags_pushed = TRUE;
diff --git a/gst/encoding/Makefile.in b/gst/encoding/Makefile.in
index aa55232..fac4133 100644
--- a/gst/encoding/Makefile.in
+++ b/gst/encoding/Makefile.in
@@ -60,6 +60,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/gst-glib-gen.mak
 subdir = gst/encoding
@@ -293,8 +294,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -465,7 +472,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/encoding/gstencodebin.c b/gst/encoding/gstencodebin.c
index 3c261a2..749cf23 100644
--- a/gst/encoding/gstencodebin.c
+++ b/gst/encoding/gstencodebin.c
@@ -1496,8 +1496,9 @@
 _factory_can_handle_caps (GstElementFactory * factory, const GstCaps * caps,
     GstPadDirection dir, gboolean exact)
 {
-  GList *templates = factory->staticpadtemplates;
+  const GList *templates;
 
+  templates = gst_element_factory_get_static_pad_templates (factory);
   while (templates) {
     GstStaticPadTemplate *template = (GstStaticPadTemplate *) templates->data;
 
diff --git a/gst/gdp/Makefile.in b/gst/gdp/Makefile.in
index d9220da..86d15b5 100644
--- a/gst/gdp/Makefile.in
+++ b/gst/gdp/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/gdp
 DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -280,8 +281,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -452,7 +459,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/gio/Makefile.in b/gst/gio/Makefile.in
index f7d3c68..a1b0bc3 100644
--- a/gst/gio/Makefile.in
+++ b/gst/gio/Makefile.in
@@ -54,6 +54,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/gio
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -284,8 +285,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -456,7 +463,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/playback/Makefile.in b/gst/playback/Makefile.in
index aad467a..3910174 100644
--- a/gst/playback/Makefile.in
+++ b/gst/playback/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/playback
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -293,8 +294,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -465,7 +472,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/playback/gstplaybin2.c b/gst/playback/gstplaybin2.c
index c997104..74b53f7 100644
--- a/gst/playback/gstplaybin2.c
+++ b/gst/playback/gstplaybin2.c
@@ -334,6 +334,10 @@
   GMutex stream_changed_pending_lock;
   GList *stream_changed_pending;
 
+  /* to prevent that suburidecodebin seek flushes disrupt playback */
+  GMutex suburi_flushes_to_drop_lock;
+  GSList *suburi_flushes_to_drop;
+
   /* selectors for different streams */
   GstSourceSelect selector[PLAYBIN_STREAM_LAST];
 };
@@ -406,6 +410,16 @@
                                  * input-selector, so that we only post a
                                  * warning once */
 
+  gboolean video_pending_flush_finish;  /* whether we are pending to send a custom
+                                         * custom-video-flush-finish event
+                                         * on pad activation */
+  gboolean audio_pending_flush_finish;  /* whether we are pending to send a custom
+                                         * custom-audio-flush-finish event
+                                         * on pad activation */
+  gboolean text_pending_flush_finish;   /* whether we are pending to send a custom
+                                         * custom-subtitle-flush-finish event
+                                         * on pad activation */
+
   GstElement *audio_sink;       /* configured audio sink, or NULL      */
   GstElement *video_sink;       /* configured video sink, or NULL      */
   GstElement *text_sink;        /* configured text sink, or NULL       */
@@ -482,7 +496,9 @@
 {
   PROP_0,
   PROP_URI,
+  PROP_CURRENT_URI,
   PROP_SUBURI,
+  PROP_CURRENT_SUBURI,
   PROP_SOURCE,
   PROP_FLAGS,
   PROP_N_VIDEO,
@@ -566,8 +582,7 @@
 
 static void gst_play_bin_suburidecodebin_block (GstSourceGroup * group,
     GstElement * suburidecodebin, gboolean block);
-static void gst_play_bin_suburidecodebin_seek_to_start (GstElement *
-    suburidecodebin);
+static void gst_play_bin_suburidecodebin_seek_to_start (GstSourceGroup * group);
 
 static GstElementClass *parent_class;
 
@@ -663,6 +678,16 @@
       g_param_spec_string ("uri", "URI", "URI of the media to play",
           NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
 
+   /**
+   * GstPlayBin:current-uri
+   *
+   * The currently playing uri.
+   */
+  g_object_class_install_property (gobject_klass, PROP_CURRENT_URI,
+      g_param_spec_string ("current-uri", "Current URI",
+          "The currently playing URI", NULL,
+          G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
+
   /**
    * GstPlayBin:suburi
    *
@@ -673,6 +698,16 @@
       g_param_spec_string ("suburi", ".sub-URI", "Optional URI of a subtitle",
           NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
 
+  /**
+   * GstPlayBin:current-suburi
+   *
+   * The currently playing subtitle uri.
+   */
+  g_object_class_install_property (gobject_klass, PROP_CURRENT_SUBURI,
+      g_param_spec_string ("current-suburi", "Current .sub-URI",
+          "The currently playing URI of a subtitle",
+          NULL, G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
+
   g_object_class_install_property (gobject_klass, PROP_SOURCE,
       g_param_spec_object ("source", "Source", "Source element",
           GST_TYPE_ELEMENT, G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
@@ -767,7 +802,7 @@
           GST_TYPE_ELEMENT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
   g_object_class_install_property (gobject_klass, PROP_TEXT_SINK,
       g_param_spec_object ("text-sink", "Text plugin",
-          "the text output element to use (NULL = default textoverlay)",
+          "the text output element to use (NULL = default subtitleoverlay)",
           GST_TYPE_ELEMENT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
 
   /**
@@ -1226,6 +1261,13 @@
   if (group->stream_changed_pending_lock.p)
     g_mutex_clear (&group->stream_changed_pending_lock);
   group->stream_changed_pending_lock.p = NULL;
+
+  g_slist_free (group->suburi_flushes_to_drop);
+  group->suburi_flushes_to_drop = NULL;
+
+  if (group->suburi_flushes_to_drop_lock.p)
+    g_mutex_clear (&group->suburi_flushes_to_drop_lock);
+  group->suburi_flushes_to_drop_lock.p = NULL;
 }
 
 static void
@@ -1247,6 +1289,35 @@
   gst_color_balance_value_changed (GST_COLOR_BALANCE (playbin), channel, value);
 }
 
+static gint
+compare_factories_func (gconstpointer p1, gconstpointer p2)
+{
+  GstPluginFeature *f1, *f2;
+  gint diff;
+  gboolean s1, s2;
+
+  f1 = (GstPluginFeature *) p1;
+  f2 = (GstPluginFeature *) p2;
+
+  s1 = gst_element_factory_list_is_type (GST_ELEMENT_FACTORY_CAST (f1),
+      GST_ELEMENT_FACTORY_TYPE_SINK);
+  s2 = gst_element_factory_list_is_type (GST_ELEMENT_FACTORY_CAST (f2),
+      GST_ELEMENT_FACTORY_TYPE_SINK);
+
+  if (s1 && !s2)
+    return -1;
+  else if (!s1 && s2)
+    return 1;
+
+  diff = gst_plugin_feature_get_rank (f2) - gst_plugin_feature_get_rank (f1);
+  if (diff != 0)
+    return diff;
+
+  diff = strcmp (GST_OBJECT_NAME (f2), GST_OBJECT_NAME (f1));
+
+  return diff;
+}
+
 /* Must be called with elements lock! */
 static void
 gst_play_bin_update_elements_list (GstPlayBin * playbin)
@@ -1265,8 +1336,7 @@
         gst_element_factory_list_get_elements
         (GST_ELEMENT_FACTORY_TYPE_AUDIOVIDEO_SINKS, GST_RANK_MARGINAL);
     playbin->elements = g_list_concat (res, tmp);
-    playbin->elements =
-        g_list_sort (playbin->elements, gst_plugin_feature_rank_compare_func);
+    playbin->elements = g_list_sort (playbin->elements, compare_factories_func);
     playbin->elements_cookie = cookie;
   }
 }
@@ -1604,6 +1674,28 @@
 }
 
 static gboolean
+gst_playbin2_send_custom_event (GstObject * selector, const gchar * event_name)
+{
+  GstPad *src;
+  GstPad *peer;
+  GstStructure *s;
+  GstEvent *event;
+  gboolean ret = FALSE;
+
+  src = gst_element_get_static_pad (GST_ELEMENT_CAST (selector), "src");
+  peer = gst_pad_get_peer (src);
+  if (peer) {
+    s = gst_structure_new_empty (event_name);
+    event = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM_OOB, s);
+    gst_pad_send_event (peer, event);
+    gst_object_unref (peer);
+    ret = TRUE;
+  }
+  gst_object_unref (src);
+  return ret;
+}
+
+static gboolean
 gst_play_bin_set_current_video_stream (GstPlayBin * playbin, gint stream)
 {
   GstSourceGroup *group;
@@ -1634,8 +1726,19 @@
     GstObject *selector;
 
     if ((selector = gst_pad_get_parent (sinkpad))) {
-      /* activate the selected pad */
-      g_object_set (selector, "active-pad", sinkpad, NULL);
+      GstPad *old_sinkpad;
+
+      g_object_get (selector, "active-pad", &old_sinkpad, NULL);
+
+      if (old_sinkpad != sinkpad) {
+        if (gst_playbin2_send_custom_event (selector,
+                "playsink-custom-video-flush"))
+          playbin->video_pending_flush_finish = TRUE;
+
+        /* activate the selected pad */
+        g_object_set (selector, "active-pad", sinkpad, NULL);
+      }
+
       gst_object_unref (selector);
     }
     gst_object_unref (sinkpad);
@@ -1681,8 +1784,18 @@
     GstObject *selector;
 
     if ((selector = gst_pad_get_parent (sinkpad))) {
-      /* activate the selected pad */
-      g_object_set (selector, "active-pad", sinkpad, NULL);
+      GstPad *old_sinkpad;
+
+      g_object_get (selector, "active-pad", &old_sinkpad, NULL);
+
+      if (old_sinkpad != sinkpad) {
+        if (gst_playbin2_send_custom_event (selector,
+                "playsink-custom-audio-flush"))
+          playbin->audio_pending_flush_finish = TRUE;
+
+        /* activate the selected pad */
+        g_object_set (selector, "active-pad", sinkpad, NULL);
+      }
       gst_object_unref (selector);
     }
     gst_object_unref (sinkpad);
@@ -1698,8 +1811,9 @@
 }
 
 static void
-gst_play_bin_suburidecodebin_seek_to_start (GstElement * suburidecodebin)
+gst_play_bin_suburidecodebin_seek_to_start (GstSourceGroup * group)
 {
+  GstElement *suburidecodebin = group->suburidecodebin;
   GstIterator *it = gst_element_iterate_src_pads (suburidecodebin);
   GstPad *sinkpad;
   GValue item = { 0, };
@@ -1707,16 +1821,34 @@
   if (it && gst_iterator_next (it, &item) == GST_ITERATOR_OK
       && ((sinkpad = g_value_get_object (&item)) != NULL)) {
     GstEvent *event;
+    guint32 seqnum;
 
     event =
-        gst_event_new_seek (1.0, GST_FORMAT_BYTES, GST_SEEK_FLAG_NONE,
+        gst_event_new_seek (1.0, GST_FORMAT_BYTES, GST_SEEK_FLAG_FLUSH,
         GST_SEEK_TYPE_SET, 0, GST_SEEK_TYPE_NONE, -1);
+    seqnum = gst_event_get_seqnum (event);
+
+    /* store the seqnum to drop flushes from this seek later */
+    g_mutex_lock (&group->suburi_flushes_to_drop_lock);
+    group->suburi_flushes_to_drop =
+        g_slist_append (group->suburi_flushes_to_drop,
+        GUINT_TO_POINTER (seqnum));
+    g_mutex_unlock (&group->suburi_flushes_to_drop_lock);
+
     if (!gst_pad_send_event (sinkpad, event)) {
       event =
-          gst_event_new_seek (1.0, GST_FORMAT_TIME, GST_SEEK_FLAG_NONE,
+          gst_event_new_seek (1.0, GST_FORMAT_TIME, GST_SEEK_FLAG_FLUSH,
           GST_SEEK_TYPE_SET, 0, GST_SEEK_TYPE_NONE, -1);
-      if (!gst_pad_send_event (sinkpad, event))
+      gst_event_set_seqnum (event, seqnum);
+      if (!gst_pad_send_event (sinkpad, event)) {
         GST_DEBUG_OBJECT (suburidecodebin, "Seeking to the beginning failed!");
+
+        g_mutex_lock (&group->suburi_flushes_to_drop_lock);
+        group->suburi_flushes_to_drop =
+            g_slist_remove (group->suburi_flushes_to_drop,
+            GUINT_TO_POINTER (seqnum));
+        g_mutex_unlock (&group->suburi_flushes_to_drop_lock);
+      }
     }
 
     g_value_unset (&item);
@@ -1806,7 +1938,7 @@
 
       if (old_sinkpad != sinkpad) {
         gboolean need_unblock, need_block, need_seek;
-        GstPad *src, *peer = NULL, *oldpeer = NULL;
+        GstPad *peer = NULL, *oldpeer = NULL;
         GstElement *parent_element = NULL, *old_parent_element = NULL;
 
         /* Now check if we need to seek the suburidecodebin to the beginning
@@ -1843,25 +1975,13 @@
           gst_play_bin_suburidecodebin_block (group, group->suburidecodebin,
               TRUE);
 
+        if (gst_playbin2_send_custom_event (selector,
+                "playsink-custom-subtitle-flush"))
+          playbin->text_pending_flush_finish = TRUE;
+
         /* activate the selected pad */
         g_object_set (selector, "active-pad", sinkpad, NULL);
 
-        src = gst_element_get_static_pad (GST_ELEMENT_CAST (selector), "src");
-        peer = gst_pad_get_peer (src);
-        if (peer) {
-          GstStructure *s;
-          GstEvent *event;
-          /* Flush the subtitle renderer to remove any
-           * currently displayed subtitles. This event will
-           * never travel outside subtitleoverlay!
-           */
-          s = gst_structure_new_empty ("subtitleoverlay-flush-subtitle");
-          event = gst_event_new_custom (GST_EVENT_CUSTOM_DOWNSTREAM_OOB, s);
-          gst_pad_send_event (peer, event);
-          gst_object_unref (peer);
-        }
-        gst_object_unref (src);
-
         /* Unblock pads if necessary */
         if (need_unblock)
           gst_play_bin_suburidecodebin_block (group, group->suburidecodebin,
@@ -1869,7 +1989,7 @@
 
         /* seek to the beginning */
         if (need_seek)
-          gst_play_bin_suburidecodebin_seek_to_start (group->suburidecodebin);
+          gst_play_bin_suburidecodebin_seek_to_start (group);
       }
       gst_object_unref (selector);
 
@@ -2040,6 +2160,17 @@
       GstSourceGroup *group;
 
       GST_PLAY_BIN_LOCK (playbin);
+      group = playbin->next_group;
+      g_value_set_string (value, group->uri);
+      GST_PLAY_BIN_UNLOCK (playbin);
+      break;
+      break;
+    }
+    case PROP_CURRENT_URI:
+    {
+      GstSourceGroup *group;
+
+      GST_PLAY_BIN_LOCK (playbin);
       group = get_group (playbin);
       g_value_set_string (value, group->uri);
       GST_PLAY_BIN_UNLOCK (playbin);
@@ -2050,6 +2181,16 @@
       GstSourceGroup *group;
 
       GST_PLAY_BIN_LOCK (playbin);
+      group = playbin->next_group;
+      g_value_set_string (value, group->suburi);
+      GST_PLAY_BIN_UNLOCK (playbin);
+      break;
+    }
+    case PROP_CURRENT_SUBURI:
+    {
+      GstSourceGroup *group;
+
+      GST_PLAY_BIN_LOCK (playbin);
       group = get_group (playbin);
       g_value_set_string (value, group->suburi);
       GST_PLAY_BIN_UNLOCK (playbin);
@@ -2463,23 +2604,48 @@
       property = "current-video";
       playbin->current_video = get_current_stream_number (playbin,
           group->video_channels);
+
+      if (playbin->video_pending_flush_finish) {
+        playbin->video_pending_flush_finish = FALSE;
+        GST_PLAY_BIN_UNLOCK (playbin);
+        gst_playbin2_send_custom_event (GST_OBJECT (selector),
+            "playsink-custom-video-flush-finish");
+        goto notify;
+      }
       break;
     case GST_PLAY_SINK_TYPE_AUDIO:
     case GST_PLAY_SINK_TYPE_AUDIO_RAW:
       property = "current-audio";
       playbin->current_audio = get_current_stream_number (playbin,
           group->audio_channels);
+
+      if (playbin->audio_pending_flush_finish) {
+        playbin->audio_pending_flush_finish = FALSE;
+        GST_PLAY_BIN_UNLOCK (playbin);
+        gst_playbin2_send_custom_event (GST_OBJECT (selector),
+            "playsink-custom-audio-flush-finish");
+        goto notify;
+      }
       break;
     case GST_PLAY_SINK_TYPE_TEXT:
       property = "current-text";
       playbin->current_text = get_current_stream_number (playbin,
           group->text_channels);
+
+      if (playbin->text_pending_flush_finish) {
+        playbin->text_pending_flush_finish = FALSE;
+        GST_PLAY_BIN_UNLOCK (playbin);
+        gst_playbin2_send_custom_event (GST_OBJECT (selector),
+            "playsink-custom-subtitle-flush-finish");
+        goto notify;
+      }
       break;
     default:
       property = NULL;
   }
   GST_PLAY_BIN_UNLOCK (playbin);
 
+notify:
   if (property)
     g_object_notify (G_OBJECT (playbin), property);
 }
@@ -2518,6 +2684,35 @@
   }
 }
 
+static GstPadProbeReturn
+_suburidecodebin_event_probe (GstPad * pad, GstPadProbeInfo * info,
+    gpointer udata)
+{
+  GstPadProbeReturn ret = GST_PAD_PROBE_OK;
+  GstSourceGroup *group = udata;
+  GstEvent *event = GST_PAD_PROBE_INFO_DATA (info);
+
+  switch (GST_EVENT_TYPE (event)) {
+    case GST_EVENT_FLUSH_START:
+    case GST_EVENT_FLUSH_STOP:
+    {
+      guint32 seqnum = gst_event_get_seqnum (event);
+      GSList *item = g_slist_find (group->suburi_flushes_to_drop,
+          GUINT_TO_POINTER (seqnum));
+      if (item) {
+        ret = GST_PAD_PROBE_DROP;       /* this is from subtitle seek only, drop it */
+        if (GST_EVENT_TYPE (event) == GST_EVENT_FLUSH_STOP) {
+          group->suburi_flushes_to_drop =
+              g_slist_delete_link (group->suburi_flushes_to_drop, item);
+        }
+      }
+    }
+    default:
+      break;
+  }
+  return ret;
+}
+
 /* helper function to lookup stuff in lists */
 static gboolean
 array_has_value (const gchar * values[], const gchar * value, gboolean exact)
@@ -2638,7 +2833,12 @@
           (_("Missing element '%s' - check your GStreamer installation."),
               "input-selector"), (NULL));
     } else {
-      g_object_set (select->selector, "sync-streams", TRUE, NULL);
+      /* sync-mode=1, use clock */
+      if (select->type == GST_PLAY_SINK_TYPE_TEXT)
+        g_object_set (select->selector, "sync-streams", TRUE,
+            "sync-mode", 1, "cache-buffers", TRUE, NULL);
+      else
+        g_object_set (select->selector, "sync-streams", TRUE, NULL);
 
       g_signal_connect (select->selector, "notify::active-pad",
           G_CALLBACK (selector_active_pad_changed), playbin);
@@ -2721,6 +2921,13 @@
   }
   GST_SOURCE_GROUP_UNLOCK (group);
 
+  if (decodebin == group->suburidecodebin) {
+    /* TODO store the probe id */
+    /* to avoid propagating flushes from suburi specific seeks */
+    gst_pad_add_probe (pad, GST_PAD_PROBE_TYPE_EVENT_DOWNSTREAM,
+        _suburidecodebin_event_probe, group, NULL);
+  }
+
   if (changed) {
     int signal;
     gboolean always_ok = (decodebin == group->suburidecodebin);
@@ -2988,7 +3195,7 @@
           gst_structure_set (s, "suburi", G_TYPE_STRING, group->suburi, NULL);
         msg = gst_message_new_element (GST_OBJECT_CAST (playbin), s);
         seqnum = gst_message_get_seqnum (msg);
-        event = gst_event_new_sink_message (msg);
+        event = gst_event_new_sink_message ("GstPlaybin", msg);
         g_mutex_lock (&group->stream_changed_pending_lock);
         group->stream_changed_pending =
             g_list_prepend (group->stream_changed_pending,
@@ -3563,6 +3770,11 @@
   if (!group->stream_changed_pending_lock.p)
     g_mutex_init (&group->stream_changed_pending_lock);
 
+  g_slist_free (group->suburi_flushes_to_drop);
+  group->suburi_flushes_to_drop = NULL;
+  if (!group->suburi_flushes_to_drop_lock.p)
+    g_mutex_init (&group->suburi_flushes_to_drop_lock);
+
   if (group->uridecodebin) {
     GST_DEBUG_OBJECT (playbin, "reusing existing uridecodebin");
     uridecodebin = group->uridecodebin;
diff --git a/gst/playback/gstplaysink.c b/gst/playback/gstplaysink.c
index 33ca446..c17b278 100644
--- a/gst/playback/gstplaysink.c
+++ b/gst/playback/gstplaysink.c
@@ -256,6 +256,25 @@
   GstColorBalance *colorbalance_element;
   GList *colorbalance_channels; /* CONTRAST, BRIGHTNESS, HUE, SATURATION */
   gint colorbalance_values[4];
+
+  /* sending audio/video flushes break stream changes when the pipeline
+   * is paused and played again in 0.10 */
+#if 0
+  GstSegment video_segment;
+  gboolean video_custom_flush_finished;
+  gboolean video_ignore_wrong_state;
+  gboolean video_pending_flush;
+
+  GstSegment audio_segment;
+  gboolean audio_custom_flush_finished;
+  gboolean audio_ignore_wrong_state;
+  gboolean audio_pending_flush;
+#endif
+
+  GstSegment text_segment;
+  gboolean text_custom_flush_finished;
+  gboolean text_ignore_wrong_state;
+  gboolean text_pending_flush;
 };
 
 struct _GstPlaySinkClass
@@ -339,6 +358,21 @@
 
 static void gst_play_sink_handle_message (GstBin * bin, GstMessage * message);
 
+/* sending audio/video flushes break stream changes when the pipeline
+ * is paused and played again in 0.10 */
+#if 0
+static gboolean gst_play_sink_video_sink_event (GstPad * pad, GstEvent * event);
+static GstFlowReturn gst_play_sink_video_sink_chain (GstPad * pad,
+    GstBuffer * buffer);
+static gboolean gst_play_sink_audio_sink_event (GstPad * pad, GstEvent * event);
+static GstFlowReturn gst_play_sink_audio_sink_chain (GstPad * pad,
+    GstBuffer * buffer);
+#endif
+static gboolean gst_play_sink_text_sink_event (GstPad * pad, GstObject * parent,
+    GstEvent * event);
+static GstFlowReturn gst_play_sink_text_sink_chain (GstPad * pad,
+    GstObject * parent, GstBuffer * buffer);
+
 static void notify_volume_cb (GObject * object, GParamSpec * pspec,
     GstPlaySink * playsink);
 static void notify_mute_cb (GObject * object, GParamSpec * pspec,
@@ -346,6 +380,8 @@
 
 static void update_av_offset (GstPlaySink * playsink);
 
+static GQuark _playsink_reset_segment_event_marker_id = 0;
+
 /* static guint gst_play_sink_signals[LAST_SIGNAL] = { 0 }; */
 
 static void gst_play_sink_overlay_init (gpointer g_iface,
@@ -502,7 +538,7 @@
    */
   g_object_class_install_property (gobject_klass, PROP_TEXT_SINK,
       g_param_spec_object ("text-sink", "Text sink",
-          "the text output element to use (NULL = default textoverlay)",
+          "the text output element to use (NULL = default subtitleoverlay)",
           GST_TYPE_ELEMENT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
 
   /**
@@ -572,6 +608,9 @@
 
   klass->reconfigure = GST_DEBUG_FUNCPTR (gst_play_sink_reconfigure);
   klass->convert_sample = GST_DEBUG_FUNCPTR (gst_play_sink_convert_sample);
+
+  _playsink_reset_segment_event_marker_id =
+      g_quark_from_static_string ("gst-playsink-reset-segment-event-marker");
 }
 
 static void
@@ -1189,9 +1228,10 @@
     found = gst_iterator_find_custom (it,
         (GCompareFunc) find_property, &item, &helper);
     gst_iterator_free (it);
-    if (found)
+    if (found) {
       result = g_value_dup_object (&item);
-    g_value_unset (&item);
+      g_value_unset (&item);
+    }
   } else {
     if (element_has_property (obj, name, expected_type)) {
       result = obj;
@@ -1679,8 +1719,17 @@
 
   pad = gst_element_get_static_pad (head, "sink");
   chain->sinkpad = gst_ghost_pad_new ("sink", pad);
-  gst_object_unref (pad);
 
+  /* sending audio/video flushes break stream changes when the pipeline
+   * is paused and played again in 0.10 */
+#if 0
+  gst_pad_set_event_function (chain->sinkpad,
+      GST_DEBUG_FUNCPTR (gst_play_sink_video_sink_event));
+  gst_pad_set_chain_function (chain->sinkpad,
+      GST_DEBUG_FUNCPTR (gst_play_sink_video_sink_chain));
+#endif
+
+  gst_object_unref (pad);
   gst_element_add_pad (chain->chain.bin, chain->sinkpad);
 
   return chain;
@@ -1833,6 +1882,312 @@
   return TRUE;
 }
 
+static void
+_generate_update_newsegment_event (GstPad * pad, GstSegment * segment,
+    GstEvent ** event1)
+{
+  GstEvent *event;
+  GstStructure *structure;
+  event = gst_event_new_segment (segment);
+  structure = gst_event_writable_structure (event);
+  gst_structure_id_set (structure,
+      _playsink_reset_segment_event_marker_id, G_TYPE_BOOLEAN, TRUE, NULL);
+  *event1 = event;
+}
+
+static gboolean
+gst_play_sink_sink_event (GstPad * pad, GstObject * parent, GstEvent * event,
+    const gchar * sink_type,
+    gboolean * sink_ignore_wrong_state,
+    gboolean * sink_custom_flush_finished,
+    gboolean * sink_pending_flush, GstSegment * sink_segment)
+{
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_object_get_parent (parent));
+  gboolean ret;
+  const GstStructure *structure = gst_event_get_structure (event);
+
+  if (GST_EVENT_TYPE (event) == GST_EVENT_CUSTOM_DOWNSTREAM_OOB && structure) {
+    gchar *custom_flush;
+    gchar *custom_flush_finish;
+
+    custom_flush = g_strdup_printf ("playsink-custom-%s-flush", sink_type);
+    custom_flush_finish =
+        g_strdup_printf ("playsink-custom-%s-flush-finish", sink_type);
+    if (strcmp (gst_structure_get_name (structure), custom_flush) == 0) {
+      GST_DEBUG_OBJECT (pad,
+          "Custom %s flush event received, marking to flush %s", sink_type,
+          sink_type);
+      GST_PLAY_SINK_LOCK (playsink);
+      *sink_ignore_wrong_state = TRUE;
+      *sink_custom_flush_finished = FALSE;
+      GST_PLAY_SINK_UNLOCK (playsink);
+    } else if (strcmp (gst_structure_get_name (structure),
+            custom_flush_finish) == 0) {
+      GST_DEBUG_OBJECT (pad, "Custom %s flush finish event received",
+          sink_type);
+      GST_PLAY_SINK_LOCK (playsink);
+      *sink_pending_flush = TRUE;
+      *sink_custom_flush_finished = TRUE;
+      GST_PLAY_SINK_UNLOCK (playsink);
+    }
+
+    g_free (custom_flush);
+    g_free (custom_flush_finish);
+  } else if (GST_EVENT_TYPE (event) == GST_EVENT_FLUSH_STOP) {
+    GST_PLAY_SINK_LOCK (playsink);
+    GST_DEBUG_OBJECT (pad, "Resetting %s segment because of flush-stop event",
+        sink_type);
+    gst_segment_init (sink_segment, GST_FORMAT_UNDEFINED);
+    GST_PLAY_SINK_UNLOCK (playsink);
+  }
+
+  GST_DEBUG_OBJECT (pad, "Forwarding event %" GST_PTR_FORMAT, event);
+  ret = gst_proxy_pad_event_default (pad, parent, gst_event_ref (event));
+
+  if (GST_EVENT_TYPE (event) == GST_EVENT_SEGMENT) {
+    const GstSegment *segment;
+
+    gst_event_parse_segment (event, &segment);
+    GST_DEBUG_OBJECT (pad, "Segment event: %" GST_SEGMENT_FORMAT, segment);
+
+    GST_PLAY_SINK_LOCK (playsink);
+    if (sink_segment->format != segment->format) {
+      GST_DEBUG_OBJECT (pad, "%s segment format changed: %s -> %s",
+          sink_type,
+          gst_format_get_name (sink_segment->format),
+          gst_format_get_name (segment->format));
+      gst_segment_init (sink_segment, segment->format);
+    }
+
+    GST_DEBUG_OBJECT (pad, "Old %s segment: %" GST_SEGMENT_FORMAT,
+        sink_type, sink_segment);
+    gst_segment_copy_into (&playsink->text_segment, sink_segment);
+    GST_DEBUG_OBJECT (pad, "New %s segment: %" GST_SEGMENT_FORMAT,
+        sink_type, sink_segment);
+    GST_PLAY_SINK_UNLOCK (playsink);
+  }
+
+  gst_event_unref (event);
+  gst_object_unref (playsink);
+  return ret;
+}
+
+static GstFlowReturn
+gst_play_sink_sink_chain (GstPad * pad, GstObject * parent, GstBuffer * buffer,
+    const gchar * sink_type,
+    gboolean * sink_ignore_wrong_state,
+    gboolean * sink_custom_flush_finished,
+    gboolean * sink_pending_flush, GstSegment * sink_segment)
+{
+  GstBin *tbin = GST_BIN_CAST (gst_pad_get_parent (pad));
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_pad_get_parent (tbin));
+  GstFlowReturn ret;
+
+  GST_PLAY_SINK_LOCK (playsink);
+
+  if (*sink_pending_flush) {
+    GstEvent *event;
+    GstStructure *structure;
+
+    *sink_pending_flush = FALSE;
+
+    GST_PLAY_SINK_UNLOCK (playsink);
+
+    /* make the bin drop all cached data.
+     * This event will be dropped on the src pad, if any. */
+    event = gst_event_new_flush_start ();
+    structure = gst_event_writable_structure (event);
+    gst_structure_id_set (structure,
+        _playsink_reset_segment_event_marker_id, G_TYPE_BOOLEAN, TRUE, NULL);
+
+    GST_DEBUG_OBJECT (pad,
+        "Pushing %s flush-start event with reset segment marker set: %"
+        GST_PTR_FORMAT, sink_type, event);
+    gst_pad_send_event (pad, event);
+
+    /* make queue drop all cached data.
+     * This event will be dropped on the src pad. */
+    event = gst_event_new_flush_stop (TRUE);
+    structure = gst_event_writable_structure (event);
+    gst_structure_id_set (structure,
+        _playsink_reset_segment_event_marker_id, G_TYPE_BOOLEAN, TRUE, NULL);
+
+    GST_DEBUG_OBJECT (pad,
+        "Pushing %s flush-stop event with reset segment marker set: %"
+        GST_PTR_FORMAT, sink_type, event);
+    gst_pad_send_event (pad, event);
+
+    /* Re-sync queue segment info after flush-stop.
+     * This event will be dropped on the src pad. */
+    if (sink_segment->format != GST_FORMAT_UNDEFINED) {
+      GstEvent *event1;
+
+      _generate_update_newsegment_event (pad, sink_segment, &event1);
+      GST_DEBUG_OBJECT (playsink,
+          "Pushing segment event with reset "
+          "segment marker set: %" GST_PTR_FORMAT, event1);
+      gst_pad_send_event (pad, event1);
+    }
+  } else {
+    GST_PLAY_SINK_UNLOCK (playsink);
+  }
+
+  ret = gst_proxy_pad_chain_default (pad, parent, buffer);
+
+  GST_PLAY_SINK_LOCK (playsink);
+  if (ret == GST_FLOW_FLUSHING && *sink_ignore_wrong_state) {
+    GST_DEBUG_OBJECT (pad, "Ignoring wrong state for %s during flush",
+        sink_type);
+    if (*sink_custom_flush_finished) {
+      GST_DEBUG_OBJECT (pad, "Custom flush finished, stop ignoring "
+          "wrong state for %s", sink_type);
+      *sink_ignore_wrong_state = FALSE;
+    }
+
+    ret = GST_FLOW_OK;
+  }
+  GST_PLAY_SINK_UNLOCK (playsink);
+
+  gst_object_unref (playsink);
+  gst_object_unref (tbin);
+  return ret;
+}
+
+/* sending audio/video flushes break stream changes when the pipeline
+ * is paused and played again in 0.10 */
+#if 0
+static gboolean
+gst_play_sink_video_sink_event (GstPad * pad, GstEvent * event)
+{
+  GstBin *tbin = GST_BIN_CAST (gst_pad_get_parent (pad));
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_pad_get_parent (tbin));
+  gboolean ret;
+
+  ret = gst_play_sink_sink_event (pad, event, "video",
+      &playsink->video_ignore_wrong_state,
+      &playsink->video_custom_flush_finished,
+      &playsink->video_pending_flush, &playsink->video_segment);
+
+  gst_object_unref (playsink);
+  gst_object_unref (tbin);
+  return ret;
+}
+
+static GstFlowReturn
+gst_play_sink_video_sink_chain (GstPad * pad, GstBuffer * buffer)
+{
+  GstBin *tbin = GST_BIN_CAST (gst_pad_get_parent (pad));
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_pad_get_parent (tbin));
+  gboolean ret;
+
+  ret = gst_play_sink_sink_chain (pad, buffer, "video",
+      &playsink->video_ignore_wrong_state,
+      &playsink->video_custom_flush_finished,
+      &playsink->video_pending_flush, &playsink->video_segment);
+
+  gst_object_unref (playsink);
+  gst_object_unref (tbin);
+  return ret;
+}
+
+static gboolean
+gst_play_sink_audio_sink_event (GstPad * pad, GstEvent * event)
+{
+  GstBin *tbin = GST_BIN_CAST (gst_pad_get_parent (pad));
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_pad_get_parent (tbin));
+  gboolean ret;
+
+  ret = gst_play_sink_sink_event (pad, event, "audio",
+      &playsink->audio_ignore_wrong_state,
+      &playsink->audio_custom_flush_finished,
+      &playsink->audio_pending_flush, &playsink->audio_segment);
+
+  gst_object_unref (playsink);
+  gst_object_unref (tbin);
+  return ret;
+}
+
+static GstFlowReturn
+gst_play_sink_audio_sink_chain (GstPad * pad, GstBuffer * buffer)
+{
+  GstBin *tbin = GST_BIN_CAST (gst_pad_get_parent (pad));
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_pad_get_parent (tbin));
+  gboolean ret;
+
+  ret = gst_play_sink_sink_chain (pad, buffer, "audio",
+      &playsink->audio_ignore_wrong_state,
+      &playsink->audio_custom_flush_finished,
+      &playsink->audio_pending_flush, &playsink->audio_segment);
+
+  gst_object_unref (playsink);
+  gst_object_unref (tbin);
+  return ret;
+}
+#endif
+
+static gboolean
+gst_play_sink_text_sink_event (GstPad * pad, GstObject * parent,
+    GstEvent * event)
+{
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_object_get_parent (parent));
+  gboolean ret;
+
+  ret = gst_play_sink_sink_event (pad, parent, event, "subtitle",
+      &playsink->text_ignore_wrong_state,
+      &playsink->text_custom_flush_finished,
+      &playsink->text_pending_flush, &playsink->text_segment);
+
+  gst_object_unref (playsink);
+
+  return ret;
+}
+
+static GstFlowReturn
+gst_play_sink_text_sink_chain (GstPad * pad, GstObject * parent,
+    GstBuffer * buffer)
+{
+  gboolean ret;
+  GstPlaySink *playsink = GST_PLAY_SINK_CAST (gst_object_get_parent (parent));
+
+  ret = gst_play_sink_sink_chain (pad, parent, buffer, "subtitle",
+      &playsink->text_ignore_wrong_state,
+      &playsink->text_custom_flush_finished,
+      &playsink->text_pending_flush, &playsink->text_segment);
+
+  gst_object_unref (playsink);
+  return ret;
+}
+
+static gboolean
+gst_play_sink_text_src_event (GstPad * pad, GstObject * parent,
+    GstEvent * event)
+{
+  gboolean ret;
+  const GstStructure *structure;
+
+  GST_DEBUG_OBJECT (pad, "Got event %" GST_PTR_FORMAT, event);
+
+  structure = gst_event_get_structure (event);
+
+  if (structure &&
+      gst_structure_id_has_field (structure,
+          _playsink_reset_segment_event_marker_id)) {
+    /* the events marked with a reset segment marker
+     * are sent internally to reset the queue and
+     * must be dropped here */
+    GST_DEBUG_OBJECT (pad, "Dropping event with reset "
+        "segment marker set: %" GST_PTR_FORMAT, event);
+    ret = TRUE;
+    goto out;
+  }
+
+  ret = gst_proxy_pad_event_default (pad, parent, gst_event_ref (event));
+
+out:
+  gst_event_unref (event);
+  return ret;
+}
+
 /* make an element for playback of video with subtitles embedded.
  * Only used for *raw* video streams.
  *
@@ -1889,7 +2244,7 @@
                   "queue"), ("rendering might be suboptimal"));
         } else {
           g_object_set (G_OBJECT (chain->queue), "max-size-buffers", 3,
-              "max-size-bytes", 0, "max-size-time", (gint64) 0,
+              "max-size-bytes", 0, "max-size-time", (gint64) GST_SECOND,
               "silent", TRUE, NULL);
           gst_bin_add (bin, chain->queue);
         }
@@ -1923,7 +2278,7 @@
     if (textsinkpad == NULL) {
       GST_ELEMENT_WARNING (playsink, CORE, MISSING_PLUGIN,
           (_("Custom text sink element is not usable.")),
-          ("fallback to default textoverlay"));
+          ("fallback to default subtitleoverlay"));
     }
   }
 
@@ -1978,7 +2333,7 @@
                   "queue"), ("rendering might be suboptimal"));
         } else {
           g_object_set (G_OBJECT (element), "max-size-buffers", 3,
-              "max-size-bytes", 0, "max-size-time", (gint64) 0,
+              "max-size-bytes", 0, "max-size-time", (gint64) GST_SECOND,
               "silent", TRUE, NULL);
           gst_bin_add (bin, element);
           if (gst_element_link_pads_full (element, "src", chain->overlay,
@@ -2026,11 +2381,21 @@
   if (textsinkpad) {
     chain->textsinkpad = gst_ghost_pad_new ("text_sink", textsinkpad);
     gst_object_unref (textsinkpad);
+
+    gst_pad_set_event_function (chain->textsinkpad,
+        GST_DEBUG_FUNCPTR (gst_play_sink_text_sink_event));
+    gst_pad_set_chain_function (chain->textsinkpad,
+        GST_DEBUG_FUNCPTR (gst_play_sink_text_sink_chain));
+
     gst_element_add_pad (chain->chain.bin, chain->textsinkpad);
   }
   if (srcpad) {
     chain->srcpad = gst_ghost_pad_new ("src", srcpad);
     gst_object_unref (srcpad);
+
+    gst_pad_set_event_function (chain->srcpad,
+        GST_DEBUG_FUNCPTR (gst_play_sink_text_src_event));
+
     gst_element_add_pad (chain->chain.bin, chain->srcpad);
   }
 
@@ -2251,6 +2616,16 @@
   GST_DEBUG_OBJECT (playsink, "ghosting sink pad");
   pad = gst_element_get_static_pad (head, "sink");
   chain->sinkpad = gst_ghost_pad_new ("sink", pad);
+
+  /* sending audio/video flushes break stream changes when the pipeline
+   * is paused and played again in 0.10 */
+#if 0
+  gst_pad_set_event_function (chain->sinkpad,
+      GST_DEBUG_FUNCPTR (gst_play_sink_audio_sink_event));
+  gst_pad_set_chain_function (chain->sinkpad,
+      GST_DEBUG_FUNCPTR (gst_play_sink_audio_sink_chain));
+#endif
+
   gst_object_unref (pad);
   gst_element_add_pad (chain->chain.bin, chain->sinkpad);
 
@@ -3532,7 +3907,7 @@
     block_id = &playsink->text_block_id;
   }
 
-  if (type != GST_PLAY_SINK_TYPE_FLUSHING) {
+  if (type != GST_PLAY_SINK_TYPE_FLUSHING && (block_id && *block_id == 0)) {
     GstPad *blockpad =
         GST_PAD_CAST (gst_proxy_pad_get_internal (GST_PROXY_PAD (pad)));
 
@@ -3953,6 +4328,8 @@
   playsink = GST_PLAY_SINK (element);
   switch (transition) {
     case GST_STATE_CHANGE_READY_TO_PAUSED:
+      gst_segment_init (&playsink->text_segment, GST_FORMAT_UNDEFINED);
+
       playsink->need_async_start = TRUE;
       /* we want to go async to PAUSED until we managed to configure and add the
        * sinks */
diff --git a/gst/playback/gstsubtitleoverlay.c b/gst/playback/gstsubtitleoverlay.c
index c20bf3c..e88d345 100644
--- a/gst/playback/gstsubtitleoverlay.c
+++ b/gst/playback/gstsubtitleoverlay.c
@@ -608,13 +608,80 @@
   }
 }
 
+static gboolean
+_pad_query_convert_to_time (GstPad * pad, GstFormat src_format, gint64 src_val,
+    gint64 * dest_val)
+{
+  GstFormat dest_format;
+
+  if (src_val == GST_CLOCK_TIME_NONE) {
+    *dest_val = GST_CLOCK_TIME_NONE;
+    return TRUE;
+  }
+
+  dest_format = GST_FORMAT_TIME;
+  return gst_pad_query_convert (pad, src_format, src_val, dest_format,
+      dest_val);
+}
+
 static void
-_generate_update_segment_event (GstSegment * segment, GstEvent ** event1)
+_generate_update_segment_event (GstPad * pad, GstSegment * segment,
+    GstEvent ** event1)
 {
   GstEvent *event;
   GstStructure *structure;
+  GstSegment newsegment;
+  gboolean use_newseg = FALSE;
+  gint64 start, stop, base, time, position, duration;
 
-  event = gst_event_new_segment (segment);
+  /* always push newsegment with format TIME */
+  if (segment->format != GST_FORMAT_TIME) {
+    gboolean res;
+    GstPad *peer;
+
+    peer = gst_pad_get_peer (pad);
+    if (peer) {
+      res = _pad_query_convert_to_time (peer, segment->format,
+          segment->start, &start);
+      res = res && _pad_query_convert_to_time (peer, segment->format,
+          segment->stop, &stop);
+      res = res && _pad_query_convert_to_time (peer, segment->format,
+          segment->time, &time);
+      res = res && _pad_query_convert_to_time (peer, segment->format,
+          segment->base, &base);
+      res = res && _pad_query_convert_to_time (peer, segment->format,
+          segment->position, &position);
+      res = res && _pad_query_convert_to_time (peer, segment->format,
+          segment->duration, &duration);
+      if (!res) {
+        start = 0;
+        stop = GST_CLOCK_TIME_NONE;
+        time = 0;
+        position = 0;
+        duration = GST_CLOCK_TIME_NONE;
+        base = 0;
+      } else {
+        use_newseg = TRUE;
+        gst_segment_init (&newsegment, GST_FORMAT_TIME);
+        newsegment.rate = segment->rate;
+        newsegment.applied_rate = segment->applied_rate;
+        newsegment.start = start;
+        newsegment.stop = stop;
+        newsegment.time = time;
+        newsegment.base = base;
+        newsegment.position = position;
+        newsegment.duration = duration;
+      }
+
+      gst_object_unref (peer);
+    }
+  }
+
+  if (use_newseg) {
+    event = gst_event_new_segment (&newsegment);
+  } else {
+    event = gst_event_new_segment (segment);
+  }
   structure = gst_event_writable_structure (event);
   gst_structure_id_set (structure, _subtitle_overlay_event_marker_id,
       G_TYPE_BOOLEAN, TRUE, NULL);
@@ -684,7 +751,7 @@
   if (self->video_segment.format != GST_FORMAT_UNDEFINED) {
     GstEvent *event1;
 
-    _generate_update_segment_event (&self->video_segment, &event1);
+    _generate_update_segment_event (sink, &self->video_segment, &event1);
     GST_DEBUG_OBJECT (self,
         "Pushing video segment event: %" GST_PTR_FORMAT, event1);
     gst_pad_send_event (sink, event1);
@@ -1313,7 +1380,7 @@
       sink = _get_video_pad ((self->renderer) ? self->renderer : self->overlay);
     }
 
-    _generate_update_segment_event (&self->video_segment, &event1);
+    _generate_update_segment_event (sink, &self->video_segment, &event1);
     GST_DEBUG_OBJECT (self,
         "Pushing video update segment event: %" GST_PTR_FORMAT,
         gst_event_get_structure (event1));
@@ -1330,7 +1397,7 @@
     else
       sink = gst_element_get_static_pad (self->parser, "sink");
 
-    _generate_update_segment_event (&self->subtitle_segment, &event1);
+    _generate_update_segment_event (sink, &self->subtitle_segment, &event1);
     GST_DEBUG_OBJECT (self,
         "Pushing subtitle update segment event: %" GST_PTR_FORMAT,
         gst_event_get_structure (event1));
@@ -1996,8 +2063,10 @@
   GstSubtitleOverlay *self = GST_SUBTITLE_OVERLAY (parent);
   gboolean ret;
 
+  GST_DEBUG_OBJECT (pad, "Got event %" GST_PTR_FORMAT, event);
+
   if (GST_EVENT_TYPE (event) == GST_EVENT_CUSTOM_DOWNSTREAM_OOB &&
-      gst_event_has_name (event, "subtitleoverlay-flush-subtitle")) {
+      gst_event_has_name (event, "playsink-custom-subtitle-flush")) {
     GST_DEBUG_OBJECT (pad, "Custom subtitle flush event");
     GST_SUBTITLE_OVERLAY_LOCK (self);
     self->subtitle_flush = TRUE;
@@ -2050,8 +2119,68 @@
   ret = gst_proxy_pad_event_default (pad, parent, gst_event_ref (event));
 
   if (GST_EVENT_TYPE (event) == GST_EVENT_SEGMENT) {
+    const GstSegment *eventsegment;
     GST_DEBUG_OBJECT (pad, "segment event: %" GST_PTR_FORMAT, event);
-    gst_event_copy_segment (event, &self->subtitle_segment);
+
+    gst_event_parse_segment (event, &eventsegment);
+
+    if (eventsegment->format == GST_FORMAT_TIME) {
+      gst_event_copy_segment (event, &self->subtitle_segment);
+    } else {
+      GstPad *peer;
+      gboolean res = FALSE;
+      gint64 tstart = 0;
+      gint64 tstop = GST_CLOCK_TIME_NONE;
+      gint64 tposition = 0;
+      gint64 tduration = 0;
+      gint64 ttime = 0;
+      gint64 tbase = 0;
+      GstFormat format = eventsegment->format;
+
+      GST_DEBUG_OBJECT (pad, "Subtitle newsegment event (%s) not in TIME "
+          "format, converting", gst_format_get_name (format));
+      peer = gst_pad_get_peer (pad);
+
+      if (peer) {
+        res =
+            _pad_query_convert_to_time (peer, format, eventsegment->start,
+            &tstart);
+        res = res
+            && _pad_query_convert_to_time (peer, format, eventsegment->stop,
+            &tstop);
+        res = res
+            && _pad_query_convert_to_time (peer, format, eventsegment->position,
+            &tposition);
+        res = res
+            && _pad_query_convert_to_time (peer, format, eventsegment->base,
+            &tbase);
+        res = res
+            && _pad_query_convert_to_time (peer, format, eventsegment->time,
+            &ttime);
+        res = res
+            && _pad_query_convert_to_time (peer, format, eventsegment->duration,
+            &tduration);
+
+        gst_object_unref (peer);
+      }
+
+      if (!res) {
+        tstart = 0;
+        tstop = GST_CLOCK_TIME_NONE;
+        tposition = 0;
+        tduration = GST_CLOCK_TIME_NONE;
+        ttime = 0;
+        tbase = 0;
+      }
+
+      gst_segment_init (&self->subtitle_segment, GST_FORMAT_TIME);
+      self->subtitle_segment.start = tstart;
+      self->subtitle_segment.stop = tstop;
+      self->subtitle_segment.base = tbase;
+      self->subtitle_segment.time = ttime;
+      self->subtitle_segment.position = tposition;
+      self->subtitle_segment.duration = tduration;
+    }
     GST_DEBUG_OBJECT (pad, "New subtitle segment: %" GST_SEGMENT_FORMAT,
         &self->subtitle_segment);
   }
diff --git a/gst/playback/gsturidecodebin.c b/gst/playback/gsturidecodebin.c
index ce61b86..3054899 100644
--- a/gst/playback/gsturidecodebin.c
+++ b/gst/playback/gsturidecodebin.c
@@ -1810,7 +1810,7 @@
     gchar *temp_template, *filename;
     const gchar *tmp_dir, *prgname;
 
-    tmp_dir = g_get_tmp_dir ();
+    tmp_dir = g_get_user_cache_dir ();
     prgname = g_get_prgname ();
     if (prgname == NULL)
       prgname = "GStreamer";
diff --git a/gst/subparse/Makefile.in b/gst/subparse/Makefile.in
index 14e3f04..034400a 100644
--- a/gst/subparse/Makefile.in
+++ b/gst/subparse/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/subparse
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -287,8 +288,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -459,7 +466,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/subparse/gstssaparse.c b/gst/subparse/gstssaparse.c
index bea39b6..0749bd2 100644
--- a/gst/subparse/gstssaparse.c
+++ b/gst/subparse/gstssaparse.c
@@ -341,7 +341,7 @@
     tags = gst_tag_list_new_empty ();
     gst_tag_list_add (tags, GST_TAG_MERGE_APPEND, GST_TAG_SUBTITLE_CODEC,
         "SubStation Alpha", NULL);
-    gst_pad_push_event (parse->srcpad, gst_event_new_tag (tags));
+    gst_pad_push_event (parse->srcpad, gst_event_new_tag ("GstParser", tags));
     parse->send_tags = FALSE;
   }
 
diff --git a/gst/subparse/gstsubparse.c b/gst/subparse/gstsubparse.c
index fa98efd..3d6d31b 100644
--- a/gst/subparse/gstsubparse.c
+++ b/gst/subparse/gstsubparse.c
@@ -1468,7 +1468,7 @@
 
       tags = gst_tag_list_new (GST_TAG_SUBTITLE_CODEC, self->subtitle_codec,
           NULL);
-      gst_pad_push_event (self->srcpad, gst_event_new_tag (tags));
+      gst_pad_push_event (self->srcpad, gst_event_new_tag ("GstParser", tags));
     }
   }
 
diff --git a/gst/tcp/Makefile.in b/gst/tcp/Makefile.in
index 7b50060..4c24175 100644
--- a/gst/tcp/Makefile.in
+++ b/gst/tcp/Makefile.in
@@ -60,6 +60,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/gst-glib-gen.mak
 subdir = gst/tcp
@@ -301,8 +302,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -473,7 +480,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/typefind/Makefile.in b/gst/typefind/Makefile.in
index 24e9a83..0021e11 100644
--- a/gst/typefind/Makefile.in
+++ b/gst/typefind/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/typefind
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -279,8 +280,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -451,7 +458,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/typefind/gsttypefindfunctions.c b/gst/typefind/gsttypefindfunctions.c
index a02b12f..8e8c5df 100644
--- a/gst/typefind/gsttypefindfunctions.c
+++ b/gst/typefind/gsttypefindfunctions.c
@@ -3769,12 +3769,11 @@
 }
 
 
-/*** Ogg and Annodex variants ***/
-static GstStaticCaps ogg_annodex_caps =
-    GST_STATIC_CAPS ("application/ogg;video/ogg;audio/ogg;"
-    "application/annodex;audio/annodex;video/annodex;application/kate");
+/*** Ogg variants ***/
+static GstStaticCaps ogg_caps =
+    GST_STATIC_CAPS ("application/ogg;video/ogg;audio/ogg;application/kate");
 
-#define OGGANX_CAPS (gst_static_caps_get(&ogg_annodex_caps))
+#define OGG_CAPS (gst_static_caps_get(&ogg_caps))
 
 typedef enum
 {
@@ -3864,15 +3863,8 @@
   if (ogg_syncs == 0)
     return;
 
-  /* FIXME: what about XSPF? */
-  if (hdr_count[OGG_ANNODEX] > 0) {
-    if (hdr_count[OGG_VIDEO] > 0)
-      media_type = "video/annodex";
-    else if (hdr_count[OGG_AUDIO] > 0)
-      media_type = "audio/annodex";
-    else
-      media_type = "application/annodex";
-  } else if (hdr_count[OGG_VIDEO] > 0) {
+  /* We don't bother with annodex types. FIXME: what about XSPF? */
+  if (hdr_count[OGG_VIDEO] > 0) {
     media_type = "video/ogg";
   } else if (hdr_count[OGG_AUDIO] > 0) {
     media_type = "audio/ogg";
@@ -4729,7 +4721,7 @@
   TYPE_FIND_REGISTER (plugin, "video/mpegts", GST_RANK_PRIMARY,
       mpeg_ts_type_find, "ts,mts", MPEGTS_CAPS, NULL, NULL);
   TYPE_FIND_REGISTER (plugin, "application/ogg", GST_RANK_PRIMARY,
-      ogganx_type_find, "ogg,oga,ogv,ogm,ogx,spx,anx,axa,axv", OGGANX_CAPS,
+      ogganx_type_find, "ogg,oga,ogv,ogm,ogx,spx,anx,axa,axv", OGG_CAPS,
       NULL, NULL);
   TYPE_FIND_REGISTER (plugin, "video/mpeg-elementary", GST_RANK_MARGINAL,
       mpeg_video_stream_type_find, "mpv,mpeg,mpg", MPEG_VIDEO_CAPS, NULL, NULL);
diff --git a/gst/videoconvert/Makefile.am b/gst/videoconvert/Makefile.am
index 4ef3697..2939d85 100644
--- a/gst/videoconvert/Makefile.am
+++ b/gst/videoconvert/Makefile.am
@@ -3,7 +3,7 @@
 ORC_SOURCE=gstvideoconvertorc
 include $(top_srcdir)/common/orc.mak
 
-libgstvideoconvert_la_SOURCES = gstvideoconvert.c videoconvert.c
+libgstvideoconvert_la_SOURCES = gstvideoconvert.c videoconvert.c gstcms.c
 nodist_libgstvideoconvert_la_SOURCES = $(ORC_NODIST_SOURCES)
 libgstvideoconvert_la_CFLAGS = \
 	$(GST_PLUGINS_BASE_CFLAGS) \
@@ -17,7 +17,7 @@
 libgstvideoconvert_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
 libgstvideoconvert_la_LIBTOOLFLAGS = --tag=disable-static
 
-noinst_HEADERS = gstvideoconvert.h videoconvert.h
+noinst_HEADERS = gstvideoconvert.h videoconvert.h gstcms.h
 
 Android.mk: Makefile.am $(BUILT_SOURCES)
 	androgenizer \
diff --git a/gst/videoconvert/Makefile.in b/gst/videoconvert/Makefile.in
index 865693e..00f5102 100644
--- a/gst/videoconvert/Makefile.in
+++ b/gst/videoconvert/Makefile.in
@@ -74,6 +74,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/orc.mak
 subdir = gst/videoconvert
@@ -156,7 +157,8 @@
 	$(am__DEPENDENCIES_1)
 am_libgstvideoconvert_la_OBJECTS =  \
 	libgstvideoconvert_la-gstvideoconvert.lo \
-	libgstvideoconvert_la-videoconvert.lo
+	libgstvideoconvert_la-videoconvert.lo \
+	libgstvideoconvert_la-gstcms.lo
 am__objects_1 = libgstvideoconvert_la-tmp-orc.lo
 nodist_libgstvideoconvert_la_OBJECTS = $(am__objects_1)
 libgstvideoconvert_la_OBJECTS = $(am_libgstvideoconvert_la_OBJECTS) \
@@ -307,8 +309,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -479,7 +487,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
@@ -494,7 +506,7 @@
 cp_v_gen = $(cp_v_gen_$(V))
 cp_v_gen_ = $(cp_v_gen_$(AM_DEFAULT_VERBOSITY))
 cp_v_gen_0 = @echo "  CP     $@";
-libgstvideoconvert_la_SOURCES = gstvideoconvert.c videoconvert.c
+libgstvideoconvert_la_SOURCES = gstvideoconvert.c videoconvert.c gstcms.c
 nodist_libgstvideoconvert_la_SOURCES = $(ORC_NODIST_SOURCES)
 libgstvideoconvert_la_CFLAGS = \
 	$(GST_PLUGINS_BASE_CFLAGS) \
@@ -509,7 +521,7 @@
 
 libgstvideoconvert_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
 libgstvideoconvert_la_LIBTOOLFLAGS = --tag=disable-static
-noinst_HEADERS = gstvideoconvert.h videoconvert.h
+noinst_HEADERS = gstvideoconvert.h videoconvert.h gstcms.h
 all: $(BUILT_SOURCES)
 	$(MAKE) $(AM_MAKEFLAGS) all-am
 
@@ -587,6 +599,7 @@
 distclean-compile:
 	-rm -f *.tab.c
 
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideoconvert_la-gstcms.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideoconvert_la-gstvideoconvert.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideoconvert_la-tmp-orc.Plo@am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libgstvideoconvert_la-videoconvert.Plo@am__quote@
@@ -626,6 +639,13 @@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
 @am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(libgstvideoconvert_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideoconvert_la_CFLAGS) $(CFLAGS) -c -o libgstvideoconvert_la-videoconvert.lo `test -f 'videoconvert.c' || echo '$(srcdir)/'`videoconvert.c
 
+libgstvideoconvert_la-gstcms.lo: gstcms.c
+@am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(libgstvideoconvert_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideoconvert_la_CFLAGS) $(CFLAGS) -MT libgstvideoconvert_la-gstcms.lo -MD -MP -MF $(DEPDIR)/libgstvideoconvert_la-gstcms.Tpo -c -o libgstvideoconvert_la-gstcms.lo `test -f 'gstcms.c' || echo '$(srcdir)/'`gstcms.c
+@am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideoconvert_la-gstcms.Tpo $(DEPDIR)/libgstvideoconvert_la-gstcms.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='gstcms.c' object='libgstvideoconvert_la-gstcms.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@	$(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(libgstvideoconvert_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideoconvert_la_CFLAGS) $(CFLAGS) -c -o libgstvideoconvert_la-gstcms.lo `test -f 'gstcms.c' || echo '$(srcdir)/'`gstcms.c
+
 libgstvideoconvert_la-tmp-orc.lo: tmp-orc.c
 @am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(libgstvideoconvert_la_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgstvideoconvert_la_CFLAGS) $(CFLAGS) -MT libgstvideoconvert_la-tmp-orc.lo -MD -MP -MF $(DEPDIR)/libgstvideoconvert_la-tmp-orc.Tpo -c -o libgstvideoconvert_la-tmp-orc.lo `test -f 'tmp-orc.c' || echo '$(srcdir)/'`tmp-orc.c
 @am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/libgstvideoconvert_la-tmp-orc.Tpo $(DEPDIR)/libgstvideoconvert_la-tmp-orc.Plo
diff --git a/gst/videoconvert/gstcms.c b/gst/videoconvert/gstcms.c
new file mode 100644
index 0000000..ae7367e
--- /dev/null
+++ b/gst/videoconvert/gstcms.c
@@ -0,0 +1,573 @@
+/* GStreamer
+ * Copyright (C) 2008 David Schleef <ds@entropywave.com>
+ *
+ * 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>
+#include <gst/math-compat.h>
+#include "gstcms.h"
+
+#include <stdio.h>
+#include <string.h>
+#include <math.h>
+
+
+/* our simple CMS */
+
+void
+color_xyY_to_XYZ (Color * c)
+{
+  if (c->v[1] == 0) {
+    c->v[0] = 0;
+    c->v[1] = 0;
+    c->v[2] = 0;
+  } else {
+    double X, Y, Z;
+    X = c->v[0] * c->v[2] / c->v[1];
+    Y = c->v[2];
+    Z = (1.0 - c->v[0] - c->v[1]) * c->v[2] / c->v[1];
+    c->v[0] = X;
+    c->v[1] = Y;
+    c->v[2] = Z;
+  }
+}
+
+void
+color_XYZ_to_xyY (Color * c)
+{
+  double d;
+  d = c->v[0] + c->v[1] + c->v[2];
+  if (d == 0) {
+    c->v[0] = 0.3128;
+    c->v[1] = 0.3290;
+    c->v[2] = 0;
+  } else {
+    double x, y, Y;
+    x = c->v[0] / d;
+    y = c->v[1] / d;
+    Y = c->v[1];
+    c->v[0] = x;
+    c->v[1] = y;
+    c->v[2] = Y;
+  }
+}
+
+void
+color_set (Color * c, double x, double y, double z)
+{
+  c->v[0] = x;
+  c->v[1] = y;
+  c->v[2] = z;
+}
+
+void
+color_matrix_set_identity (ColorMatrix * m)
+{
+  int i, j;
+
+  for (i = 0; i < 4; i++) {
+    for (j = 0; j < 4; j++) {
+      m->m[i][j] = (i == j);
+    }
+  }
+}
+
+/* Prettyprint a 4x4 matrix @m@ */
+void
+color_matrix_dump (ColorMatrix * m)
+{
+  int i, j;
+
+  printf ("[\n");
+  for (i = 0; i < 4; i++) {
+    printf ("  ");
+    for (j = 0; j < 4; j++) {
+      printf (" %8.5g", m->m[i][j]);
+    }
+    printf ("\n");
+  }
+  printf ("]\n");
+}
+
+/* Perform 4x4 matrix multiplication:
+ *  - @dst@ = @a@ * @b@
+ *  - @dst@ may be a pointer to @a@ andor @b@
+ */
+void
+color_matrix_multiply (ColorMatrix * dst, ColorMatrix * a, ColorMatrix * b)
+{
+  ColorMatrix tmp;
+  int i, j, k;
+
+  for (i = 0; i < 4; i++) {
+    for (j = 0; j < 4; j++) {
+      double x = 0;
+      for (k = 0; k < 4; k++) {
+        x += a->m[i][k] * b->m[k][j];
+      }
+      tmp.m[i][j] = x;
+    }
+  }
+
+  memcpy (dst, &tmp, sizeof (ColorMatrix));
+}
+
+void
+color_matrix_apply (ColorMatrix * m, Color * dest, Color * src)
+{
+  int i;
+  Color tmp;
+
+  for (i = 0; i < 3; i++) {
+    double x = 0;
+    x += m->m[i][0] * src->v[0];
+    x += m->m[i][1] * src->v[1];
+    x += m->m[i][2] * src->v[2];
+    x += m->m[i][3];
+    tmp.v[i] = x;
+  }
+  memcpy (dest, &tmp, sizeof (tmp));
+}
+
+void
+color_matrix_offset_components (ColorMatrix * m, double a1, double a2,
+    double a3)
+{
+  ColorMatrix a;
+
+  color_matrix_set_identity (&a);
+  a.m[0][3] = a1;
+  a.m[1][3] = a2;
+  a.m[2][3] = a3;
+  color_matrix_multiply (m, &a, m);
+}
+
+void
+color_matrix_scale_components (ColorMatrix * m, double a1, double a2, double a3)
+{
+  ColorMatrix a;
+
+  color_matrix_set_identity (&a);
+  a.m[0][0] = a1;
+  a.m[1][1] = a2;
+  a.m[2][2] = a3;
+  color_matrix_multiply (m, &a, m);
+}
+
+void
+color_matrix_YCbCr_to_RGB (ColorMatrix * m, double Kr, double Kb)
+{
+  double Kg = 1.0 - Kr - Kb;
+  ColorMatrix k = {
+    {
+          {1., 0., 2 * (1 - Kr), 0.},
+          {1., -2 * Kb * (1 - Kb) / Kg, -2 * Kr * (1 - Kr) / Kg, 0.},
+          {1., 2 * (1 - Kb), 0., 0.},
+          {0., 0., 0., 1.},
+        }
+  };
+
+  color_matrix_multiply (m, &k, m);
+}
+
+void
+color_matrix_RGB_to_YCbCr (ColorMatrix * m, double Kr, double Kb)
+{
+  double Kg = 1.0 - Kr - Kb;
+  ColorMatrix k;
+  double x;
+
+  k.m[0][0] = Kr;
+  k.m[0][1] = Kg;
+  k.m[0][2] = Kb;
+  k.m[0][3] = 0;
+
+  x = 1 / (2 * (1 - Kb));
+  k.m[1][0] = -x * Kr;
+  k.m[1][1] = -x * Kg;
+  k.m[1][2] = x * (1 - Kb);
+  k.m[1][3] = 0;
+
+  x = 1 / (2 * (1 - Kr));
+  k.m[2][0] = x * (1 - Kr);
+  k.m[2][1] = -x * Kg;
+  k.m[2][2] = -x * Kb;
+  k.m[2][3] = 0;
+
+  k.m[3][0] = 0;
+  k.m[3][1] = 0;
+  k.m[3][2] = 0;
+  k.m[3][3] = 1;
+
+  color_matrix_multiply (m, &k, m);
+}
+
+void
+color_matrix_build_yuv_to_rgb_601 (ColorMatrix * dst)
+{
+  /*
+   * At this point, everything is in YCbCr
+   * All components are in the range [0,255]
+   */
+  color_matrix_set_identity (dst);
+
+  /* offset required to get input video black to (0.,0.,0.) */
+  color_matrix_offset_components (dst, -16, -128, -128);
+
+  /* scale required to get input video black to (0.,0.,0.) */
+  color_matrix_scale_components (dst, (1 / 219.0), (1 / 224.0), (1 / 224.0));
+
+  /* colour matrix, YCbCr -> RGB */
+  /* Requires Y in [0,1.0], Cb&Cr in [-0.5,0.5] */
+  color_matrix_YCbCr_to_RGB (dst, 0.2990, 0.1140);      /* SD */
+
+  /*
+   * We are now in RGB space
+   */
+
+#if 0
+  /* scale to output range. */
+  color_matrix_scale_components (dst, 255.0, 255.0, 255.0);
+#endif
+}
+
+void
+color_matrix_build_bt709_to_bt601 (ColorMatrix * dst)
+{
+  color_matrix_set_identity (dst);
+
+  /* offset required to get input video black to (0.,0.,0.) */
+  color_matrix_offset_components (dst, -16, -128, -128);
+
+  /* scale required to get input video black to (0.,0.,0.) */
+  color_matrix_scale_components (dst, (1 / 219.0), (1 / 224.0), (1 / 224.0));
+
+  /* colour matrix, YCbCr -> RGB */
+  /* Requires Y in [0,1.0], Cb&Cr in [-0.5,0.5] */
+  color_matrix_YCbCr_to_RGB (dst, 0.2126, 0.0722);      /* HD */
+
+  color_matrix_RGB_to_YCbCr (dst, 0.2990, 0.1140);      /* SD */
+
+  color_matrix_scale_components (dst, 219.0, 224.0, 224.0);
+
+  color_matrix_offset_components (dst, 16, 128, 128);
+}
+
+void
+color_matrix_build_rgb_to_yuv_601 (ColorMatrix * dst)
+{
+  color_matrix_set_identity (dst);
+
+  color_matrix_RGB_to_YCbCr (dst, 0.2990, 0.1140);      /* SD */
+
+  color_matrix_scale_components (dst, 219.0, 224.0, 224.0);
+
+  color_matrix_offset_components (dst, 16, 128, 128);
+
+  {
+    Color c;
+    int i;
+    for (i = 7; i >= 0; i--) {
+      color_set (&c, (i & 2) ? 0.75 : 0.0, (i & 4) ? 0.75 : 0.0,
+          (i & 1) ? 0.75 : 0.0);
+      color_matrix_apply (dst, &c, &c);
+      g_print ("  { %g, %g, %g },\n", rint (c.v[0]), rint (c.v[1]),
+          rint (c.v[2]));
+    }
+    color_set (&c, -0.075, -0.075, -0.075);
+    color_matrix_apply (dst, &c, &c);
+    g_print ("  { %g, %g, %g },\n", rint (c.v[0]), rint (c.v[1]),
+        rint (c.v[2]));
+    color_set (&c, 0.075, 0.075, 0.075);
+    color_matrix_apply (dst, &c, &c);
+    g_print ("  { %g, %g, %g },\n", rint (c.v[0]), rint (c.v[1]),
+        rint (c.v[2]));
+  }
+}
+
+void
+color_matrix_invert (ColorMatrix * m)
+{
+  ColorMatrix tmp;
+  int i, j;
+  double det;
+
+  color_matrix_set_identity (&tmp);
+  for (j = 0; j < 3; j++) {
+    for (i = 0; i < 3; i++) {
+      tmp.m[j][i] =
+          m->m[(i + 1) % 3][(j + 1) % 3] * m->m[(i + 2) % 3][(j + 2) % 3] -
+          m->m[(i + 1) % 3][(j + 2) % 3] * m->m[(i + 2) % 3][(j + 1) % 3];
+    }
+  }
+  det =
+      tmp.m[0][0] * m->m[0][0] + tmp.m[0][1] * m->m[1][0] +
+      tmp.m[0][2] * m->m[2][0];
+  for (j = 0; j < 3; j++) {
+    for (i = 0; i < 3; i++) {
+      tmp.m[i][j] /= det;
+    }
+  }
+  memcpy (m, &tmp, sizeof (tmp));
+}
+
+void
+color_matrix_copy (ColorMatrix * dest, ColorMatrix * src)
+{
+  memcpy (dest, src, sizeof (ColorMatrix));
+}
+
+void
+color_matrix_transpose (ColorMatrix * m)
+{
+  int i, j;
+  ColorMatrix tmp;
+
+  color_matrix_set_identity (&tmp);
+  for (i = 0; i < 3; i++) {
+    for (j = 0; j < 3; j++) {
+      tmp.m[i][j] = m->m[j][i];
+    }
+  }
+  memcpy (m, &tmp, sizeof (ColorMatrix));
+}
+
+void
+color_matrix_build_XYZ (ColorMatrix * dst,
+    double rx, double ry,
+    double gx, double gy, double bx, double by, double wx, double wy)
+{
+  Color r, g, b, w, scale;
+  ColorMatrix m;
+
+  color_set (&r, rx, ry, 1.0);
+  color_xyY_to_XYZ (&r);
+  color_set (&g, gx, gy, 1.0);
+  color_xyY_to_XYZ (&g);
+  color_set (&b, bx, by, 1.0);
+  color_xyY_to_XYZ (&b);
+  color_set (&w, wx, wy, 1.0);
+  color_xyY_to_XYZ (&w);
+
+  color_matrix_set_identity (dst);
+
+  dst->m[0][0] = r.v[0];
+  dst->m[0][1] = r.v[1];
+  dst->m[0][2] = r.v[2];
+  dst->m[1][0] = g.v[0];
+  dst->m[1][1] = g.v[1];
+  dst->m[1][2] = g.v[2];
+  dst->m[2][0] = b.v[0];
+  dst->m[2][1] = b.v[1];
+  dst->m[2][2] = b.v[2];
+
+  color_matrix_dump (dst);
+  color_matrix_copy (&m, dst);
+  color_matrix_invert (&m);
+  color_matrix_dump (&m);
+
+  color_matrix_transpose (&m);
+  color_matrix_apply (&m, &scale, &w);
+  g_print ("%g %g %g\n", scale.v[0], scale.v[1], scale.v[2]);
+
+  dst->m[0][0] = r.v[0] * scale.v[0];
+  dst->m[0][1] = r.v[1] * scale.v[0];
+  dst->m[0][2] = r.v[2] * scale.v[0];
+  dst->m[1][0] = g.v[0] * scale.v[1];
+  dst->m[1][1] = g.v[1] * scale.v[1];
+  dst->m[1][2] = g.v[2] * scale.v[1];
+  dst->m[2][0] = b.v[0] * scale.v[2];
+  dst->m[2][1] = b.v[1] * scale.v[2];
+  dst->m[2][2] = b.v[2] * scale.v[2];
+
+  color_matrix_transpose (dst);
+  color_matrix_dump (dst);
+
+  color_set (&scale, 1, 1, 1);
+  color_matrix_apply (dst, &scale, &scale);
+  color_XYZ_to_xyY (&scale);
+  g_print ("white %g %g %g\n", scale.v[0], scale.v[1], scale.v[2]);
+
+}
+
+void
+color_matrix_build_rgb_to_XYZ_601 (ColorMatrix * dst)
+{
+  /* SMPTE C primaries, SMPTE 170M-2004 */
+  color_matrix_build_XYZ (dst,
+      0.630, 0.340, 0.310, 0.595, 0.155, 0.070, 0.3127, 0.3290);
+#if 0
+  /* NTSC 1953 primaries, SMPTE 170M-2004 */
+  color_matrix_build_XYZ (dst,
+      0.67, 0.33, 0.21, 0.71, 0.14, 0.08, 0.3127, 0.3290);
+#endif
+}
+
+void
+color_matrix_build_XYZ_to_rgb_709 (ColorMatrix * dst)
+{
+  /* Rec. ITU-R BT.709-5 */
+  color_matrix_build_XYZ (dst,
+      0.640, 0.330, 0.300, 0.600, 0.150, 0.060, 0.3127, 0.3290);
+}
+
+void
+color_matrix_build_XYZ_to_rgb_dell (ColorMatrix * dst)
+{
+  /* Dell monitor */
+#if 1
+  color_matrix_build_XYZ (dst,
+      0.662, 0.329, 0.205, 0.683, 0.146, 0.077, 0.3135, 0.3290);
+#endif
+#if 0
+  color_matrix_build_XYZ (dst,
+      0.630, 0.340, 0.310, 0.595, 0.155, 0.070, 0.3127, 0.3290);
+#endif
+  color_matrix_invert (dst);
+}
+
+void
+color_transfer_function_apply (Color * dest, Color * src)
+{
+  int i;
+
+  for (i = 0; i < 3; i++) {
+    if (src->v[i] < 0.0812) {
+      dest->v[i] = src->v[i] / 4.500;
+    } else {
+      dest->v[i] = pow (src->v[i] + 0.099, 1 / 0.4500);
+    }
+  }
+}
+
+void
+color_transfer_function_unapply (Color * dest, Color * src)
+{
+  int i;
+
+  for (i = 0; i < 3; i++) {
+    if (src->v[i] < 0.0812 / 4.500) {
+      dest->v[i] = src->v[i] * 4.500;
+    } else {
+      dest->v[i] = pow (src->v[i], 0.4500) - 0.099;
+    }
+  }
+}
+
+void
+color_gamut_clamp (Color * dest, Color * src)
+{
+  dest->v[0] = CLAMP (src->v[0], 0.0, 1.0);
+  dest->v[1] = CLAMP (src->v[1], 0.0, 1.0);
+  dest->v[2] = CLAMP (src->v[2], 0.0, 1.0);
+}
+
+#if 0
+static guint8 *
+get_color_transform_table (void)
+{
+  static guint8 *color_transform_table = NULL;
+
+#if 1
+  if (!color_transform_table) {
+    ColorMatrix bt601_to_rgb;
+    ColorMatrix bt601_to_yuv;
+    ColorMatrix bt601_rgb_to_XYZ;
+    ColorMatrix dell_XYZ_to_rgb;
+    guint8 *table_y;
+    guint8 *table_u;
+    guint8 *table_v;
+    int y, u, v;
+
+    color_matrix_build_yuv_to_rgb_601 (&bt601_to_rgb);
+    color_matrix_build_rgb_to_yuv_601 (&bt601_to_yuv);
+    color_matrix_build_rgb_to_XYZ_601 (&bt601_rgb_to_XYZ);
+    color_matrix_build_XYZ_to_rgb_dell (&dell_XYZ_to_rgb);
+
+    color_transform_table = g_malloc (0x1000000 * 3);
+
+    table_y = COG_OFFSET (color_transform_table, 0 * 0x1000000);
+    table_u = COG_OFFSET (color_transform_table, 1 * 0x1000000);
+    table_v = COG_OFFSET (color_transform_table, 2 * 0x1000000);
+
+    for (y = 0; y < 256; y++) {
+      for (u = 0; u < 256; u++) {
+        for (v = 0; v < 256; v++) {
+          Color c;
+
+          c.v[0] = y;
+          c.v[1] = u;
+          c.v[2] = v;
+          color_matrix_apply (&bt601_to_rgb, &c, &c);
+          color_gamut_clamp (&c, &c);
+          color_transfer_function_apply (&c, &c);
+          color_matrix_apply (&bt601_rgb_to_XYZ, &c, &c);
+          color_matrix_apply (&dell_XYZ_to_rgb, &c, &c);
+          color_transfer_function_unapply (&c, &c);
+          color_gamut_clamp (&c, &c);
+          color_matrix_apply (&bt601_to_yuv, &c, &c);
+
+          table_y[(y << 16) | (u << 8) | (v)] = rint (c.v[0]);
+          table_u[(y << 16) | (u << 8) | (v)] = rint (c.v[1]);
+          table_v[(y << 16) | (u << 8) | (v)] = rint (c.v[2]);
+        }
+      }
+    }
+  }
+#endif
+#if 0
+  if (!color_transform_table) {
+    ColorMatrix bt709_to_bt601;
+    guint8 *table_y;
+    guint8 *table_u;
+    guint8 *table_v;
+    int y, u, v;
+
+    color_matrix_build_bt709_to_bt601 (&bt709_to_bt601);
+
+    color_transform_table = g_malloc (0x1000000 * 3);
+
+    table_y = COG_OFFSET (color_transform_table, 0 * 0x1000000);
+    table_u = COG_OFFSET (color_transform_table, 1 * 0x1000000);
+    table_v = COG_OFFSET (color_transform_table, 2 * 0x1000000);
+
+    for (y = 0; y < 256; y++) {
+      for (u = 0; u < 256; u++) {
+        for (v = 0; v < 256; v++) {
+          Color c;
+
+          c.v[0] = y;
+          c.v[1] = u;
+          c.v[2] = v;
+          color_matrix_apply (&bt709_to_bt601, &c, &c);
+
+          table_y[(y << 16) | (u << 8) | (v)] = rint (c.v[0]);
+          table_u[(y << 16) | (u << 8) | (v)] = rint (c.v[1]);
+          table_v[(y << 16) | (u << 8) | (v)] = rint (c.v[2]);
+        }
+      }
+    }
+  }
+#endif
+
+  return color_transform_table;
+}
+#endif
diff --git a/gst/videoconvert/gstcms.h b/gst/videoconvert/gstcms.h
new file mode 100644
index 0000000..2930b7d
--- /dev/null
+++ b/gst/videoconvert/gstcms.h
@@ -0,0 +1,71 @@
+/* GStreamer
+ * Copyright (C) 2008 David Schleef <ds@entropywave.com>
+ *
+ * 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_CMS_H_
+#define _GST_CMS_H_
+
+#include <gst/gst.h>
+
+G_BEGIN_DECLS
+
+typedef struct _Color Color;
+typedef struct _ColorMatrix ColorMatrix;
+
+struct _Color
+{
+  double v[3];
+};
+
+struct _ColorMatrix
+{
+  double m[4][4];
+};
+
+void color_xyY_to_XYZ (Color * c);
+void color_XYZ_to_xyY (Color * c);
+void color_set (Color * c, double x, double y, double z);
+void color_matrix_set_identity (ColorMatrix * m);
+void color_matrix_dump (ColorMatrix * m);
+void color_matrix_multiply (ColorMatrix * dst, ColorMatrix * a, ColorMatrix * b);
+void color_matrix_apply (ColorMatrix * m, Color * dest, Color * src);
+void color_matrix_offset_components (ColorMatrix * m, double a1, double a2,
+    double a3);
+void color_matrix_scale_components (ColorMatrix * m, double a1, double a2, double a3);
+void color_matrix_YCbCr_to_RGB (ColorMatrix * m, double Kr, double Kb);
+void color_matrix_RGB_to_YCbCr (ColorMatrix * m, double Kr, double Kb);
+void color_matrix_build_yuv_to_rgb_601 (ColorMatrix * dst);
+void color_matrix_build_bt709_to_bt601 (ColorMatrix * dst);
+void color_matrix_build_rgb_to_yuv_601 (ColorMatrix * dst);
+void color_matrix_invert (ColorMatrix * m);
+void color_matrix_copy (ColorMatrix * dest, ColorMatrix * src);
+void color_matrix_transpose (ColorMatrix * m);
+void color_matrix_build_XYZ (ColorMatrix * dst,
+    double rx, double ry,
+    double gx, double gy, double bx, double by, double wx, double wy);
+void color_matrix_build_rgb_to_XYZ_601 (ColorMatrix * dst);
+void color_matrix_build_XYZ_to_rgb_709 (ColorMatrix * dst);
+void color_matrix_build_XYZ_to_rgb_dell (ColorMatrix * dst);
+void color_transfer_function_apply (Color * dest, Color * src);
+void color_transfer_function_unapply (Color * dest, Color * src);
+void color_gamut_clamp (Color * dest, Color * src);
+
+G_END_DECLS
+
+#endif
+
diff --git a/gst/videoconvert/gstvideoconvert.c b/gst/videoconvert/gstvideoconvert.c
index 853b470..0f1a690 100644
--- a/gst/videoconvert/gstvideoconvert.c
+++ b/gst/videoconvert/gstvideoconvert.c
@@ -127,7 +127,7 @@
       continue;
 
     st = gst_structure_copy (st);
-    gst_structure_remove_fields (st, "format", "palette_data",
+    gst_structure_remove_fields (st, "format",
         "colorimetry", "chroma-site", NULL);
 
     gst_caps_append_structure (res, st);
@@ -217,8 +217,6 @@
     GstVideoInfo * out_info)
 {
   GstVideoConvert *space;
-  ColorSpaceColorSpec in_spec, out_spec;
-  gboolean interlaced;
 
   space = GST_VIDEO_CONVERT_CAST (filter);
 
@@ -226,30 +224,6 @@
     videoconvert_convert_free (space->convert);
   }
 
-  /* input caps */
-  if (GST_VIDEO_INFO_IS_RGB (in_info)) {
-    in_spec = COLOR_SPEC_RGB;
-  } else if (GST_VIDEO_INFO_IS_YUV (in_info)) {
-    if (in_info->colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT709)
-      in_spec = COLOR_SPEC_YUV_BT709;
-    else
-      in_spec = COLOR_SPEC_YUV_BT470_6;
-  } else {
-    in_spec = COLOR_SPEC_GRAY;
-  }
-
-  /* output caps */
-  if (GST_VIDEO_INFO_IS_RGB (out_info)) {
-    out_spec = COLOR_SPEC_RGB;
-  } else if (GST_VIDEO_INFO_IS_YUV (out_info)) {
-    if (out_info->colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT709)
-      out_spec = COLOR_SPEC_YUV_BT709;
-    else
-      out_spec = COLOR_SPEC_YUV_BT470_6;
-  } else {
-    out_spec = COLOR_SPEC_GRAY;
-  }
-
   /* these must match */
   if (in_info->width != out_info->width || in_info->height != out_info->height
       || in_info->fps_n != out_info->fps_n || in_info->fps_d != out_info->fps_d)
@@ -263,54 +237,10 @@
   if (in_info->interlace_mode != out_info->interlace_mode)
     goto format_mismatch;
 
-  space->from_spec = in_spec;
-  space->to_spec = out_spec;
-
-  interlaced = GST_VIDEO_INFO_IS_INTERLACED (in_info);
-
-  space->convert =
-      videoconvert_convert_new (GST_VIDEO_INFO_FORMAT (out_info), out_spec,
-      GST_VIDEO_INFO_FORMAT (in_info), in_spec, in_info->width,
-      in_info->height);
+  space->convert = videoconvert_convert_new (in_info, out_info);
   if (space->convert == NULL)
     goto no_convert;
 
-  videoconvert_convert_set_interlaced (space->convert, interlaced);
-
-  /* palette, only for from data */
-  if (GST_VIDEO_INFO_FORMAT (in_info) ==
-      GST_VIDEO_FORMAT_RGB8_PALETTED
-      && GST_VIDEO_INFO_FORMAT (out_info) == GST_VIDEO_FORMAT_RGB8_PALETTED) {
-    goto format_mismatch;
-  } else if (GST_VIDEO_INFO_FORMAT (in_info) == GST_VIDEO_FORMAT_RGB8_PALETTED) {
-    GstBuffer *palette;
-    GstMapInfo map;
-
-    palette = gst_video_parse_caps_palette (incaps);
-
-    if (!palette || gst_buffer_get_size (palette) < 256 * 4) {
-      if (palette)
-        gst_buffer_unref (palette);
-      goto invalid_palette;
-    }
-
-    gst_buffer_map (palette, &map, GST_MAP_READ);
-    videoconvert_convert_set_palette (space->convert, (guint32 *) map.data);
-    gst_buffer_unmap (palette, &map);
-
-    gst_buffer_unref (palette);
-  } else if (GST_VIDEO_INFO_FORMAT (out_info) == GST_VIDEO_FORMAT_RGB8_PALETTED) {
-    const guint32 *palette;
-    GstBuffer *p_buf;
-
-    palette = videoconvert_convert_get_palette (space->convert);
-
-    p_buf = gst_buffer_new_and_alloc (256 * 4);
-    gst_buffer_fill (p_buf, 0, palette, 256 * 4);
-    gst_caps_set_simple (outcaps, "palette_data", GST_TYPE_BUFFER, p_buf, NULL);
-    gst_buffer_unref (p_buf);
-  }
-
   GST_DEBUG ("reconfigured %d %d", GST_VIDEO_INFO_FORMAT (in_info),
       GST_VIDEO_INFO_FORMAT (out_info));
 
@@ -327,11 +257,6 @@
     GST_ERROR_OBJECT (space, "could not create converter");
     return FALSE;
   }
-invalid_palette:
-  {
-    GST_ERROR_OBJECT (space, "invalid palette");
-    return FALSE;
-  }
 }
 
 static void
diff --git a/gst/videoconvert/gstvideoconvert.h b/gst/videoconvert/gstvideoconvert.h
index fc9a85f..0ea0241 100644
--- a/gst/videoconvert/gstvideoconvert.h
+++ b/gst/videoconvert/gstvideoconvert.h
@@ -47,9 +47,6 @@
 struct _GstVideoConvert {
   GstVideoFilter element;
 
-  ColorSpaceColorSpec from_spec;
-  ColorSpaceColorSpec to_spec;
-
   VideoConvert *convert;
   gboolean dither;
 };
diff --git a/gst/videoconvert/gstvideoconvertorc-dist.c b/gst/videoconvert/gstvideoconvertorc-dist.c
index 9a9836f..b7329b1 100644
--- a/gst/videoconvert/gstvideoconvertorc-dist.c
+++ b/gst/videoconvert/gstvideoconvertorc-dist.c
@@ -84,73 +84,6 @@
 #endif
 void cogorc_memcpy_2d (guint8 * ORC_RESTRICT d1, int d1_stride,
     const guint8 * ORC_RESTRICT s1, int s1_stride, int n, int m);
-void cogorc_downsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void cogorc_downsample_horiz_cosite_3tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_downsample_420_jpeg (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_downsample_vert_halfsite_2tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_downsample_vert_cosite_3tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int n);
-void cogorc_downsample_vert_halfsite_4tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n);
-void cogorc_upsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void cogorc_upsample_horiz_cosite (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_upsample_vert_avgub (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void orc_unpack_yuyv_y (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_yuyv_u (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_yuyv_v (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void orc_pack_yuyv (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
-void orc_unpack_uyvy_y (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_uyvy_u (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_uyvy_v (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n);
-void orc_pack_uyvy (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
-void orc_matrix2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int p3, int n);
-void orc_matrix2_11_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1,
-    int p2, int n);
-void orc_matrix2_12_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1,
-    int p2, int n);
-void orc_matrix3_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int p4, int n);
-void orc_matrix3_100_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int n);
-void orc_matrix3_100_offset_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int p5,
-    int n);
-void orc_matrix3_000_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int p5,
-    int n);
-void orc_pack_123x (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int n);
-void orc_pack_x123 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int n);
-void cogorc_combine2_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1,
-    int p2, int n);
 void cogorc_convert_I420_UYVY (guint8 * ORC_RESTRICT d1,
     guint8 * ORC_RESTRICT d2, const guint8 * ORC_RESTRICT s1,
     const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3,
@@ -472,4710 +405,6 @@
 #endif
 
 
-/* cogorc_downsample_horiz_cosite_1tap */
-#ifdef DISABLE_ORC
-void
-cogorc_downsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  orc_union16 var32;
-  orc_int8 var33;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union16 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var32 = ptr4[i];
-    /* 1: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var32.i;
-      var33 = _src.x2[0];
-    }
-    /* 2: storeb */
-    ptr0[i] = var33;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_downsample_horiz_cosite_1tap (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  orc_union16 var32;
-  orc_int8 var33;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var32 = ptr4[i];
-    /* 1: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var32.i;
-      var33 = _src.x2[0];
-    }
-    /* 2: storeb */
-    ptr0[i] = var33;
-  }
-
-}
-
-void
-cogorc_downsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_downsample_horiz_cosite_1tap");
-      orc_program_set_backup_function (p,
-          _backup_cogorc_downsample_horiz_cosite_1tap);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 2, "s1");
-
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_D1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_downsample_horiz_cosite_3tap */
-#ifdef DISABLE_ORC
-void
-cogorc_downsample_horiz_cosite_3tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_union16 *ORC_RESTRICT ptr5;
-  orc_union16 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_union16 var43;
-  orc_int8 var44;
-  orc_int8 var45;
-  orc_int8 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union16 *) s1;
-  ptr5 = (orc_union16 *) s2;
-
-  /* 9: loadpw */
-  var40.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-  /* 13: loadpw */
-  var41.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var38 = ptr4[i];
-    /* 1: copyw */
-    var43.i = var38.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var43.i;
-      var44 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var43.i;
-      var45 = _src.x2[1];
-    }
-    /* 4: loadw */
-    var39 = ptr5[i];
-    /* 5: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var39.i;
-      var46 = _src.x2[0];
-    }
-    /* 6: convubw */
-    var47.i = (orc_uint8) var44;
-    /* 7: convubw */
-    var48.i = (orc_uint8) var45;
-    /* 8: convubw */
-    var49.i = (orc_uint8) var46;
-    /* 10: mullw */
-    var50.i = (var48.i * var40.i) & 0xffff;
-    /* 11: addw */
-    var51.i = var47.i + var49.i;
-    /* 12: addw */
-    var52.i = var51.i + var50.i;
-    /* 14: addw */
-    var53.i = var52.i + var41.i;
-    /* 15: shrsw */
-    var54.i = var53.i >> 2;
-    /* 16: convsuswb */
-    var42 = ORC_CLAMP_UB (var54.i);
-    /* 17: storeb */
-    ptr0[i] = var42;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_downsample_horiz_cosite_3tap (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_union16 *ORC_RESTRICT ptr5;
-  orc_union16 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_union16 var43;
-  orc_int8 var44;
-  orc_int8 var45;
-  orc_int8 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-  ptr5 = (orc_union16 *) ex->arrays[5];
-
-  /* 9: loadpw */
-  var40.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-  /* 13: loadpw */
-  var41.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var38 = ptr4[i];
-    /* 1: copyw */
-    var43.i = var38.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var43.i;
-      var44 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var43.i;
-      var45 = _src.x2[1];
-    }
-    /* 4: loadw */
-    var39 = ptr5[i];
-    /* 5: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var39.i;
-      var46 = _src.x2[0];
-    }
-    /* 6: convubw */
-    var47.i = (orc_uint8) var44;
-    /* 7: convubw */
-    var48.i = (orc_uint8) var45;
-    /* 8: convubw */
-    var49.i = (orc_uint8) var46;
-    /* 10: mullw */
-    var50.i = (var48.i * var40.i) & 0xffff;
-    /* 11: addw */
-    var51.i = var47.i + var49.i;
-    /* 12: addw */
-    var52.i = var51.i + var50.i;
-    /* 14: addw */
-    var53.i = var52.i + var41.i;
-    /* 15: shrsw */
-    var54.i = var53.i >> 2;
-    /* 16: convsuswb */
-    var42 = ORC_CLAMP_UB (var54.i);
-    /* 17: storeb */
-    ptr0[i] = var42;
-  }
-
-}
-
-void
-cogorc_downsample_horiz_cosite_3tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_downsample_horiz_cosite_3tap");
-      orc_program_set_backup_function (p,
-          _backup_cogorc_downsample_horiz_cosite_3tap);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 2, "s1");
-      orc_program_add_source (p, 2, "s2");
-      orc_program_add_constant (p, 4, 0x00000002, "c1");
-      orc_program_add_temporary (p, 1, "t1");
-      orc_program_add_temporary (p, 1, "t2");
-      orc_program_add_temporary (p, 1, "t3");
-      orc_program_add_temporary (p, 2, "t4");
-      orc_program_add_temporary (p, 2, "t5");
-      orc_program_add_temporary (p, 2, "t6");
-
-      orc_program_append_2 (p, "copyw", 0, ORC_VAR_T4, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_T1, ORC_VAR_T4,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_T2, ORC_VAR_T4,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_T3, ORC_VAR_S2,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T4, ORC_VAR_T1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T5, ORC_VAR_T2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T6, ORC_VAR_T3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T5, ORC_VAR_T5, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T4, ORC_VAR_T4, ORC_VAR_T6,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T4, ORC_VAR_T4, ORC_VAR_T5,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T4, ORC_VAR_T4, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T4, ORC_VAR_T4, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T4,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_downsample_420_jpeg */
-#ifdef DISABLE_ORC
-void
-cogorc_downsample_420_jpeg (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_union16 *ORC_RESTRICT ptr5;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_int8 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_int8 var45;
-  orc_int8 var46;
-  orc_int8 var47;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union16 *) s1;
-  ptr5 = (orc_union16 *) s2;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var37 = ptr4[i];
-    /* 1: copyw */
-    var40.i = var37.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var40.i;
-      var41 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var40.i;
-      var42 = _src.x2[1];
-    }
-    /* 4: avgub */
-    var43 = ((orc_uint8) var41 + (orc_uint8) var42 + 1) >> 1;
-    /* 5: loadw */
-    var38 = ptr5[i];
-    /* 6: copyw */
-    var44.i = var38.i;
-    /* 7: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var44.i;
-      var45 = _src.x2[0];
-    }
-    /* 8: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var44.i;
-      var46 = _src.x2[1];
-    }
-    /* 9: avgub */
-    var47 = ((orc_uint8) var45 + (orc_uint8) var46 + 1) >> 1;
-    /* 10: avgub */
-    var39 = ((orc_uint8) var43 + (orc_uint8) var47 + 1) >> 1;
-    /* 11: storeb */
-    ptr0[i] = var39;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_downsample_420_jpeg (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_union16 *ORC_RESTRICT ptr5;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_int8 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_int8 var45;
-  orc_int8 var46;
-  orc_int8 var47;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-  ptr5 = (orc_union16 *) ex->arrays[5];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var37 = ptr4[i];
-    /* 1: copyw */
-    var40.i = var37.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var40.i;
-      var41 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var40.i;
-      var42 = _src.x2[1];
-    }
-    /* 4: avgub */
-    var43 = ((orc_uint8) var41 + (orc_uint8) var42 + 1) >> 1;
-    /* 5: loadw */
-    var38 = ptr5[i];
-    /* 6: copyw */
-    var44.i = var38.i;
-    /* 7: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var44.i;
-      var45 = _src.x2[0];
-    }
-    /* 8: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var44.i;
-      var46 = _src.x2[1];
-    }
-    /* 9: avgub */
-    var47 = ((orc_uint8) var45 + (orc_uint8) var46 + 1) >> 1;
-    /* 10: avgub */
-    var39 = ((orc_uint8) var43 + (orc_uint8) var47 + 1) >> 1;
-    /* 11: storeb */
-    ptr0[i] = var39;
-  }
-
-}
-
-void
-cogorc_downsample_420_jpeg (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_downsample_420_jpeg");
-      orc_program_set_backup_function (p, _backup_cogorc_downsample_420_jpeg);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 2, "s1");
-      orc_program_add_source (p, 2, "s2");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 1, "t2");
-      orc_program_add_temporary (p, 1, "t3");
-      orc_program_add_temporary (p, 1, "t4");
-      orc_program_add_temporary (p, 1, "t5");
-
-      orc_program_append_2 (p, "copyw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_T2, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_T3, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "avgub", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "copyw", 0, ORC_VAR_T1, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_T4, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_T5, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "avgub", 0, ORC_VAR_T4, ORC_VAR_T4, ORC_VAR_T5,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D1, ORC_VAR_T2, ORC_VAR_T4,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_downsample_vert_halfsite_2tap */
-#ifdef DISABLE_ORC
-void
-cogorc_downsample_vert_halfsite_2tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var32;
-  orc_int8 var33;
-  orc_int8 var34;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var32 = ptr4[i];
-    /* 1: loadb */
-    var33 = ptr5[i];
-    /* 2: avgub */
-    var34 = ((orc_uint8) var32 + (orc_uint8) var33 + 1) >> 1;
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_downsample_vert_halfsite_2tap (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var32;
-  orc_int8 var33;
-  orc_int8 var34;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var32 = ptr4[i];
-    /* 1: loadb */
-    var33 = ptr5[i];
-    /* 2: avgub */
-    var34 = ((orc_uint8) var32 + (orc_uint8) var33 + 1) >> 1;
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-cogorc_downsample_vert_halfsite_2tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_downsample_vert_halfsite_2tap");
-      orc_program_set_backup_function (p,
-          _backup_cogorc_downsample_vert_halfsite_2tap);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-
-      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D1, ORC_VAR_S1, ORC_VAR_S2,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_downsample_vert_cosite_3tap */
-#ifdef DISABLE_ORC
-void
-cogorc_downsample_vert_cosite_3tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var35;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_union16 var38;
-  orc_union16 var39;
-  orc_int8 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 6: loadpw */
-  var38.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-  /* 10: loadpw */
-  var39.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var35 = ptr4[i];
-    /* 1: convubw */
-    var41.i = (orc_uint8) var35;
-    /* 2: loadb */
-    var36 = ptr5[i];
-    /* 3: convubw */
-    var42.i = (orc_uint8) var36;
-    /* 4: loadb */
-    var37 = ptr6[i];
-    /* 5: convubw */
-    var43.i = (orc_uint8) var37;
-    /* 7: mullw */
-    var44.i = (var42.i * var38.i) & 0xffff;
-    /* 8: addw */
-    var45.i = var41.i + var43.i;
-    /* 9: addw */
-    var46.i = var45.i + var44.i;
-    /* 11: addw */
-    var47.i = var46.i + var39.i;
-    /* 12: shrsw */
-    var48.i = var47.i >> 2;
-    /* 13: convsuswb */
-    var40 = ORC_CLAMP_UB (var48.i);
-    /* 14: storeb */
-    ptr0[i] = var40;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_downsample_vert_cosite_3tap (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var35;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_union16 var38;
-  orc_union16 var39;
-  orc_int8 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 6: loadpw */
-  var38.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-  /* 10: loadpw */
-  var39.i = (int) 0x00000002;   /* 2 or 9.88131e-324f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var35 = ptr4[i];
-    /* 1: convubw */
-    var41.i = (orc_uint8) var35;
-    /* 2: loadb */
-    var36 = ptr5[i];
-    /* 3: convubw */
-    var42.i = (orc_uint8) var36;
-    /* 4: loadb */
-    var37 = ptr6[i];
-    /* 5: convubw */
-    var43.i = (orc_uint8) var37;
-    /* 7: mullw */
-    var44.i = (var42.i * var38.i) & 0xffff;
-    /* 8: addw */
-    var45.i = var41.i + var43.i;
-    /* 9: addw */
-    var46.i = var45.i + var44.i;
-    /* 11: addw */
-    var47.i = var46.i + var39.i;
-    /* 12: shrsw */
-    var48.i = var47.i >> 2;
-    /* 13: convsuswb */
-    var40 = ORC_CLAMP_UB (var48.i);
-    /* 14: storeb */
-    ptr0[i] = var40;
-  }
-
-}
-
-void
-cogorc_downsample_vert_cosite_3tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_downsample_vert_cosite_3tap");
-      orc_program_set_backup_function (p,
-          _backup_cogorc_downsample_vert_cosite_3tap);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_constant (p, 4, 0x00000002, "c1");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T3, ORC_VAR_S3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_downsample_vert_halfsite_4tap */
-#ifdef DISABLE_ORC
-void
-cogorc_downsample_vert_halfsite_4tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  const orc_int8 *ORC_RESTRICT ptr7;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_int8 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-  ptr7 = (orc_int8 *) s4;
-
-  /* 9: loadpw */
-  var40.i = (int) 0x0000001a;   /* 26 or 1.28457e-322f */
-  /* 12: loadpw */
-  var41.i = (int) 0x00000006;   /* 6 or 2.96439e-323f */
-  /* 15: loadpw */
-  var42.i = (int) 0x00000020;   /* 32 or 1.58101e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var36 = ptr4[i];
-    /* 1: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 2: loadb */
-    var37 = ptr5[i];
-    /* 3: convubw */
-    var45.i = (orc_uint8) var37;
-    /* 4: loadb */
-    var38 = ptr6[i];
-    /* 5: convubw */
-    var46.i = (orc_uint8) var38;
-    /* 6: loadb */
-    var39 = ptr7[i];
-    /* 7: convubw */
-    var47.i = (orc_uint8) var39;
-    /* 8: addw */
-    var48.i = var45.i + var46.i;
-    /* 10: mullw */
-    var49.i = (var48.i * var40.i) & 0xffff;
-    /* 11: addw */
-    var50.i = var44.i + var47.i;
-    /* 13: mullw */
-    var51.i = (var50.i * var41.i) & 0xffff;
-    /* 14: addw */
-    var52.i = var49.i + var51.i;
-    /* 16: addw */
-    var53.i = var52.i + var42.i;
-    /* 17: shrsw */
-    var54.i = var53.i >> 6;
-    /* 18: convsuswb */
-    var43 = ORC_CLAMP_UB (var54.i);
-    /* 19: storeb */
-    ptr0[i] = var43;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_downsample_vert_halfsite_4tap (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  const orc_int8 *ORC_RESTRICT ptr7;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_int8 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-  ptr7 = (orc_int8 *) ex->arrays[7];
-
-  /* 9: loadpw */
-  var40.i = (int) 0x0000001a;   /* 26 or 1.28457e-322f */
-  /* 12: loadpw */
-  var41.i = (int) 0x00000006;   /* 6 or 2.96439e-323f */
-  /* 15: loadpw */
-  var42.i = (int) 0x00000020;   /* 32 or 1.58101e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var36 = ptr4[i];
-    /* 1: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 2: loadb */
-    var37 = ptr5[i];
-    /* 3: convubw */
-    var45.i = (orc_uint8) var37;
-    /* 4: loadb */
-    var38 = ptr6[i];
-    /* 5: convubw */
-    var46.i = (orc_uint8) var38;
-    /* 6: loadb */
-    var39 = ptr7[i];
-    /* 7: convubw */
-    var47.i = (orc_uint8) var39;
-    /* 8: addw */
-    var48.i = var45.i + var46.i;
-    /* 10: mullw */
-    var49.i = (var48.i * var40.i) & 0xffff;
-    /* 11: addw */
-    var50.i = var44.i + var47.i;
-    /* 13: mullw */
-    var51.i = (var50.i * var41.i) & 0xffff;
-    /* 14: addw */
-    var52.i = var49.i + var51.i;
-    /* 16: addw */
-    var53.i = var52.i + var42.i;
-    /* 17: shrsw */
-    var54.i = var53.i >> 6;
-    /* 18: convsuswb */
-    var43 = ORC_CLAMP_UB (var54.i);
-    /* 19: storeb */
-    ptr0[i] = var43;
-  }
-
-}
-
-void
-cogorc_downsample_vert_halfsite_4tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_downsample_vert_halfsite_4tap");
-      orc_program_set_backup_function (p,
-          _backup_cogorc_downsample_vert_halfsite_4tap);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_source (p, 1, "s4");
-      orc_program_add_constant (p, 4, 0x0000001a, "c1");
-      orc_program_add_constant (p, 4, 0x00000006, "c2");
-      orc_program_add_constant (p, 4, 0x00000020, "c3");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-      orc_program_add_temporary (p, 2, "t4");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T3, ORC_VAR_S3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T4, ORC_VAR_S4, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T4,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_T1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T2,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->arrays[ORC_VAR_S4] = (void *) s4;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_upsample_horiz_cosite_1tap */
-#ifdef DISABLE_ORC
-void
-cogorc_upsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n)
-{
-  int i;
-  orc_union16 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  orc_int8 var33;
-  orc_union16 var34;
-  orc_int8 var35;
-
-  ptr0 = (orc_union16 *) d1;
-  ptr4 = (orc_int8 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var33 = ptr4[i];
-    /* 1: copyb */
-    var35 = var33;
-    /* 2: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var35;
-      _dest.x2[1] = var35;
-      var34.i = _dest.i;
-    }
-    /* 3: storew */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_upsample_horiz_cosite_1tap (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_union16 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  orc_int8 var33;
-  orc_union16 var34;
-  orc_int8 var35;
-
-  ptr0 = (orc_union16 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var33 = ptr4[i];
-    /* 1: copyb */
-    var35 = var33;
-    /* 2: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var35;
-      _dest.x2[1] = var35;
-      var34.i = _dest.i;
-    }
-    /* 3: storew */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-cogorc_upsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_upsample_horiz_cosite_1tap");
-      orc_program_set_backup_function (p,
-          _backup_cogorc_upsample_horiz_cosite_1tap);
-      orc_program_add_destination (p, 2, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_temporary (p, 1, "t1");
-
-      orc_program_append_2 (p, "copyb", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T1,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_upsample_horiz_cosite */
-#ifdef DISABLE_ORC
-void
-cogorc_upsample_horiz_cosite (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  int i;
-  orc_union16 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var34;
-  orc_int8 var35;
-  orc_union16 var36;
-  orc_int8 var37;
-  orc_int8 var38;
-
-  ptr0 = (orc_union16 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: copyb */
-    var37 = var34;
-    /* 2: loadb */
-    var35 = ptr5[i];
-    /* 3: avgub */
-    var38 = ((orc_uint8) var37 + (orc_uint8) var35 + 1) >> 1;
-    /* 4: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var37;
-      _dest.x2[1] = var38;
-      var36.i = _dest.i;
-    }
-    /* 5: storew */
-    ptr0[i] = var36;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_upsample_horiz_cosite (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_union16 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var34;
-  orc_int8 var35;
-  orc_union16 var36;
-  orc_int8 var37;
-  orc_int8 var38;
-
-  ptr0 = (orc_union16 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: copyb */
-    var37 = var34;
-    /* 2: loadb */
-    var35 = ptr5[i];
-    /* 3: avgub */
-    var38 = ((orc_uint8) var37 + (orc_uint8) var35 + 1) >> 1;
-    /* 4: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var37;
-      _dest.x2[1] = var38;
-      var36.i = _dest.i;
-    }
-    /* 5: storew */
-    ptr0[i] = var36;
-  }
-
-}
-
-void
-cogorc_upsample_horiz_cosite (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_upsample_horiz_cosite");
-      orc_program_set_backup_function (p, _backup_cogorc_upsample_horiz_cosite);
-      orc_program_add_destination (p, 2, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_temporary (p, 1, "t1");
-      orc_program_add_temporary (p, 1, "t2");
-
-      orc_program_append_2 (p, "copyb", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "avgub", 0, ORC_VAR_T2, ORC_VAR_T1, ORC_VAR_S2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_upsample_vert_avgub */
-#ifdef DISABLE_ORC
-void
-cogorc_upsample_vert_avgub (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var32;
-  orc_int8 var33;
-  orc_int8 var34;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var32 = ptr4[i];
-    /* 1: loadb */
-    var33 = ptr5[i];
-    /* 2: avgub */
-    var34 = ((orc_uint8) var32 + (orc_uint8) var33 + 1) >> 1;
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_upsample_vert_avgub (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var32;
-  orc_int8 var33;
-  orc_int8 var34;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var32 = ptr4[i];
-    /* 1: loadb */
-    var33 = ptr5[i];
-    /* 2: avgub */
-    var34 = ((orc_uint8) var32 + (orc_uint8) var33 + 1) >> 1;
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-cogorc_upsample_vert_avgub (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_upsample_vert_avgub");
-      orc_program_set_backup_function (p, _backup_cogorc_upsample_vert_avgub);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-
-      orc_program_append_2 (p, "avgub", 0, ORC_VAR_D1, ORC_VAR_S1, ORC_VAR_S2,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_unpack_yuyv_y */
-#ifdef DISABLE_ORC
-void
-orc_unpack_yuyv_y (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  orc_union16 var32;
-  orc_int8 var33;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union16 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var32 = ptr4[i];
-    /* 1: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var32.i;
-      var33 = _src.x2[0];
-    }
-    /* 2: storeb */
-    ptr0[i] = var33;
-  }
-
-}
-
-#else
-static void
-_backup_orc_unpack_yuyv_y (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  orc_union16 var32;
-  orc_int8 var33;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var32 = ptr4[i];
-    /* 1: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var32.i;
-      var33 = _src.x2[0];
-    }
-    /* 2: storeb */
-    ptr0[i] = var33;
-  }
-
-}
-
-void
-orc_unpack_yuyv_y (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_unpack_yuyv_y");
-      orc_program_set_backup_function (p, _backup_orc_unpack_yuyv_y);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 2, "s1");
-
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_D1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_unpack_yuyv_u */
-#ifdef DISABLE_ORC
-void
-orc_unpack_yuyv_u (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union32 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select0lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[0];
-    }
-    /* 2: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[1];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_orc_unpack_yuyv_u (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union32 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select0lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[0];
-    }
-    /* 2: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[1];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-orc_unpack_yuyv_u (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_unpack_yuyv_u");
-      orc_program_set_backup_function (p, _backup_orc_unpack_yuyv_u);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 4, "s1");
-      orc_program_add_temporary (p, 2, "t1");
-
-      orc_program_append_2 (p, "select0lw", 0, ORC_VAR_T1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_unpack_yuyv_v */
-#ifdef DISABLE_ORC
-void
-orc_unpack_yuyv_v (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union32 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select1lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[1];
-    }
-    /* 2: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[1];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_orc_unpack_yuyv_v (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union32 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select1lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[1];
-    }
-    /* 2: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[1];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-orc_unpack_yuyv_v (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_unpack_yuyv_v");
-      orc_program_set_backup_function (p, _backup_orc_unpack_yuyv_v);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 4, "s1");
-      orc_program_add_temporary (p, 2, "t1");
-
-      orc_program_append_2 (p, "select1lw", 0, ORC_VAR_T1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_pack_yuyv */
-#ifdef DISABLE_ORC
-void
-orc_pack_yuyv (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
-{
-  int i;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_int8 var39;
-  orc_union32 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-
-  ptr0 = (orc_union32 *) d1;
-  ptr4 = (orc_union16 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var37 = ptr4[i];
-    /* 1: copyw */
-    var41.i = var37.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var42 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var43 = _src.x2[1];
-    }
-    /* 4: loadb */
-    var38 = ptr5[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var42;
-      _dest.x2[1] = var38;
-      var44.i = _dest.i;
-    }
-    /* 6: loadb */
-    var39 = ptr6[i];
-    /* 7: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var43;
-      _dest.x2[1] = var39;
-      var45.i = _dest.i;
-    }
-    /* 8: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var44.i;
-      _dest.x2[1] = var45.i;
-      var40.i = _dest.i;
-    }
-    /* 9: storel */
-    ptr0[i] = var40;
-  }
-
-}
-
-#else
-static void
-_backup_orc_pack_yuyv (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_int8 var39;
-  orc_union32 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-
-  ptr0 = (orc_union32 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var37 = ptr4[i];
-    /* 1: copyw */
-    var41.i = var37.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var42 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var43 = _src.x2[1];
-    }
-    /* 4: loadb */
-    var38 = ptr5[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var42;
-      _dest.x2[1] = var38;
-      var44.i = _dest.i;
-    }
-    /* 6: loadb */
-    var39 = ptr6[i];
-    /* 7: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var43;
-      _dest.x2[1] = var39;
-      var45.i = _dest.i;
-    }
-    /* 8: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var44.i;
-      _dest.x2[1] = var45.i;
-      var40.i = _dest.i;
-    }
-    /* 9: storel */
-    ptr0[i] = var40;
-  }
-
-}
-
-void
-orc_pack_yuyv (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_pack_yuyv");
-      orc_program_set_backup_function (p, _backup_orc_pack_yuyv);
-      orc_program_add_destination (p, 4, "d1");
-      orc_program_add_source (p, 2, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_temporary (p, 1, "t1");
-      orc_program_add_temporary (p, 1, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-      orc_program_add_temporary (p, 2, "t4");
-      orc_program_add_temporary (p, 2, "t5");
-
-      orc_program_append_2 (p, "copyw", 0, ORC_VAR_T5, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_T1, ORC_VAR_T5,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_T2, ORC_VAR_T5,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_S2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_S3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T3, ORC_VAR_T4,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_unpack_uyvy_y */
-#ifdef DISABLE_ORC
-void
-orc_unpack_uyvy_y (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  orc_union16 var32;
-  orc_int8 var33;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union16 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var32 = ptr4[i];
-    /* 1: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var32.i;
-      var33 = _src.x2[1];
-    }
-    /* 2: storeb */
-    ptr0[i] = var33;
-  }
-
-}
-
-#else
-static void
-_backup_orc_unpack_uyvy_y (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  orc_union16 var32;
-  orc_int8 var33;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var32 = ptr4[i];
-    /* 1: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var32.i;
-      var33 = _src.x2[1];
-    }
-    /* 2: storeb */
-    ptr0[i] = var33;
-  }
-
-}
-
-void
-orc_unpack_uyvy_y (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_unpack_uyvy_y");
-      orc_program_set_backup_function (p, _backup_orc_unpack_uyvy_y);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 2, "s1");
-
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_D1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_unpack_uyvy_u */
-#ifdef DISABLE_ORC
-void
-orc_unpack_uyvy_u (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union32 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select0lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[0];
-    }
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[0];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_orc_unpack_uyvy_u (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union32 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select0lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[0];
-    }
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[0];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-orc_unpack_uyvy_u (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_unpack_uyvy_u");
-      orc_program_set_backup_function (p, _backup_orc_unpack_uyvy_u);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 4, "s1");
-      orc_program_add_temporary (p, 2, "t1");
-
-      orc_program_append_2 (p, "select0lw", 0, ORC_VAR_T1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_unpack_uyvy_v */
-#ifdef DISABLE_ORC
-void
-orc_unpack_uyvy_v (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_union32 *) s1;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select1lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[1];
-    }
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[0];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-#else
-static void
-_backup_orc_unpack_uyvy_v (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_union32 *ORC_RESTRICT ptr4;
-  orc_union32 var33;
-  orc_int8 var34;
-  orc_union16 var35;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_union32 *) ex->arrays[4];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadl */
-    var33 = ptr4[i];
-    /* 1: select1lw */
-    {
-      orc_union32 _src;
-      _src.i = var33.i;
-      var35.i = _src.x2[1];
-    }
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var35.i;
-      var34 = _src.x2[0];
-    }
-    /* 3: storeb */
-    ptr0[i] = var34;
-  }
-
-}
-
-void
-orc_unpack_uyvy_v (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_unpack_uyvy_v");
-      orc_program_set_backup_function (p, _backup_orc_unpack_uyvy_v);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 4, "s1");
-      orc_program_add_temporary (p, 2, "t1");
-
-      orc_program_append_2 (p, "select1lw", 0, ORC_VAR_T1, ORC_VAR_S1,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_pack_uyvy */
-#ifdef DISABLE_ORC
-void
-orc_pack_uyvy (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
-{
-  int i;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_int8 var39;
-  orc_union32 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-
-  ptr0 = (orc_union32 *) d1;
-  ptr4 = (orc_union16 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var37 = ptr4[i];
-    /* 1: copyw */
-    var41.i = var37.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var42 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var43 = _src.x2[1];
-    }
-    /* 4: loadb */
-    var38 = ptr5[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var38;
-      _dest.x2[1] = var42;
-      var44.i = _dest.i;
-    }
-    /* 6: loadb */
-    var39 = ptr6[i];
-    /* 7: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var39;
-      _dest.x2[1] = var43;
-      var45.i = _dest.i;
-    }
-    /* 8: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var44.i;
-      _dest.x2[1] = var45.i;
-      var40.i = _dest.i;
-    }
-    /* 9: storel */
-    ptr0[i] = var40;
-  }
-
-}
-
-#else
-static void
-_backup_orc_pack_uyvy (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_union16 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_int8 var39;
-  orc_union32 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-
-  ptr0 = (orc_union32 *) ex->arrays[0];
-  ptr4 = (orc_union16 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadw */
-    var37 = ptr4[i];
-    /* 1: copyw */
-    var41.i = var37.i;
-    /* 2: select0wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var42 = _src.x2[0];
-    }
-    /* 3: select1wb */
-    {
-      orc_union16 _src;
-      _src.i = var41.i;
-      var43 = _src.x2[1];
-    }
-    /* 4: loadb */
-    var38 = ptr5[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var38;
-      _dest.x2[1] = var42;
-      var44.i = _dest.i;
-    }
-    /* 6: loadb */
-    var39 = ptr6[i];
-    /* 7: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var39;
-      _dest.x2[1] = var43;
-      var45.i = _dest.i;
-    }
-    /* 8: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var44.i;
-      _dest.x2[1] = var45.i;
-      var40.i = _dest.i;
-    }
-    /* 9: storel */
-    ptr0[i] = var40;
-  }
-
-}
-
-void
-orc_pack_uyvy (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_pack_uyvy");
-      orc_program_set_backup_function (p, _backup_orc_pack_uyvy);
-      orc_program_add_destination (p, 4, "d1");
-      orc_program_add_source (p, 2, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_temporary (p, 1, "t1");
-      orc_program_add_temporary (p, 1, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-      orc_program_add_temporary (p, 2, "t4");
-      orc_program_add_temporary (p, 2, "t5");
-
-      orc_program_append_2 (p, "copyw", 0, ORC_VAR_T5, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "select0wb", 0, ORC_VAR_T1, ORC_VAR_T5,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "select1wb", 0, ORC_VAR_T2, ORC_VAR_T5,
-          ORC_VAR_D1, ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T3, ORC_VAR_S2, ORC_VAR_T1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T4, ORC_VAR_S3, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T3, ORC_VAR_T4,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix2_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int p3, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-  /* 2: loadpw */
-  var35.i = p1;
-  /* 6: loadpw */
-  var37.i = p2;
-  /* 9: loadpw */
-  var38.i = p3;
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var40.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var41.i = (var40.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var42.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var43.i = (var42.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var44.i = var41.i + var43.i;
-    /* 10: addw */
-    var45.i = var44.i + var38.i;
-    /* 11: shrsw */
-    var46.i = var45.i >> 6;
-    /* 12: convsuswb */
-    var39 = ORC_CLAMP_UB (var46.i);
-    /* 13: storeb */
-    ptr0[i] = var39;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix2_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-  /* 2: loadpw */
-  var35.i = ex->params[24];
-  /* 6: loadpw */
-  var37.i = ex->params[25];
-  /* 9: loadpw */
-  var38.i = ex->params[26];
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var40.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var41.i = (var40.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var42.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var43.i = (var42.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var44.i = var41.i + var43.i;
-    /* 10: addw */
-    var45.i = var44.i + var38.i;
-    /* 11: shrsw */
-    var46.i = var45.i >> 6;
-    /* 12: convsuswb */
-    var39 = ORC_CLAMP_UB (var46.i);
-    /* 13: storeb */
-    ptr0[i] = var39;
-  }
-
-}
-
-void
-orc_matrix2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int p3, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix2_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix2_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_constant (p, 4, 0x00000006, "c1");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_parameter (p, 2, "p3");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-  ex->params[ORC_VAR_P3] = p3;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix2_11_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix2_11_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-  /* 2: loadpw */
-  var37.i = (int) 0x00000010;   /* 16 or 7.90505e-323f */
-  /* 4: loadpw */
-  var38.i = p1;
-  /* 8: loadpw */
-  var40.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 10: loadpw */
-  var41.i = p2;
-  /* 13: loadpw */
-  var42.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var36 = ptr4[i];
-    /* 1: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 3: subw */
-    var45.i = var44.i - var37.i;
-    /* 5: mullw */
-    var46.i = (var45.i * var38.i) & 0xffff;
-    /* 6: loadb */
-    var39 = ptr5[i];
-    /* 7: convubw */
-    var47.i = (orc_uint8) var39;
-    /* 9: subw */
-    var48.i = var47.i - var40.i;
-    /* 11: mullw */
-    var49.i = (var48.i * var41.i) & 0xffff;
-    /* 12: addw */
-    var50.i = var46.i + var49.i;
-    /* 14: addw */
-    var51.i = var50.i + var42.i;
-    /* 15: shrsw */
-    var52.i = var51.i >> 8;
-    /* 16: addw */
-    var53.i = var52.i + var45.i;
-    /* 17: addw */
-    var54.i = var53.i + var48.i;
-    /* 18: convsuswb */
-    var43 = ORC_CLAMP_UB (var54.i);
-    /* 19: storeb */
-    ptr0[i] = var43;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix2_11_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-  /* 2: loadpw */
-  var37.i = (int) 0x00000010;   /* 16 or 7.90505e-323f */
-  /* 4: loadpw */
-  var38.i = ex->params[24];
-  /* 8: loadpw */
-  var40.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 10: loadpw */
-  var41.i = ex->params[25];
-  /* 13: loadpw */
-  var42.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var36 = ptr4[i];
-    /* 1: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 3: subw */
-    var45.i = var44.i - var37.i;
-    /* 5: mullw */
-    var46.i = (var45.i * var38.i) & 0xffff;
-    /* 6: loadb */
-    var39 = ptr5[i];
-    /* 7: convubw */
-    var47.i = (orc_uint8) var39;
-    /* 9: subw */
-    var48.i = var47.i - var40.i;
-    /* 11: mullw */
-    var49.i = (var48.i * var41.i) & 0xffff;
-    /* 12: addw */
-    var50.i = var46.i + var49.i;
-    /* 14: addw */
-    var51.i = var50.i + var42.i;
-    /* 15: shrsw */
-    var52.i = var51.i >> 8;
-    /* 16: addw */
-    var53.i = var52.i + var45.i;
-    /* 17: addw */
-    var54.i = var53.i + var48.i;
-    /* 18: convsuswb */
-    var43 = ORC_CLAMP_UB (var54.i);
-    /* 19: storeb */
-    ptr0[i] = var43;
-  }
-
-}
-
-void
-orc_matrix2_11_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix2_11_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix2_11_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_constant (p, 4, 0x00000010, "c1");
-      orc_program_add_constant (p, 4, 0x00000080, "c2");
-      orc_program_add_constant (p, 4, 0x00000008, "c3");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-      orc_program_add_temporary (p, 2, "t4");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T4,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_C3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T3,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix2_12_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix2_12_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-  orc_union16 var55;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-  /* 2: loadpw */
-  var37.i = (int) 0x00000010;   /* 16 or 7.90505e-323f */
-  /* 4: loadpw */
-  var38.i = p1;
-  /* 8: loadpw */
-  var40.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 10: loadpw */
-  var41.i = p2;
-  /* 13: loadpw */
-  var42.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var36 = ptr4[i];
-    /* 1: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 3: subw */
-    var45.i = var44.i - var37.i;
-    /* 5: mullw */
-    var46.i = (var45.i * var38.i) & 0xffff;
-    /* 6: loadb */
-    var39 = ptr5[i];
-    /* 7: convubw */
-    var47.i = (orc_uint8) var39;
-    /* 9: subw */
-    var48.i = var47.i - var40.i;
-    /* 11: mullw */
-    var49.i = (var48.i * var41.i) & 0xffff;
-    /* 12: addw */
-    var50.i = var46.i + var49.i;
-    /* 14: addw */
-    var51.i = var50.i + var42.i;
-    /* 15: shrsw */
-    var52.i = var51.i >> 8;
-    /* 16: addw */
-    var53.i = var52.i + var45.i;
-    /* 17: addw */
-    var54.i = var53.i + var48.i;
-    /* 18: addw */
-    var55.i = var54.i + var48.i;
-    /* 19: convsuswb */
-    var43 = ORC_CLAMP_UB (var55.i);
-    /* 20: storeb */
-    ptr0[i] = var43;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix2_12_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_int8 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-  orc_union16 var55;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-  /* 2: loadpw */
-  var37.i = (int) 0x00000010;   /* 16 or 7.90505e-323f */
-  /* 4: loadpw */
-  var38.i = ex->params[24];
-  /* 8: loadpw */
-  var40.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 10: loadpw */
-  var41.i = ex->params[25];
-  /* 13: loadpw */
-  var42.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var36 = ptr4[i];
-    /* 1: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 3: subw */
-    var45.i = var44.i - var37.i;
-    /* 5: mullw */
-    var46.i = (var45.i * var38.i) & 0xffff;
-    /* 6: loadb */
-    var39 = ptr5[i];
-    /* 7: convubw */
-    var47.i = (orc_uint8) var39;
-    /* 9: subw */
-    var48.i = var47.i - var40.i;
-    /* 11: mullw */
-    var49.i = (var48.i * var41.i) & 0xffff;
-    /* 12: addw */
-    var50.i = var46.i + var49.i;
-    /* 14: addw */
-    var51.i = var50.i + var42.i;
-    /* 15: shrsw */
-    var52.i = var51.i >> 8;
-    /* 16: addw */
-    var53.i = var52.i + var45.i;
-    /* 17: addw */
-    var54.i = var53.i + var48.i;
-    /* 18: addw */
-    var55.i = var54.i + var48.i;
-    /* 19: convsuswb */
-    var43 = ORC_CLAMP_UB (var55.i);
-    /* 20: storeb */
-    ptr0[i] = var43;
-  }
-
-}
-
-void
-orc_matrix2_12_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix2_12_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix2_12_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_constant (p, 4, 0x00000010, "c1");
-      orc_program_add_constant (p, 4, 0x00000080, "c2");
-      orc_program_add_constant (p, 4, 0x00000008, "c3");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-      orc_program_add_temporary (p, 2, "t4");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T4, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T4,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_C3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T3,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix3_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix3_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int p4, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 2: loadpw */
-  var35.i = p1;
-  /* 6: loadpw */
-  var37.i = p2;
-  /* 11: loadpw */
-  var39.i = p3;
-  /* 14: loadpw */
-  var40.i = p4;
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var42.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var43.i = (var42.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var45.i = (var44.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var46.i = var43.i + var45.i;
-    /* 9: loadb */
-    var38 = ptr6[i];
-    /* 10: convubw */
-    var47.i = (orc_uint8) var38;
-    /* 12: mullw */
-    var48.i = (var47.i * var39.i) & 0xffff;
-    /* 13: addw */
-    var49.i = var46.i + var48.i;
-    /* 15: addw */
-    var50.i = var49.i + var40.i;
-    /* 16: shrsw */
-    var51.i = var50.i >> 6;
-    /* 17: convsuswb */
-    var41 = ORC_CLAMP_UB (var51.i);
-    /* 18: storeb */
-    ptr0[i] = var41;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix3_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 2: loadpw */
-  var35.i = ex->params[24];
-  /* 6: loadpw */
-  var37.i = ex->params[25];
-  /* 11: loadpw */
-  var39.i = ex->params[26];
-  /* 14: loadpw */
-  var40.i = ex->params[27];
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var42.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var43.i = (var42.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var45.i = (var44.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var46.i = var43.i + var45.i;
-    /* 9: loadb */
-    var38 = ptr6[i];
-    /* 10: convubw */
-    var47.i = (orc_uint8) var38;
-    /* 12: mullw */
-    var48.i = (var47.i * var39.i) & 0xffff;
-    /* 13: addw */
-    var49.i = var46.i + var48.i;
-    /* 15: addw */
-    var50.i = var49.i + var40.i;
-    /* 16: shrsw */
-    var51.i = var50.i >> 6;
-    /* 17: convsuswb */
-    var41 = ORC_CLAMP_UB (var51.i);
-    /* 18: storeb */
-    ptr0[i] = var41;
-  }
-
-}
-
-void
-orc_matrix3_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int p4, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix3_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix3_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_constant (p, 4, 0x00000006, "c1");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_parameter (p, 2, "p3");
-      orc_program_add_parameter (p, 2, "p4");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P4,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-  ex->params[ORC_VAR_P3] = p3;
-  ex->params[ORC_VAR_P4] = p4;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix3_100_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix3_100_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var35;
-  orc_union16 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_int8 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-  orc_union16 var55;
-  orc_union16 var56;
-  orc_union16 var57;
-  orc_union16 var58;
-  orc_union16 var59;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 2: loadpw */
-  var36.i = (int) 0x00000010;   /* 16 or 7.90505e-323f */
-  /* 4: loadpw */
-  var37.i = p1;
-  /* 8: loadpw */
-  var39.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 10: loadpw */
-  var40.i = p2;
-  /* 15: loadpw */
-  var42.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 17: loadpw */
-  var43.i = p3;
-  /* 20: loadpw */
-  var44.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var35 = ptr4[i];
-    /* 1: convubw */
-    var46.i = (orc_uint8) var35;
-    /* 3: subw */
-    var47.i = var46.i - var36.i;
-    /* 5: mullw */
-    var48.i = (var47.i * var37.i) & 0xffff;
-    /* 6: loadb */
-    var38 = ptr5[i];
-    /* 7: convubw */
-    var49.i = (orc_uint8) var38;
-    /* 9: subw */
-    var50.i = var49.i - var39.i;
-    /* 11: mullw */
-    var51.i = (var50.i * var40.i) & 0xffff;
-    /* 12: addw */
-    var52.i = var48.i + var51.i;
-    /* 13: loadb */
-    var41 = ptr6[i];
-    /* 14: convubw */
-    var53.i = (orc_uint8) var41;
-    /* 16: subw */
-    var54.i = var53.i - var42.i;
-    /* 18: mullw */
-    var55.i = (var54.i * var43.i) & 0xffff;
-    /* 19: addw */
-    var56.i = var52.i + var55.i;
-    /* 21: addw */
-    var57.i = var56.i + var44.i;
-    /* 22: shrsw */
-    var58.i = var57.i >> 8;
-    /* 23: addw */
-    var59.i = var58.i + var47.i;
-    /* 24: convsuswb */
-    var45 = ORC_CLAMP_UB (var59.i);
-    /* 25: storeb */
-    ptr0[i] = var45;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix3_100_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var35;
-  orc_union16 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_int8 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-  orc_union16 var54;
-  orc_union16 var55;
-  orc_union16 var56;
-  orc_union16 var57;
-  orc_union16 var58;
-  orc_union16 var59;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 2: loadpw */
-  var36.i = (int) 0x00000010;   /* 16 or 7.90505e-323f */
-  /* 4: loadpw */
-  var37.i = ex->params[24];
-  /* 8: loadpw */
-  var39.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 10: loadpw */
-  var40.i = ex->params[25];
-  /* 15: loadpw */
-  var42.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-  /* 17: loadpw */
-  var43.i = ex->params[26];
-  /* 20: loadpw */
-  var44.i = (int) 0x00000080;   /* 128 or 6.32404e-322f */
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var35 = ptr4[i];
-    /* 1: convubw */
-    var46.i = (orc_uint8) var35;
-    /* 3: subw */
-    var47.i = var46.i - var36.i;
-    /* 5: mullw */
-    var48.i = (var47.i * var37.i) & 0xffff;
-    /* 6: loadb */
-    var38 = ptr5[i];
-    /* 7: convubw */
-    var49.i = (orc_uint8) var38;
-    /* 9: subw */
-    var50.i = var49.i - var39.i;
-    /* 11: mullw */
-    var51.i = (var50.i * var40.i) & 0xffff;
-    /* 12: addw */
-    var52.i = var48.i + var51.i;
-    /* 13: loadb */
-    var41 = ptr6[i];
-    /* 14: convubw */
-    var53.i = (orc_uint8) var41;
-    /* 16: subw */
-    var54.i = var53.i - var42.i;
-    /* 18: mullw */
-    var55.i = (var54.i * var43.i) & 0xffff;
-    /* 19: addw */
-    var56.i = var52.i + var55.i;
-    /* 21: addw */
-    var57.i = var56.i + var44.i;
-    /* 22: shrsw */
-    var58.i = var57.i >> 8;
-    /* 23: addw */
-    var59.i = var58.i + var47.i;
-    /* 24: convsuswb */
-    var45 = ORC_CLAMP_UB (var59.i);
-    /* 25: storeb */
-    ptr0[i] = var45;
-  }
-
-}
-
-void
-orc_matrix3_100_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix3_100_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix3_100_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_constant (p, 4, 0x00000010, "c1");
-      orc_program_add_constant (p, 4, 0x00000080, "c2");
-      orc_program_add_constant (p, 4, 0x00000008, "c3");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_parameter (p, 2, "p3");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T3, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "subw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_C2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_C3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T3, ORC_VAR_T3, ORC_VAR_T1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T3,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-  ex->params[ORC_VAR_P3] = p3;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix3_100_offset_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix3_100_offset_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int p5,
-    int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var35;
-  orc_union16 var36;
-  orc_int8 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 2: loadpw */
-  var36.i = p1;
-  /* 6: loadpw */
-  var38.i = p2;
-  /* 11: loadpw */
-  var40.i = p3;
-  /* 14: loadpw */
-  var41.i = p4;
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var35 = ptr4[i];
-    /* 1: convubw */
-    var43.i = (orc_uint8) var35;
-    /* 3: mullw */
-    var44.i = (var43.i * var36.i) & 0xffff;
-    /* 4: loadb */
-    var37 = ptr5[i];
-    /* 5: convubw */
-    var45.i = (orc_uint8) var37;
-    /* 7: mullw */
-    var46.i = (var45.i * var38.i) & 0xffff;
-    /* 8: addw */
-    var47.i = var44.i + var46.i;
-    /* 9: loadb */
-    var39 = ptr6[i];
-    /* 10: convubw */
-    var48.i = (orc_uint8) var39;
-    /* 12: mullw */
-    var49.i = (var48.i * var40.i) & 0xffff;
-    /* 13: addw */
-    var50.i = var47.i + var49.i;
-    /* 15: addw */
-    var51.i = var50.i + var41.i;
-    /* 16: shrsw */
-    var52.i = var51.i >> p5;
-    /* 17: addw */
-    var53.i = var52.i + var43.i;
-    /* 18: convsuswb */
-    var42 = ORC_CLAMP_UB (var53.i);
-    /* 19: storeb */
-    ptr0[i] = var42;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix3_100_offset_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var35;
-  orc_union16 var36;
-  orc_int8 var37;
-  orc_union16 var38;
-  orc_int8 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_int8 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-  orc_union16 var52;
-  orc_union16 var53;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 2: loadpw */
-  var36.i = ex->params[24];
-  /* 6: loadpw */
-  var38.i = ex->params[25];
-  /* 11: loadpw */
-  var40.i = ex->params[26];
-  /* 14: loadpw */
-  var41.i = ex->params[27];
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var35 = ptr4[i];
-    /* 1: convubw */
-    var43.i = (orc_uint8) var35;
-    /* 3: mullw */
-    var44.i = (var43.i * var36.i) & 0xffff;
-    /* 4: loadb */
-    var37 = ptr5[i];
-    /* 5: convubw */
-    var45.i = (orc_uint8) var37;
-    /* 7: mullw */
-    var46.i = (var45.i * var38.i) & 0xffff;
-    /* 8: addw */
-    var47.i = var44.i + var46.i;
-    /* 9: loadb */
-    var39 = ptr6[i];
-    /* 10: convubw */
-    var48.i = (orc_uint8) var39;
-    /* 12: mullw */
-    var49.i = (var48.i * var40.i) & 0xffff;
-    /* 13: addw */
-    var50.i = var47.i + var49.i;
-    /* 15: addw */
-    var51.i = var50.i + var41.i;
-    /* 16: shrsw */
-    var52.i = var51.i >> ex->params[28];
-    /* 17: addw */
-    var53.i = var52.i + var43.i;
-    /* 18: convsuswb */
-    var42 = ORC_CLAMP_UB (var53.i);
-    /* 19: storeb */
-    ptr0[i] = var42;
-  }
-
-}
-
-void
-orc_matrix3_100_offset_u8 (guint8 * ORC_RESTRICT d1,
-    const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2,
-    const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int p5,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix3_100_offset_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix3_100_offset_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_parameter (p, 2, "p3");
-      orc_program_add_parameter (p, 2, "p4");
-      orc_program_add_parameter (p, 2, "p5");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-      orc_program_add_temporary (p, 2, "t3");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T3, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T1, ORC_VAR_T3, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P4,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P5,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-  ex->params[ORC_VAR_P3] = p3;
-  ex->params[ORC_VAR_P4] = p4;
-  ex->params[ORC_VAR_P5] = p5;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_matrix3_000_u8 */
-#ifdef DISABLE_ORC
-void
-orc_matrix3_000_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int p4, int p5, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 2: loadpw */
-  var35.i = p1;
-  /* 6: loadpw */
-  var37.i = p2;
-  /* 11: loadpw */
-  var39.i = p3;
-  /* 14: loadpw */
-  var40.i = p4;
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var42.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var43.i = (var42.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var45.i = (var44.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var46.i = var43.i + var45.i;
-    /* 9: loadb */
-    var38 = ptr6[i];
-    /* 10: convubw */
-    var47.i = (orc_uint8) var38;
-    /* 12: mullw */
-    var48.i = (var47.i * var39.i) & 0xffff;
-    /* 13: addw */
-    var49.i = var46.i + var48.i;
-    /* 15: addw */
-    var50.i = var49.i + var40.i;
-    /* 16: shrsw */
-    var51.i = var50.i >> p5;
-    /* 17: convwb */
-    var41 = var51.i;
-    /* 18: storeb */
-    ptr0[i] = var41;
-  }
-
-}
-
-#else
-static void
-_backup_orc_matrix3_000_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_int8 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-  orc_union16 var45;
-  orc_union16 var46;
-  orc_union16 var47;
-  orc_union16 var48;
-  orc_union16 var49;
-  orc_union16 var50;
-  orc_union16 var51;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 2: loadpw */
-  var35.i = ex->params[24];
-  /* 6: loadpw */
-  var37.i = ex->params[25];
-  /* 11: loadpw */
-  var39.i = ex->params[26];
-  /* 14: loadpw */
-  var40.i = ex->params[27];
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var42.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var43.i = (var42.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var44.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var45.i = (var44.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var46.i = var43.i + var45.i;
-    /* 9: loadb */
-    var38 = ptr6[i];
-    /* 10: convubw */
-    var47.i = (orc_uint8) var38;
-    /* 12: mullw */
-    var48.i = (var47.i * var39.i) & 0xffff;
-    /* 13: addw */
-    var49.i = var46.i + var48.i;
-    /* 15: addw */
-    var50.i = var49.i + var40.i;
-    /* 16: shrsw */
-    var51.i = var50.i >> ex->params[28];
-    /* 17: convwb */
-    var41 = var51.i;
-    /* 18: storeb */
-    ptr0[i] = var41;
-  }
-
-}
-
-void
-orc_matrix3_000_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int p2, int p3, int p4, int p5, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_matrix3_000_u8");
-      orc_program_set_backup_function (p, _backup_orc_matrix3_000_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_parameter (p, 2, "p3");
-      orc_program_add_parameter (p, 2, "p4");
-      orc_program_add_parameter (p, 2, "p5");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S3, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P4,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shrsw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P5,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convwb", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_D1,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-  ex->params[ORC_VAR_P3] = p3;
-  ex->params[ORC_VAR_P4] = p4;
-  ex->params[ORC_VAR_P5] = p5;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_pack_123x */
-#ifdef DISABLE_ORC
-void
-orc_pack_123x (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int n)
-{
-  int i;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_int8 var35;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_union32 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-
-  ptr0 = (orc_union32 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 4: loadpb */
-  var37 = p1;
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: loadb */
-    var35 = ptr5[i];
-    /* 2: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var34;
-      _dest.x2[1] = var35;
-      var39.i = _dest.i;
-    }
-    /* 3: loadb */
-    var36 = ptr6[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var36;
-      _dest.x2[1] = var37;
-      var40.i = _dest.i;
-    }
-    /* 6: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var39.i;
-      _dest.x2[1] = var40.i;
-      var38.i = _dest.i;
-    }
-    /* 7: storel */
-    ptr0[i] = var38;
-  }
-
-}
-
-#else
-static void
-_backup_orc_pack_123x (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_int8 var35;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_union32 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-
-  ptr0 = (orc_union32 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 4: loadpb */
-  var37 = ex->params[24];
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: loadb */
-    var35 = ptr5[i];
-    /* 2: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var34;
-      _dest.x2[1] = var35;
-      var39.i = _dest.i;
-    }
-    /* 3: loadb */
-    var36 = ptr6[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var36;
-      _dest.x2[1] = var37;
-      var40.i = _dest.i;
-    }
-    /* 6: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var39.i;
-      _dest.x2[1] = var40.i;
-      var38.i = _dest.i;
-    }
-    /* 7: storel */
-    ptr0[i] = var38;
-  }
-
-}
-
-void
-orc_pack_123x (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_pack_123x");
-      orc_program_set_backup_function (p, _backup_orc_pack_123x);
-      orc_program_add_destination (p, 4, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_parameter (p, 1, "p1");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_S2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T2, ORC_VAR_S3, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->params[ORC_VAR_P1] = p1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* orc_pack_x123 */
-#ifdef DISABLE_ORC
-void
-orc_pack_x123 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int n)
-{
-  int i;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_int8 var35;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_union32 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-
-  ptr0 = (orc_union32 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-  ptr6 = (orc_int8 *) s3;
-
-  /* 0: loadpb */
-  var34 = p1;
-
-  for (i = 0; i < n; i++) {
-    /* 1: loadb */
-    var35 = ptr4[i];
-    /* 2: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var34;
-      _dest.x2[1] = var35;
-      var39.i = _dest.i;
-    }
-    /* 3: loadb */
-    var36 = ptr5[i];
-    /* 4: loadb */
-    var37 = ptr6[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var36;
-      _dest.x2[1] = var37;
-      var40.i = _dest.i;
-    }
-    /* 6: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var39.i;
-      _dest.x2[1] = var40.i;
-      var38.i = _dest.i;
-    }
-    /* 7: storel */
-    ptr0[i] = var38;
-  }
-
-}
-
-#else
-static void
-_backup_orc_pack_x123 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_union32 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  const orc_int8 *ORC_RESTRICT ptr6;
-  orc_int8 var34;
-  orc_int8 var35;
-  orc_int8 var36;
-  orc_int8 var37;
-  orc_union32 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-
-  ptr0 = (orc_union32 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-  ptr6 = (orc_int8 *) ex->arrays[6];
-
-  /* 0: loadpb */
-  var34 = ex->params[24];
-
-  for (i = 0; i < n; i++) {
-    /* 1: loadb */
-    var35 = ptr4[i];
-    /* 2: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var34;
-      _dest.x2[1] = var35;
-      var39.i = _dest.i;
-    }
-    /* 3: loadb */
-    var36 = ptr5[i];
-    /* 4: loadb */
-    var37 = ptr6[i];
-    /* 5: mergebw */
-    {
-      orc_union16 _dest;
-      _dest.x2[0] = var36;
-      _dest.x2[1] = var37;
-      var40.i = _dest.i;
-    }
-    /* 6: mergewl */
-    {
-      orc_union32 _dest;
-      _dest.x2[0] = var39.i;
-      _dest.x2[1] = var40.i;
-      var38.i = _dest.i;
-    }
-    /* 7: storel */
-    ptr0[i] = var38;
-  }
-
-}
-
-void
-orc_pack_x123 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1,
-    int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "orc_pack_x123");
-      orc_program_set_backup_function (p, _backup_orc_pack_x123);
-      orc_program_add_destination (p, 4, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_source (p, 1, "s3");
-      orc_program_add_parameter (p, 1, "p1");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T1, ORC_VAR_P1, ORC_VAR_S1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergebw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_S3,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mergewl", 0, ORC_VAR_D1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->arrays[ORC_VAR_S3] = (void *) s3;
-  ex->params[ORC_VAR_P1] = p1;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
-/* cogorc_combine2_u8 */
-#ifdef DISABLE_ORC
-void
-cogorc_combine2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int n)
-{
-  int i;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-
-  ptr0 = (orc_int8 *) d1;
-  ptr4 = (orc_int8 *) s1;
-  ptr5 = (orc_int8 *) s2;
-
-  /* 2: loadpw */
-  var35.i = p1;
-  /* 6: loadpw */
-  var37.i = p2;
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var39.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var40.i = (var39.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var41.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var42.i = (var41.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var43.i = var40.i + var42.i;
-    /* 9: shruw */
-    var44.i = ((orc_uint16) var43.i) >> 8;
-    /* 10: convsuswb */
-    var38 = ORC_CLAMP_UB (var44.i);
-    /* 11: storeb */
-    ptr0[i] = var38;
-  }
-
-}
-
-#else
-static void
-_backup_cogorc_combine2_u8 (OrcExecutor * ORC_RESTRICT ex)
-{
-  int i;
-  int n = ex->n;
-  orc_int8 *ORC_RESTRICT ptr0;
-  const orc_int8 *ORC_RESTRICT ptr4;
-  const orc_int8 *ORC_RESTRICT ptr5;
-  orc_int8 var34;
-  orc_union16 var35;
-  orc_int8 var36;
-  orc_union16 var37;
-  orc_int8 var38;
-  orc_union16 var39;
-  orc_union16 var40;
-  orc_union16 var41;
-  orc_union16 var42;
-  orc_union16 var43;
-  orc_union16 var44;
-
-  ptr0 = (orc_int8 *) ex->arrays[0];
-  ptr4 = (orc_int8 *) ex->arrays[4];
-  ptr5 = (orc_int8 *) ex->arrays[5];
-
-  /* 2: loadpw */
-  var35.i = ex->params[24];
-  /* 6: loadpw */
-  var37.i = ex->params[25];
-
-  for (i = 0; i < n; i++) {
-    /* 0: loadb */
-    var34 = ptr4[i];
-    /* 1: convubw */
-    var39.i = (orc_uint8) var34;
-    /* 3: mullw */
-    var40.i = (var39.i * var35.i) & 0xffff;
-    /* 4: loadb */
-    var36 = ptr5[i];
-    /* 5: convubw */
-    var41.i = (orc_uint8) var36;
-    /* 7: mullw */
-    var42.i = (var41.i * var37.i) & 0xffff;
-    /* 8: addw */
-    var43.i = var40.i + var42.i;
-    /* 9: shruw */
-    var44.i = ((orc_uint16) var43.i) >> 8;
-    /* 10: convsuswb */
-    var38 = ORC_CLAMP_UB (var44.i);
-    /* 11: storeb */
-    ptr0[i] = var38;
-  }
-
-}
-
-void
-cogorc_combine2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1,
-    const guint8 * ORC_RESTRICT s2, int p1, int p2, int n)
-{
-  OrcExecutor _ex, *ex = &_ex;
-  static volatile int p_inited = 0;
-  static OrcProgram *p = 0;
-  void (*func) (OrcExecutor *);
-
-  if (!p_inited) {
-    orc_once_mutex_lock ();
-    if (!p_inited) {
-
-      p = orc_program_new ();
-      orc_program_set_name (p, "cogorc_combine2_u8");
-      orc_program_set_backup_function (p, _backup_cogorc_combine2_u8);
-      orc_program_add_destination (p, 1, "d1");
-      orc_program_add_source (p, 1, "s1");
-      orc_program_add_source (p, 1, "s2");
-      orc_program_add_constant (p, 4, 0x00000008, "c1");
-      orc_program_add_parameter (p, 2, "p1");
-      orc_program_add_parameter (p, 2, "p2");
-      orc_program_add_temporary (p, 2, "t1");
-      orc_program_add_temporary (p, 2, "t2");
-
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T1, ORC_VAR_S1, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_P1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convubw", 0, ORC_VAR_T2, ORC_VAR_S2, ORC_VAR_D1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "mullw", 0, ORC_VAR_T2, ORC_VAR_T2, ORC_VAR_P2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "addw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_T2,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "shruw", 0, ORC_VAR_T1, ORC_VAR_T1, ORC_VAR_C1,
-          ORC_VAR_D1);
-      orc_program_append_2 (p, "convsuswb", 0, ORC_VAR_D1, ORC_VAR_T1,
-          ORC_VAR_D1, ORC_VAR_D1);
-
-      orc_program_compile (p);
-    }
-    p_inited = TRUE;
-    orc_once_mutex_unlock ();
-  }
-  ex->program = p;
-
-  ex->n = n;
-  ex->arrays[ORC_VAR_D1] = d1;
-  ex->arrays[ORC_VAR_S1] = (void *) s1;
-  ex->arrays[ORC_VAR_S2] = (void *) s2;
-  ex->params[ORC_VAR_P1] = p1;
-  ex->params[ORC_VAR_P2] = p2;
-
-  func = p->code_exec;
-  func (ex);
-}
-#endif
-
-
 /* cogorc_convert_I420_UYVY */
 #ifdef DISABLE_ORC
 void
diff --git a/gst/videoconvert/gstvideoconvertorc-dist.h b/gst/videoconvert/gstvideoconvertorc-dist.h
index 6ba5ae6..17e7a01 100644
--- a/gst/videoconvert/gstvideoconvertorc-dist.h
+++ b/gst/videoconvert/gstvideoconvertorc-dist.h
@@ -68,33 +68,6 @@
 #endif
 #endif
 void cogorc_memcpy_2d (guint8 * ORC_RESTRICT d1, int d1_stride, const guint8 * ORC_RESTRICT s1, int s1_stride, int n, int m);
-void cogorc_downsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void cogorc_downsample_horiz_cosite_3tap (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_downsample_420_jpeg (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_downsample_vert_halfsite_2tap (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_downsample_vert_cosite_3tap (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
-void cogorc_downsample_vert_halfsite_4tap (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n);
-void cogorc_upsample_horiz_cosite_1tap (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void cogorc_upsample_horiz_cosite (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void cogorc_upsample_vert_avgub (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int n);
-void orc_unpack_yuyv_y (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_yuyv_u (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_yuyv_v (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void orc_pack_yuyv (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
-void orc_unpack_uyvy_y (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_uyvy_u (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void orc_unpack_uyvy_v (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, int n);
-void orc_pack_uyvy (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int n);
-void orc_matrix2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1, int p2, int p3, int n);
-void orc_matrix2_11_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1, int p2, int n);
-void orc_matrix2_12_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1, int p2, int n);
-void orc_matrix3_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int n);
-void orc_matrix3_100_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int n);
-void orc_matrix3_100_offset_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int p5, int n);
-void orc_matrix3_000_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1, int p2, int p3, int p4, int p5, int n);
-void orc_pack_123x (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1, int n);
-void orc_pack_x123 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, int p1, int n);
-void cogorc_combine2_u8 (guint8 * ORC_RESTRICT d1, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, int p1, int p2, int n);
 void cogorc_convert_I420_UYVY (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n);
 void cogorc_convert_I420_YUY2 (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n);
 void cogorc_convert_I420_AYUV (guint8 * ORC_RESTRICT d1, guint8 * ORC_RESTRICT d2, const guint8 * ORC_RESTRICT s1, const guint8 * ORC_RESTRICT s2, const guint8 * ORC_RESTRICT s3, const guint8 * ORC_RESTRICT s4, int n);
diff --git a/gst/videoconvert/gstvideoconvertorc.orc b/gst/videoconvert/gstvideoconvertorc.orc
index 086990e..978a562 100644
--- a/gst/videoconvert/gstvideoconvertorc.orc
+++ b/gst/videoconvert/gstvideoconvertorc.orc
@@ -6,470 +6,6 @@
 
 copyb d1, s1
 
-
-.function cogorc_downsample_horiz_cosite_1tap
-.dest 1 d1 guint8
-.source 2 s1 guint8
-
-select0wb d1, s1
-
-
-.function cogorc_downsample_horiz_cosite_3tap
-.dest 1 d1 guint8
-.source 2 s1 guint8
-.source 2 s2 guint8
-.temp 1 t1
-.temp 1 t2
-.temp 1 t3
-.temp 2 t4
-.temp 2 t5
-.temp 2 t6
-
-copyw t4, s1
-select0wb t1, t4
-select1wb t2, t4
-select0wb t3, s2
-convubw t4, t1
-convubw t5, t2
-convubw t6, t3
-mullw t5, t5, 2
-addw t4, t4, t6
-addw t4, t4, t5
-addw t4, t4, 2
-shrsw t4, t4, 2
-convsuswb d1, t4
-
-
-.function cogorc_downsample_420_jpeg
-.dest 1 d1 guint8
-.source 2 s1 guint8
-.source 2 s2 guint8
-.temp 2 t1
-.temp 1 t2
-.temp 1 t3
-.temp 1 t4
-.temp 1 t5
-
-copyw t1, s1
-select0wb t2, t1
-select1wb t3, t1
-avgub t2, t2, t3
-copyw t1, s2
-select0wb t4, t1
-select1wb t5, t1
-avgub t4, t4, t5
-avgub d1, t2, t4
-
-
-.function cogorc_downsample_vert_halfsite_2tap
-.dest 1 d1 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-
-avgub d1, s1, s2
-
-
-.function cogorc_downsample_vert_cosite_3tap
-.dest 1 d1 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-.source 1 s3 guint8
-.temp 2 t1
-.temp 2 t2
-.temp 2 t3
-
-convubw t1, s1
-convubw t2, s2
-convubw t3, s3
-mullw t2, t2, 2
-addw t1, t1, t3
-addw t1, t1, t2
-addw t1, t1, 2
-shrsw t1, t1, 2
-convsuswb d1, t1
-
-
-
-.function cogorc_downsample_vert_halfsite_4tap
-.dest 1 d1 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-.source 1 s3 guint8
-.source 1 s4 guint8
-.temp 2 t1
-.temp 2 t2
-.temp 2 t3
-.temp 2 t4
-
-convubw t1, s1
-convubw t2, s2
-convubw t3, s3
-convubw t4, s4
-addw t2, t2, t3
-mullw t2, t2, 26
-addw t1, t1, t4
-mullw t1, t1, 6
-addw t2, t2, t1
-addw t2, t2, 32
-shrsw t2, t2, 6
-convsuswb d1, t2
-
-
-.function cogorc_upsample_horiz_cosite_1tap
-.dest 2 d1 guint8 guint8
-.source 1 s1 guint8
-.temp 1 t1
-
-copyb t1, s1
-mergebw d1, t1, t1
-
-
-.function cogorc_upsample_horiz_cosite
-.dest 2 d1 guint8 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-.temp 1 t1
-.temp 1 t2
-
-copyb t1, s1
-avgub t2, t1, s2
-mergebw d1, t1, t2
-
-
-.function cogorc_upsample_vert_avgub
-.dest 1 d1 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-
-avgub d1, s1, s2
-
-
-
-
-.function orc_unpack_yuyv_y
-.dest 1 d1 guint8
-.source 2 s1 guint8
-
-select0wb d1, s1
-
-
-.function orc_unpack_yuyv_u
-.dest 1 d1 guint8
-.source 4 s1 guint8
-.temp 2 t1
-
-select0lw t1, s1
-select1wb d1, t1
-
-
-.function orc_unpack_yuyv_v
-.dest 1 d1 guint8
-.source 4 s1 guint8
-.temp 2 t1
-
-select1lw t1, s1
-select1wb d1, t1
-
-
-.function orc_pack_yuyv
-.dest 4 d1 guint8
-.source 2 s1 guint8 guint8
-.source 1 s2 guint8
-.source 1 s3 guint8
-.temp 1 t1
-.temp 1 t2
-.temp 2 t3
-.temp 2 t4
-.temp 2 t5
-
-copyw t5, s1
-select0wb t1, t5
-select1wb t2, t5
-mergebw t3, t1, s2
-mergebw t4, t2, s3
-mergewl d1, t3, t4
-
-
-.function orc_unpack_uyvy_y
-.dest 1 d1 guint8
-.source 2 s1 guint8
-
-select1wb d1, s1
-
-
-.function orc_unpack_uyvy_u
-.dest 1 d1 guint8
-.source 4 s1 guint8
-.temp 2 t1
-
-select0lw t1, s1
-select0wb d1, t1
-
-
-.function orc_unpack_uyvy_v
-.dest 1 d1 guint8
-.source 4 s1 guint8
-.temp 2 t1
-
-select1lw t1, s1
-select0wb d1, t1
-
-
-.function orc_pack_uyvy
-.dest 4 d1 guint8
-.source 2 s1 guint8 guint8
-.source 1 s2 guint8
-.source 1 s3 guint8
-.temp 1 t1
-.temp 1 t2
-.temp 2 t3
-.temp 2 t4
-.temp 2 t5
-
-copyw t5, s1
-select0wb t1, t5
-select1wb t2, t5
-mergebw t3, s2, t1
-mergebw t4, s3, t2
-mergewl d1, t3, t4
-
-
-.function orc_matrix2_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.param 2 p1
-.param 2 p2
-.param 2 p3
-.temp 2 t1
-.temp 2 t2
-
-convubw t1, s1
-mullw t1, t1, p1
-convubw t2, s2
-mullw t2, t2, p2
-addw t1, t1, t2
-addw t1, t1, p3
-shrsw t1, t1, 6
-convsuswb d1, t1
-
-
-.function orc_matrix2_11_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.param 2 p1
-.param 2 p2
-.temp 2 t1
-.temp 2 t2
-.temp 2 t3
-.temp 2 t4
-
-convubw t1, s1
-subw t1, t1, 16
-mullw t3, t1, p1
-convubw t2, s2
-subw t2, t2, 128
-mullw t4, t2, p2
-addw t3, t3, t4
-addw t3, t3, 128
-shrsw t3, t3, 8
-addw t3, t3, t1
-addw t3, t3, t2
-convsuswb d1, t3
-
-
-.function orc_matrix2_12_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.param 2 p1
-.param 2 p2
-.temp 2 t1
-.temp 2 t2
-.temp 2 t3
-.temp 2 t4
-
-convubw t1, s1
-subw t1, t1, 16
-mullw t3, t1, p1
-convubw t2, s2
-subw t2, t2, 128
-mullw t4, t2, p2
-addw t3, t3, t4
-addw t3, t3, 128
-shrsw t3, t3, 8
-addw t3, t3, t1
-addw t3, t3, t2
-addw t3, t3, t2
-convsuswb d1, t3
-
-
-.function orc_matrix3_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.source 1 s3 guint8 guint8
-.param 2 p1
-.param 2 p2
-.param 2 p3
-.param 2 p4
-.temp 2 t1
-.temp 2 t2
-
-convubw t1, s1
-mullw t1, t1, p1
-convubw t2, s2
-mullw t2, t2, p2
-addw t1, t1, t2
-convubw t2, s3
-mullw t2, t2, p3
-addw t1, t1, t2
-addw t1, t1, p4
-shrsw t1, t1, 6
-convsuswb d1, t1
-
-
-.function orc_matrix3_100_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.source 1 s3 guint8 guint8
-.param 2 p1
-.param 2 p2
-.param 2 p3
-.temp 2 t1
-.temp 2 t2
-.temp 2 t3
-#.temp 2 t4
-
-convubw t1, s1
-subw t1, t1, 16
-mullw t3, t1, p1
-convubw t2, s2
-subw t2, t2, 128
-mullw t2, t2, p2
-addw t3, t3, t2
-convubw t2, s3
-subw t2, t2, 128
-mullw t2, t2, p3
-addw t3, t3, t2
-addw t3, t3, 128
-shrsw t3, t3, 8
-addw t3, t3, t1
-convsuswb d1, t3
-
-
-.function orc_matrix3_100_offset_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.source 1 s3 guint8 guint8
-.param 2 p1
-.param 2 p2
-.param 2 p3
-.param 2 p4
-.param 2 p5
-#.param 2 p6
-.temp 2 t1
-.temp 2 t2
-.temp 2 t3
-#.temp 2 t3
-#.temp 2 t4
-
-convubw t3, s1
-mullw t1, t3, p1
-convubw t2, s2
-mullw t2, t2, p2
-addw t1, t1, t2
-convubw t2, s3
-mullw t2, t2, p3
-addw t1, t1, t2
-addw t1, t1, p4
-shrsw t1, t1, p5
-#addw t1, t1, p6
-addw t1, t1, t3
-convsuswb d1, t1
-
-
-
-.function orc_matrix3_000_u8
-.dest 1 d1 guint8 guint8
-.source 1 s1 guint8 guint8
-.source 1 s2 guint8 guint8
-.source 1 s3 guint8 guint8
-.param 2 p1
-.param 2 p2
-.param 2 p3
-.param 2 p4
-.param 2 p5
-#.param 2 p6
-.temp 2 t1
-.temp 2 t2
-#.temp 2 t3
-#.temp 2 t4
-
-convubw t1, s1
-mullw t1, t1, p1
-convubw t2, s2
-mullw t2, t2, p2
-addw t1, t1, t2
-convubw t2, s3
-mullw t2, t2, p3
-addw t1, t1, t2
-addw t1, t1, p4
-shrsw t1, t1, p5
-#addw t1, t1, p6
-convwb d1, t1
-
-
-
-.function orc_pack_123x
-.dest 4 d1 guint32 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-.source 1 s3 guint8
-.param 1 p1
-.temp 2 t1
-.temp 2 t2
-
-mergebw t1, s1, s2
-mergebw t2, s3, p1
-mergewl d1, t1, t2
-
-
-.function orc_pack_x123
-.dest 4 d1 guint32 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-.source 1 s3 guint8
-.param 1 p1
-.temp 2 t1
-.temp 2 t2
-
-mergebw t1, p1, s1
-mergebw t2, s2, s3
-mergewl d1, t1, t2
-
-
-.function cogorc_combine2_u8
-.dest 1 d1 guint8
-.source 1 s1 guint8
-.source 1 s2 guint8
-.param 2 p1
-.param 2 p2
-.temp 2 t1
-.temp 2 t2
-
-convubw t1, s1
-mullw t1, t1, p1
-convubw t2, s2
-mullw t2, t2, p2
-addw t1, t1, t2
-shruw t1, t1, 8
-convsuswb d1, t1
-
-
 .function cogorc_convert_I420_UYVY
 .dest 4 d1 guint8
 .dest 4 d2 guint8
diff --git a/gst/videoconvert/videoconvert.c b/gst/videoconvert/videoconvert.c
index 54dc629..395a4c5 100644
--- a/gst/videoconvert/videoconvert.c
+++ b/gst/videoconvert/videoconvert.c
@@ -23,78 +23,53 @@
 #endif
 
 #include "videoconvert.h"
+
 #include <glib.h>
 #include <string.h>
+#include <math.h>
+
 #include "gstvideoconvertorc.h"
 
 
 static void videoconvert_convert_generic (VideoConvert * convert,
     GstVideoFrame * dest, const GstVideoFrame * src);
-static void videoconvert_convert_lookup_fastpath (VideoConvert * convert);
-static void videoconvert_convert_lookup_getput (VideoConvert * convert);
+static void videoconvert_convert_matrix (VideoConvert * convert);
+static void videoconvert_convert_matrix16 (VideoConvert * convert);
+static gboolean videoconvert_convert_lookup_fastpath (VideoConvert * convert);
+static gboolean videoconvert_convert_compute_matrix (VideoConvert * convert);
 static void videoconvert_dither_none (VideoConvert * convert, int j);
 static void videoconvert_dither_verterr (VideoConvert * convert, int j);
 static void videoconvert_dither_halftone (VideoConvert * convert, int j);
 
 
 VideoConvert *
-videoconvert_convert_new (GstVideoFormat to_format, ColorSpaceColorSpec to_spec,
-    GstVideoFormat from_format, ColorSpaceColorSpec from_spec,
-    int width, int height)
+videoconvert_convert_new (GstVideoInfo * in_info, GstVideoInfo * out_info)
 {
-  const GstVideoFormatInfo *to_info, *from_info;
   VideoConvert *convert;
-  int i;
+  int i, width;
 
-  from_info = gst_video_format_get_info (from_format);
-  to_info = gst_video_format_get_info (to_format);
+  convert = g_malloc0 (sizeof (VideoConvert));
 
-  g_return_val_if_fail (!GST_VIDEO_FORMAT_INFO_IS_RGB (to_info)
-      || to_spec == COLOR_SPEC_RGB, NULL);
-  g_return_val_if_fail (!GST_VIDEO_FORMAT_INFO_IS_YUV (to_info)
-      || to_spec == COLOR_SPEC_YUV_BT709
-      || to_spec == COLOR_SPEC_YUV_BT470_6, NULL);
-  g_return_val_if_fail (GST_VIDEO_FORMAT_INFO_IS_RGB (to_info)
-      || GST_VIDEO_FORMAT_INFO_IS_YUV (to_info)
-      || (GST_VIDEO_FORMAT_INFO_IS_GRAY (to_info) &&
-          to_spec == COLOR_SPEC_GRAY), NULL);
-
-  g_return_val_if_fail (!GST_VIDEO_FORMAT_INFO_IS_RGB (from_info)
-      || from_spec == COLOR_SPEC_RGB, NULL);
-  g_return_val_if_fail (!GST_VIDEO_FORMAT_INFO_IS_YUV (from_info)
-      || from_spec == COLOR_SPEC_YUV_BT709
-      || from_spec == COLOR_SPEC_YUV_BT470_6, NULL);
-  g_return_val_if_fail (GST_VIDEO_FORMAT_INFO_IS_RGB (from_info)
-      || GST_VIDEO_FORMAT_INFO_IS_YUV (from_info)
-      || (GST_VIDEO_FORMAT_INFO_IS_GRAY (from_info) &&
-          from_spec == COLOR_SPEC_GRAY), NULL);
-
-  convert = g_malloc (sizeof (VideoConvert));
-  memset (convert, 0, sizeof (VideoConvert));
-
-  convert->to_format = to_format;
-  convert->to_spec = to_spec;
-  convert->from_format = from_format;
-  convert->from_spec = from_spec;
-  convert->height = height;
-  convert->width = width;
-  convert->convert = videoconvert_convert_generic;
+  convert->in_info = *in_info;
+  convert->out_info = *out_info;
   convert->dither16 = videoconvert_dither_none;
 
-  if (to_info->depth[0] > 8 || from_info->depth[0] > 8) {
-    convert->use_16bit = TRUE;
-  } else {
-    convert->use_16bit = FALSE;
+  if (!videoconvert_convert_lookup_fastpath (convert)) {
+    convert->convert = videoconvert_convert_generic;
+    if (!videoconvert_convert_compute_matrix (convert))
+      goto no_convert;
   }
 
-  videoconvert_convert_lookup_fastpath (convert);
-  videoconvert_convert_lookup_getput (convert);
+  convert->width = GST_VIDEO_INFO_WIDTH (in_info);
+  convert->height = GST_VIDEO_INFO_HEIGHT (in_info);
+
+  width = convert->width;
 
   convert->tmpline = g_malloc (sizeof (guint8) * (width + 8) * 4);
   convert->tmpline16 = g_malloc (sizeof (guint16) * (width + 8) * 4);
-  convert->errline = g_malloc (sizeof (guint16) * width * 4);
+  convert->errline = g_malloc0 (sizeof (guint16) * width * 4);
 
-  if (to_format == GST_VIDEO_FORMAT_RGB8_PALETTED) {
+  if (GST_VIDEO_INFO_FORMAT (out_info) == GST_VIDEO_FORMAT_RGB8P) {
     /* build poor man's palette, taken from ffmpegcolorspace */
     static const guint8 pal_value[6] = { 0x00, 0x33, 0x66, 0x99, 0xcc, 0xff };
     guint32 *palette;
@@ -115,8 +90,14 @@
     while (i < 256)
       palette[i++] = 0xff000000;
   }
-
   return convert;
+
+  /* ERRORS */
+no_convert:
+  {
+    videoconvert_convert_free (convert);
+    return NULL;
+  }
 }
 
 void
@@ -131,13 +112,6 @@
 }
 
 void
-videoconvert_convert_set_interlaced (VideoConvert * convert,
-    gboolean interlaced)
-{
-  convert->interlaced = interlaced;
-}
-
-void
 videoconvert_convert_set_dither (VideoConvert * convert, int type)
 {
   switch (type) {
@@ -155,1239 +129,14 @@
 }
 
 void
-videoconvert_convert_set_palette (VideoConvert * convert,
-    const guint32 * palette)
-{
-  if (convert->palette == NULL) {
-    convert->palette = g_malloc (sizeof (guint32) * 256);
-  }
-  memcpy (convert->palette, palette, sizeof (guint32) * 256);
-}
-
-const guint32 *
-videoconvert_convert_get_palette (VideoConvert * convert)
-{
-  return convert->palette;
-}
-
-void
 videoconvert_convert_convert (VideoConvert * convert,
     GstVideoFrame * dest, const GstVideoFrame * src)
 {
   convert->convert (convert, dest, src);
 }
 
-/* Line conversion to AYUV */
-
-#define FRAME_GET_STRIDE(dir, comp) \
-  ((dir)->info.stride[comp])
-#define FRAME_GET_LINE(dir, comp, line) \
-  (((guint8*)(dir)->data[comp]) + FRAME_GET_STRIDE (dir, comp) * (line))
-
-static void
-getline_I420 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_I420 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j >> 1),
-      FRAME_GET_LINE (src, 2, j >> 1), convert->width);
-}
-
-static void
-putline_I420 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_I420 (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 1, j >> 1),
-      FRAME_GET_LINE (dest, 2, j >> 1), src, convert->width / 2);
-}
-
-static void
-getline_YV12 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_I420 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j >> 1),
-      FRAME_GET_LINE (src, 2, j >> 1), convert->width);
-}
-
-static void
-putline_YV12 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_I420 (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 1, j >> 1),
-      FRAME_GET_LINE (dest, 2, j >> 1), src, convert->width / 2);
-}
-
-static void
-getline_YUY2 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_YUY2 (dest, FRAME_GET_LINE (src, 0, j), convert->width / 2);
-}
-
-static void
-putline_YUY2 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_YUY2 (FRAME_GET_LINE (dest, 0, j), src, convert->width / 2);
-}
-
-static void
-getline_UYVY (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_UYVY (dest, FRAME_GET_LINE (src, 0, j), convert->width / 2);
-}
-
-static void
-putline_UYVY (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_UYVY (FRAME_GET_LINE (dest, 0, j), src, convert->width / 2);
-}
-
-static void
-getline_YVYU (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_YVYU (dest, FRAME_GET_LINE (src, 0, j), convert->width / 2);
-}
-
-static void
-putline_YVYU (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_YVYU (FRAME_GET_LINE (dest, 0, j), src, convert->width / 2);
-}
-
-static void
-getline_v308 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = srcline[i * 3 + 0];
-    dest[i * 4 + 2] = srcline[i * 3 + 1];
-    dest[i * 4 + 3] = srcline[i * 3 + 2];
-  }
-}
-
-static void
-putline_v308 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i * 3 + 0] = src[i * 4 + 1];
-    destline[i * 3 + 1] = src[i * 4 + 2];
-    destline[i * 3 + 2] = src[i * 4 + 3];
-  }
-}
-
-static void
-getline_AYUV (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  memcpy (dest, FRAME_GET_LINE (src, 0, j), convert->width * 4);
-}
-
-static void
-putline_AYUV (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  memcpy (FRAME_GET_LINE (dest, 0, j), src, convert->width * 4);
-}
-
-#if 0
-static void
-getline_v410 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = GST_READ_UINT16_LE (srcline + i * 8 + 0);
-    dest[i * 4 + 1] = GST_READ_UINT16_LE (srcline + i * 8 + 2);
-    dest[i * 4 + 2] = GST_READ_UINT16_LE (srcline + i * 8 + 4);
-    dest[i * 4 + 3] = GST_READ_UINT16_LE (srcline + i * 8 + 6);
-  }
-}
-#endif
-
-static void
-getline_v210 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-
-  for (i = 0; i < convert->width; i += 6) {
-    guint32 a0, a1, a2, a3;
-    guint16 y0, y1, y2, y3, y4, y5;
-    guint16 u0, u2, u4;
-    guint16 v0, v2, v4;
-
-    a0 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 0);
-    a1 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 4);
-    a2 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 8);
-    a3 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 12);
-
-    u0 = ((a0 >> 0) & 0x3ff) >> 2;
-    y0 = ((a0 >> 10) & 0x3ff) >> 2;
-    v0 = ((a0 >> 20) & 0x3ff) >> 2;
-    y1 = ((a1 >> 0) & 0x3ff) >> 2;
-
-    u2 = ((a1 >> 10) & 0x3ff) >> 2;
-    y2 = ((a1 >> 20) & 0x3ff) >> 2;
-    v2 = ((a2 >> 0) & 0x3ff) >> 2;
-    y3 = ((a2 >> 10) & 0x3ff) >> 2;
-
-    u4 = ((a2 >> 20) & 0x3ff) >> 2;
-    y4 = ((a3 >> 0) & 0x3ff) >> 2;
-    v4 = ((a3 >> 10) & 0x3ff) >> 2;
-    y5 = ((a3 >> 20) & 0x3ff) >> 2;
-
-    dest[4 * (i + 0) + 0] = 0xff;
-    dest[4 * (i + 0) + 1] = y0;
-    dest[4 * (i + 0) + 2] = u0;
-    dest[4 * (i + 0) + 3] = v0;
-
-    dest[4 * (i + 1) + 0] = 0xff;
-    dest[4 * (i + 1) + 1] = y1;
-    dest[4 * (i + 1) + 2] = u0;
-    dest[4 * (i + 1) + 3] = v0;
-
-    dest[4 * (i + 2) + 0] = 0xff;
-    dest[4 * (i + 2) + 1] = y2;
-    dest[4 * (i + 2) + 2] = u2;
-    dest[4 * (i + 2) + 3] = v2;
-
-    dest[4 * (i + 3) + 0] = 0xff;
-    dest[4 * (i + 3) + 1] = y3;
-    dest[4 * (i + 3) + 2] = u2;
-    dest[4 * (i + 3) + 3] = v2;
-
-    dest[4 * (i + 4) + 0] = 0xff;
-    dest[4 * (i + 4) + 1] = y4;
-    dest[4 * (i + 4) + 2] = u4;
-    dest[4 * (i + 4) + 3] = v4;
-
-    dest[4 * (i + 5) + 0] = 0xff;
-    dest[4 * (i + 5) + 1] = y5;
-    dest[4 * (i + 5) + 2] = u4;
-    dest[4 * (i + 5) + 3] = v4;
-
-  }
-
-}
-
-static void
-putline_v210 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-
-  for (i = 0; i < convert->width; i += 6) {
-    guint32 a0, a1, a2, a3;
-    guint16 y0, y1, y2, y3, y4, y5;
-    guint16 u0, u1, u2;
-    guint16 v0, v1, v2;
-
-    y0 = src[4 * (i + 0) + 1] << 2;
-    y1 = src[4 * (i + 1) + 1] << 2;
-    y2 = src[4 * (i + 2) + 1] << 2;
-    y3 = src[4 * (i + 3) + 1] << 2;
-    y4 = src[4 * (i + 4) + 1] << 2;
-    y5 = src[4 * (i + 5) + 1] << 2;
-
-    u0 = (src[4 * (i + 0) + 2] + src[4 * (i + 1) + 2]) << 1;
-    u1 = (src[4 * (i + 2) + 2] + src[4 * (i + 3) + 2]) << 1;
-    u2 = (src[4 * (i + 4) + 2] + src[4 * (i + 5) + 2]) << 1;
-
-    v0 = (src[4 * (i + 0) + 3] + src[4 * (i + 1) + 3]) << 1;
-    v1 = (src[4 * (i + 2) + 3] + src[4 * (i + 3) + 3]) << 1;
-    v2 = (src[4 * (i + 4) + 3] + src[4 * (i + 5) + 3]) << 1;
-
-    a0 = u0 | (y0 << 10) | (v0 << 20);
-    a1 = y1 | (u1 << 10) | (y2 << 20);
-    a2 = v1 | (y3 << 10) | (u2 << 20);
-    a3 = y4 | (v2 << 10) | (y5 << 20);
-
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 0, a0);
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 4, a1);
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 8, a2);
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 12, a3);
-  }
-}
-
-static void
-getline16_v210 (VideoConvert * convert, guint16 * dest,
-    const GstVideoFrame * src, int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-
-  for (i = 0; i < convert->width; i += 6) {
-    guint32 a0, a1, a2, a3;
-    guint16 y0, y1, y2, y3, y4, y5;
-    guint16 u0, u2, u4;
-    guint16 v0, v2, v4;
-
-    a0 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 0);
-    a1 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 4);
-    a2 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 8);
-    a3 = GST_READ_UINT32_LE (srcline + (i / 6) * 16 + 12);
-
-    u0 = ((a0 >> 0) & 0x3ff) << 6;
-    y0 = ((a0 >> 10) & 0x3ff) << 6;
-    v0 = ((a0 >> 20) & 0x3ff) << 6;
-    y1 = ((a1 >> 0) & 0x3ff) << 6;
-
-    u2 = ((a1 >> 10) & 0x3ff) << 6;
-    y2 = ((a1 >> 20) & 0x3ff) << 6;
-    v2 = ((a2 >> 0) & 0x3ff) << 6;
-    y3 = ((a2 >> 10) & 0x3ff) << 6;
-
-    u4 = ((a2 >> 20) & 0x3ff) << 6;
-    y4 = ((a3 >> 0) & 0x3ff) << 6;
-    v4 = ((a3 >> 10) & 0x3ff) << 6;
-    y5 = ((a3 >> 20) & 0x3ff) << 6;
-
-    dest[4 * (i + 0) + 0] = 0xffff;
-    dest[4 * (i + 0) + 1] = y0;
-    dest[4 * (i + 0) + 2] = u0;
-    dest[4 * (i + 0) + 3] = v0;
-
-    dest[4 * (i + 1) + 0] = 0xffff;
-    dest[4 * (i + 1) + 1] = y1;
-    dest[4 * (i + 1) + 2] = u0;
-    dest[4 * (i + 1) + 3] = v0;
-
-    dest[4 * (i + 2) + 0] = 0xffff;
-    dest[4 * (i + 2) + 1] = y2;
-    dest[4 * (i + 2) + 2] = u2;
-    dest[4 * (i + 2) + 3] = v2;
-
-    dest[4 * (i + 3) + 0] = 0xffff;
-    dest[4 * (i + 3) + 1] = y3;
-    dest[4 * (i + 3) + 2] = u2;
-    dest[4 * (i + 3) + 3] = v2;
-
-    dest[4 * (i + 4) + 0] = 0xffff;
-    dest[4 * (i + 4) + 1] = y4;
-    dest[4 * (i + 4) + 2] = u4;
-    dest[4 * (i + 4) + 3] = v4;
-
-    dest[4 * (i + 5) + 0] = 0xffff;
-    dest[4 * (i + 5) + 1] = y5;
-    dest[4 * (i + 5) + 2] = u4;
-    dest[4 * (i + 5) + 3] = v4;
-
-  }
-}
-
-static void
-putline16_v210 (VideoConvert * convert, GstVideoFrame * dest,
-    const guint16 * src, int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-
-  for (i = 0; i < convert->width; i += 6) {
-    guint32 a0, a1, a2, a3;
-    guint16 y0, y1, y2, y3, y4, y5;
-    guint16 u0, u1, u2;
-    guint16 v0, v1, v2;
-
-    y0 = src[4 * (i + 0) + 1] >> 6;
-    y1 = src[4 * (i + 1) + 1] >> 6;
-    y2 = src[4 * (i + 2) + 1] >> 6;
-    y3 = src[4 * (i + 3) + 1] >> 6;
-    y4 = src[4 * (i + 4) + 1] >> 6;
-    y5 = src[4 * (i + 5) + 1] >> 6;
-
-    u0 = (src[4 * (i + 0) + 2] + src[4 * (i + 1) + 2] + 1) >> 7;
-    u1 = (src[4 * (i + 2) + 2] + src[4 * (i + 3) + 2] + 1) >> 7;
-    u2 = (src[4 * (i + 4) + 2] + src[4 * (i + 5) + 2] + 1) >> 7;
-
-    v0 = (src[4 * (i + 0) + 3] + src[4 * (i + 1) + 3] + 1) >> 7;
-    v1 = (src[4 * (i + 2) + 3] + src[4 * (i + 3) + 3] + 1) >> 7;
-    v2 = (src[4 * (i + 4) + 3] + src[4 * (i + 5) + 3] + 1) >> 7;
-
-    a0 = u0 | (y0 << 10) | (v0 << 20);
-    a1 = y1 | (u1 << 10) | (y2 << 20);
-    a2 = v1 | (y3 << 10) | (u2 << 20);
-    a3 = y4 | (v2 << 10) | (y5 << 20);
-
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 0, a0);
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 4, a1);
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 8, a2);
-    GST_WRITE_UINT32_LE (destline + (i / 6) * 16 + 12, a3);
-  }
-}
-
-static void
-getline_v216 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = GST_READ_UINT16_LE (srcline + i * 4 + 2) >> 8;
-    dest[i * 4 + 2] = GST_READ_UINT16_LE (srcline + (i >> 1) * 8 + 0) >> 8;
-    dest[i * 4 + 3] = GST_READ_UINT16_LE (srcline + (i >> 1) * 8 + 4) >> 8;
-  }
-}
-
-static void
-putline_v216 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width / 2; i++) {
-    GST_WRITE_UINT16_LE (destline + i * 8 + 0, src[(i * 2 + 0) * 4 + 2] << 8);
-    GST_WRITE_UINT16_LE (destline + i * 8 + 2, src[(i * 2 + 0) * 4 + 1] << 8);
-    GST_WRITE_UINT16_LE (destline + i * 8 + 4, src[(i * 2 + 1) * 4 + 3] << 8);
-    GST_WRITE_UINT16_LE (destline + i * 8 + 8, src[(i * 2 + 0) * 4 + 1] << 8);
-  }
-}
-
-static void
-getline16_v216 (VideoConvert * convert, guint16 * dest,
-    const GstVideoFrame * src, int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xffff;
-    dest[i * 4 + 1] = GST_READ_UINT16_LE (srcline + i * 4 + 2);
-    dest[i * 4 + 2] = GST_READ_UINT16_LE (srcline + (i >> 1) * 8 + 0);
-    dest[i * 4 + 3] = GST_READ_UINT16_LE (srcline + (i >> 1) * 8 + 4);
-  }
-}
-
-static void
-putline16_v216 (VideoConvert * convert, GstVideoFrame * dest,
-    const guint16 * src, int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width / 2; i++) {
-    GST_WRITE_UINT16_LE (destline + i * 8 + 0, src[(i * 2 + 0) * 4 + 2]);
-    GST_WRITE_UINT16_LE (destline + i * 8 + 2, src[(i * 2 + 0) * 4 + 1]);
-    GST_WRITE_UINT16_LE (destline + i * 8 + 4, src[(i * 2 + 1) * 4 + 3]);
-    GST_WRITE_UINT16_LE (destline + i * 8 + 8, src[(i * 2 + 0) * 4 + 1]);
-  }
-}
-
-static void
-getline_Y41B (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_YUV9 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j), FRAME_GET_LINE (src, 2, j),
-      convert->width / 2);
-}
-
-static void
-putline_Y41B (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destlineY = FRAME_GET_LINE (dest, 0, j);
-  guint8 *destlineU = FRAME_GET_LINE (dest, 1, j);
-  guint8 *destlineV = FRAME_GET_LINE (dest, 2, j);
-
-  for (i = 0; i < convert->width - 3; i += 4) {
-    destlineY[i] = src[i * 4 + 1];
-    destlineY[i + 1] = src[i * 4 + 5];
-    destlineY[i + 2] = src[i * 4 + 9];
-    destlineY[i + 3] = src[i * 4 + 13];
-
-    destlineU[i >> 2] =
-        (src[i * 4 + 2] + src[i * 4 + 6] + src[i * 4 + 10] + src[i * 4 + 14] +
-        2) >> 2;
-    destlineV[i >> 2] =
-        (src[i * 4 + 3] + src[i * 4 + 7] + src[i * 4 + 11] + src[i * 4 + 15] +
-        2) >> 2;
-  }
-
-  if (i == convert->width - 3) {
-    destlineY[i] = src[i * 4 + 1];
-    destlineY[i + 1] = src[i * 4 + 5];
-    destlineY[i + 2] = src[i * 4 + 9];
-
-    destlineU[i >> 2] =
-        (src[i * 4 + 2] + src[i * 4 + 6] + src[i * 4 + 10] + 1) / 3;
-    destlineV[i >> 2] =
-        (src[i * 4 + 3] + src[i * 4 + 7] + src[i * 4 + 11] + 1) / 3;
-  } else if (i == convert->width - 2) {
-    destlineY[i] = src[i * 4 + 1];
-    destlineY[i + 1] = src[i * 4 + 5];
-
-    destlineU[i >> 2] = (src[i * 4 + 2] + src[i * 4 + 6] + 1) >> 1;
-    destlineV[i >> 2] = (src[i * 4 + 3] + src[i * 4 + 7] + 1) >> 1;
-  } else if (i == convert->width - 1) {
-    destlineY[i + 1] = src[i * 4 + 5];
-
-    destlineU[i >> 2] = src[i * 4 + 2];
-    destlineV[i >> 2] = src[i * 4 + 3];
-  }
-}
-
-static void
-getline_Y42B (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_Y42B (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j),
-      FRAME_GET_LINE (src, 2, j), convert->width / 2);
-}
-
-static void
-putline_Y42B (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_Y42B (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 1, j),
-      FRAME_GET_LINE (dest, 2, j), src, convert->width / 2);
-}
-
-static void
-getline_Y444 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_Y444 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j), FRAME_GET_LINE (src, 2, j), convert->width);
-}
-
-static void
-putline_Y444 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_Y444 (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 1, j),
-      FRAME_GET_LINE (dest, 2, j), src, convert->width);
-}
-
-static void
-getline_Y800 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_Y800 (dest, FRAME_GET_LINE (src, 0, j), convert->width);
-}
-
-static void
-putline_Y800 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_Y800 (FRAME_GET_LINE (dest, 0, j), src, convert->width);
-}
-
-static void
-getline_Y16 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_Y16 (dest, FRAME_GET_LINE (src, 0, j), convert->width);
-}
-
-static void
-putline_Y16 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_Y16 (FRAME_GET_LINE (dest, 0, j), src, convert->width);
-}
-
-static void
-getline_RGB16 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint16 *srcline = (const guint16 *) FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = ((srcline[i] >> 11) & 0x1f) << 3;
-    dest[i * 4 + 2] = ((srcline[i] >> 5) & 0x3f) << 2;
-    dest[i * 4 + 3] = ((srcline[i]) & 0x1f) << 3;
-  }
-}
-
-static void
-putline_RGB16 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint16 *destline = (guint16 *) FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i] =
-        ((src[i * 4 + 1] >> 3) << 11) | ((src[i * 4 +
-                2] >> 2) << 5) | (src[i * 4 + 3] >> 3);
-  }
-}
-
-static void
-getline_BGR16 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint16 *srcline = (const guint16 *) FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 3] = ((srcline[i] >> 11) & 0x1f) << 3;
-    dest[i * 4 + 2] = ((srcline[i] >> 5) & 0x3f) << 2;
-    dest[i * 4 + 1] = ((srcline[i]) & 0x1f) << 3;
-  }
-}
-
-static void
-putline_BGR16 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint16 *destline = (guint16 *) FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i] =
-        ((src[i * 4 + 3] >> 3) << 11) | ((src[i * 4 +
-                2] >> 2) << 5) | (src[i * 4 + 1] >> 3);
-  }
-}
-
-static void
-getline_RGB15 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint16 *srcline = (const guint16 *) FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = ((srcline[i] >> 10) & 0x1f) << 3;
-    dest[i * 4 + 2] = ((srcline[i] >> 5) & 0x1f) << 3;
-    dest[i * 4 + 3] = ((srcline[i]) & 0x1f) << 3;
-  }
-}
-
-static void
-putline_RGB15 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint16 *destline = (guint16 *) FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i] =
-        ((src[i * 4 + 1] >> 3) << 10) | ((src[i * 4 +
-                2] >> 3) << 5) | (src[i * 4 + 3] >> 3);
-  }
-}
-
-static void
-getline_BGR15 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint16 *srcline = (const guint16 *) FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 3] = ((srcline[i] >> 10) & 0x1f) << 3;
-    dest[i * 4 + 2] = ((srcline[i] >> 5) & 0x1f) << 3;
-    dest[i * 4 + 1] = ((srcline[i]) & 0x1f) << 3;
-  }
-}
-
-static void
-putline_BGR15 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint16 *destline = (guint16 *) FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i] =
-        ((src[i * 4 + 3] >> 3) << 10) | ((src[i * 4 +
-                2] >> 3) << 5) | (src[i * 4 + 1] >> 3);
-  }
-}
-
-static void
-getline_BGRA (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_BGRA (dest, FRAME_GET_LINE (src, 0, j), convert->width);
-}
-
-static void
-putline_BGRA (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_BGRA (FRAME_GET_LINE (dest, 0, j), src, convert->width);
-}
-
-static void
-getline_ABGR (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_ABGR (dest, FRAME_GET_LINE (src, 0, j), convert->width);
-}
-
-static void
-putline_ABGR (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_ABGR (FRAME_GET_LINE (dest, 0, j), src, convert->width);
-}
-
-static void
-getline_RGBA (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_RGBA (dest, FRAME_GET_LINE (src, 0, j), convert->width);
-}
-
-static void
-putline_RGBA (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_RGBA (FRAME_GET_LINE (dest, 0, j), src, convert->width);
-}
-
-static void
-getline_RGB (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = srcline[i * 3 + 0];
-    dest[i * 4 + 2] = srcline[i * 3 + 1];
-    dest[i * 4 + 3] = srcline[i * 3 + 2];
-  }
-}
-
-static void
-putline_RGB (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i * 3 + 0] = src[i * 4 + 1];
-    destline[i * 3 + 1] = src[i * 4 + 2];
-    destline[i * 3 + 2] = src[i * 4 + 3];
-  }
-}
-
-static void
-getline_BGR (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = srcline[i * 3 + 2];
-    dest[i * 4 + 2] = srcline[i * 3 + 1];
-    dest[i * 4 + 3] = srcline[i * 3 + 0];
-  }
-}
-
-static void
-putline_BGR (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    destline[i * 3 + 0] = src[i * 4 + 3];
-    destline[i * 3 + 1] = src[i * 4 + 2];
-    destline[i * 3 + 2] = src[i * 4 + 1];
-  }
-}
-
-static void
-getline_NV12 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_NV12 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j >> 1), convert->width / 2);
-}
-
-static void
-putline_NV12 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_NV12 (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 1, j >> 1), src, convert->width / 2);
-}
-
-static void
-getline_NV21 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_NV21 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 2, j >> 1), convert->width / 2);
-}
-
-static void
-putline_NV21 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_NV21 (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 2, j >> 1), src, convert->width / 2);
-}
-
-static void
-getline_UYVP (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i += 2) {
-    guint16 y0, y1;
-    guint16 u0;
-    guint16 v0;
-
-    u0 = (srcline[(i / 2) * 5 + 0] << 2) | (srcline[(i / 2) * 5 + 1] >> 6);
-    y0 = ((srcline[(i / 2) * 5 + 1] & 0x3f) << 4) | (srcline[(i / 2) * 5 +
-            2] >> 4);
-    v0 = ((srcline[(i / 2) * 5 + 2] & 0x0f) << 6) | (srcline[(i / 2) * 5 +
-            3] >> 2);
-    y1 = ((srcline[(i / 2) * 5 + 3] & 0x03) << 8) | srcline[(i / 2) * 5 + 4];
-
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = y0 >> 2;
-    dest[i * 4 + 2] = u0 >> 2;
-    dest[i * 4 + 3] = v0 >> 2;
-    dest[i * 4 + 4] = 0xff;
-    dest[i * 4 + 5] = y1 >> 2;
-    dest[i * 4 + 6] = u0 >> 2;
-    dest[i * 4 + 7] = v0 >> 2;
-  }
-}
-
-static void
-putline_UYVP (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i += 2) {
-    guint16 y0, y1;
-    guint16 u0;
-    guint16 v0;
-
-    y0 = src[4 * (i + 0) + 1];
-    y1 = src[4 * (i + 1) + 1];
-    u0 = (src[4 * (i + 0) + 2] + src[4 * (i + 1) + 2] + 1) >> 1;
-    v0 = (src[4 * (i + 0) + 3] + src[4 * (i + 1) + 3] + 1) >> 1;
-
-    destline[(i / 2) * 5 + 0] = u0;
-    destline[(i / 2) * 5 + 1] = y0 >> 2;
-    destline[(i / 2) * 5 + 2] = (y0 << 6) | (v0 >> 4);
-    destline[(i / 2) * 5 + 3] = (v0 << 4) | (y1 >> 2);
-    destline[(i / 2) * 5 + 4] = (y1 << 2);
-  }
-}
-
-static void
-getline_A420 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_A420 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j >> 1),
-      FRAME_GET_LINE (src, 2, j >> 1),
-      FRAME_GET_LINE (src, 3, j), convert->width);
-}
-
-static void
-putline_A420 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  cogorc_putline_A420 (FRAME_GET_LINE (dest, 0, j),
-      FRAME_GET_LINE (dest, 1, j >> 1),
-      FRAME_GET_LINE (dest, 2, j >> 1),
-      FRAME_GET_LINE (dest, 3, j), src, convert->width / 2);
-}
-
-static void
-getline_RGB8P (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    guint32 v = convert->palette[srcline[i]];
-    dest[i * 4 + 0] = (v >> 24) & 0xff;
-    dest[i * 4 + 1] = (v >> 16) & 0xff;
-    dest[i * 4 + 2] = (v >> 8) & 0xff;
-    dest[i * 4 + 3] = (v) & 0xff;
-  }
-}
-
-static void
-putline_RGB8P (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  /* Use our poor man's palette, taken from ffmpegcolorspace too */
-  for (i = 0; i < convert->width; i++) {
-    /* crude approximation for alpha ! */
-    if (src[i * 4 + 0] < 0x80)
-      destline[i] = 6 * 6 * 6;
-    else
-      destline[i] =
-          ((((src[i * 4 + 1]) / 47) % 6) * 6 * 6 + (((src[i * 4 +
-                          2]) / 47) % 6) * 6 + (((src[i * 4 + 3]) / 47) % 6));
-  }
-}
-
-
-static void
-getline_YUV9 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  cogorc_getline_YUV9 (dest,
-      FRAME_GET_LINE (src, 0, j),
-      FRAME_GET_LINE (src, 1, j >> 2),
-      FRAME_GET_LINE (src, 2, j >> 2), convert->width / 2);
-}
-
-static void
-putline_YUV9 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destY = FRAME_GET_LINE (dest, 0, j);
-  guint8 *destU = FRAME_GET_LINE (dest, 1, j >> 2);
-  guint8 *destV = FRAME_GET_LINE (dest, 2, j >> 2);
-
-  for (i = 0; i < convert->width - 3; i += 4) {
-    destY[i] = src[i * 4 + 1];
-    destY[i + 1] = src[i * 4 + 5];
-    destY[i + 2] = src[i * 4 + 9];
-    destY[i + 3] = src[i * 4 + 13];
-    if (j % 4 == 0) {
-      destU[i >> 2] =
-          (src[i * 4 + 2] + src[i * 4 + 6] + src[i * 4 + 10] + src[i * 4 +
-              14]) >> 2;
-      destV[i >> 2] =
-          (src[i * 4 + 3] + src[i * 4 + 7] + src[i * 4 + 11] + src[i * 4 +
-              15]) >> 2;
-    }
-  }
-
-  if (i == convert->width - 3) {
-    destY[i] = src[i * 4 + 1];
-    destY[i + 1] = src[i * 4 + 5];
-    destY[i + 2] = src[i * 4 + 9];
-    if (j % 4 == 0) {
-      destU[i >> 2] = (src[i * 4 + 2] + src[i * 4 + 6] + src[i * 4 + 10]) / 3;
-      destV[i >> 2] = (src[i * 4 + 3] + src[i * 4 + 7] + src[i * 4 + 11]) / 3;
-    }
-  } else if (i == convert->width - 2) {
-    destY[i] = src[i * 4 + 1];
-    destY[i + 1] = src[i * 4 + 5];
-    if (j % 4 == 0) {
-      destU[i >> 2] = (src[i * 4 + 2] + src[i * 4 + 6]) >> 1;
-      destV[i >> 2] = (src[i * 4 + 3] + src[i * 4 + 7]) >> 1;
-    }
-  } else if (i == convert->width - 1) {
-    destY[i] = src[i * 4 + 1];
-    destU[i >> 2] = src[i * 4 + 2];
-    destV[i >> 2] = src[i * 4 + 3];
-  }
-}
-
-static void
-getline_IYU1 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-
-  for (i = 0; i < convert->width - 3; i += 4) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 4] = 0xff;
-    dest[i * 4 + 8] = 0xff;
-    dest[i * 4 + 12] = 0xff;
-    dest[i * 4 + 1] = srcline[(i >> 2) * 6 + 1];
-    dest[i * 4 + 5] = srcline[(i >> 2) * 6 + 2];
-    dest[i * 4 + 9] = srcline[(i >> 2) * 6 + 4];
-    dest[i * 4 + 13] = srcline[(i >> 2) * 6 + 5];
-    dest[i * 4 + 2] = dest[i * 4 + 6] = dest[i * 4 + 10] = dest[i * 4 + 14] =
-        srcline[(i >> 2) * 6 + 0];
-    dest[i * 4 + 3] = dest[i * 4 + 7] = dest[i * 4 + 11] = dest[i * 4 + 15] =
-        srcline[(i >> 2) * 6 + 3];
-  }
-
-  if (i == convert->width - 3) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 4] = 0xff;
-    dest[i * 4 + 8] = 0xff;
-    dest[i * 4 + 1] = srcline[(i >> 2) * 6 + 1];
-    dest[i * 4 + 5] = srcline[(i >> 2) * 6 + 2];
-    dest[i * 4 + 9] = srcline[(i >> 2) * 6 + 4];
-    dest[i * 4 + 2] = dest[i * 4 + 6] = dest[i * 4 + 10] =
-        srcline[(i >> 2) * 6 + 0];
-    dest[i * 4 + 3] = dest[i * 4 + 7] = dest[i * 4 + 11] =
-        srcline[(i >> 2) * 6 + 3];
-  } else if (i == convert->width - 2) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 4] = 0xff;
-    dest[i * 4 + 1] = srcline[(i >> 2) * 6 + 1];
-    dest[i * 4 + 5] = srcline[(i >> 2) * 6 + 2];
-    dest[i * 4 + 2] = dest[i * 4 + 6] = srcline[(i >> 2) * 6 + 0];
-    dest[i * 4 + 3] = dest[i * 4 + 7] = srcline[(i >> 2) * 6 + 3];
-  } else if (i == convert->width - 1) {
-    dest[i * 4 + 0] = 0xff;
-    dest[i * 4 + 1] = srcline[(i >> 2) * 6 + 1];
-    dest[i * 4 + 2] = srcline[(i >> 2) * 6 + 0];
-    dest[i * 4 + 3] = srcline[(i >> 2) * 6 + 3];
-  }
-}
-
-static void
-putline_IYU1 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-
-  for (i = 0; i < convert->width - 3; i += 4) {
-    destline[(i >> 2) * 6 + 1] = src[i * 4 + 1];
-    destline[(i >> 2) * 6 + 2] = src[i * 4 + 5];
-    destline[(i >> 2) * 6 + 4] = src[i * 4 + 9];
-    destline[(i >> 2) * 6 + 5] = src[i * 4 + 13];
-    destline[(i >> 2) * 6 + 0] =
-        (src[i * 4 + 2] + src[i * 4 + 6] + src[i * 4 + 10] + src[i * 4 +
-            14]) >> 2;
-    destline[(i >> 2) * 6 + 3] =
-        (src[i * 4 + 3] + src[i * 4 + 7] + src[i * 4 + 11] + src[i * 4 +
-            15]) >> 2;
-  }
-
-  if (i == convert->width - 3) {
-    destline[(i >> 2) * 6 + 1] = src[i * 4 + 1];
-    destline[(i >> 2) * 6 + 2] = src[i * 4 + 5];
-    destline[(i >> 2) * 6 + 4] = src[i * 4 + 9];
-    destline[(i >> 2) * 6 + 0] =
-        (src[i * 4 + 2] + src[i * 4 + 6] + src[i * 4 + 10]) / 3;
-    destline[(i >> 2) * 6 + 3] =
-        (src[i * 4 + 3] + src[i * 4 + 7] + src[i * 4 + 11]) / 3;
-  } else if (i == convert->width - 2) {
-    destline[(i >> 2) * 6 + 1] = src[i * 4 + 1];
-    destline[(i >> 2) * 6 + 2] = src[i * 4 + 5];
-    destline[(i >> 2) * 6 + 0] = (src[i * 4 + 2] + src[i * 4 + 6]) >> 1;
-    destline[(i >> 2) * 6 + 3] = (src[i * 4 + 3] + src[i * 4 + 7]) >> 1;
-  } else if (i == convert->width - 1) {
-    destline[(i >> 2) * 6 + 1] = src[i * 4 + 1];
-    destline[(i >> 2) * 6 + 0] = src[i * 4 + 2];
-    destline[(i >> 2) * 6 + 3] = src[i * 4 + 3];
-  }
-}
-
-static void
-getline_AY64 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint16 *srcline = (const guint16 *) FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width * 4; i++) {
-    dest[i] = srcline[i] >> 8;
-  }
-}
-
-static void
-putline_AY64 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint16 *destline = (guint16 *) FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width * 4; i++) {
-    destline[i] = src[i] << 8;
-  }
-}
-
-static void
-getline16_AY64 (VideoConvert * convert, guint16 * dest,
-    const GstVideoFrame * src, int j)
-{
-  memcpy (dest, FRAME_GET_LINE (src, 0, j), convert->width * 8);
-}
-
-static void
-putline16_AY64 (VideoConvert * convert, GstVideoFrame * dest,
-    const guint16 * src, int j)
-{
-  memcpy (FRAME_GET_LINE (dest, 0, j), src, convert->width * 8);
-}
-
-static void
-getline_r210 (VideoConvert * convert, guint8 * dest, const GstVideoFrame * src,
-    int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    guint8 x;
-    dest[i * 4 + 0] = 0xff;
-    x = GST_READ_UINT32_BE (srcline + i * 4);
-    dest[i * 4 + 1] = (x >> 22) & 0xff;
-    dest[i * 4 + 2] = (x >> 12) & 0xff;
-    dest[i * 4 + 3] = (x >> 2) & 0xff;
-  }
-}
-
-static void
-putline_r210 (VideoConvert * convert, GstVideoFrame * dest, const guint8 * src,
-    int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width / 2; i++) {
-    guint32 x = 0;
-    x |= src[i * 4 + 1] << 22;
-    x |= (src[i * 4 + 1] & 0xc0) << 14;
-    x |= src[i * 4 + 2] << 12;
-    x |= (src[i * 4 + 2] & 0xc0) << 10;
-    x |= src[i * 4 + 3] << 2;
-    x |= (src[i * 4 + 3] & 0xc0) >> 6;
-    GST_WRITE_UINT32_BE (destline + i * 4, x);
-  }
-}
-
-static void
-getline16_r210 (VideoConvert * convert, guint16 * dest,
-    const GstVideoFrame * src, int j)
-{
-  int i;
-  const guint8 *srcline = FRAME_GET_LINE (src, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    guint32 x;
-    dest[i * 4 + 0] = 0xffff;
-    x = GST_READ_UINT32_BE (srcline + i * 4);
-    dest[i * 4 + 1] = ((x >> 14) & 0xffc0) | (x >> 24);
-    dest[i * 4 + 2] = ((x >> 4) & 0xffc0) | ((x >> 14) & 0x3f);
-    dest[i * 4 + 3] = ((x << 6) & 0xffc0) | ((x >> 4) & 0x3f);
-  }
-}
-
-static void
-putline16_r210 (VideoConvert * convert, GstVideoFrame * dest,
-    const guint16 * src, int j)
-{
-  int i;
-  guint8 *destline = FRAME_GET_LINE (dest, 0, j);
-  for (i = 0; i < convert->width; i++) {
-    guint32 x = 0;
-    x |= (src[i * 4 + 1] & 0xffc0) << 14;
-    x |= (src[i * 4 + 2] & 0xffc0) << 4;
-    x |= (src[i * 4 + 3] & 0xffc0) >> 6;
-    GST_WRITE_UINT32_BE (destline + i * 4, x);
-  }
-}
-
-static void
-getline16_convert (VideoConvert * convert, guint16 * dest,
-    const GstVideoFrame * src, int j)
-{
-  int i;
-  convert->getline (convert, convert->tmpline, src, j);
-  for (i = 0; i < convert->width * 4; i++) {
-    dest[i] = convert->tmpline[i] << 8;
-  }
-}
-
-static void
-putline16_convert (VideoConvert * convert, GstVideoFrame * dest,
-    const guint16 * src, int j)
-{
-  int i;
-  for (i = 0; i < convert->width * 4; i++) {
-    convert->tmpline[i] = src[i] >> 8;
-  }
-  convert->putline (convert, dest, convert->tmpline, j);
-}
-
-typedef struct
-{
-  GstVideoFormat format;
-  void (*getline) (VideoConvert * convert, guint8 * dest,
-      const GstVideoFrame * src, int j);
-  void (*putline) (VideoConvert * convert, GstVideoFrame * dest,
-      const guint8 * src, int j);
-  void (*getline16) (VideoConvert * convert, guint16 * dest,
-      const GstVideoFrame * src, int j);
-  void (*putline16) (VideoConvert * convert, GstVideoFrame * dest,
-      const guint16 * src, int j);
-} VideoLine;
-static const VideoLine lines[] = {
-  {GST_VIDEO_FORMAT_I420, getline_I420, putline_I420},
-  {GST_VIDEO_FORMAT_YV12, getline_YV12, putline_YV12},
-  {GST_VIDEO_FORMAT_YUY2, getline_YUY2, putline_YUY2},
-  {GST_VIDEO_FORMAT_UYVY, getline_UYVY, putline_UYVY},
-  {GST_VIDEO_FORMAT_AYUV, getline_AYUV, putline_AYUV},
-  {GST_VIDEO_FORMAT_RGBx, getline_RGBA, putline_RGBA},
-  {GST_VIDEO_FORMAT_BGRx, getline_BGRA, putline_BGRA},
-  {GST_VIDEO_FORMAT_xRGB, getline_AYUV, putline_AYUV},
-  {GST_VIDEO_FORMAT_xBGR, getline_ABGR, putline_ABGR},
-  {GST_VIDEO_FORMAT_RGBA, getline_RGBA, putline_RGBA},
-  {GST_VIDEO_FORMAT_BGRA, getline_BGRA, putline_BGRA},
-  {GST_VIDEO_FORMAT_ARGB, getline_AYUV, putline_AYUV},
-  {GST_VIDEO_FORMAT_ABGR, getline_ABGR, putline_ABGR},
-  {GST_VIDEO_FORMAT_RGB, getline_RGB, putline_RGB},
-  {GST_VIDEO_FORMAT_BGR, getline_BGR, putline_BGR},
-  {GST_VIDEO_FORMAT_Y41B, getline_Y41B, putline_Y41B},
-  {GST_VIDEO_FORMAT_Y42B, getline_Y42B, putline_Y42B},
-  {GST_VIDEO_FORMAT_YVYU, getline_YVYU, putline_YVYU},
-  {GST_VIDEO_FORMAT_Y444, getline_Y444, putline_Y444},
-  {GST_VIDEO_FORMAT_v210, getline_v210, putline_v210,
-      getline16_v210, putline16_v210},
-  {GST_VIDEO_FORMAT_v216, getline_v216, putline_v216,
-      getline16_v216, putline16_v216},
-  {GST_VIDEO_FORMAT_NV12, getline_NV12, putline_NV12},
-  {GST_VIDEO_FORMAT_NV21, getline_NV21, putline_NV21},
-  //{GST_VIDEO_FORMAT_GRAY8, getline_GRAY8, putline_GRAY8},
-  //{GST_VIDEO_FORMAT_GRAY16_BE, getline_GRAY16_BE, putline_GRAY16_BE},
-  //{GST_VIDEO_FORMAT_GRAY16_LE, getline_GRAY16_LE, putline_GRAY16_LE},
-  {GST_VIDEO_FORMAT_v308, getline_v308, putline_v308},
-  {GST_VIDEO_FORMAT_Y800, getline_Y800, putline_Y800},
-  {GST_VIDEO_FORMAT_Y16, getline_Y16, putline_Y16},
-  {GST_VIDEO_FORMAT_RGB16, getline_RGB16, putline_RGB16},
-  {GST_VIDEO_FORMAT_BGR16, getline_BGR16, putline_BGR16},
-  {GST_VIDEO_FORMAT_RGB15, getline_RGB15, putline_RGB15},
-  {GST_VIDEO_FORMAT_BGR15, getline_BGR15, putline_BGR15},
-  {GST_VIDEO_FORMAT_UYVP, getline_UYVP, putline_UYVP},
-  {GST_VIDEO_FORMAT_A420, getline_A420, putline_A420}
-  , {GST_VIDEO_FORMAT_RGB8_PALETTED, getline_RGB8P, putline_RGB8P},
-  {GST_VIDEO_FORMAT_YUV9, getline_YUV9, putline_YUV9},
-  {GST_VIDEO_FORMAT_YVU9, getline_YUV9, putline_YUV9},  /* alias */
-  {GST_VIDEO_FORMAT_IYU1, getline_IYU1, putline_IYU1},
-  {GST_VIDEO_FORMAT_ARGB64, getline_AY64, putline_AY64, getline16_AY64,
-      putline16_AY64},
-  {GST_VIDEO_FORMAT_AYUV64, getline_AY64, putline_AY64, getline16_AY64,
-      putline16_AY64},
-  {GST_VIDEO_FORMAT_r210, getline_r210, putline_r210, getline16_r210,
-      putline16_r210}
-};
-
-static void
-matrix_rgb_to_yuv_bt470_6 (VideoConvert * convert)
+void
+videoconvert_convert_matrix (VideoConvert * convert)
 {
   int i;
   int r, g, b;
@@ -1399,9 +148,12 @@
     g = tmpline[i * 4 + 2];
     b = tmpline[i * 4 + 3];
 
-    y = (66 * r + 129 * g + 25 * b + 4096) >> 8;
-    u = (-38 * r - 74 * g + 112 * b + 32768) >> 8;
-    v = (112 * r - 94 * g - 18 * b + 32768) >> 8;
+    y = (convert->cmatrix[0][0] * r + convert->cmatrix[0][1] * g +
+        convert->cmatrix[0][2] * b + convert->cmatrix[0][3]) >> 8;
+    u = (convert->cmatrix[1][0] * r + convert->cmatrix[1][1] * g +
+        convert->cmatrix[1][2] * b + convert->cmatrix[1][3]) >> 8;
+    v = (convert->cmatrix[2][0] * r + convert->cmatrix[2][1] * g +
+        convert->cmatrix[2][2] * b + convert->cmatrix[2][3]) >> 8;
 
     tmpline[i * 4 + 1] = CLAMP (y, 0, 255);
     tmpline[i * 4 + 2] = CLAMP (u, 0, 255);
@@ -1409,118 +161,29 @@
   }
 }
 
-static void
-matrix_rgb_to_yuv_bt709 (VideoConvert * convert)
+void
+videoconvert_convert_matrix16 (VideoConvert * convert)
 {
   int i;
   int r, g, b;
   int y, u, v;
-  guint8 *tmpline = convert->tmpline;
+  guint16 *tmpline = convert->tmpline16;
 
   for (i = 0; i < convert->width; i++) {
     r = tmpline[i * 4 + 1];
     g = tmpline[i * 4 + 2];
     b = tmpline[i * 4 + 3];
 
-    y = (47 * r + 157 * g + 16 * b + 4096) >> 8;
-    u = (-26 * r - 87 * g + 112 * b + 32768) >> 8;
-    v = (112 * r - 102 * g - 10 * b + 32768) >> 8;
+    y = (convert->cmatrix[0][0] * r + convert->cmatrix[0][1] * g +
+        convert->cmatrix[0][2] * b + convert->cmatrix[0][3]) >> 8;
+    u = (convert->cmatrix[1][0] * r + convert->cmatrix[1][1] * g +
+        convert->cmatrix[1][2] * b + convert->cmatrix[1][3]) >> 8;
+    v = (convert->cmatrix[2][0] * r + convert->cmatrix[2][1] * g +
+        convert->cmatrix[2][2] * b + convert->cmatrix[2][3]) >> 8;
 
-    tmpline[i * 4 + 1] = CLAMP (y, 0, 255);
-    tmpline[i * 4 + 2] = CLAMP (u, 0, 255);
-    tmpline[i * 4 + 3] = CLAMP (v, 0, 255);
-  }
-}
-
-static void
-matrix_yuv_bt470_6_to_rgb (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint8 *tmpline = convert->tmpline;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (298 * y + 409 * v - 57068) >> 8;
-    g = (298 * y - 100 * u - 208 * v + 34707) >> 8;
-    b = (298 * y + 516 * u - 70870) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 255);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 255);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 255);
-  }
-}
-
-static void
-matrix_yuv_bt709_to_rgb (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint8 *tmpline = convert->tmpline;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (298 * y + 459 * v - 63514) >> 8;
-    g = (298 * y - 55 * u - 136 * v + 19681) >> 8;
-    b = (298 * y + 541 * u - 73988) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 255);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 255);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 255);
-  }
-}
-
-static void
-matrix_yuv_bt709_to_yuv_bt470_6 (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint8 *tmpline = convert->tmpline;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (256 * y + 25 * u + 49 * v - 9536) >> 8;
-    g = (253 * u - 28 * v + 3958) >> 8;
-    b = (-19 * u + 252 * v + 2918) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 255);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 255);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 255);
-  }
-}
-
-static void
-matrix_yuv_bt470_6_to_yuv_bt709 (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint8 *tmpline = convert->tmpline;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (256 * y - 30 * u - 53 * v + 10600) >> 8;
-    g = (261 * u + 29 * v - 4367) >> 8;
-    b = (19 * u + 262 * v - 3289) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 255);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 255);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 255);
+    tmpline[i * 4 + 1] = CLAMP (y, 0, 65535);
+    tmpline[i * 4 + 2] = CLAMP (u, 0, 65535);
+    tmpline[i * 4 + 3] = CLAMP (v, 0, 65535);
   }
 }
 
@@ -1531,244 +194,195 @@
 }
 
 static void
-matrix16_rgb_to_yuv_bt470_6 (VideoConvert * convert)
+get_offset_scale (const GstVideoFormatInfo * finfo, GstVideoColorRange range,
+    gint depth, gint offset[4], gint scale[4])
 {
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint16 *tmpline = convert->tmpline16;
+  gint minL, minC, baseL, baseC, maxL, maxC;
 
-  for (i = 0; i < convert->width; i++) {
-    r = tmpline[i * 4 + 1];
-    g = tmpline[i * 4 + 2];
-    b = tmpline[i * 4 + 3];
+  if (depth < 8)
+    depth = 8;
 
-    y = (66 * r + 129 * g + 25 * b + 4096 * 256) >> 8;
-    u = (-38 * r - 74 * g + 112 * b + 32768 * 256) >> 8;
-    v = (112 * r - 94 * g - 18 * b + 32768 * 256) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (y, 0, 65535);
-    tmpline[i * 4 + 2] = CLAMP (u, 0, 65535);
-    tmpline[i * 4 + 3] = CLAMP (v, 0, 65535);
-  }
-}
-
-static void
-matrix16_rgb_to_yuv_bt709 (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint16 *tmpline = convert->tmpline16;
-
-  for (i = 0; i < convert->width; i++) {
-    r = tmpline[i * 4 + 1];
-    g = tmpline[i * 4 + 2];
-    b = tmpline[i * 4 + 3];
-
-    y = (47 * r + 157 * g + 16 * b + 4096 * 256) >> 8;
-    u = (-26 * r - 87 * g + 112 * b + 32768 * 256) >> 8;
-    v = (112 * r - 102 * g - 10 * b + 32768 * 256) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (y, 0, 65535);
-    tmpline[i * 4 + 2] = CLAMP (u, 0, 65535);
-    tmpline[i * 4 + 3] = CLAMP (v, 0, 65535);
-  }
-}
-
-static void
-matrix16_yuv_bt470_6_to_rgb (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint16 *tmpline = convert->tmpline16;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (298 * y + 409 * v - 57068 * 256) >> 8;
-    g = (298 * y - 100 * u - 208 * v + 34707 * 256) >> 8;
-    b = (298 * y + 516 * u - 70870 * 256) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 65535);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 65535);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 65535);
-  }
-}
-
-static void
-matrix16_yuv_bt709_to_rgb (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint16 *tmpline = convert->tmpline16;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (298 * y + 459 * v - 63514 * 256) >> 8;
-    g = (298 * y - 55 * u - 136 * v + 19681 * 256) >> 8;
-    b = (298 * y + 541 * u - 73988 * 256) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 65535);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 65535);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 65535);
-  }
-}
-
-static void
-matrix16_yuv_bt709_to_yuv_bt470_6 (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint16 *tmpline = convert->tmpline16;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (256 * y + 25 * u + 49 * v - 9536 * 256) >> 8;
-    g = (253 * u - 28 * v + 3958 * 256) >> 8;
-    b = (-19 * u + 252 * v + 2918 * 256) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 65535);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 65535);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 65535);
-  }
-}
-
-static void
-matrix16_yuv_bt470_6_to_yuv_bt709 (VideoConvert * convert)
-{
-  int i;
-  int r, g, b;
-  int y, u, v;
-  guint16 *tmpline = convert->tmpline16;
-
-  for (i = 0; i < convert->width; i++) {
-    y = tmpline[i * 4 + 1];
-    u = tmpline[i * 4 + 2];
-    v = tmpline[i * 4 + 3];
-
-    r = (256 * y - 30 * u - 53 * v + 10600 * 256) >> 8;
-    g = (261 * u + 29 * v - 4367 * 256) >> 8;
-    b = (19 * u + 262 * v - 3289 * 256) >> 8;
-
-    tmpline[i * 4 + 1] = CLAMP (r, 0, 65535);
-    tmpline[i * 4 + 2] = CLAMP (g, 0, 65535);
-    tmpline[i * 4 + 3] = CLAMP (b, 0, 65535);
-  }
-}
-
-static void
-matrix16_identity (VideoConvert * convert)
-{
-  /* do nothing */
-}
-
-
-
-static void
-videoconvert_convert_lookup_getput (VideoConvert * convert)
-{
-  int i;
-
-  convert->getline = NULL;
-  convert->getline16 = NULL;
-  for (i = 0; i < sizeof (lines) / sizeof (lines[0]); i++) {
-    if (lines[i].format == convert->from_format) {
-      convert->getline = lines[i].getline;
-      convert->getline16 = lines[i].getline16;
+  switch (range) {
+    default:
+    case GST_VIDEO_COLOR_RANGE_0_255:
+      minL = minC = 0;
+      baseL = 0;
+      baseC = 128 << (depth - 8);
+      maxL = (1 << depth) - 1;
+      maxC = (1 << depth) - 1;
       break;
-    }
-  }
-  convert->putline = NULL;
-  convert->putline16 = NULL;
-  for (i = 0; i < sizeof (lines) / sizeof (lines[0]); i++) {
-    if (lines[i].format == convert->to_format) {
-      convert->putline = lines[i].putline;
-      convert->putline16 = lines[i].putline16;
+    case GST_VIDEO_COLOR_RANGE_16_235:
+      minL = 16 << (depth - 8);
+      minC = 16 << (depth - 8);
+      baseL = minL;
+      baseC = 128 << (depth - 8);
+      maxL = 235 << (depth - 8);
+      maxC = 240 << (depth - 8);
       break;
-    }
-  }
-  GST_DEBUG ("get %p put %p", convert->getline, convert->putline);
-
-  if (convert->getline16 == NULL) {
-    convert->getline16 = getline16_convert;
-  }
-  if (convert->putline16 == NULL) {
-    convert->putline16 = putline16_convert;
   }
 
-  if (convert->from_spec == convert->to_spec) {
-    convert->matrix = matrix_identity;
-    convert->matrix16 = matrix16_identity;
-  } else if (convert->from_spec == COLOR_SPEC_RGB
-      && convert->to_spec == COLOR_SPEC_YUV_BT470_6) {
-    convert->matrix = matrix_rgb_to_yuv_bt470_6;
-    convert->matrix16 = matrix16_rgb_to_yuv_bt470_6;
-  } else if (convert->from_spec == COLOR_SPEC_RGB
-      && convert->to_spec == COLOR_SPEC_YUV_BT709) {
-    convert->matrix = matrix_rgb_to_yuv_bt709;
-    convert->matrix16 = matrix16_rgb_to_yuv_bt709;
-  } else if (convert->from_spec == COLOR_SPEC_YUV_BT470_6
-      && convert->to_spec == COLOR_SPEC_RGB) {
-    convert->matrix = matrix_yuv_bt470_6_to_rgb;
-    convert->matrix16 = matrix16_yuv_bt470_6_to_rgb;
-  } else if (convert->from_spec == COLOR_SPEC_YUV_BT709
-      && convert->to_spec == COLOR_SPEC_RGB) {
-    convert->matrix = matrix_yuv_bt709_to_rgb;
-    convert->matrix16 = matrix16_yuv_bt709_to_rgb;
-  } else if (convert->from_spec == COLOR_SPEC_YUV_BT709
-      && convert->to_spec == COLOR_SPEC_YUV_BT470_6) {
-    convert->matrix = matrix_yuv_bt709_to_yuv_bt470_6;
-    convert->matrix16 = matrix16_yuv_bt709_to_yuv_bt470_6;
-  } else if (convert->from_spec == COLOR_SPEC_YUV_BT470_6
-      && convert->to_spec == COLOR_SPEC_YUV_BT709) {
-    convert->matrix = matrix_yuv_bt470_6_to_yuv_bt709;
-    convert->matrix16 = matrix16_yuv_bt470_6_to_yuv_bt709;
-  }
-}
-
-static void
-videoconvert_convert_generic (VideoConvert * convert, GstVideoFrame * dest,
-    const GstVideoFrame * src)
-{
-  int j;
-
-  if (convert->getline == NULL) {
-    GST_ERROR ("no getline for format %s",
-        gst_video_format_to_string (GST_VIDEO_FRAME_FORMAT (src)));
-    return;
-  }
-
-  if (convert->putline == NULL) {
-    GST_ERROR ("no putline for format %s",
-        gst_video_format_to_string (GST_VIDEO_FRAME_FORMAT (dest)));
-    return;
-  }
-
-  if (convert->use_16bit) {
-    for (j = 0; j < convert->height; j++) {
-      convert->getline16 (convert, convert->tmpline16, src, j);
-      convert->matrix16 (convert);
-      convert->dither16 (convert, j);
-      convert->putline16 (convert, dest, convert->tmpline16, j);
-    }
+  if (GST_VIDEO_FORMAT_INFO_IS_YUV (finfo)) {
+    offset[0] = 0;
+    offset[1] = baseL;
+    offset[2] = offset[3] = baseC;
+    scale[0] = 0;
+    scale[1] = maxL - minL;
+    scale[2] = scale[3] = maxC - minC;
+  } else if (GST_VIDEO_FORMAT_INFO_IS_RGB (finfo)) {
+    offset[0] = 0;
+    offset[1] = offset[2] = offset[3] = baseL;
+    scale[0] = 0;
+    scale[1] = scale[2] = scale[3] = maxL - minL;
+  } else if (GST_VIDEO_FORMAT_INFO_IS_GRAY (finfo)) {
+    offset[0] = offset[2] = offset[3] = 0;
+    offset[1] = baseL;
+    scale[0] = scale[2] = scale[3] = 0;
+    scale[1] = maxL - minL;
   } else {
-    for (j = 0; j < convert->height; j++) {
-      convert->getline (convert, convert->tmpline, src, j);
-      convert->matrix (convert);
-      convert->putline (convert, dest, convert->tmpline, j);
-    }
+    offset[0] = offset[1] = offset[2] = offset[3] = 0;
+    scale[0] = scale[1] = scale[2] = scale[3] = (maxL - minL);
+  }
+}
+
+static gboolean
+get_Kr_Kb (GstVideoColorMatrix matrix, gdouble * Kr, gdouble * Kb)
+{
+  gboolean res = TRUE;
+
+  switch (matrix) {
+      /* RGB */
+    default:
+    case GST_VIDEO_COLOR_MATRIX_RGB:
+      res = FALSE;
+      break;
+      /* YUV */
+    case GST_VIDEO_COLOR_MATRIX_FCC:
+      *Kr = 0.30;
+      *Kb = 0.11;
+      break;
+    case GST_VIDEO_COLOR_MATRIX_BT709:
+      *Kr = 0.2126;
+      *Kb = 0.0722;
+      break;
+    case GST_VIDEO_COLOR_MATRIX_BT601:
+      *Kr = 0.2990;
+      *Kb = 0.1140;
+      break;
+    case GST_VIDEO_COLOR_MATRIX_SMPTE240M:
+      *Kr = 0.212;
+      *Kb = 0.087;
+      break;
+  }
+  return res;
+}
+
+static gboolean
+videoconvert_convert_compute_matrix (VideoConvert * convert)
+{
+  GstVideoInfo *in_info, *out_info;
+  ColorMatrix dst;
+  gint i, j;
+  const GstVideoFormatInfo *sfinfo, *dfinfo;
+  gint depth;
+  gint offset[4], scale[4];
+  gdouble Kr, Kb;
+
+  in_info = &convert->in_info;
+  out_info = &convert->out_info;
+
+  sfinfo = in_info->finfo;
+  dfinfo = out_info->finfo;
+
+  if (sfinfo->unpack_func == NULL)
+    goto no_unpack_func;
+
+  if (dfinfo->pack_func == NULL)
+    goto no_pack_func;
+
+  convert->in_bits =
+      GST_VIDEO_FORMAT_INFO_DEPTH (gst_video_format_get_info
+      (sfinfo->unpack_format), 0);
+  convert->out_bits =
+      GST_VIDEO_FORMAT_INFO_DEPTH (gst_video_format_get_info
+      (dfinfo->unpack_format), 0);
+
+  if (in_info->colorimetry.range == out_info->colorimetry.range &&
+      in_info->colorimetry.matrix == out_info->colorimetry.matrix) {
+    GST_DEBUG ("using identity color transform");
+    convert->matrix = matrix_identity;
+    convert->matrix16 = matrix_identity;
+    return TRUE;
+  }
+
+  if (convert->in_bits == 16 || convert->out_bits == 16)
+    depth = 16;
+  else
+    depth = 8;
+
+  color_matrix_set_identity (&dst);
+
+  /* 1, bring color components to [0..1.0] range */
+  get_offset_scale (sfinfo, in_info->colorimetry.range, depth, offset, scale);
+
+  color_matrix_offset_components (&dst, -offset[1], -offset[2], -offset[3]);
+  color_matrix_scale_components (&dst, 1 / ((float) scale[1]),
+      1 / ((float) scale[2]), 1 / ((float) scale[3]));
+
+  /* 2. bring components to R'G'B' space */
+  if (get_Kr_Kb (in_info->colorimetry.matrix, &Kr, &Kb))
+    color_matrix_YCbCr_to_RGB (&dst, Kr, Kb);
+
+  /* 3. inverse transfer function. R'G'B' to linear RGB */
+
+  /* 4. from RGB to XYZ using the primaries */
+
+  /* 5. from XYZ to RGB using the primaries */
+
+  /* 6. transfer function. linear RGB to R'G'B' */
+
+  /* 7. bring components to YCbCr space */
+  if (get_Kr_Kb (out_info->colorimetry.matrix, &Kr, &Kb))
+    color_matrix_RGB_to_YCbCr (&dst, Kr, Kb);
+
+  /* 8, bring color components to nominal range */
+  get_offset_scale (dfinfo, out_info->colorimetry.range, depth, offset, scale);
+  color_matrix_scale_components (&dst, (float) scale[1], (float) scale[2],
+      (float) scale[3]);
+  color_matrix_offset_components (&dst, offset[1], offset[2], offset[3]);
+
+  /* because we're doing 8-bit matrix coefficients */
+  color_matrix_scale_components (&dst, 256.0, 256.0, 256.0);
+
+  for (i = 0; i < 4; i++)
+    for (j = 0; j < 4; j++)
+      convert->cmatrix[i][j] = rint (dst.m[i][j]);
+
+  GST_DEBUG ("[%6d %6d %6d %6d]", convert->cmatrix[0][0],
+      convert->cmatrix[0][1], convert->cmatrix[0][2], convert->cmatrix[0][3]);
+  GST_DEBUG ("[%6d %6d %6d %6d]", convert->cmatrix[1][0],
+      convert->cmatrix[1][1], convert->cmatrix[1][2], convert->cmatrix[1][3]);
+  GST_DEBUG ("[%6d %6d %6d %6d]", convert->cmatrix[2][0],
+      convert->cmatrix[2][1], convert->cmatrix[2][2], convert->cmatrix[2][3]);
+  GST_DEBUG ("[%6d %6d %6d %6d]", convert->cmatrix[3][0],
+      convert->cmatrix[3][1], convert->cmatrix[3][2], convert->cmatrix[3][3]);
+
+  convert->matrix = videoconvert_convert_matrix;
+  convert->matrix16 = videoconvert_convert_matrix16;
+
+  return TRUE;
+
+  /* ERRORS */
+no_unpack_func:
+  {
+    GST_ERROR ("no unpack_func for format %s",
+        gst_video_format_to_string (GST_VIDEO_INFO_FORMAT (in_info)));
+    return FALSE;
+  }
+no_pack_func:
+  {
+    GST_ERROR ("no pack_func for format %s",
+        gst_video_format_to_string (GST_VIDEO_INFO_FORMAT (out_info)));
+    return FALSE;
   }
 }
 
@@ -1819,6 +433,84 @@
   }
 }
 
+#define TO_16(x) (((x)<<8) | (x))
+
+#define UNPACK_FRAME(frame,dest,line,width) \
+  frame->info.finfo->unpack_func (frame->info.finfo, GST_VIDEO_PACK_FLAG_NONE, \
+      dest, frame->data, frame->info.stride, 0, line, width)
+#define PACK_FRAME(frame,dest,line,width) \
+  frame->info.finfo->pack_func (frame->info.finfo, GST_VIDEO_PACK_FLAG_NONE, \
+      dest, 0, frame->data, frame->info.stride, frame->info.chroma_site, line, width);
+
+static void
+videoconvert_convert_generic (VideoConvert * convert, GstVideoFrame * dest,
+    const GstVideoFrame * src)
+{
+  int i, j;
+  gint width, height;
+  guint in_bits, out_bits;
+
+  height = convert->height;
+  width = convert->width;
+
+  in_bits = convert->in_bits;
+  out_bits = convert->out_bits;
+
+  for (j = 0; j < height; j++) {
+    if (in_bits == 16) {
+      UNPACK_FRAME (src, convert->tmpline16, j, width);
+    } else {
+      UNPACK_FRAME (src, convert->tmpline, j, width);
+
+      if (out_bits == 16)
+        for (i = 0; i < width * 4; i++)
+          convert->tmpline16[i] = TO_16 (convert->tmpline[i]);
+    }
+
+    if (out_bits == 16 || in_bits == 16) {
+      convert->matrix16 (convert);
+      convert->dither16 (convert, j);
+    } else {
+      convert->matrix (convert);
+    }
+
+    if (out_bits == 16) {
+      PACK_FRAME (dest, convert->tmpline16, j, width);
+    } else {
+      if (in_bits == 16)
+        for (i = 0; i < width * 4; i++)
+          convert->tmpline[i] = convert->tmpline16[i] >> 8;
+
+      PACK_FRAME (dest, convert->tmpline, j, width);
+    }
+  }
+}
+
+#define FRAME_GET_PLANE_STRIDE(frame, plane) \
+  GST_VIDEO_FRAME_PLANE_STRIDE (frame, plane)
+#define FRAME_GET_PLANE_LINE(frame, plane, line) \
+  (gpointer)(((guint8*)(GST_VIDEO_FRAME_PLANE_DATA (frame, plane))) + \
+      FRAME_GET_PLANE_STRIDE (frame, plane) * (line))
+
+#define FRAME_GET_COMP_STRIDE(frame, comp) \
+  GST_VIDEO_FRAME_COMP_STRIDE (frame, comp)
+#define FRAME_GET_COMP_LINE(frame, comp, line) \
+  (gpointer)(((guint8*)(GST_VIDEO_FRAME_COMP_DATA (frame, comp))) + \
+      FRAME_GET_COMP_STRIDE (frame, comp) * (line))
+
+#define FRAME_GET_STRIDE(frame)      FRAME_GET_PLANE_STRIDE (frame, 0)
+#define FRAME_GET_LINE(frame,line)   FRAME_GET_PLANE_LINE (frame, 0, line)
+
+#define FRAME_GET_Y_LINE(frame,line) FRAME_GET_COMP_LINE(frame, GST_VIDEO_COMP_Y, line)
+#define FRAME_GET_U_LINE(frame,line) FRAME_GET_COMP_LINE(frame, GST_VIDEO_COMP_U, line)
+#define FRAME_GET_V_LINE(frame,line) FRAME_GET_COMP_LINE(frame, GST_VIDEO_COMP_V, line)
+#define FRAME_GET_A_LINE(frame,line) FRAME_GET_COMP_LINE(frame, GST_VIDEO_COMP_A, line)
+
+#define FRAME_GET_Y_STRIDE(frame)    FRAME_GET_COMP_STRIDE(frame, GST_VIDEO_COMP_Y)
+#define FRAME_GET_U_STRIDE(frame)    FRAME_GET_COMP_STRIDE(frame, GST_VIDEO_COMP_U)
+#define FRAME_GET_V_STRIDE(frame)    FRAME_GET_COMP_STRIDE(frame, GST_VIDEO_COMP_V)
+#define FRAME_GET_A_STRIDE(frame)    FRAME_GET_COMP_STRIDE(frame, GST_VIDEO_COMP_A)
+
 /* Fast paths */
 
 static void
@@ -1826,20 +518,22 @@
     const GstVideoFrame * src)
 {
   int i;
+  gint width = convert->width;
+  gint height = convert->height;
 
-  for (i = 0; i < GST_ROUND_DOWN_2 (convert->height); i += 2) {
-    cogorc_convert_I420_YUY2 (FRAME_GET_LINE (dest, 0, i),
-        FRAME_GET_LINE (dest, 0, i + 1),
-        FRAME_GET_LINE (src, 0, i),
-        FRAME_GET_LINE (src, 0, i + 1),
-        FRAME_GET_LINE (src, 1, i >> 1),
-        FRAME_GET_LINE (src, 2, i >> 1), (convert->width + 1) / 2);
+  for (i = 0; i < GST_ROUND_DOWN_2 (height); i += 2) {
+    cogorc_convert_I420_YUY2 (FRAME_GET_LINE (dest, i),
+        FRAME_GET_LINE (dest, i + 1),
+        FRAME_GET_Y_LINE (src, i),
+        FRAME_GET_Y_LINE (src, i + 1),
+        FRAME_GET_U_LINE (src, i >> 1),
+        FRAME_GET_V_LINE (src, i >> 1), (width + 1) / 2);
   }
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_I420 (convert, convert->tmpline, src, convert->height - 1);
-    putline_YUY2 (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -1848,20 +542,22 @@
     const GstVideoFrame * src)
 {
   int i;
+  gint width = convert->width;
+  gint height = convert->height;
 
-  for (i = 0; i < GST_ROUND_DOWN_2 (convert->height); i += 2) {
-    cogorc_convert_I420_UYVY (FRAME_GET_LINE (dest, 0, i),
-        FRAME_GET_LINE (dest, 0, i + 1),
-        FRAME_GET_LINE (src, 0, i),
-        FRAME_GET_LINE (src, 0, i + 1),
-        FRAME_GET_LINE (src, 1, i >> 1),
-        FRAME_GET_LINE (src, 2, i >> 1), (convert->width + 1) / 2);
+  for (i = 0; i < GST_ROUND_DOWN_2 (height); i += 2) {
+    cogorc_convert_I420_UYVY (FRAME_GET_LINE (dest, i),
+        FRAME_GET_LINE (dest, i + 1),
+        FRAME_GET_Y_LINE (src, i),
+        FRAME_GET_Y_LINE (src, i + 1),
+        FRAME_GET_U_LINE (src, i >> 1),
+        FRAME_GET_V_LINE (src, i >> 1), (width + 1) / 2);
   }
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_I420 (convert, convert->tmpline, src, convert->height - 1);
-    putline_UYVY (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -1870,20 +566,21 @@
     const GstVideoFrame * src)
 {
   int i;
+  gint width = convert->width;
+  gint height = convert->height;
 
-  for (i = 0; i < GST_ROUND_DOWN_2 (convert->height); i += 2) {
-    cogorc_convert_I420_AYUV (FRAME_GET_LINE (dest, 0, i),
-        FRAME_GET_LINE (dest, 0, i + 1),
-        FRAME_GET_LINE (src, 0, i),
-        FRAME_GET_LINE (src, 0, i + 1),
-        FRAME_GET_LINE (src, 1, i >> 1),
-        FRAME_GET_LINE (src, 2, i >> 1), convert->width);
+  for (i = 0; i < GST_ROUND_DOWN_2 (height); i += 2) {
+    cogorc_convert_I420_AYUV (FRAME_GET_LINE (dest, i),
+        FRAME_GET_LINE (dest, i + 1),
+        FRAME_GET_Y_LINE (src, i),
+        FRAME_GET_Y_LINE (src, i + 1),
+        FRAME_GET_U_LINE (src, i >> 1), FRAME_GET_V_LINE (src, i >> 1), width);
   }
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_I420 (convert, convert->tmpline, src, convert->height - 1);
-    putline_AYUV (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -1891,43 +588,47 @@
 convert_I420_Y42B (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_memcpy_2d (FRAME_GET_LINE (dest, 0, 0), FRAME_GET_STRIDE (dest, 0),
-      FRAME_GET_LINE (src, 0, 0), FRAME_GET_STRIDE (src, 0),
-      convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
 
-  cogorc_planar_chroma_420_422 (FRAME_GET_LINE (dest, 1, 0),
-      2 * FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 1, 1),
-      2 * FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), (convert->width + 1) / 2, convert->height / 2);
+  cogorc_memcpy_2d (FRAME_GET_Y_LINE (dest, 0), FRAME_GET_Y_STRIDE (dest),
+      FRAME_GET_Y_LINE (src, 0), FRAME_GET_Y_STRIDE (src), width, height);
 
-  cogorc_planar_chroma_420_422 (FRAME_GET_LINE (dest, 2, 0),
-      2 * FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (dest, 2, 1),
-      2 * FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height / 2);
+  cogorc_planar_chroma_420_422 (FRAME_GET_U_LINE (dest, 0),
+      2 * FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (dest, 1),
+      2 * FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), (width + 1) / 2, height / 2);
+
+  cogorc_planar_chroma_420_422 (FRAME_GET_V_LINE (dest, 0),
+      2 * FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (dest, 1),
+      2 * FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height / 2);
 }
 
 static void
 convert_I420_Y444 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_memcpy_2d (FRAME_GET_LINE (dest, 0, 0), FRAME_GET_STRIDE (dest, 0),
-      FRAME_GET_LINE (src, 0, 0), FRAME_GET_STRIDE (src, 0),
-      convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
 
-  cogorc_planar_chroma_420_444 (FRAME_GET_LINE (dest, 1, 0),
-      2 * FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 1, 1),
-      2 * FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), (convert->width + 1) / 2, convert->height / 2);
+  cogorc_memcpy_2d (FRAME_GET_Y_LINE (dest, 0), FRAME_GET_Y_STRIDE (dest),
+      FRAME_GET_Y_LINE (src, 0), FRAME_GET_Y_STRIDE (src), width, height);
 
-  cogorc_planar_chroma_420_444 (FRAME_GET_LINE (dest, 2, 0),
-      2 * FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (dest, 2, 1),
-      2 * FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height / 2);
+  cogorc_planar_chroma_420_444 (FRAME_GET_U_LINE (dest, 0),
+      2 * FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (dest, 1),
+      2 * FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), (width + 1) / 2, height / 2);
+
+  cogorc_planar_chroma_420_444 (FRAME_GET_V_LINE (dest, 0),
+      2 * FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (dest, 1),
+      2 * FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height / 2);
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_I420 (convert, convert->tmpline, src, convert->height - 1);
-    putline_Y444 (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -1936,24 +637,25 @@
     const GstVideoFrame * src)
 {
   int i, h;
+  gint width = convert->width;
+  gint height = convert->height;
 
-  h = convert->height;
-  if (convert->width & 1)
+  h = height;
+  if (width & 1)
     h--;
 
   for (i = 0; i < h; i += 2) {
-    cogorc_convert_YUY2_I420 (FRAME_GET_LINE (dest, 0, i),
-        FRAME_GET_LINE (dest, 0, i + 1),
-        FRAME_GET_LINE (dest, 1, i >> 1),
-        FRAME_GET_LINE (dest, 2, i >> 1),
-        FRAME_GET_LINE (src, 0, i),
-        FRAME_GET_LINE (src, 0, i + 1), (convert->width + 1) / 2);
+    cogorc_convert_YUY2_I420 (FRAME_GET_Y_LINE (dest, i),
+        FRAME_GET_Y_LINE (dest, i + 1),
+        FRAME_GET_U_LINE (dest, i >> 1),
+        FRAME_GET_V_LINE (dest, i >> 1),
+        FRAME_GET_LINE (src, i), FRAME_GET_LINE (src, i + 1), (width + 1) / 2);
   }
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_YUY2 (convert, convert->tmpline, src, convert->height - 1);
-    putline_I420 (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -1961,15 +663,18 @@
 convert_YUY2_AYUV (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_YUY2_AYUV (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2,
-      convert->height & 1 ? convert->height - 1 : convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_YUY2_AYUV (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2,
+      height & 1 ? height - 1 : height);
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_YUY2 (convert, convert->tmpline, src, convert->height - 1);
-    putline_AYUV (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -1977,22 +682,28 @@
 convert_YUY2_Y42B (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_YUY2_Y42B (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_YUY2_Y42B (FRAME_GET_Y_LINE (dest, 0),
+      FRAME_GET_Y_STRIDE (dest), FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_YUY2_Y444 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_YUY2_Y444 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_YUY2_Y444 (FRAME_GET_COMP_LINE (dest, 0, 0),
+      FRAME_GET_COMP_STRIDE (dest, 0), FRAME_GET_COMP_LINE (dest, 1, 0),
+      FRAME_GET_COMP_STRIDE (dest, 1), FRAME_GET_COMP_LINE (dest, 2, 0),
+      FRAME_GET_COMP_STRIDE (dest, 2), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2, height);
 }
 
 
@@ -2001,20 +712,21 @@
     const GstVideoFrame * src)
 {
   int i;
+  gint width = convert->width;
+  gint height = convert->height;
 
-  for (i = 0; i < GST_ROUND_DOWN_2 (convert->height); i += 2) {
-    cogorc_convert_UYVY_I420 (FRAME_GET_LINE (dest, 0, i),
-        FRAME_GET_LINE (dest, 0, i + 1),
-        FRAME_GET_LINE (dest, 1, i >> 1),
-        FRAME_GET_LINE (dest, 2, i >> 1),
-        FRAME_GET_LINE (src, 0, i),
-        FRAME_GET_LINE (src, 0, i + 1), (convert->width + 1) / 2);
+  for (i = 0; i < GST_ROUND_DOWN_2 (height); i += 2) {
+    cogorc_convert_UYVY_I420 (FRAME_GET_COMP_LINE (dest, 0, i),
+        FRAME_GET_COMP_LINE (dest, 0, i + 1),
+        FRAME_GET_COMP_LINE (dest, 1, i >> 1),
+        FRAME_GET_COMP_LINE (dest, 2, i >> 1),
+        FRAME_GET_LINE (src, i), FRAME_GET_LINE (src, i + 1), (width + 1) / 2);
   }
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_UYVY (convert, convert->tmpline, src, convert->height - 1);
-    putline_I420 (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -2022,15 +734,18 @@
 convert_UYVY_AYUV (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_UYVY_AYUV (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2,
-      convert->height & 1 ? convert->height - 1 : convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_UYVY_AYUV (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2,
+      height & 1 ? height - 1 : height);
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_UYVY (convert, convert->tmpline, src, convert->height - 1);
-    putline_AYUV (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -2038,79 +753,100 @@
 convert_UYVY_YUY2 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_UYVY_YUY2 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_UYVY_YUY2 (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_UYVY_Y42B (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_UYVY_Y42B (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_UYVY_Y42B (FRAME_GET_Y_LINE (dest, 0),
+      FRAME_GET_Y_STRIDE (dest), FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_UYVY_Y444 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_UYVY_Y444 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_UYVY_Y444 (FRAME_GET_Y_LINE (dest, 0),
+      FRAME_GET_Y_STRIDE (dest), FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_AYUV_I420 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_I420 (FRAME_GET_LINE (dest, 0, 0),
-      2 * FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 0, 1),
-      2 * FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      2 * FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 0, 1),
-      2 * FRAME_GET_STRIDE (src, 0), convert->width / 2, convert->height / 2);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_I420 (FRAME_GET_Y_LINE (dest, 0),
+      2 * FRAME_GET_Y_STRIDE (dest), FRAME_GET_Y_LINE (dest, 1),
+      2 * FRAME_GET_Y_STRIDE (dest), FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      2 * FRAME_GET_STRIDE (src), FRAME_GET_LINE (src, 1),
+      2 * FRAME_GET_STRIDE (src), width / 2, height / 2);
 }
 
 static void
 convert_AYUV_YUY2 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_YUY2 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_YUY2 (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width / 2, height);
 }
 
 static void
 convert_AYUV_UYVY (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_UYVY (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_UYVY (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width / 2, height);
 }
 
 static void
 convert_AYUV_Y42B (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_Y42B (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), (convert->width + 1) / 2,
-      convert->height & 1 ? convert->height - 1 : convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_Y42B (FRAME_GET_Y_LINE (dest, 0),
+      FRAME_GET_Y_STRIDE (dest), FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), (width + 1) / 2,
+      height & 1 ? height - 1 : height);
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_AYUV (convert, convert->tmpline, src, convert->height - 1);
-    putline_Y42B (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -2118,37 +854,40 @@
 convert_AYUV_Y444 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_Y444 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_Y444 (FRAME_GET_Y_LINE (dest, 0),
+      FRAME_GET_Y_STRIDE (dest), FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width, height);
 }
 
 static void
 convert_Y42B_I420 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_memcpy_2d (FRAME_GET_LINE (dest, 0, 0), FRAME_GET_STRIDE (dest, 0),
-      FRAME_GET_LINE (src, 0, 0), FRAME_GET_STRIDE (src, 0),
-      convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
 
-  cogorc_planar_chroma_422_420 (FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (src, 1, 0),
-      2 * FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 1, 1),
-      2 * FRAME_GET_STRIDE (src, 1), (convert->width + 1) / 2,
-      convert->height / 2);
+  cogorc_memcpy_2d (FRAME_GET_Y_LINE (dest, 0), FRAME_GET_Y_STRIDE (dest),
+      FRAME_GET_Y_LINE (src, 0), FRAME_GET_Y_STRIDE (src), width, height);
 
-  cogorc_planar_chroma_422_420 (FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 2, 0),
-      2 * FRAME_GET_STRIDE (src, 2), FRAME_GET_LINE (src, 2, 1),
-      2 * FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2,
-      convert->height / 2);
+  cogorc_planar_chroma_422_420 (FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (src, 0),
+      2 * FRAME_GET_U_STRIDE (src), FRAME_GET_U_LINE (src, 1),
+      2 * FRAME_GET_U_STRIDE (src), (width + 1) / 2, height / 2);
+
+  cogorc_planar_chroma_422_420 (FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (src, 0),
+      2 * FRAME_GET_V_STRIDE (src), FRAME_GET_V_LINE (src, 1),
+      2 * FRAME_GET_V_STRIDE (src), (width + 1) / 2, height / 2);
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_Y42B (convert, convert->tmpline, src, convert->height - 1);
-    putline_I420 (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -2156,76 +895,87 @@
 convert_Y42B_Y444 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_memcpy_2d (FRAME_GET_LINE (dest, 0, 0), FRAME_GET_STRIDE (dest, 0),
-      FRAME_GET_LINE (src, 0, 0), FRAME_GET_STRIDE (src, 0),
-      convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
 
-  cogorc_planar_chroma_422_444 (FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), (convert->width + 1) / 2, convert->height);
+  cogorc_memcpy_2d (FRAME_GET_Y_LINE (dest, 0), FRAME_GET_Y_STRIDE (dest),
+      FRAME_GET_Y_LINE (src, 0), FRAME_GET_Y_STRIDE (src), width, height);
 
-  cogorc_planar_chroma_422_444 (FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height);
+  cogorc_planar_chroma_422_444 (FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), (width + 1) / 2, height);
+
+  cogorc_planar_chroma_422_444 (FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_Y42B_YUY2 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_Y42B_YUY2 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_Y42B_YUY2 (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_Y_LINE (src, 0),
+      FRAME_GET_Y_STRIDE (src), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_Y42B_UYVY (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_Y42B_UYVY (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_Y42B_UYVY (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_Y_LINE (src, 0),
+      FRAME_GET_Y_STRIDE (src), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_Y42B_AYUV (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_Y42B_AYUV (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_Y42B_AYUV (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_Y_LINE (src, 0),
+      FRAME_GET_Y_STRIDE (src), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width) / 2, height);
 }
 
 static void
 convert_Y444_I420 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_memcpy_2d (FRAME_GET_LINE (dest, 0, 0), FRAME_GET_STRIDE (dest, 0),
-      FRAME_GET_LINE (src, 0, 0), FRAME_GET_STRIDE (src, 0),
-      convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
 
-  cogorc_planar_chroma_444_420 (FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (src, 1, 0),
-      2 * FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 1, 1),
-      2 * FRAME_GET_STRIDE (src, 1), (convert->width + 1) / 2,
-      convert->height / 2);
+  cogorc_memcpy_2d (FRAME_GET_Y_LINE (dest, 0), FRAME_GET_Y_STRIDE (dest),
+      FRAME_GET_Y_LINE (src, 0), FRAME_GET_Y_STRIDE (src), width, height);
 
-  cogorc_planar_chroma_444_420 (FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 2, 0),
-      2 * FRAME_GET_STRIDE (src, 2), FRAME_GET_LINE (src, 2, 1),
-      2 * FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2,
-      convert->height / 2);
+  cogorc_planar_chroma_444_420 (FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (src, 0),
+      2 * FRAME_GET_U_STRIDE (src), FRAME_GET_U_LINE (src, 1),
+      2 * FRAME_GET_U_STRIDE (src), (width + 1) / 2, height / 2);
+
+  cogorc_planar_chroma_444_420 (FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (src, 0),
+      2 * FRAME_GET_V_STRIDE (src), FRAME_GET_V_LINE (src, 1),
+      2 * FRAME_GET_V_STRIDE (src), (width + 1) / 2, height / 2);
 
   /* now handle last line */
-  if (convert->height & 1) {
-    getline_Y444 (convert, convert->tmpline, src, convert->height - 1);
-    putline_I420 (convert, dest, convert->tmpline, convert->height - 1);
+  if (height & 1) {
+    UNPACK_FRAME (src, convert->tmpline, height - 1, width);
+    PACK_FRAME (dest, convert->tmpline, height - 1, width);
   }
 }
 
@@ -2233,50 +983,61 @@
 convert_Y444_Y42B (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_memcpy_2d (FRAME_GET_LINE (dest, 0, 0), FRAME_GET_STRIDE (dest, 0),
-      FRAME_GET_LINE (src, 0, 0), FRAME_GET_STRIDE (src, 0),
-      convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
 
-  cogorc_planar_chroma_444_422 (FRAME_GET_LINE (dest, 1, 0),
-      FRAME_GET_STRIDE (dest, 1), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), (convert->width + 1) / 2, convert->height);
+  cogorc_memcpy_2d (FRAME_GET_Y_LINE (dest, 0), FRAME_GET_Y_STRIDE (dest),
+      FRAME_GET_Y_LINE (src, 0), FRAME_GET_Y_STRIDE (src), width, height);
 
-  cogorc_planar_chroma_444_422 (FRAME_GET_LINE (dest, 2, 0),
-      FRAME_GET_STRIDE (dest, 2), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height);
+  cogorc_planar_chroma_444_422 (FRAME_GET_U_LINE (dest, 0),
+      FRAME_GET_U_STRIDE (dest), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), (width + 1) / 2, height);
+
+  cogorc_planar_chroma_444_422 (FRAME_GET_V_LINE (dest, 0),
+      FRAME_GET_V_STRIDE (dest), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_Y444_YUY2 (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_Y444_YUY2 (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_Y444_YUY2 (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_Y_LINE (src, 0),
+      FRAME_GET_Y_STRIDE (src), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_Y444_UYVY (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_Y444_UYVY (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), (convert->width + 1) / 2, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_Y444_UYVY (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_Y_LINE (src, 0),
+      FRAME_GET_Y_STRIDE (src), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), (width + 1) / 2, height);
 }
 
 static void
 convert_Y444_AYUV (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_Y444_AYUV (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), FRAME_GET_LINE (src, 1, 0),
-      FRAME_GET_STRIDE (src, 1), FRAME_GET_LINE (src, 2, 0),
-      FRAME_GET_STRIDE (src, 2), convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_Y444_AYUV (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_Y_LINE (src, 0),
+      FRAME_GET_Y_STRIDE (src), FRAME_GET_U_LINE (src, 0),
+      FRAME_GET_U_STRIDE (src), FRAME_GET_V_LINE (src, 0),
+      FRAME_GET_V_STRIDE (src), width, height);
 }
 
 #if G_BYTE_ORDER == G_LITTLE_ENDIAN
@@ -2284,36 +1045,48 @@
 convert_AYUV_ARGB (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_ARGB (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_ARGB (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width, height);
 }
 
 static void
 convert_AYUV_BGRA (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_BGRA (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_BGRA (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width, height);
 }
 
 static void
 convert_AYUV_ABGR (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_ABGR (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_ABGR (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width, height);
 }
 
 static void
 convert_AYUV_RGBA (VideoConvert * convert, GstVideoFrame * dest,
     const GstVideoFrame * src)
 {
-  cogorc_convert_AYUV_RGBA (FRAME_GET_LINE (dest, 0, 0),
-      FRAME_GET_STRIDE (dest, 0), FRAME_GET_LINE (src, 0, 0),
-      FRAME_GET_STRIDE (src, 0), convert->width, convert->height);
+  gint width = convert->width;
+  gint height = convert->height;
+
+  cogorc_convert_AYUV_RGBA (FRAME_GET_LINE (dest, 0),
+      FRAME_GET_STRIDE (dest), FRAME_GET_LINE (src, 0),
+      FRAME_GET_STRIDE (src), width, height);
 }
 
 static void
@@ -2322,29 +1095,31 @@
 {
   int i;
   int quality = 0;
+  gint width = convert->width;
+  gint height = convert->height;
 
   if (quality > 3) {
-    for (i = 0; i < convert->height; i++) {
+    for (i = 0; i < height; i++) {
       if (i & 1) {
-        cogorc_convert_I420_BGRA_avg (FRAME_GET_LINE (dest, 0, i),
-            FRAME_GET_LINE (src, 0, i),
-            FRAME_GET_LINE (src, 1, i >> 1),
-            FRAME_GET_LINE (src, 1, (i >> 1) + 1),
-            FRAME_GET_LINE (src, 2, i >> 1),
-            FRAME_GET_LINE (src, 2, (i >> 1) + 1), convert->width);
+        cogorc_convert_I420_BGRA_avg (FRAME_GET_LINE (dest, i),
+            FRAME_GET_Y_LINE (src, i),
+            FRAME_GET_U_LINE (src, i >> 1),
+            FRAME_GET_U_LINE (src, (i >> 1) + 1),
+            FRAME_GET_V_LINE (src, i >> 1),
+            FRAME_GET_V_LINE (src, (i >> 1) + 1), width);
       } else {
-        cogorc_convert_I420_BGRA (FRAME_GET_LINE (dest, 0, i),
-            FRAME_GET_LINE (src, 0, i),
-            FRAME_GET_LINE (src, 1, i >> 1),
-            FRAME_GET_LINE (src, 2, i >> 1), convert->width);
+        cogorc_convert_I420_BGRA (FRAME_GET_LINE (dest, i),
+            FRAME_GET_Y_LINE (src, i),
+            FRAME_GET_U_LINE (src, i >> 1),
+            FRAME_GET_V_LINE (src, i >> 1), width);
       }
     }
   } else {
-    for (i = 0; i < convert->height; i++) {
-      cogorc_convert_I420_BGRA (FRAME_GET_LINE (dest, 0, i),
-          FRAME_GET_LINE (src, 0, i),
-          FRAME_GET_LINE (src, 1, i >> 1),
-          FRAME_GET_LINE (src, 2, i >> 1), convert->width);
+    for (i = 0; i < height; i++) {
+      cogorc_convert_I420_BGRA (FRAME_GET_LINE (dest, i),
+          FRAME_GET_Y_LINE (src, i),
+          FRAME_GET_U_LINE (src, i >> 1),
+          FRAME_GET_V_LINE (src, i >> 1), width);
     }
   }
 }
@@ -2356,112 +1131,121 @@
 
 typedef struct
 {
-  GstVideoFormat from_format;
-  ColorSpaceColorSpec from_spec;
-  GstVideoFormat to_format;
-  ColorSpaceColorSpec to_spec;
-  gboolean keeps_color_spec;
+  GstVideoFormat in_format;
+  GstVideoColorMatrix in_matrix;
+  GstVideoFormat out_format;
+  GstVideoColorMatrix out_matrix;
+  gboolean keeps_color_matrix;
   void (*convert) (VideoConvert * convert, GstVideoFrame * dest,
       const GstVideoFrame * src);
 } VideoTransform;
 static const VideoTransform transforms[] = {
-  {GST_VIDEO_FORMAT_I420, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_YUY2,
-      COLOR_SPEC_NONE, TRUE, convert_I420_YUY2},
-  {GST_VIDEO_FORMAT_I420, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_UYVY,
-      COLOR_SPEC_NONE, TRUE, convert_I420_UYVY},
-  {GST_VIDEO_FORMAT_I420, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_AYUV,
-      COLOR_SPEC_NONE, TRUE, convert_I420_AYUV},
-  {GST_VIDEO_FORMAT_I420, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y42B,
-      COLOR_SPEC_NONE, TRUE, convert_I420_Y42B},
-  {GST_VIDEO_FORMAT_I420, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y444,
-      COLOR_SPEC_NONE, TRUE, convert_I420_Y444},
+  {GST_VIDEO_FORMAT_I420, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_YUY2,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_I420_YUY2},
+  {GST_VIDEO_FORMAT_I420, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_UYVY,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_I420_UYVY},
+  {GST_VIDEO_FORMAT_I420, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_AYUV,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_I420_AYUV},
+  {GST_VIDEO_FORMAT_I420, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y42B,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_I420_Y42B},
+  {GST_VIDEO_FORMAT_I420, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y444,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_I420_Y444},
 
-  {GST_VIDEO_FORMAT_YUY2, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_I420,
-      COLOR_SPEC_NONE, TRUE, convert_YUY2_I420},
-  {GST_VIDEO_FORMAT_YUY2, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_UYVY, COLOR_SPEC_NONE, TRUE, convert_UYVY_YUY2},    /* alias */
-  {GST_VIDEO_FORMAT_YUY2, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_AYUV,
-      COLOR_SPEC_NONE, TRUE, convert_YUY2_AYUV},
-  {GST_VIDEO_FORMAT_YUY2, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y42B,
-      COLOR_SPEC_NONE, TRUE, convert_YUY2_Y42B},
-  {GST_VIDEO_FORMAT_YUY2, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y444,
-      COLOR_SPEC_NONE, TRUE, convert_YUY2_Y444},
+  {GST_VIDEO_FORMAT_YUY2, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_I420,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_YUY2_I420},
+  {GST_VIDEO_FORMAT_YUY2, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_UYVY, GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_UYVY_YUY2},      /* alias */
+  {GST_VIDEO_FORMAT_YUY2, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_AYUV,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_YUY2_AYUV},
+  {GST_VIDEO_FORMAT_YUY2, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y42B,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_YUY2_Y42B},
+  {GST_VIDEO_FORMAT_YUY2, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y444,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_YUY2_Y444},
 
-  {GST_VIDEO_FORMAT_UYVY, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_I420,
-      COLOR_SPEC_NONE, TRUE, convert_UYVY_I420},
-  {GST_VIDEO_FORMAT_UYVY, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_YUY2,
-      COLOR_SPEC_NONE, TRUE, convert_UYVY_YUY2},
-  {GST_VIDEO_FORMAT_UYVY, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_AYUV,
-      COLOR_SPEC_NONE, TRUE, convert_UYVY_AYUV},
-  {GST_VIDEO_FORMAT_UYVY, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y42B,
-      COLOR_SPEC_NONE, TRUE, convert_UYVY_Y42B},
-  {GST_VIDEO_FORMAT_UYVY, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y444,
-      COLOR_SPEC_NONE, TRUE, convert_UYVY_Y444},
+  {GST_VIDEO_FORMAT_UYVY, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_I420,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_UYVY_I420},
+  {GST_VIDEO_FORMAT_UYVY, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_YUY2,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_UYVY_YUY2},
+  {GST_VIDEO_FORMAT_UYVY, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_AYUV,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_UYVY_AYUV},
+  {GST_VIDEO_FORMAT_UYVY, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y42B,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_UYVY_Y42B},
+  {GST_VIDEO_FORMAT_UYVY, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y444,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_UYVY_Y444},
 
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_I420,
-      COLOR_SPEC_NONE, TRUE, convert_AYUV_I420},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_YUY2,
-      COLOR_SPEC_NONE, TRUE, convert_AYUV_YUY2},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_UYVY,
-      COLOR_SPEC_NONE, TRUE, convert_AYUV_UYVY},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y42B,
-      COLOR_SPEC_NONE, TRUE, convert_AYUV_Y42B},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y444,
-      COLOR_SPEC_NONE, TRUE, convert_AYUV_Y444},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_I420,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_AYUV_I420},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_YUY2,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_AYUV_YUY2},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_UYVY,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_AYUV_UYVY},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y42B,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_AYUV_Y42B},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y444,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_AYUV_Y444},
 
-  {GST_VIDEO_FORMAT_Y42B, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_I420,
-      COLOR_SPEC_NONE, TRUE, convert_Y42B_I420},
-  {GST_VIDEO_FORMAT_Y42B, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_YUY2,
-      COLOR_SPEC_NONE, TRUE, convert_Y42B_YUY2},
-  {GST_VIDEO_FORMAT_Y42B, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_UYVY,
-      COLOR_SPEC_NONE, TRUE, convert_Y42B_UYVY},
-  {GST_VIDEO_FORMAT_Y42B, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_AYUV,
-      COLOR_SPEC_NONE, TRUE, convert_Y42B_AYUV},
-  {GST_VIDEO_FORMAT_Y42B, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y444,
-      COLOR_SPEC_NONE, TRUE, convert_Y42B_Y444},
+  {GST_VIDEO_FORMAT_Y42B, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_I420,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y42B_I420},
+  {GST_VIDEO_FORMAT_Y42B, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_YUY2,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y42B_YUY2},
+  {GST_VIDEO_FORMAT_Y42B, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_UYVY,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y42B_UYVY},
+  {GST_VIDEO_FORMAT_Y42B, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_AYUV,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y42B_AYUV},
+  {GST_VIDEO_FORMAT_Y42B, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y444,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y42B_Y444},
 
-  {GST_VIDEO_FORMAT_Y444, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_I420,
-      COLOR_SPEC_NONE, TRUE, convert_Y444_I420},
-  {GST_VIDEO_FORMAT_Y444, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_YUY2,
-      COLOR_SPEC_NONE, TRUE, convert_Y444_YUY2},
-  {GST_VIDEO_FORMAT_Y444, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_UYVY,
-      COLOR_SPEC_NONE, TRUE, convert_Y444_UYVY},
-  {GST_VIDEO_FORMAT_Y444, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_AYUV,
-      COLOR_SPEC_NONE, TRUE, convert_Y444_AYUV},
-  {GST_VIDEO_FORMAT_Y444, COLOR_SPEC_NONE, GST_VIDEO_FORMAT_Y42B,
-      COLOR_SPEC_NONE, TRUE, convert_Y444_Y42B},
+  {GST_VIDEO_FORMAT_Y444, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_I420,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y444_I420},
+  {GST_VIDEO_FORMAT_Y444, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_YUY2,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y444_YUY2},
+  {GST_VIDEO_FORMAT_Y444, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_UYVY,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y444_UYVY},
+  {GST_VIDEO_FORMAT_Y444, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_AYUV,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y444_AYUV},
+  {GST_VIDEO_FORMAT_Y444, GST_VIDEO_COLOR_MATRIX_UNKNOWN, GST_VIDEO_FORMAT_Y42B,
+      GST_VIDEO_COLOR_MATRIX_UNKNOWN, TRUE, convert_Y444_Y42B},
 
 #if G_BYTE_ORDER == G_LITTLE_ENDIAN
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_ARGB,
-      COLOR_SPEC_RGB, FALSE, convert_AYUV_ARGB},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_BGRA,
-      COLOR_SPEC_RGB, FALSE, convert_AYUV_BGRA},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_xRGB, COLOR_SPEC_RGB, FALSE, convert_AYUV_ARGB},     /* alias */
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_BGRx, COLOR_SPEC_RGB, FALSE, convert_AYUV_BGRA},     /* alias */
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_ABGR,
-      COLOR_SPEC_RGB, FALSE, convert_AYUV_ABGR},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_RGBA,
-      COLOR_SPEC_RGB, FALSE, convert_AYUV_RGBA},
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_xBGR, COLOR_SPEC_RGB, FALSE, convert_AYUV_ABGR},     /* alias */
-  {GST_VIDEO_FORMAT_AYUV, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_RGBx, COLOR_SPEC_RGB, FALSE, convert_AYUV_RGBA},     /* alias */
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_ARGB,
+      GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_ARGB},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_BGRA,
+      GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_BGRA},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_xRGB, GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_ARGB},   /* alias */
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_BGRx, GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_BGRA},   /* alias */
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_ABGR,
+      GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_ABGR},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_RGBA,
+      GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_RGBA},
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_xBGR, GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_ABGR},   /* alias */
+  {GST_VIDEO_FORMAT_AYUV, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_RGBx, GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_AYUV_RGBA},   /* alias */
 
-  {GST_VIDEO_FORMAT_I420, COLOR_SPEC_YUV_BT470_6, GST_VIDEO_FORMAT_BGRA,
-      COLOR_SPEC_RGB, FALSE, convert_I420_BGRA},
+  {GST_VIDEO_FORMAT_I420, GST_VIDEO_COLOR_MATRIX_BT601, GST_VIDEO_FORMAT_BGRA,
+      GST_VIDEO_COLOR_MATRIX_RGB, FALSE, convert_I420_BGRA},
 #endif
 };
 
-static void
+static gboolean
 videoconvert_convert_lookup_fastpath (VideoConvert * convert)
 {
   int i;
+  GstVideoFormat in_format, out_format;
+  GstVideoColorMatrix in_matrix, out_matrix;
+
+  in_format = GST_VIDEO_INFO_FORMAT (&convert->in_info);
+  out_format = GST_VIDEO_INFO_FORMAT (&convert->out_info);
+
+  in_matrix = convert->in_info.colorimetry.matrix;
+  out_matrix = convert->out_info.colorimetry.matrix;
 
   for (i = 0; i < sizeof (transforms) / sizeof (transforms[0]); i++) {
-    if (transforms[i].to_format == convert->to_format &&
-        transforms[i].from_format == convert->from_format &&
-        (transforms[i].keeps_color_spec ||
-            (transforms[i].from_spec == convert->from_spec &&
-                transforms[i].to_spec == convert->to_spec))) {
+    if (transforms[i].in_format == in_format &&
+        transforms[i].out_format == out_format &&
+        (transforms[i].keeps_color_matrix ||
+            (transforms[i].in_matrix == in_matrix &&
+                transforms[i].out_matrix == out_matrix))) {
       convert->convert = transforms[i].convert;
-      return;
+      return TRUE;
     }
   }
+  return FALSE;
 }
diff --git a/gst/videoconvert/videoconvert.h b/gst/videoconvert/videoconvert.h
index 8d946ab..6b2cc18 100644
--- a/gst/videoconvert/videoconvert.h
+++ b/gst/videoconvert/videoconvert.h
@@ -21,66 +21,48 @@
 #define __COLORSPACE_H__
 
 #include <gst/video/video.h>
+#include "gstcms.h"
 
 G_BEGIN_DECLS
 
 typedef struct _VideoConvert VideoConvert;
 
 typedef enum {
-  COLOR_SPEC_NONE = 0,
-  COLOR_SPEC_RGB,
-  COLOR_SPEC_GRAY,
-  COLOR_SPEC_YUV_BT470_6,
-  COLOR_SPEC_YUV_BT709
-} ColorSpaceColorSpec;
-
-typedef enum {
   DITHER_NONE,
   DITHER_VERTERR,
   DITHER_HALFTONE
 } ColorSpaceDitherMethod;
 
 struct _VideoConvert {
-  gint width, height;
-  gboolean interlaced;
-  gboolean use_16bit;
-  gboolean dither;
+  GstVideoInfo in_info;
+  GstVideoInfo out_info;
 
-  GstVideoFormat from_format;
-  ColorSpaceColorSpec from_spec;
-  GstVideoFormat to_format;
-  ColorSpaceColorSpec to_spec;
+  gint width;
+  gint height;
+
+  gint in_bits;
+  gint out_bits;
+  gint cmatrix[4][4];
+
   guint32 *palette;
 
+  ColorSpaceDitherMethod dither;
+
   guint8 *tmpline;
   guint16 *tmpline16;
   guint16 *errline;
 
   void (*convert) (VideoConvert *convert, GstVideoFrame *dest, const GstVideoFrame *src);
-  void (*getline) (VideoConvert *convert, guint8 *dest, const GstVideoFrame *src, int j);
-  void (*putline) (VideoConvert *convert, GstVideoFrame *dest, const guint8 *src, int j);
   void (*matrix) (VideoConvert *convert);
-
-  void (*getline16) (VideoConvert *convert, guint16 *dest, const GstVideoFrame *src, int j);
-  void (*putline16) (VideoConvert *convert, GstVideoFrame *dest, const guint16 *src, int j);
   void (*matrix16) (VideoConvert *convert);
   void (*dither16) (VideoConvert *convert, int j);
 };
 
-VideoConvert *   videoconvert_convert_new            (GstVideoFormat to_format,
-                                                      ColorSpaceColorSpec from_spec,
-                                                      GstVideoFormat from_format,
-                                                      ColorSpaceColorSpec to_spec,
-                                                      int width, int height);
+VideoConvert *   videoconvert_convert_new            (GstVideoInfo *in_info,
+                                                      GstVideoInfo *out_info);
 void             videoconvert_convert_free           (VideoConvert * convert);
 
 void             videoconvert_convert_set_dither     (VideoConvert * convert, int type);
-void             videoconvert_convert_set_interlaced (VideoConvert *convert,
-                                                      gboolean interlaced);
-
-void             videoconvert_convert_set_palette    (VideoConvert *convert,
-                                                      const guint32 *palette);
-const guint32 *  videoconvert_convert_get_palette    (VideoConvert *convert);
 
 void             videoconvert_convert_convert        (VideoConvert * convert,
                                                       GstVideoFrame *dest, const GstVideoFrame *src);
diff --git a/gst/videorate/Makefile.in b/gst/videorate/Makefile.in
index 17e585f..5734c26 100644
--- a/gst/videorate/Makefile.in
+++ b/gst/videorate/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = gst/videorate
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -278,8 +279,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -450,7 +457,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/videoscale/Makefile.in b/gst/videoscale/Makefile.in
index 676a71a..f3cfa6c 100644
--- a/gst/videoscale/Makefile.in
+++ b/gst/videoscale/Makefile.in
@@ -74,6 +74,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = README $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/orc.mak
 subdir = gst/videoscale
@@ -310,8 +311,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -482,7 +489,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/videoscale/gstvideoscale.c b/gst/videoscale/gstvideoscale.c
index 6f53473..ae29309 100644
--- a/gst/videoscale/gstvideoscale.c
+++ b/gst/videoscale/gstvideoscale.c
@@ -1071,12 +1071,10 @@
       return black[5];
     case GST_VIDEO_FORMAT_UYVY:
       return black[6];
-    case GST_VIDEO_FORMAT_Y800:
     case GST_VIDEO_FORMAT_GRAY8:
       return black[7];
     case GST_VIDEO_FORMAT_GRAY16_LE:
     case GST_VIDEO_FORMAT_GRAY16_BE:
-    case GST_VIDEO_FORMAT_Y16:
       return NULL;              /* Handled by the caller */
     case GST_VIDEO_FORMAT_I420:
     case GST_VIDEO_FORMAT_YV12:
@@ -1241,7 +1239,6 @@
           goto unknown_mode;
       }
       break;
-    case GST_VIDEO_FORMAT_Y800:
     case GST_VIDEO_FORMAT_GRAY8:
       if (add_borders)
         vs_fill_borders_Y (&dest[0], black);
@@ -1261,7 +1258,6 @@
       break;
     case GST_VIDEO_FORMAT_GRAY16_LE:
     case GST_VIDEO_FORMAT_GRAY16_BE:
-    case GST_VIDEO_FORMAT_Y16:
       if (add_borders)
         vs_fill_borders_Y16 (&dest[0], 0);
       switch (method) {
diff --git a/gst/videotestsrc/Makefile.in b/gst/videotestsrc/Makefile.in
index 189f93f..9c8db10 100644
--- a/gst/videotestsrc/Makefile.in
+++ b/gst/videotestsrc/Makefile.in
@@ -74,6 +74,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/orc.mak
 EXTRA_PROGRAMS = generate_sine_table$(EXEEXT)
@@ -319,8 +320,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -491,7 +498,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/gst/videotestsrc/gstvideotestsrc.c b/gst/videotestsrc/gstvideotestsrc.c
index e37ce2a..97579bc 100644
--- a/gst/videotestsrc/gstvideotestsrc.c
+++ b/gst/videotestsrc/gstvideotestsrc.c
@@ -79,6 +79,20 @@
 };
 
 
+#define VTS_VIDEO_CAPS GST_VIDEO_CAPS_MAKE (GST_VIDEO_FORMATS_ALL) ";" \
+  "video/x-bayer, format=(string) { bggr, rggb, grbg, gbrg }, "        \
+  "width = " GST_VIDEO_SIZE_RANGE ", "                                 \
+  "height = " GST_VIDEO_SIZE_RANGE ", "                                \
+  "framerate = " GST_VIDEO_FPS_RANGE
+
+
+static GstStaticPadTemplate gst_video_test_src_template =
+GST_STATIC_PAD_TEMPLATE ("src",
+    GST_PAD_SRC,
+    GST_PAD_ALWAYS,
+    GST_STATIC_CAPS (VTS_VIDEO_CAPS)
+    );
+
 #define gst_video_test_src_parent_class parent_class
 G_DEFINE_TYPE (GstVideoTestSrc, gst_video_test_src, GST_TYPE_PUSH_SRC);
 
@@ -89,8 +103,6 @@
 static void gst_video_test_src_get_property (GObject * object, guint prop_id,
     GValue * value, GParamSpec * pspec);
 
-static GstCaps *gst_video_test_src_getcaps (GstBaseSrc * bsrc,
-    GstCaps * filter);
 static gboolean gst_video_test_src_setcaps (GstBaseSrc * bsrc, GstCaps * caps);
 static GstCaps *gst_video_test_src_src_fixate (GstBaseSrc * bsrc,
     GstCaps * caps);
@@ -154,7 +166,6 @@
   GstElementClass *gstelement_class;
   GstBaseSrcClass *gstbasesrc_class;
   GstPushSrcClass *gstpushsrc_class;
-  GstCaps *templ_caps;
 
   gobject_class = (GObjectClass *) klass;
   gstelement_class = (GstElementClass *) klass;
@@ -268,12 +279,9 @@
       "Video test source", "Source/Video",
       "Creates a test video stream", "David A. Schleef <ds@schleef.org>");
 
-  templ_caps = gst_video_test_src_getcaps (NULL, NULL);
   gst_element_class_add_pad_template (gstelement_class,
-      gst_pad_template_new ("src", GST_PAD_SRC, GST_PAD_ALWAYS, templ_caps));
-  gst_caps_unref (templ_caps);
+      gst_static_pad_template_get (&gst_video_test_src_template));
 
-  gstbasesrc_class->get_caps = gst_video_test_src_getcaps;
   gstbasesrc_class->set_caps = gst_video_test_src_setcaps;
   gstbasesrc_class->fixate = gst_video_test_src_src_fixate;
   gstbasesrc_class->is_seekable = gst_video_test_src_is_seekable;
@@ -539,45 +547,15 @@
   }
 }
 
-/* threadsafe because this gets called as the plugin is loaded */
-static GstCaps *
-gst_video_test_src_getcaps (GstBaseSrc * bsrc, GstCaps * filter)
-{
-  static GstCaps *capslist = NULL;
-
-  if (!capslist) {
-    GstCaps *caps;
-    GstStructure *structure;
-    int i;
-
-    caps = gst_caps_new_empty ();
-    for (i = 0; i < n_formats; i++) {
-      structure = paint_get_structure (format_list + i);
-      gst_structure_set (structure,
-          "width", GST_TYPE_INT_RANGE, 1, G_MAXINT,
-          "height", GST_TYPE_INT_RANGE, 1, G_MAXINT,
-          "framerate", GST_TYPE_FRACTION_RANGE, 0, 1, G_MAXINT, 1, NULL);
-      gst_caps_append_structure (caps, structure);
-    }
-
-    capslist = caps;
-  }
-
-  if (filter)
-    return gst_caps_intersect_full (filter, capslist, GST_CAPS_INTERSECT_FIRST);
-  else
-    return gst_caps_ref (capslist);
-}
-
 static gboolean
 gst_video_test_src_parse_caps (const GstCaps * caps,
     gint * width, gint * height, gint * fps_n, gint * fps_d,
-    GstVideoColorimetry * colorimetry)
+    GstVideoColorimetry * colorimetry, gint * x_inv, gint * y_inv)
 {
   const GstStructure *structure;
   GstPadLinkReturn ret;
   const GValue *framerate;
-  const gchar *csp;
+  const gchar *str;
 
   GST_DEBUG ("parsing caps");
 
@@ -593,9 +571,23 @@
   } else
     goto no_framerate;
 
-  if ((csp = gst_structure_get_string (structure, "colorimetry")))
-    gst_video_colorimetry_from_string (colorimetry, csp);
+  if ((str = gst_structure_get_string (structure, "colorimetry")))
+    gst_video_colorimetry_from_string (colorimetry, str);
 
+  if ((str = gst_structure_get_string (structure, "format"))) {
+    if (g_str_equal (str, "bggr")) {
+      *x_inv = *y_inv = 0;
+    } else if (g_str_equal (str, "rggb")) {
+      *x_inv = *y_inv = 1;
+    } else if (g_str_equal (str, "grbg")) {
+      *x_inv = 0;
+      *y_inv = 1;
+    } else if (g_str_equal (str, "grbg")) {
+      *x_inv = 1;
+      *y_inv = 0;
+    } else
+      goto invalid_format;
+  }
   return ret;
 
   /* ERRORS */
@@ -604,6 +596,11 @@
     GST_DEBUG ("videotestsrc no framerate given");
     return FALSE;
   }
+invalid_format:
+  {
+    GST_DEBUG ("videotestsrc invalid bayer format given");
+    return FALSE;
+  }
 }
 
 static gboolean
@@ -632,7 +629,10 @@
 
   /* no downstream pool, make our own */
   if (pool == NULL) {
-    pool = gst_video_buffer_pool_new ();
+    if (videotestsrc->bayer)
+      pool = gst_buffer_pool_new ();
+    else
+      pool = gst_video_buffer_pool_new ();
   }
 
   config = gst_buffer_pool_get_config (pool);
@@ -656,7 +656,6 @@
 static gboolean
 gst_video_test_src_setcaps (GstBaseSrc * bsrc, GstCaps * caps)
 {
-  struct format_list_struct *format;
   const GstStructure *structure;
   GstVideoTestSrc *videotestsrc;
   GstVideoInfo info;
@@ -671,19 +670,25 @@
       goto parse_failed;
 
   } else if (gst_structure_has_name (structure, "video/x-bayer")) {
+    gint x_inv = 0, y_inv = 0;
+
+    gst_video_info_init (&info);
+
+    info.finfo = gst_video_format_get_info (GST_VIDEO_FORMAT_GRAY8);
+
     if (!gst_video_test_src_parse_caps (caps, &info.width, &info.height,
-            &info.fps_n, &info.fps_d, &info.colorimetry))
+            &info.fps_n, &info.fps_d, &info.colorimetry, &x_inv, &y_inv))
       goto parse_failed;
 
-    info.size =
-        gst_video_test_src_get_size (videotestsrc, info.width, info.height);
+    info.size = GST_ROUND_UP_4 (info.width) * info.height;
+    info.stride[0] = GST_ROUND_UP_4 (info.width);
+
+    videotestsrc->bayer = TRUE;
+    videotestsrc->x_invert = x_inv;
+    videotestsrc->y_invert = y_inv;
   }
 
-  if (!(format = paintinfo_find_by_structure (structure)))
-    goto unknown_format;
-
   /* looks ok here */
-  videotestsrc->format = format;
   videotestsrc->info = info;
 
   GST_DEBUG_OBJECT (videotestsrc, "size %dx%d, %d/%d fps",
@@ -692,9 +697,11 @@
   g_free (videotestsrc->tmpline);
   g_free (videotestsrc->tmpline2);
   g_free (videotestsrc->tmpline_u8);
+  g_free (videotestsrc->tmpline_u16);
   videotestsrc->tmpline_u8 = g_malloc (info.width + 8);
   videotestsrc->tmpline = g_malloc ((info.width + 8) * 4);
   videotestsrc->tmpline2 = g_malloc ((info.width + 8) * 4);
+  videotestsrc->tmpline_u16 = g_malloc ((info.width + 16) * 8);
 
   return TRUE;
 
@@ -704,11 +711,6 @@
     GST_DEBUG_OBJECT (bsrc, "failed to parse caps");
     return FALSE;
   }
-unknown_format:
-  {
-    GST_DEBUG ("videotestsrc format not found");
-    return FALSE;
-  }
 }
 
 static gboolean
@@ -809,7 +811,8 @@
 
   src = GST_VIDEO_TEST_SRC (psrc);
 
-  if (G_UNLIKELY (src->format == NULL))
+  if (G_UNLIKELY (GST_VIDEO_INFO_FORMAT (&src->info) ==
+          GST_VIDEO_FORMAT_UNKNOWN))
     goto not_negotiated;
 
   /* 0 framerate and we are at the second frame, eos */
@@ -884,6 +887,8 @@
   src->tmpline2 = NULL;
   g_free (src->tmpline_u8);
   src->tmpline_u8 = NULL;
+  g_free (src->tmpline_u16);
+  src->tmpline_u16 = NULL;
 
   return TRUE;
 }
diff --git a/gst/videotestsrc/gstvideotestsrc.h b/gst/videotestsrc/gstvideotestsrc.h
index d07c350..f64837e 100644
--- a/gst/videotestsrc/gstvideotestsrc.h
+++ b/gst/videotestsrc/gstvideotestsrc.h
@@ -124,9 +124,9 @@
 
   /* video state */
   GstVideoInfo info;
-
-  char *format_name;
-  struct format_list_struct *format;
+  gboolean bayer;
+  gint x_invert;
+  gint y_invert;
 
   /* private */
   gint64 timestamp_offset;              /* base offset */
@@ -161,6 +161,7 @@
   guint8 *tmpline_u8;
   guint8 *tmpline;
   guint8 *tmpline2;
+  guint16 *tmpline_u16;
 };
 
 struct _GstVideoTestSrcClass {
diff --git a/gst/videotestsrc/videotestsrc.c b/gst/videotestsrc/videotestsrc.c
index 53ff9c1..d0a39bc 100644
--- a/gst/videotestsrc/videotestsrc.c
+++ b/gst/videotestsrc/videotestsrc.c
@@ -33,10 +33,6 @@
 #include <stdlib.h>
 
 #define TO_16(x) (((x)<<8) | (x))
-#define TO_10(x) (((x)<<2) | ((x)>>6))
-
-static void paint_tmpline_ARGB (paintinfo * p, int x, int w);
-static void paint_tmpline_AYUV (paintinfo * p, int x, int w);
 
 static unsigned char
 random_char (void)
@@ -125,342 +121,11 @@
 };
 
 
-static void paint_setup_I420_YV12 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_YUY2 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_UYVY (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_YVYU (paintinfo * p, GstVideoFrame * frame);
-#ifdef disabled
-static void paint_setup_IYU2 (paintinfo * p, GstVideoFrame * frame);
-#endif
-static void paint_setup_Y41B (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_Y42B (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_Y444 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_Y800 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_AYUV (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_v308 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_NV12 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_NV21 (paintinfo * p, GstVideoFrame * frame);
-#ifdef disabled
-static void paint_setup_v410 (paintinfo * p, GstVideoFrame * frame);
-#endif
-static void paint_setup_v216 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_v210 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_UYVP (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_AY64 (paintinfo * p, GstVideoFrame * frame);
+static void paint_tmpline_ARGB (paintinfo * p, int x, int w);
+static void paint_tmpline_AYUV (paintinfo * p, int x, int w);
 
-static void paint_setup_YUV9 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_YVU9 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_ARGB8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_ABGR8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_RGBA8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_BGRA8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_xRGB8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_xBGR8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_RGBx8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_BGRx8888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_RGB888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_BGR888 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_RGB565 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_xRGB1555 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_ARGB64 (paintinfo * p, GstVideoFrame * frame);
-
-static void paint_setup_bayer_bggr (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_bayer_rggb (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_bayer_gbrg (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_bayer_grbg (paintinfo * p, GstVideoFrame * frame);
-
-static void convert_hline_I420 (paintinfo * p, int y);
-static void convert_hline_NV12 (paintinfo * p, int y);
-static void convert_hline_NV21 (paintinfo * p, int y);
-static void convert_hline_YUY2 (paintinfo * p, int y);
-#ifdef disabled
-static void convert_hline_IYU2 (paintinfo * p, int y);
-#endif
-static void convert_hline_Y41B (paintinfo * p, int y);
-static void convert_hline_Y42B (paintinfo * p, int y);
-static void convert_hline_Y444 (paintinfo * p, int y);
-static void convert_hline_Y800 (paintinfo * p, int y);
-static void convert_hline_v308 (paintinfo * p, int y);
-static void convert_hline_AYUV (paintinfo * p, int y);
-#ifdef disabled
-static void convert_hline_v410 (paintinfo * p, int y);
-#endif
-static void convert_hline_v216 (paintinfo * p, int y);
-static void convert_hline_v210 (paintinfo * p, int y);
-static void convert_hline_UYVP (paintinfo * p, int y);
-static void convert_hline_AY64 (paintinfo * p, int y);
-
-static void convert_hline_YUV9 (paintinfo * p, int y);
-static void convert_hline_astr4 (paintinfo * p, int y);
-static void convert_hline_astr8 (paintinfo * p, int y);
-static void convert_hline_str4 (paintinfo * p, int y);
-static void convert_hline_str3 (paintinfo * p, int y);
-static void convert_hline_RGB565 (paintinfo * p, int y);
-static void convert_hline_xRGB1555 (paintinfo * p, int y);
-
-static void convert_hline_bayer (paintinfo * p, int y);
-
-static void paint_setup_GRAY8 (paintinfo * p, GstVideoFrame * frame);
-static void paint_setup_GRAY16 (paintinfo * p, GstVideoFrame * frame);
-static void convert_hline_GRAY8 (paintinfo * p, int y);
-static void convert_hline_GRAY16 (paintinfo * p, int y);
-
-struct format_list_struct format_list[] = {
-/* packed */
-  {VTS_YUV, "YUY2", "YUY2", 16, paint_setup_YUY2, convert_hline_YUY2},
-  {VTS_YUV, "UYVY", "UYVY", 16, paint_setup_UYVY, convert_hline_YUY2},
-#ifdef disabled
-  {VTS_YUV, "Y422", "Y422", 16, paint_setup_UYVY, convert_hline_YUY2},
-  {VTS_YUV, "UYNV", "UYNV", 16, paint_setup_UYVY, convert_hline_YUY2},  /* FIXME: UYNV? */
-#endif
-  {VTS_YUV, "YVYU", "YVYU", 16, paint_setup_YVYU, convert_hline_YUY2},
-  {VTS_YUV, "v308", "v308", 24, paint_setup_v308, convert_hline_v308},
-  {VTS_YUV, "AYUV", "AYUV", 32, paint_setup_AYUV, convert_hline_AYUV},
-#ifdef disabled
-  {VTS_YUV, "v410", "v410", 32, paint_setup_v410, convert_hline_v410},
-#endif
-  {VTS_YUV, "v210", "v210", 21, paint_setup_v210, convert_hline_v210},
-  {VTS_YUV, "v216", "v216", 32, paint_setup_v216, convert_hline_v216},
-  {VTS_YUV, "UYVP", "UYVP", 20, paint_setup_UYVP, convert_hline_UYVP},
-  {VTS_YUV, "AY64", "AY64", 64, paint_setup_AY64, convert_hline_AY64},
-
-#ifdef disabled
-  {VTS_YUV, "IYU2", "IYU2", 24, paint_setup_IYU2, convert_hline_IYU2},
-#endif
-
-/* planar */
-  /* YVU9 */
-  {VTS_YUV, "YVU9", "YVU9", 9, paint_setup_YVU9, convert_hline_YUV9},
-  /* YUV9 */
-  {VTS_YUV, "YUV9", "YUV9", 9, paint_setup_YUV9, convert_hline_YUV9},
-  /* IF09 */
-  /* YV12 */
-  {VTS_YUV, "YV12", "YV12", 12, paint_setup_I420_YV12, convert_hline_I420},
-  /* I420 */
-  {VTS_YUV, "I420", "I420", 12, paint_setup_I420_YV12, convert_hline_I420},
-  /* NV12 */
-  {VTS_YUV, "NV12", "NV12", 12, paint_setup_NV12, convert_hline_NV12},
-  /* NV21 */
-  {VTS_YUV, "NV21", "NV21", 12, paint_setup_NV21, convert_hline_NV21},
-  /* CLPL */
-  /* Y41B */
-  {VTS_YUV, "Y41B", "Y41B", 12, paint_setup_Y41B, convert_hline_Y41B},
-  /* Y42B */
-  {VTS_YUV, "Y42B", "Y42B", 16, paint_setup_Y42B, convert_hline_Y42B},
-  /* Y444 */
-  {VTS_YUV, "Y444", "Y444", 24, paint_setup_Y444, convert_hline_Y444},
-  /* Y800 grayscale */
-  {VTS_YUV, "Y800", "Y800", 8, paint_setup_Y800, convert_hline_Y800},
-
-  /* Not exactly YUV but it's the same as above */
-  {VTS_GRAY, "GRAY8", "GRAY8", 8, paint_setup_GRAY8, convert_hline_GRAY8},
-#if G_BYTE_ORDER == G_LITTLE_ENDIAN
-  {VTS_GRAY, "GRAY16_LE", "GRAY16", 16, paint_setup_GRAY16,
-      convert_hline_GRAY16},
-#else
-  {VTS_GRAY, "GRAY16_BE", "GRAY16", 16, paint_setup_GRAY16,
-      convert_hline_GRAY16},
-#endif
-
-  {VTS_RGB, "xRGB", "xRGB8888", 32, paint_setup_xRGB8888, convert_hline_str4,
-        24,
-      0x00ff0000, 0x0000ff00, 0x000000ff},
-  {VTS_RGB, "xBGR", "xBGR8888", 32, paint_setup_xBGR8888, convert_hline_str4,
-        24,
-      0x000000ff, 0x0000ff00, 0x00ff0000},
-  {VTS_RGB, "RGBx", "RGBx8888", 32, paint_setup_RGBx8888, convert_hline_str4,
-        24,
-      0xff000000, 0x00ff0000, 0x0000ff00},
-  {VTS_RGB, "BGRx", "BGRx8888", 32, paint_setup_BGRx8888, convert_hline_str4,
-        24,
-      0x0000ff00, 0x00ff0000, 0xff000000},
-  {VTS_RGB, "ARGB", "ARGB8888", 32, paint_setup_ARGB8888, convert_hline_astr4,
-        32,
-      0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000},
-  {VTS_RGB, "ABGR", "ABGR8888", 32, paint_setup_ABGR8888, convert_hline_astr4,
-        32,
-      0x000000ff, 0x0000ff00, 0x00ff0000, 0xff000000},
-  {VTS_RGB, "RGBA", "RGBA8888", 32, paint_setup_RGBA8888, convert_hline_astr4,
-        32,
-      0xff000000, 0x00ff0000, 0x0000ff00, 0x000000ff},
-  {VTS_RGB, "BGRA", "BGRA8888", 32, paint_setup_BGRA8888, convert_hline_astr4,
-        32,
-      0x0000ff00, 0x00ff0000, 0xff000000, 0x000000ff},
-  {VTS_RGB, "RGB", "RGB888", 24, paint_setup_RGB888, convert_hline_str3, 24,
-      0x00ff0000, 0x0000ff00, 0x000000ff},
-  {VTS_RGB, "BGR", "BGR888", 24, paint_setup_BGR888, convert_hline_str3, 24,
-      0x000000ff, 0x0000ff00, 0x00ff0000},
-  {VTS_RGB, "RGB16", "RGB565", 16, paint_setup_RGB565, convert_hline_RGB565, 16,
-      0x0000f800, 0x000007e0, 0x0000001f},
-  {VTS_RGB, "RGB15", "xRGB1555", 16, paint_setup_xRGB1555,
-        convert_hline_xRGB1555,
-        15,
-      0x00007c00, 0x000003e0, 0x0000001f},
-  {VTS_RGB, "ARGB64", "ARGB8888", 64, paint_setup_ARGB64, convert_hline_astr8,
-        64,
-      0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000},
-
-  {VTS_BAYER, "bggr", "Bayer", 8, paint_setup_bayer_bggr, convert_hline_bayer},
-  {VTS_BAYER, "rggb", "Bayer", 8, paint_setup_bayer_rggb, convert_hline_bayer},
-  {VTS_BAYER, "grbg", "Bayer", 8, paint_setup_bayer_grbg, convert_hline_bayer},
-  {VTS_BAYER, "gbrg", "Bayer", 8, paint_setup_bayer_gbrg, convert_hline_bayer}
-};
-
-int n_formats = G_N_ELEMENTS (format_list);
-
-struct format_list_struct *
-paintinfo_find_by_structure (const GstStructure * structure)
-{
-  int i;
-  const char *media_type = gst_structure_get_name (structure);
-
-  g_return_val_if_fail (structure, NULL);
-
-  if (strcmp (media_type, "video/x-raw") == 0) {
-    const gchar *format;
-
-    format = gst_structure_get_string (structure, "format");
-    if (!format) {
-      GST_WARNING ("incomplete caps structure: %" GST_PTR_FORMAT, structure);
-      return NULL;
-    }
-
-    for (i = 0; i < n_formats; i++) {
-      if (g_str_equal (format, format_list[i].format)) {
-        return format_list + i;
-      }
-    }
-    return NULL;
-  } else if (strcmp (media_type, "video/x-bayer") == 0) {
-    const gchar *format;
-
-    format = gst_structure_get_string (structure, "format");
-    if (!format) {
-      GST_WARNING ("incomplete caps structure: %" GST_PTR_FORMAT, structure);
-      return NULL;
-    }
-
-    for (i = 0; i < n_formats; i++) {
-      if (format_list[i].type == VTS_BAYER &&
-          g_str_equal (format, format_list[i].format)) {
-        return format_list + i;
-      }
-    }
-    return NULL;
-  }
-
-  g_critical ("format not found for media type %s", media_type);
-
-  return NULL;
-}
-
-struct format_list_struct *
-paintrect_find_format (const gchar * find_format)
-{
-  int i;
-
-  for (i = 0; i < n_formats; i++) {
-    if (g_str_equal (find_format, format_list[i].format)) {
-      return format_list + i;
-    }
-  }
-  return NULL;
-}
-
-struct format_list_struct *
-paintrect_find_name (const char *name)
-{
-  int i;
-
-  for (i = 0; i < n_formats; i++) {
-    if (g_str_equal (name, format_list[i].name)) {
-      return format_list + i;
-    }
-  }
-  return NULL;
-}
-
-
-GstStructure *
-paint_get_structure (struct format_list_struct * format)
-{
-  GstStructure *structure = NULL;
-
-  g_return_val_if_fail (format, NULL);
-
-  switch (format->type) {
-    case VTS_RGB:
-    case VTS_GRAY:
-      structure = gst_structure_new ("video/x-raw",
-          "format", G_TYPE_STRING, format->format, NULL);
-      break;
-    case VTS_YUV:
-    {
-      GValue value_list = { 0 };
-      GValue value = { 0 };
-
-      structure = gst_structure_new ("video/x-raw",
-          "format", G_TYPE_STRING, format->format, NULL);
-
-      if (strcmp (format->format, "Y800") != 0) {
-        g_value_init (&value_list, GST_TYPE_LIST);
-
-        g_value_init (&value, G_TYPE_STRING);
-        g_value_set_static_string (&value, "bt601");
-        gst_value_list_append_value (&value_list, &value);
-
-        g_value_set_static_string (&value, "bt709");
-        gst_value_list_append_value (&value_list, &value);
-
-        gst_structure_set_value (structure, "colorimetry", &value_list);
-        g_value_reset (&value_list);
-
-        if (strcmp (format->format, "AYUV") &&
-            strcmp (format->format, "v308") &&
-            strcmp (format->format, "v410") &&
-            strcmp (format->format, "Y444")) {
-          g_value_set_static_string (&value, "mpeg2");
-          gst_value_list_append_value (&value_list, &value);
-
-          g_value_set_static_string (&value, "jpeg");
-          gst_value_list_append_value (&value_list, &value);
-
-          gst_structure_set_value (structure, "chroma-site", &value_list);
-        }
-        g_value_unset (&value_list);
-      }
-      break;
-    }
-    case VTS_BAYER:
-      structure = gst_structure_new ("video/x-bayer",
-          "format", G_TYPE_STRING, format->format, NULL);
-      break;
-    default:
-      g_assert_not_reached ();
-      break;
-  }
-  return structure;
-}
-
-/* returns the size in bytes for one video frame of the given dimensions
- * given the format in GstVideoTestSrc */
-int
-gst_video_test_src_get_size (GstVideoTestSrc * v, int w, int h)
-{
-  paintinfo pi = { NULL, };
-  paintinfo *p = &pi;
-  struct format_list_struct *format;
-
-  p->width = w;
-  p->height = h;
-  format = v->format;
-  if (format == NULL)
-    return 0;
-
-  format->paint_setup (p, NULL);
-
-  return p->size;
-}
+static void convert_hline_generic (paintinfo * p, GstVideoFrame * frame, int y);
+static void convert_hline_bayer (paintinfo * p, GstVideoFrame * frame, int y);
 
 #define SCALEBITS 10
 #define ONE_HALF  (1 << (SCALEBITS - 1))
@@ -505,28 +170,38 @@
 static void
 videotestsrc_setup_paintinfo (GstVideoTestSrc * v, paintinfo * p, int w, int h)
 {
-  int a, r, g, b;
+  gint a, r, g, b;
+  gint width;
+  GstVideoInfo *info = &v->info;
 
-  if (v->info.colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT601) {
+  width = GST_VIDEO_INFO_WIDTH (info);
+
+  if (info->colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT601) {
     p->colors = vts_colors_bt601_ycbcr_100;
   } else {
     p->colors = vts_colors_bt709_ycbcr_100;
   }
-  p->width = w;
-  p->height = h;
 
-  p->convert_tmpline = v->format->convert_hline;
-  if (v->format->type == VTS_RGB || v->format->type == VTS_BAYER) {
+  if (v->bayer) {
     p->paint_tmpline = paint_tmpline_ARGB;
+    p->convert_tmpline = convert_hline_bayer;
   } else {
-    p->paint_tmpline = paint_tmpline_AYUV;
+    p->convert_tmpline = convert_hline_generic;
+    if (GST_VIDEO_INFO_IS_RGB (info)) {
+      p->paint_tmpline = paint_tmpline_ARGB;
+    } else {
+      p->paint_tmpline = paint_tmpline_AYUV;
+    }
   }
   p->tmpline = v->tmpline;
   p->tmpline2 = v->tmpline2;
   p->tmpline_u8 = v->tmpline_u8;
-  p->x_offset = (v->horizontal_speed * v->n_frames) % p->width;
+  p->tmpline_u16 = v->tmpline_u16;
+  p->x_offset = (v->horizontal_speed * v->n_frames) % width;
   if (p->x_offset < 0)
-    p->x_offset += p->width;
+    p->x_offset += width;
+  p->x_invert = v->x_invert;
+  p->y_invert = v->y_invert;
 
   a = (v->foreground_color >> 24) & 0xff;
   r = (v->foreground_color >> 16) & 0xff;
@@ -536,7 +211,8 @@
   p->foreground_color.R = r;
   p->foreground_color.G = g;
   p->foreground_color.B = b;
-  if (v->info.colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT601) {
+
+  if (info->colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT601) {
     p->foreground_color.Y = RGB_TO_Y_CCIR (r, g, b);
     p->foreground_color.U = RGB_TO_U_CCIR (r, g, b, 0);
     p->foreground_color.V = RGB_TO_V_CCIR (r, g, b, 0);
@@ -555,7 +231,8 @@
   p->background_color.R = r;
   p->background_color.G = g;
   p->background_color.B = b;
-  if (v->info.colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT601) {
+
+  if (info->colorimetry.matrix == GST_VIDEO_COLOR_MATRIX_BT601) {
     p->background_color.Y = RGB_TO_Y_CCIR (r, g, b);
     p->background_color.U = RGB_TO_U_CCIR (r, g, b, 0);
     p->background_color.V = RGB_TO_V_CCIR (r, g, b, 0);
@@ -569,25 +246,26 @@
 }
 
 static void
-videotestsrc_convert_tmpline (paintinfo * p, int j)
+videotestsrc_convert_tmpline (paintinfo * p, GstVideoFrame * frame, int j)
 {
   int x = p->x_offset;
   int i;
+  int width = frame->info.width;
 
   if (x != 0) {
-    memcpy (p->tmpline2, p->tmpline, p->width * 4);
-    memcpy (p->tmpline, p->tmpline2 + x * 4, (p->width - x) * 4);
-    memcpy (p->tmpline + (p->width - x) * 4, p->tmpline2, x * 4);
+    memcpy (p->tmpline2, p->tmpline, width * 4);
+    memcpy (p->tmpline, p->tmpline2 + x * 4, (width - x) * 4);
+    memcpy (p->tmpline + (width - x) * 4, p->tmpline2, x * 4);
   }
 
-  for (i = p->width; i < p->width + 5; i++) {
-    p->tmpline[4 * i + 0] = p->tmpline[4 * (p->width - 1) + 0];
-    p->tmpline[4 * i + 1] = p->tmpline[4 * (p->width - 1) + 1];
-    p->tmpline[4 * i + 2] = p->tmpline[4 * (p->width - 1) + 2];
-    p->tmpline[4 * i + 3] = p->tmpline[4 * (p->width - 1) + 3];
+  for (i = width; i < width + 5; i++) {
+    p->tmpline[4 * i + 0] = p->tmpline[4 * (width - 1) + 0];
+    p->tmpline[4 * i + 1] = p->tmpline[4 * (width - 1) + 1];
+    p->tmpline[4 * i + 2] = p->tmpline[4 * (width - 1) + 2];
+    p->tmpline[4 * i + 3] = p->tmpline[4 * (width - 1) + 3];
   }
 
-  p->convert_tmpline (p, j);
+  p->convert_tmpline (p, frame, j);
 }
 
 #define BLEND1(a,b,x) ((a)*(x) + (b)*(255-(x)))
@@ -615,7 +293,7 @@
     struct vts_color_struct *a, struct vts_color_struct *b, int n)
 {
   int i;
-  if (v->format->type == VTS_RGB || v->format->type == VTS_BAYER) {
+  if (v->bayer || GST_VIDEO_INFO_IS_RGB (&v->info)) {
     for (i = 0; i < n; i++) {
       dest[i * 4 + 0] = BLEND (a->A, b->A, src[i]);
       dest[i * 4 + 1] = BLEND (a->R, b->R, src[i]);
@@ -639,17 +317,11 @@
   int i;
   int y1, y2;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
-  videotestsrc_setup_paintinfo (v, p, frame->info.width, frame->info.height);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
+  videotestsrc_setup_paintinfo (v, p, w, h);
 
   y1 = 2 * h / 3;
   y2 = 3 * h / 4;
@@ -663,7 +335,7 @@
       p->color = p->colors + i;
       p->paint_tmpline (p, x1, (x2 - x1));
     }
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 
   /* inverse blue bars */
@@ -681,7 +353,7 @@
       p->color = p->colors + k;
       p->paint_tmpline (p, x1, (x2 - x1));
     }
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 
   for (j = y2; j < h; j++) {
@@ -734,7 +406,7 @@
           &p->foreground_color, &p->background_color, w - x1);
 
     }
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
 
   }
 }
@@ -744,9 +416,8 @@
 {
   int i;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
@@ -755,11 +426,6 @@
   } else {
     p->colors = vts_colors_bt709_ycbcr_75;
   }
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   /* color bars */
   for (j = 0; j < h; j++) {
@@ -770,7 +436,7 @@
       p->color = p->colors + i;
       p->paint_tmpline (p, x1, (x2 - x1));
     }
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -779,17 +445,11 @@
 {
   int i;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   /* color bars */
   for (j = 0; j < h; j++) {
@@ -800,7 +460,7 @@
       p->color = p->colors + i;
       p->paint_tmpline (p, x1, (x2 - x1));
     }
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -808,17 +468,11 @@
 gst_video_test_src_bar (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   for (j = 0; j < h; j++) {
     /* use fixed size for now */
@@ -828,7 +482,7 @@
     p->paint_tmpline (p, 0, x2);
     p->color = &p->background_color;
     p->paint_tmpline (p, x2, (w - x2));
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -837,18 +491,12 @@
 {
   int i;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   struct vts_color_struct color;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   color = p->colors[COLOR_BLACK];
   p->color = &color;
@@ -859,8 +507,8 @@
       p->tmpline_u8[i] = y;
     }
     videotestsrc_blend_line (v, p->tmpline, p->tmpline_u8,
-        &p->foreground_color, &p->background_color, p->width);
-    videotestsrc_convert_tmpline (p, j);
+        &p->foreground_color, &p->background_color, w);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -869,17 +517,11 @@
     int color_index)
 {
   int i;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   p->color = p->colors + color_index;
   if (color_index == COLOR_BLACK) {
@@ -891,7 +533,7 @@
 
   for (i = 0; i < h; i++) {
     p->paint_tmpline (p, 0, w);
-    videotestsrc_convert_tmpline (p, i);
+    videotestsrc_convert_tmpline (p, frame, i);
   }
 }
 
@@ -929,19 +571,12 @@
 gst_video_test_src_blink (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int i;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
 
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
-
   if (v->n_frames & 1) {
     p->color = &p->foreground_color;
   } else {
@@ -950,7 +585,7 @@
 
   for (i = 0; i < h; i++) {
     p->paint_tmpline (p, 0, w);
-    videotestsrc_convert_tmpline (p, i);
+    videotestsrc_convert_tmpline (p, frame, i);
   }
 }
 
@@ -958,24 +593,17 @@
 gst_video_test_src_solid (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int i;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
 
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
-
   p->color = &p->foreground_color;
 
   for (i = 0; i < h; i++) {
     p->paint_tmpline (p, 0, w);
-    videotestsrc_convert_tmpline (p, i);
+    videotestsrc_convert_tmpline (p, frame, i);
   }
 }
 
@@ -983,19 +611,12 @@
 gst_video_test_src_checkers1 (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int x, y;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
 
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
-
   for (y = 0; y < h; y++) {
     for (x = 0; x < w; x++) {
       if ((x ^ y) & 1) {
@@ -1005,7 +626,7 @@
       }
       p->paint_tmpline (p, x, 1);
     }
-    videotestsrc_convert_tmpline (p, y);
+    videotestsrc_convert_tmpline (p, frame, y);
   }
 }
 
@@ -1013,17 +634,11 @@
 gst_video_test_src_checkers2 (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int x, y;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   for (y = 0; y < h; y++) {
     for (x = 0; x < w; x += 2) {
@@ -1036,7 +651,7 @@
       }
       p->paint_tmpline (p, x, len);
     }
-    videotestsrc_convert_tmpline (p, y);
+    videotestsrc_convert_tmpline (p, frame, y);
   }
 }
 
@@ -1044,17 +659,11 @@
 gst_video_test_src_checkers4 (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int x, y;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   for (y = 0; y < h; y++) {
     for (x = 0; x < w; x += 4) {
@@ -1067,7 +676,7 @@
       }
       p->paint_tmpline (p, x, len);
     }
-    videotestsrc_convert_tmpline (p, y);
+    videotestsrc_convert_tmpline (p, frame, y);
   }
 }
 
@@ -1075,17 +684,11 @@
 gst_video_test_src_checkers8 (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int x, y;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   for (y = 0; y < h; y++) {
     for (x = 0; x < w; x += 8) {
@@ -1098,7 +701,7 @@
       }
       p->paint_tmpline (p, x, len);
     }
-    videotestsrc_convert_tmpline (p, y);
+    videotestsrc_convert_tmpline (p, frame, y);
   }
 }
 
@@ -1143,9 +746,8 @@
 {
   int i;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   struct vts_color_struct color;
   int t = v->n_frames;
   int w = frame->info.width, h = frame->info.height;
@@ -1167,11 +769,6 @@
   int scale_kx2 = 0xffff / w;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   color = p->colors[COLOR_BLACK];
   p->color = &color;
@@ -1254,8 +851,8 @@
       p->tmpline_u8[i] = sine_table[phase & 0xff];
     }
     videotestsrc_blend_line (v, p->tmpline, p->tmpline_u8,
-        &p->foreground_color, &p->background_color, p->width);
-    videotestsrc_convert_tmpline (p, j);
+        &p->foreground_color, &p->background_color, w);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -1264,9 +861,8 @@
 {
   int i;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   struct vts_color_struct color;
   int t = v->n_frames;
   int w = frame->info.width, h = frame->info.height;
@@ -1289,11 +885,6 @@
   int scale_kx2 = 0xffff / w;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   color = p->colors[COLOR_BLACK];
   p->color = &color;
@@ -1354,7 +945,7 @@
       color.gray = color.Y << 8;
       p->paint_tmpline (p, i, 1);
     }
-    videotestsrc_convert_tmpline (p, j);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -1364,20 +955,14 @@
 {
   int i;
   int j;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   double freq[8];
   int w = frame->info.width, h = frame->info.height;
 
   int d;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   for (i = 1; i < 8; i++) {
     freq[i] = 200 * pow (2.0, -(i - 1) / 4.0);
@@ -1400,8 +985,8 @@
       }
     }
     videotestsrc_blend_line (v, p->tmpline, p->tmpline_u8,
-        &p->foreground_color, &p->background_color, p->width);
-    videotestsrc_convert_tmpline (p, j);
+        &p->foreground_color, &p->background_color, w);
+    videotestsrc_convert_tmpline (p, frame, j);
   }
 }
 
@@ -1409,19 +994,13 @@
 gst_video_test_src_gamut (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int x, y;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   struct vts_color_struct yuv_primary;
   struct vts_color_struct yuv_secondary;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   for (y = 0; y < h; y++) {
     int region = (y * 4) / h;
@@ -1459,7 +1038,7 @@
       }
       p->paint_tmpline (p, x, len);
     }
-    videotestsrc_convert_tmpline (p, y);
+    videotestsrc_convert_tmpline (p, frame, y);
   }
 }
 
@@ -1467,20 +1046,14 @@
 gst_video_test_src_ball (GstVideoTestSrc * v, GstVideoFrame * frame)
 {
   int i;
-  paintinfo pi = { NULL, };
+  paintinfo pi = PAINT_INFO_INIT;
   paintinfo *p = &pi;
-  struct format_list_struct *format;
   int t = v->n_frames;
   double x, y;
   int radius = 20;
   int w = frame->info.width, h = frame->info.height;
 
   videotestsrc_setup_paintinfo (v, p, w, h);
-  format = v->format;
-  if (format == NULL)
-    return;
-
-  format->paint_setup (p, frame);
 
   x = radius + (0.5 + 0.5 * sin (2 * G_PI * t / 200)) * (w - 2 * radius);
   y = radius + (0.5 + 0.5 * sin (2 * G_PI * sqrt (2) * t / 200)) * (h -
@@ -1516,8 +1089,8 @@
       }
     }
     videotestsrc_blend_line (v, p->tmpline, p->tmpline_u8,
-        &p->foreground_color, &p->background_color, p->width);
-    videotestsrc_convert_tmpline (p, i);
+        &p->foreground_color, &p->background_color, w);
+    videotestsrc_convert_tmpline (p, frame, i);
   }
 }
 
@@ -1558,895 +1131,42 @@
 }
 
 static void
-paint_setup_NV12 (paintinfo * p, GstVideoFrame * frame)
+convert_hline_generic (paintinfo * p, GstVideoFrame * frame, int y)
 {
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->ustride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->vp = p->up + 1;
-  p->vstride = p->ustride;
-  p->size = frame->info.size;
+  const GstVideoFormatInfo *finfo = frame->info.finfo;
+  gint i, width = GST_VIDEO_FRAME_WIDTH (frame);
+  gpointer src;
+
+  if (GST_VIDEO_FORMAT_INFO_DEPTH (finfo, 0) == 16) {
+    /* 16 bits */
+    for (i = 0; i < width; i++) {
+      p->tmpline_u16[i * 4 + 0] = TO_16 (p->tmpline[i * 4 + 0]);
+      p->tmpline_u16[i * 4 + 1] = TO_16 (p->tmpline[i * 4 + 1]);
+      p->tmpline_u16[i * 4 + 2] = TO_16 (p->tmpline[i * 4 + 2]);
+      p->tmpline_u16[i * 4 + 3] = TO_16 (p->tmpline[i * 4 + 3]);
+    }
+    src = p->tmpline_u16;
+  } else {
+    src = p->tmpline;
+  }
+  finfo->pack_func (finfo, GST_VIDEO_PACK_FLAG_NONE,
+      src, 0, frame->data, frame->info.stride,
+      frame->info.chroma_site, y, width);
 }
 
 static void
-paint_setup_NV21 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->vstride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->up = p->vp + 1;
-  p->ustride = p->vstride;
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_I420 (paintinfo * p, int y)
+convert_hline_bayer (paintinfo * p, GstVideoFrame * frame, int y)
 {
   int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + (y / 2) * p->ustride;
-  guint8 *V = p->vp + (y / 2) * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 1) / 2; i++) {
-    U[i] = (ayuv[4 * (i * 2) + 2] + ayuv[4 * (i * 2 + 1) + 2] + 1) >> 1;
-    V[i] = (ayuv[4 * (i * 2) + 3] + ayuv[4 * (i * 2 + 1) + 3] + 1) >> 1;
-  }
-}
-
-static void
-convert_hline_NV12 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + (y / 2) * p->ustride;
-  guint8 *V = p->vp + (y / 2) * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 1) / 2; i++) {
-    U[i * 2] = (ayuv[4 * (i * 2) + 2] + ayuv[4 * (i * 2 + 1) + 2] + 1) >> 1;
-    V[i * 2] = (ayuv[4 * (i * 2) + 3] + ayuv[4 * (i * 2 + 1) + 3] + 1) >> 1;
-  }
-}
-
-static void
-convert_hline_NV21 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + (y / 2) * p->ustride;
-  guint8 *V = p->vp + (y / 2) * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 1) / 2; i++) {
-    U[i * 2] = (ayuv[4 * (i * 2) + 2] + ayuv[4 * (i * 2 + 1) + 2] + 1) >> 1;
-    V[i * 2] = (ayuv[4 * (i * 2) + 3] + ayuv[4 * (i * 2 + 1) + 3] + 1) >> 1;
-  }
-}
-
-static void
-paint_setup_I420_YV12 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_COMP_DATA (frame, GST_VIDEO_COMP_Y);
-  p->ystride = GST_VIDEO_FRAME_COMP_STRIDE (frame, GST_VIDEO_COMP_Y);
-  p->up = GST_VIDEO_FRAME_COMP_DATA (frame, GST_VIDEO_COMP_U);
-  p->ustride = GST_VIDEO_FRAME_COMP_STRIDE (frame, GST_VIDEO_COMP_U);
-  p->vp = GST_VIDEO_FRAME_COMP_DATA (frame, GST_VIDEO_COMP_V);
-  p->vstride = GST_VIDEO_FRAME_COMP_STRIDE (frame, GST_VIDEO_COMP_V);
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_v308 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->yp + 1;
-  p->vp = p->yp + 2;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_AYUV (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap + 1;
-  p->up = p->ap + 2;
-  p->vp = p->ap + 3;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-#ifdef disabled
-static void
-paint_setup_v410 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = dest + 0;
-  p->up = dest + 0;
-  p->vp = dest + 0;
-  p->ystride = p->width * 4;
-  p->endptr = dest + p->ystride * p->height;
-  p->size = frame->info.size;
-}
-#endif
-
-static void
-paint_setup_v216 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap + 2;
-  p->up = p->ap + 0;
-  p->vp = p->ap + 4;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_v210 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap;
-  p->up = p->ap;
-  p->vp = p->ap;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_UYVP (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap;
-  p->up = p->ap;
-  p->vp = p->ap;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_YUY2 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->yp + 1;
-  p->vp = p->yp + 3;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_UYVY (paintinfo * p, GstVideoFrame * frame)
-{
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->up + 1;
-  p->vp = p->up + 2;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_YVYU (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->yp + 3;
-  p->vp = p->yp + 1;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_AY64 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap + 2;
-  p->up = p->ap + 4;
-  p->vp = p->ap + 6;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_v308 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i * 3] = ayuv[4 * i + 1];
-    U[i * 3] = ayuv[4 * i + 2];
-    V[i * 3] = ayuv[4 * i + 3];
-  }
-}
-
-static void
-convert_hline_AYUV (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *A = p->ap + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    A[i * 4] = ayuv[4 * i + 0];
-    Y[i * 4] = ayuv[4 * i + 1];
-    U[i * 4] = ayuv[4 * i + 2];
-    V[i * 4] = ayuv[4 * i + 3];
-  }
-}
-
-static void
-convert_hline_v216 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    GST_WRITE_UINT16_LE (Y + i * 4, TO_16 (ayuv[4 * i + 1]));
-  }
-  for (i = 0; i < (p->width + 1) / 2; i++) {
-    GST_WRITE_UINT16_LE (U + i * 8, TO_16 (ayuv[4 * (i * 2) + 2]));
-    GST_WRITE_UINT16_LE (V + i * 8, TO_16 (ayuv[4 * (i * 2) + 3]));
-  }
-}
-
-#ifdef disabled
-static void
-convert_hline_v410 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    guint32 a;
-
-    a = (TO_10 (ayuv[4 * i + 2]) << 22) |
-        (TO_10 (ayuv[4 * i + 1]) << 12) | (TO_10 (ayuv[4 * i + 3]) << 2);
-    GST_WRITE_UINT32_LE (Y + i * 4, a);
-  }
-}
-#endif
-
-static void
-convert_hline_v210 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width + 5; i += 6) {
-    guint32 a0, a1, a2, a3;
-    guint16 y0, y1, y2, y3, y4, y5;
-    guint16 u0, u1, u2;
-    guint16 v0, v1, v2;
-
-    y0 = ayuv[4 * (i + 0) + 1];
-    y1 = ayuv[4 * (i + 1) + 1];
-    y2 = ayuv[4 * (i + 2) + 1];
-    y3 = ayuv[4 * (i + 3) + 1];
-    y4 = ayuv[4 * (i + 4) + 1];
-    y5 = ayuv[4 * (i + 5) + 1];
-
-    u0 = (ayuv[4 * (i + 0) + 2] + ayuv[4 * (i + 1) + 2] + 1) >> 1;
-    u1 = (ayuv[4 * (i + 2) + 2] + ayuv[4 * (i + 3) + 2] + 1) >> 1;
-    u2 = (ayuv[4 * (i + 4) + 2] + ayuv[4 * (i + 5) + 2] + 1) >> 1;
-
-    v0 = (ayuv[4 * (i + 0) + 3] + ayuv[4 * (i + 1) + 3] + 1) >> 1;
-    v1 = (ayuv[4 * (i + 2) + 3] + ayuv[4 * (i + 3) + 3] + 1) >> 1;
-    v2 = (ayuv[4 * (i + 4) + 3] + ayuv[4 * (i + 5) + 3] + 1) >> 1;
-
-#if 0
-    a0 = TO_10 (ayuv[4 * (i + 0) + 2]) | (TO_10 (ayuv[4 * (i + 0) + 1]) << 10)
-        | (TO_10 (ayuv[4 * (i + 0) + 3]) << 20);
-    a1 = TO_10 (ayuv[4 * (i + 1) + 1]) | (TO_10 (ayuv[4 * (i + 2) + 2]) << 10)
-        | (TO_10 (ayuv[4 * (i + 2) + 1]) << 20);
-    a2 = TO_10 (ayuv[4 * (i + 2) + 3]) | (TO_10 (ayuv[4 * (i + 3) + 1]) << 10)
-        | (TO_10 (ayuv[4 * (i + 4) + 2]) << 20);
-    a3 = TO_10 (ayuv[4 * (i + 4) + 1]) | (TO_10 (ayuv[4 * (i + 4) + 3]) << 10)
-        | (TO_10 (ayuv[4 * (i + 5) + 1]) << 20);
-#endif
-
-    a0 = TO_10 (u0) | (TO_10 (y0) << 10) | (TO_10 (v0) << 20);
-    a1 = TO_10 (y1) | (TO_10 (u1) << 10) | (TO_10 (y2) << 20);
-    a2 = TO_10 (v1) | (TO_10 (y3) << 10) | (TO_10 (u2) << 20);
-    a3 = TO_10 (y4) | (TO_10 (v2) << 10) | (TO_10 (y5) << 20);
-
-    GST_WRITE_UINT32_LE (Y + (i / 6) * 16 + 0, a0);
-    GST_WRITE_UINT32_LE (Y + (i / 6) * 16 + 4, a1);
-    GST_WRITE_UINT32_LE (Y + (i / 6) * 16 + 8, a2);
-    GST_WRITE_UINT32_LE (Y + (i / 6) * 16 + 12, a3);
-  }
-}
-
-static void
-convert_hline_UYVP (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i += 2) {
-    guint16 y0, y1;
-    guint16 u0;
-    guint16 v0;
-
-    y0 = ayuv[4 * (i + 0) + 1];
-    y1 = ayuv[4 * (i + 1) + 1];
-    u0 = (ayuv[4 * (i + 0) + 2] + ayuv[4 * (i + 1) + 2] + 1) >> 1;
-    v0 = (ayuv[4 * (i + 0) + 3] + ayuv[4 * (i + 1) + 3] + 1) >> 1;
-
-    Y[(i / 2) * 5 + 0] = u0;
-    Y[(i / 2) * 5 + 1] = y0 >> 2;
-    Y[(i / 2) * 5 + 2] = (y0 << 6) | (v0 >> 4);
-    Y[(i / 2) * 5 + 3] = (v0 << 4) | (y1 >> 2);
-    Y[(i / 2) * 5 + 4] = (y1 << 2);
-  }
-}
-
-static void
-convert_hline_YUY2 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i * 2] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 1) / 2; i++) {
-    U[4 * i] = (ayuv[4 * (i * 2) + 2] + ayuv[4 * (i * 2 + 1) + 2] + 1) >> 1;
-    V[4 * i] = (ayuv[4 * (i * 2) + 3] + ayuv[4 * (i * 2 + 1) + 3] + 1) >> 1;
-  }
-}
-
-static void
-convert_hline_AY64 (paintinfo * p, int y)
-{
-  int i;
-  guint16 *ayuv16 = (guint16 *) (p->ap + y * p->ystride);
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    GST_WRITE_UINT16_LE (ayuv16 + i * 4 + 0, TO_16 (ayuv[4 * i + 0]));
-    GST_WRITE_UINT16_LE (ayuv16 + i * 4 + 1, TO_16 (ayuv[4 * i + 1]));
-    GST_WRITE_UINT16_LE (ayuv16 + i * 4 + 2, TO_16 (ayuv[4 * i + 2]));
-    GST_WRITE_UINT16_LE (ayuv16 + i * 4 + 3, TO_16 (ayuv[4 * i + 3]));
-  }
-}
-
-#ifdef disabled
-static void
-paint_setup_IYU2 (paintinfo * p, GstVideoFrame * frame)
-{
-  /* untested */
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->up + 1;
-  p->vp = p->up + 2;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_IYU2 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i * 3] = ayuv[4 * i + 1];
-    U[i * 3] = ayuv[4 * i + 2];
-    V[i * 3] = ayuv[4 * i + 3];
-  }
-}
-#endif
-
-static void
-paint_setup_Y41B (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 2);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->vstride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 2);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_Y41B (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 3) / 4; i++) {
-    U[i] = (ayuv[4 * (i * 4) + 2] + ayuv[4 * (i * 4 + 1) + 2] +
-        ayuv[4 * (i * 4 + 2) + 2] + ayuv[4 * (i * 4 + 3) + 2] + 2) >> 2;
-    V[i] = (ayuv[4 * (i * 4) + 3] + ayuv[4 * (i * 4 + 1) + 3] +
-        ayuv[4 * (i * 4 + 2) + 3] + ayuv[4 * (i * 4 + 3) + 3] + 2) >> 2;
-  }
-}
-
-static void
-paint_setup_Y42B (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 2);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->vstride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 2);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_Y42B (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 1) / 2; i++) {
-    U[i] = (ayuv[4 * (i * 2) + 2] + ayuv[4 * (i * 2 + 1) + 2] + 1) >> 1;
-    V[i] = (ayuv[4 * (i * 2) + 3] + ayuv[4 * (i * 2 + 1) + 3] + 1) >> 1;
-  }
-}
-
-static void
-paint_setup_Y444 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 2);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->vstride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 2);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_Y444 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + y * p->ustride;
-  guint8 *V = p->vp + y * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-    U[i] = ayuv[4 * i + 2];
-    V[i] = ayuv[4 * i + 3];
-  }
-}
-
-static void
-paint_setup_Y800 (paintinfo * p, GstVideoFrame * frame)
-{
-  /* untested */
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_Y800 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-}
-
-static void
-paint_setup_YVU9 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 2);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->vstride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 2);
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_YUV9 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = GST_VIDEO_FRAME_PLANE_DATA (frame, 1);
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 2);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 1);
-  p->vstride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 2);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_YUV9 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *U = p->up + (y / 4) * p->ustride;
-  guint8 *V = p->vp + (y / 4) * p->vstride;
-  guint8 *ayuv = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-  for (i = 0; i < (p->width + 3) / 4; i++) {
-    U[i] = (ayuv[4 * (i * 4) + 2] + ayuv[4 * (i * 4 + 1) + 2] +
-        ayuv[4 * (i * 4 + 2) + 2] + ayuv[4 * (i * 4 + 3) + 2] + 2) >> 2;
-    V[i] = (ayuv[4 * (i * 4) + 3] + ayuv[4 * (i * 4 + 1) + 3] +
-        ayuv[4 * (i * 4 + 2) + 3] + ayuv[4 * (i * 4 + 3) + 3] + 2) >> 2;
-  }
-}
-
-static void
-paint_setup_ARGB8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  paint_setup_xRGB8888 (p, frame);
-}
-
-static void
-paint_setup_ABGR8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  paint_setup_xBGR8888 (p, frame);
-}
-
-static void
-paint_setup_RGBA8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  paint_setup_RGBx8888 (p, frame);
-}
-
-static void
-paint_setup_BGRA8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  paint_setup_BGRx8888 (p, frame);
-}
-
-static void
-paint_setup_xRGB8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap + 1;
-  p->up = p->ap + 2;
-  p->vp = p->ap + 3;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_xBGR8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap + 3;
-  p->up = p->ap + 2;
-  p->vp = p->ap + 1;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_RGBx8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->yp + 1;
-  p->vp = p->yp + 2;
-  p->ap = p->yp + 3;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_BGRx8888 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->vp + 1;
-  p->yp = p->vp + 2;
-  p->ap = p->vp + 3;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_RGB888 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->yp + 1;
-  p->vp = p->yp + 2;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_BGR888 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->vp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->up = p->vp + 1;
-  p->yp = p->vp + 2;
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-paint_setup_ARGB64 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->ap = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->yp = p->ap + 2;
-  p->up = p->ap + 4;
-  p->vp = p->ap + 6;
-  p->astride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ystride = p->astride;
-  p->ustride = p->astride;
-  p->vstride = p->astride;
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_str4 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *A = p->ap + y * p->ystride;
-  guint8 *R = p->yp + y * p->ystride;
-  guint8 *G = p->up + y * p->ustride;
-  guint8 *B = p->vp + y * p->vstride;
+  guint8 *data = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
+  guint8 *R = data + y * GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
   guint8 *argb = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    A[4 * i] = 0xff;
-    R[4 * i] = argb[4 * i + 1];
-    G[4 * i] = argb[4 * i + 2];
-    B[4 * i] = argb[4 * i + 3];
-  }
-}
-
-static void
-convert_hline_astr4 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *A = p->ap + y * p->ystride;
-  guint8 *R = p->yp + y * p->ystride;
-  guint8 *G = p->up + y * p->ustride;
-  guint8 *B = p->vp + y * p->vstride;
-  guint8 *argb = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    A[4 * i] = argb[4 * i + 0];
-    R[4 * i] = argb[4 * i + 1];
-    G[4 * i] = argb[4 * i + 2];
-    B[4 * i] = argb[4 * i + 3];
-  }
-}
-
-static void
-convert_hline_astr8 (paintinfo * p, int y)
-{
-  int i;
-  guint16 *A = (guint16 *) (p->ap + y * p->ystride);
-  guint16 *R = (guint16 *) (p->yp + y * p->ystride);
-  guint16 *G = (guint16 *) (p->up + y * p->ustride);
-  guint16 *B = (guint16 *) (p->vp + y * p->vstride);
-  guint8 *argb = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    A[4 * i] = TO_16 (argb[4 * i + 0]);
-    R[4 * i] = TO_16 (argb[4 * i + 1]);
-    G[4 * i] = TO_16 (argb[4 * i + 2]);
-    B[4 * i] = TO_16 (argb[4 * i + 3]);
-  }
-}
-
-static void
-convert_hline_str3 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *R = p->yp + y * p->ystride;
-  guint8 *G = p->up + y * p->ustride;
-  guint8 *B = p->vp + y * p->vstride;
-  guint8 *argb = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    R[3 * i] = argb[4 * i + 1];
-    G[3 * i] = argb[4 * i + 2];
-    B[3 * i] = argb[4 * i + 3];
-  }
-}
-
-static void
-paint_setup_RGB565 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_RGB565 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *R = p->yp + y * p->ystride;
-  guint8 *argb = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    guint16 value = ((argb[4 * i + 1] & 0xf8) << 8) |
-        ((argb[4 * i + 2] & 0xfc) << 3) | ((argb[4 * i + 3] & 0xf8) >> 3);
-#if G_BYTE_ORDER == G_LITTLE_ENDIAN
-    GST_WRITE_UINT16_LE (R + 2 * i, value);
-#else
-    GST_WRITE_UINT16_BE (R + 2 * i, value);
-#endif
-  }
-}
-
-static void
-convert_hline_xRGB1555 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *R = p->yp + y * p->ystride;
-  guint8 *argb = p->tmpline;
-
-  for (i = 0; i < p->width; i++) {
-    guint16 value = ((argb[4 * i + 1] & 0xf8) << 7) |
-        ((argb[4 * i + 2] & 0xf8) << 2) | ((argb[4 * i + 3] & 0xf8) >> 3);
-#if G_BYTE_ORDER == G_LITTLE_ENDIAN
-    GST_WRITE_UINT16_LE (R + 2 * i, value);
-#else
-    GST_WRITE_UINT16_BE (R + 2 * i, value);
-#endif
-  }
-}
-
-static void
-paint_setup_xRGB1555 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->ustride = p->ystride;
-  p->vstride = p->ystride;
-  p->size = frame->info.size;
-}
-
-
-static void
-paint_setup_bayer_bggr (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_ROUND_UP_4 (p->width);
-  p->ustride = GST_ROUND_UP_4 (p->width);
-  p->vstride = GST_ROUND_UP_4 (p->width);
-  p->size = p->ystride * p->height;
-  p->bayer_x_invert = 0;
-  p->bayer_y_invert = 0;
-}
-
-static void
-paint_setup_bayer_rggb (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_ROUND_UP_4 (p->width);
-  p->ustride = GST_ROUND_UP_4 (p->width);
-  p->vstride = GST_ROUND_UP_4 (p->width);
-  p->size = p->ystride * p->height;
-  p->bayer_x_invert = 1;
-  p->bayer_y_invert = 1;
-}
-
-static void
-paint_setup_bayer_grbg (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_ROUND_UP_4 (p->width);
-  p->ustride = GST_ROUND_UP_4 (p->width);
-  p->vstride = GST_ROUND_UP_4 (p->width);
-  p->size = p->ystride * p->height;
-  p->bayer_x_invert = 0;
-  p->bayer_y_invert = 1;
-}
-
-static void
-paint_setup_bayer_gbrg (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_ROUND_UP_4 (p->width);
-  p->ustride = GST_ROUND_UP_4 (p->width);
-  p->vstride = GST_ROUND_UP_4 (p->width);
-  p->size = p->ystride * p->height;
-  p->bayer_x_invert = 1;
-  p->bayer_y_invert = 0;
-}
-
-static void
-convert_hline_bayer (paintinfo * p, int y)
-{
-  int i;
-  guint8 *R = p->yp + y * p->ystride;
-  guint8 *argb = p->tmpline;
-  int x_inv = p->bayer_x_invert;
-  int y_inv = p->bayer_y_invert;
+  gint width = GST_VIDEO_FRAME_WIDTH (frame);
+  int x_inv = p->x_invert;
+  int y_inv = p->y_invert;
 
   if ((y ^ y_inv) & 1) {
-    for (i = 0; i < p->width; i++) {
+    for (i = 0; i < width; i++) {
       if ((i ^ x_inv) & 1) {
         R[i] = argb[4 * i + 1];
       } else {
@@ -2454,7 +1174,7 @@
       }
     }
   } else {
-    for (i = 0; i < p->width; i++) {
+    for (i = 0; i < width; i++) {
       if ((i ^ x_inv) & 1) {
         R[i] = argb[4 * i + 2];
       } else {
@@ -2463,49 +1183,3 @@
     }
   }
 }
-
-static void
-paint_setup_GRAY8 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_GRAY8 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  /* FIXME this should use gray, not YUV */
-  for (i = 0; i < p->width; i++) {
-    Y[i] = ayuv[4 * i + 1];
-  }
-}
-
-static void
-paint_setup_GRAY16 (paintinfo * p, GstVideoFrame * frame)
-{
-  p->yp = GST_VIDEO_FRAME_PLANE_DATA (frame, 0);
-  p->ystride = GST_VIDEO_FRAME_PLANE_STRIDE (frame, 0);
-  p->size = frame->info.size;
-}
-
-static void
-convert_hline_GRAY16 (paintinfo * p, int y)
-{
-  int i;
-  guint8 *Y = p->yp + y * p->ystride;
-  guint8 *ayuv = p->tmpline;
-
-  /* FIXME this should use gray, not YUV */
-  for (i = 0; i < p->width; i++) {
-#if G_BYTE_ORDER == G_LITTLE_ENDIAN
-    GST_WRITE_UINT16_LE (Y + i * 2, ayuv[4 * i + 1] << 8);
-#else
-    GST_WRITE_UINT16_BE (Y + i * 2, ayuv[4 * i + 1] << 8);
-#endif
-  }
-}
diff --git a/gst/videotestsrc/videotestsrc.h b/gst/videotestsrc/videotestsrc.h
index ee1f4f2..3b0657a 100644
--- a/gst/videotestsrc/videotestsrc.h
+++ b/gst/videotestsrc/videotestsrc.h
@@ -22,20 +22,6 @@
 
 #include <glib.h>
 
-enum {
-  VTS_YUV,
-  VTS_RGB,
-  VTS_GRAY,
-  VTS_BAYER
-};
-
-enum {
-  VTS_BAYER_BGGR,
-  VTS_BAYER_RGGB,
-  VTS_BAYER_GRBG,
-  VTS_BAYER_GBRG
-};
-
 struct vts_color_struct {
   guint8 Y, U, V, A;
   guint8 R, G, B;
@@ -44,59 +30,30 @@
 
 
 typedef struct paintinfo_struct paintinfo;
+
 struct paintinfo_struct
 {
-  unsigned char *ap, *yp, *up, *vp; /* pointers to first byte of each component
-                                     * for both packed/planar YUV and RGB */
-  int astride, ystride, ustride, vstride;
-
-  int size;                     /* size of a frame */
-  int width;
-  int height;
   const struct vts_color_struct *colors;
   const struct vts_color_struct *color;
-  /*  const struct vts_color_struct *color; */
-  void (*paint_hline) (paintinfo * p, int x, int y, int w);
+
   void (*paint_tmpline) (paintinfo * p, int x, int w);
-  void (*convert_tmpline) (paintinfo * p, int y);
+  void (*convert_tmpline) (paintinfo * p, GstVideoFrame *frame, int y);
+  void (*convert_hline) (paintinfo * p, GstVideoFrame *frame, int y);
   int x_offset;
 
-  int bayer_x_invert;
-  int bayer_y_invert;
+  int x_invert;
+  int y_invert;
 
   guint8 *tmpline;
   guint8 *tmpline2;
   guint8 *tmpline_u8;
+  guint16 *tmpline_u16;
 
   struct vts_color_struct foreground_color;
   struct vts_color_struct background_color;
 };
+#define PAINT_INFO_INIT {0, }
 
-struct format_list_struct
-{
-  int type;
-  const char *format;
-  const char *name;
-  int bitspp;
-  void (*paint_setup) (paintinfo * p, GstVideoFrame *frame);
-  void (*convert_hline) (paintinfo * p, int y);
-  int depth;
-  unsigned int red_mask;
-  unsigned int green_mask;
-  unsigned int blue_mask;
-  unsigned int alpha_mask;
-};
-
-struct format_list_struct *
-        paintrect_find_format           (const gchar *find_format);
-struct format_list_struct *
-        paintrect_find_name             (const char *name);
-struct format_list_struct *
-        paintinfo_find_by_structure     (const GstStructure *structure);
-GstStructure *
-        paint_get_structure             (struct format_list_struct *format);
-
-int     gst_video_test_src_get_size     (GstVideoTestSrc * v, int w, int h);
 void    gst_video_test_src_smpte        (GstVideoTestSrc * v, GstVideoFrame *frame);
 void    gst_video_test_src_smpte75      (GstVideoTestSrc * v, GstVideoFrame *frame);
 void    gst_video_test_src_snow         (GstVideoTestSrc * v, GstVideoFrame *frame);
@@ -119,7 +76,4 @@
 void    gst_video_test_src_smpte100     (GstVideoTestSrc * v, GstVideoFrame *frame);
 void    gst_video_test_src_bar          (GstVideoTestSrc * v, GstVideoFrame *frame);
 
-extern struct format_list_struct format_list[];
-extern int n_formats;
-
 #endif
diff --git a/gst/volume/Makefile.in b/gst/volume/Makefile.in
index c4286a7..c0ca118 100644
--- a/gst/volume/Makefile.in
+++ b/gst/volume/Makefile.in
@@ -74,6 +74,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/orc.mak
 subdir = gst/volume
@@ -304,8 +305,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -476,7 +483,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/m4/Makefile.in b/m4/Makefile.in
index ee12ab6..6ff0f44 100644
--- a/m4/Makefile.in
+++ b/m4/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = m4
 DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -211,8 +212,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -383,7 +390,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/pkgconfig/Makefile.in b/pkgconfig/Makefile.in
index 7f4bc92..8e14973 100644
--- a/pkgconfig/Makefile.in
+++ b/pkgconfig/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = pkgconfig
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(srcdir)/gstreamer-app-uninstalled.pc.in \
@@ -273,8 +274,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -445,7 +452,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/po/af.gmo b/po/af.gmo
index 4e52ba2..7ca8cef 100644
--- a/po/af.gmo
+++ b/po/af.gmo
Binary files differ
diff --git a/po/af.po b/po/af.po
index 36d3741..c4b949b 100644
--- a/po/af.po
+++ b/po/af.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins 0.7.6\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2004-03-18 14:16+0200\n"
 "Last-Translator: Petri Jooste <rkwjpj@puk.ac.za>\n"
 "Language-Team: Afrikaans <i18n@af.org.za>\n"
diff --git a/po/az.gmo b/po/az.gmo
index 2e3f4e9..a71825f 100644
--- a/po/az.gmo
+++ b/po/az.gmo
Binary files differ
diff --git a/po/az.po b/po/az.po
index 9bb8ed5..c72ca73 100644
--- a/po/az.po
+++ b/po/az.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-0.8.0\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2004-03-19 18:29+0200\n"
 "Last-Translator: Metin Amiroff <metin@karegen.com>\n"
 "Language-Team: Azerbaijani <translation-team-az@lists.sourceforge.net>\n"
diff --git a/po/bg.gmo b/po/bg.gmo
index 0739034..3c31985 100644
--- a/po/bg.gmo
+++ b/po/bg.gmo
Binary files differ
diff --git a/po/bg.po b/po/bg.po
index cda581b..599dee0 100644
--- a/po/bg.po
+++ b/po/bg.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-26 22:31+0300\n"
 "Last-Translator: Alexander Shopov <ash@kambanaria.org>\n"
 "Language-Team: Bulgarian <dict@fsa-bg.org>\n"
diff --git a/po/ca.gmo b/po/ca.gmo
index 7cfefcb..e91109c 100644
--- a/po/ca.gmo
+++ b/po/ca.gmo
Binary files differ
diff --git a/po/ca.po b/po/ca.po
index 100335a..8eb0395 100644
--- a/po/ca.po
+++ b/po/ca.po
@@ -9,7 +9,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2012-01-01 14:19+0100\n"
 "Last-Translator: Gil Forcada <gforcada@gnome.org>\n"
 "Language-Team: Catalan <ca@dodds.net>\n"
diff --git a/po/cs.gmo b/po/cs.gmo
index 5da6577..028c70f 100644
--- a/po/cs.gmo
+++ b/po/cs.gmo
Binary files differ
diff --git a/po/cs.po b/po/cs.po
index 00e7c8e..ca63f29 100644
--- a/po/cs.po
+++ b/po/cs.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base-0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-05-29 16:49+0200\n"
 "Last-Translator: Petr Kovar <pknbe@volny.cz>\n"
 "Language-Team: Czech <translation-team-cs@lists.sourceforge.net>\n"
diff --git a/po/da.gmo b/po/da.gmo
index 4bf7c19..ce91796 100644
--- a/po/da.gmo
+++ b/po/da.gmo
Binary files differ
diff --git a/po/da.po b/po/da.po
index a6a7279..b97794f 100644
--- a/po/da.po
+++ b/po/da.po
@@ -33,7 +33,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-28 16:38+0100\n"
 "Last-Translator: Joe Hansen <joedalton2@yahoo.dk>\n"
 "Language-Team: Danish <dansk@dansk-gruppen.dk>\n"
diff --git a/po/de.gmo b/po/de.gmo
index 9d7c70b..7940486 100644
--- a/po/de.gmo
+++ b/po/de.gmo
Binary files differ
diff --git a/po/de.po b/po/de.po
index c466e11..99d3385 100644
--- a/po/de.po
+++ b/po/de.po
@@ -9,7 +9,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-28 00:04+0200\n"
 "Last-Translator: Christian Kirbach <christian.kirbach@googlemail.com>\n"
 "Language-Team: German <translation-team-de@lists.sourceforge.net>\n"
diff --git a/po/el.gmo b/po/el.gmo
index 997bb19..4cf6334 100644
--- a/po/el.gmo
+++ b/po/el.gmo
Binary files differ
diff --git a/po/el.po b/po/el.po
index e505a3f..5519ab8 100644
--- a/po/el.po
+++ b/po/el.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.30.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-10-27 12:05+0200\n"
 "Last-Translator: Michael Kotsarinis <mk73628@gmail.com>\n"
 "Language-Team: Greek <team@lists.gnome.gr>\n"
diff --git a/po/en_GB.gmo b/po/en_GB.gmo
index 4164e74..5562990 100644
--- a/po/en_GB.gmo
+++ b/po/en_GB.gmo
Binary files differ
diff --git a/po/en_GB.po b/po/en_GB.po
index 382d6bc..6e9a168 100644
--- a/po/en_GB.po
+++ b/po/en_GB.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins 0.8.1\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2004-04-26 10:41-0400\n"
 "Last-Translator: Gareth Owen <gowen72@yahoo.com>\n"
 "Language-Team: English (British) <en_gb@li.org>\n"
diff --git a/po/eo.gmo b/po/eo.gmo
index 6608d19..5b5681c 100644
--- a/po/eo.gmo
+++ b/po/eo.gmo
Binary files differ
diff --git a/po/eo.po b/po/eo.po
index 42a7178..f72490c 100644
--- a/po/eo.po
+++ b/po/eo.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-06-04 21:11+0100\n"
 "Last-Translator: Kristjan SCHMIDT <kristjan.schmidt@googlemail.com>\n"
 "Language-Team: Esperanto <translation-team-eo@lists.sourceforge.net>\n"
diff --git a/po/es.gmo b/po/es.gmo
index 8e194ce..5560472 100644
--- a/po/es.gmo
+++ b/po/es.gmo
Binary files differ
diff --git a/po/es.po b/po/es.po
index 3f269bf..e7b071a 100644
--- a/po/es.po
+++ b/po/es.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-10-02 15:46+0200\n"
 "Last-Translator: Jorge González González <aloriel@gmail.com>\n"
 "Language-Team: Spanish <es@li.org>\n"
diff --git a/po/eu.gmo b/po/eu.gmo
index a9f9326..60785c3 100644
--- a/po/eu.gmo
+++ b/po/eu.gmo
Binary files differ
diff --git a/po/eu.po b/po/eu.po
index c113801..70d0605 100644
--- a/po/eu.po
+++ b/po/eu.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base-0.10.26.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-03-25 12:32+0100\n"
 "Last-Translator: Mikel Olasagasti Uranga <hey_neken@mundurat.net>\n"
 "Language-Team: Basque <translation-team-eu@lists.sourceforge.net>\n"
diff --git a/po/fi.gmo b/po/fi.gmo
index e23f6c0..76f03fd 100644
--- a/po/fi.gmo
+++ b/po/fi.gmo
Binary files differ
diff --git a/po/fi.po b/po/fi.po
index fc22424..354c312 100644
--- a/po/fi.po
+++ b/po/fi.po
@@ -12,7 +12,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.30.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-12-31 23:21+0200\n"
 "Last-Translator: Tommi Vainikainen <Tommi.Vainikainen@iki.fi>\n"
 "Language-Team: Finnish <translation-team-fi@lists.sourceforge.net>\n"
diff --git a/po/fr.gmo b/po/fr.gmo
index 4df100d..690b8c3 100644
--- a/po/fr.gmo
+++ b/po/fr.gmo
Binary files differ
diff --git a/po/fr.po b/po/fr.po
index 4a08934..14233e6 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -9,7 +9,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-28 09:19+0200\n"
 "Last-Translator: Claude Paroz <claude@2xlibre.net>\n"
 "Language-Team: French <traduc@traduc.org>\n"
diff --git a/po/gl.gmo b/po/gl.gmo
index 8bcadd2..22c9765 100644
--- a/po/gl.gmo
+++ b/po/gl.gmo
Binary files differ
diff --git a/po/gl.po b/po/gl.po
index e39de0c..14c5ed7 100644
--- a/po/gl.po
+++ b/po/gl.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-09-05 12:48+0200\n"
 "Last-Translator: Fran Dieguez <frandieguez@ubuntu.com>\n"
 "Language-Team: Galician <proxecto@trasno.net>\n"
diff --git a/po/gst-plugins-base-1.0.pot b/po/gst-plugins-base-1.0.pot
index e9a4b6d..86beff9 100644
--- a/po/gst-plugins-base-1.0.pot
+++ b/po/gst-plugins-base-1.0.pot
@@ -5,9 +5,9 @@
 #, fuzzy
 msgid ""
 msgstr ""
-"Project-Id-Version: gst-plugins-base 0.11.91\n"
+"Project-Id-Version: gst-plugins-base 0.11.92\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -62,19 +62,19 @@
 msgid "Could not open audio device for recording."
 msgstr ""
 
-#: ext/cdparanoia/gstcdparanoiasrc.c:278 ext/cdparanoia/gstcdparanoiasrc.c:284
+#: ext/cdparanoia/gstcdparanoiasrc.c:279 ext/cdparanoia/gstcdparanoiasrc.c:285
 msgid "Could not open CD device for reading."
 msgstr ""
 
-#: ext/cdparanoia/gstcdparanoiasrc.c:410
+#: ext/cdparanoia/gstcdparanoiasrc.c:411
 msgid "Could not seek CD."
 msgstr ""
 
-#: ext/cdparanoia/gstcdparanoiasrc.c:418
+#: ext/cdparanoia/gstcdparanoiasrc.c:419
 msgid "Could not read CD."
 msgstr ""
 
-#: ext/ogg/gstoggdemux.c:4462
+#: ext/ogg/gstoggdemux.c:4483
 msgid "Internal data stream error."
 msgstr ""
 
@@ -91,73 +91,73 @@
 msgid "This appears to be a text file"
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1297 gst/playback/gstplaysink.c:1310
-#: gst/playback/gstplaysink.c:1621 gst/playback/gstplaysink.c:1888
-#: gst/playback/gstplaysink.c:1937 gst/playback/gstplaysink.c:1952
-#: gst/playback/gstplaysink.c:1977 gst/playback/gstplaysink.c:2009
-#: gst/playback/gstplaysink.c:2129 gst/playback/gstplaysink.c:2484
-#: gst/playback/gstplaysink.c:2493 gst/playback/gstplaysink.c:2502
-#: gst/playback/gstplaysink.c:2511 gst/playback/gstplaysink.c:3592
+#: gst/playback/gstplaysink.c:1337 gst/playback/gstplaysink.c:1350
+#: gst/playback/gstplaysink.c:1661 gst/playback/gstplaysink.c:2243
+#: gst/playback/gstplaysink.c:2292 gst/playback/gstplaysink.c:2307
+#: gst/playback/gstplaysink.c:2332 gst/playback/gstplaysink.c:2364
+#: gst/playback/gstplaysink.c:2494 gst/playback/gstplaysink.c:2859
+#: gst/playback/gstplaysink.c:2868 gst/playback/gstplaysink.c:2877
+#: gst/playback/gstplaysink.c:2886 gst/playback/gstplaysink.c:3967
 #: gst/playback/gsturidecodebin.c:1384
 #, c-format
 msgid "Missing element '%s' - check your GStreamer installation."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1696
+#: gst/playback/gstplaysink.c:1745
 #, c-format
 msgid "Both autovideosink and %s elements are missing."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1700
+#: gst/playback/gstplaysink.c:1749
 msgid "The autovideosink element is missing."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1705
+#: gst/playback/gstplaysink.c:1754
 #, c-format
 msgid "Configured videosink %s is not working."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1709
+#: gst/playback/gstplaysink.c:1758
 #, c-format
 msgid "Both autovideosink and %s elements are not working."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1713
+#: gst/playback/gstplaysink.c:1762
 msgid "The autovideosink element is not working."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:1925
+#: gst/playback/gstplaysink.c:2280
 msgid "Custom text sink element is not usable."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2247
+#: gst/playback/gstplaysink.c:2612
 msgid "No volume control found"
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2267
+#: gst/playback/gstplaysink.c:2642
 #, c-format
 msgid "Both autoaudiosink and %s elements are missing."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2271
+#: gst/playback/gstplaysink.c:2646
 msgid "The autoaudiosink element is missing."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2276
+#: gst/playback/gstplaysink.c:2651
 #, c-format
 msgid "Configured audiosink %s is not working."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2280
+#: gst/playback/gstplaysink.c:2655
 #, c-format
 msgid "Both autoaudiosink and %s elements are not working."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2284
+#: gst/playback/gstplaysink.c:2659
 msgid "The autoaudiosink element is not working."
 msgstr ""
 
-#: gst/playback/gstplaysink.c:2600 gst/playback/gstplaysink.c:2605
+#: gst/playback/gstplaysink.c:2975 gst/playback/gstplaysink.c:2980
 msgid "Can't play a text file without video or visualizations."
 msgstr ""
 
@@ -414,186 +414,186 @@
 msgid "unparsed id3v2 tag frame"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:78
+#: gst-libs/gst/pbutils/descriptions.c:76
 msgid "ID3 tag"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:79
-#: gst-libs/gst/pbutils/descriptions.c:80
+#: gst-libs/gst/pbutils/descriptions.c:77
+#: gst-libs/gst/pbutils/descriptions.c:78
 msgid "APE tag"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:81
+#: gst-libs/gst/pbutils/descriptions.c:79
 msgid "ICY internet radio"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:113
+#: gst-libs/gst/pbutils/descriptions.c:110
 msgid "Apple Lossless Audio (ALAC)"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:123
+#: gst-libs/gst/pbutils/descriptions.c:121
 msgid "Free Lossless Audio Codec (FLAC)"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:149
-#: gst-libs/gst/pbutils/descriptions.c:150
+#: gst-libs/gst/pbutils/descriptions.c:147
+#: gst-libs/gst/pbutils/descriptions.c:148
 msgid "Lossless True Audio (TTA)"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:158
+#: gst-libs/gst/pbutils/descriptions.c:156
 msgid "Windows Media Speech"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:173
+#: gst-libs/gst/pbutils/descriptions.c:171
 msgid "CYUV Lossless"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:178
+#: gst-libs/gst/pbutils/descriptions.c:176
 msgid "FFMpeg v1"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:192
+#: gst-libs/gst/pbutils/descriptions.c:190
 msgid "Lossless MSZH"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:202
+#: gst-libs/gst/pbutils/descriptions.c:200
 msgid "Run-length encoding"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:250
+#: gst-libs/gst/pbutils/descriptions.c:248
 msgid "Subtitle"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:251
+#: gst-libs/gst/pbutils/descriptions.c:249
 msgid "MPL2 subtitle format"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:252
+#: gst-libs/gst/pbutils/descriptions.c:250
 msgid "DKS subtitle format"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:253
+#: gst-libs/gst/pbutils/descriptions.c:251
 msgid "QTtext subtitle format"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:254
+#: gst-libs/gst/pbutils/descriptions.c:252
 msgid "Sami subtitle format"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:255
+#: gst-libs/gst/pbutils/descriptions.c:253
 msgid "TMPlayer subtitle format"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:257
+#: gst-libs/gst/pbutils/descriptions.c:255
 msgid "Kate subtitle format"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:319
-#: gst-libs/gst/pbutils/descriptions.c:322
-#: gst-libs/gst/pbutils/descriptions.c:365
+#: gst-libs/gst/pbutils/descriptions.c:318
+#: gst-libs/gst/pbutils/descriptions.c:321
+#: gst-libs/gst/pbutils/descriptions.c:364
 msgid "Uncompressed video"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:327
+#: gst-libs/gst/pbutils/descriptions.c:326
 msgid "Uncompressed gray"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:353
+#: gst-libs/gst/pbutils/descriptions.c:352
 #, c-format
 msgid "Uncompressed %s YUV %s"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:362
+#: gst-libs/gst/pbutils/descriptions.c:361
 #, c-format
 msgid "Uncompressed %s%d-bit %s"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:415
+#: gst-libs/gst/pbutils/descriptions.c:414
 #, c-format
 msgid "DivX MPEG-4 Version %d"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:636
+#: gst-libs/gst/pbutils/descriptions.c:635
 msgid "Uncompressed audio"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:642
+#: gst-libs/gst/pbutils/descriptions.c:641
 #, c-format
 msgid "Raw %d-bit %s audio"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:729
+#: gst-libs/gst/pbutils/descriptions.c:728
 msgid "Audio CD source"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:732
+#: gst-libs/gst/pbutils/descriptions.c:731
 msgid "DVD source"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:735
+#: gst-libs/gst/pbutils/descriptions.c:734
 msgid "Real Time Streaming Protocol (RTSP) source"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:739
+#: gst-libs/gst/pbutils/descriptions.c:738
 msgid "Microsoft Media Server (MMS) protocol source"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:747
+#: gst-libs/gst/pbutils/descriptions.c:746
 #, c-format
 msgid "%s protocol source"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:819
+#: gst-libs/gst/pbutils/descriptions.c:818
 #, c-format
 msgid "%s video RTP depayloader"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:821
+#: gst-libs/gst/pbutils/descriptions.c:820
 #, c-format
 msgid "%s audio RTP depayloader"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:823
+#: gst-libs/gst/pbutils/descriptions.c:822
 #, c-format
 msgid "%s RTP depayloader"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:830
+#: gst-libs/gst/pbutils/descriptions.c:829
 #, c-format
 msgid "%s demuxer"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:832
+#: gst-libs/gst/pbutils/descriptions.c:831
 #, c-format
 msgid "%s decoder"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:870
+#: gst-libs/gst/pbutils/descriptions.c:869
 #, c-format
 msgid "%s video RTP payloader"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:872
+#: gst-libs/gst/pbutils/descriptions.c:871
 #, c-format
 msgid "%s audio RTP payloader"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:874
+#: gst-libs/gst/pbutils/descriptions.c:873
 #, c-format
 msgid "%s RTP payloader"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:881
+#: gst-libs/gst/pbutils/descriptions.c:880
 #, c-format
 msgid "%s muxer"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:883
+#: gst-libs/gst/pbutils/descriptions.c:882
 #, c-format
 msgid "%s encoder"
 msgstr ""
 
-#: gst-libs/gst/pbutils/descriptions.c:915
+#: gst-libs/gst/pbutils/descriptions.c:914
 #, c-format
 msgid "GStreamer element %s"
 msgstr ""
diff --git a/po/hu.gmo b/po/hu.gmo
index ee7edc1..88bf0ed 100644
--- a/po/hu.gmo
+++ b/po/hu.gmo
Binary files differ
diff --git a/po/hu.po b/po/hu.po
index df03d40..b34f6af 100644
--- a/po/hu.po
+++ b/po/hu.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.30.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-11-03 02:48+0100\n"
 "Last-Translator: Gabor Kelemen <kelemeng@gnome.hu>\n"
 "Language-Team: Hungarian <translation-team-hu@lists.sourceforge.net>\n"
diff --git a/po/id.gmo b/po/id.gmo
index 4500b9b..4b511c1 100644
--- a/po/id.gmo
+++ b/po/id.gmo
Binary files differ
diff --git a/po/id.po b/po/id.po
index e9e64a0..b307cb4 100644
--- a/po/id.po
+++ b/po/id.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2012-01-28 11:31+0700\n"
 "Last-Translator: Andhika Padmawan <andhika.padmawan@gmail.com>\n"
 "Language-Team: Indonesian <translation-team-id@lists.sourceforge.net>\n"
diff --git a/po/it.gmo b/po/it.gmo
index b2b6c0d..d2198ac 100644
--- a/po/it.gmo
+++ b/po/it.gmo
Binary files differ
diff --git a/po/it.po b/po/it.po
index 6bb4798..eab7913 100644
--- a/po/it.po
+++ b/po/it.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.28.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-04-28 14:27+0200\n"
 "Last-Translator: Luca Ferretti <elle.uca@infinito.it>\n"
 "Language-Team: Italian <tp@lists.linux.it>\n"
diff --git a/po/ja.gmo b/po/ja.gmo
index 6e03e32..7080962 100644
--- a/po/ja.gmo
+++ b/po/ja.gmo
Binary files differ
diff --git a/po/ja.po b/po/ja.po
index 741fd6a..a3a1a96 100644
--- a/po/ja.po
+++ b/po/ja.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.30.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-10-25 10:27+0900\n"
 "Last-Translator: Makoto Kato <makoto.kt@gmail.com>\n"
 "Language-Team: Japanese <translation-team-ja@lists.sourceforge.net>\n"
diff --git a/po/lt.gmo b/po/lt.gmo
index e599644..0686f8d 100644
--- a/po/lt.gmo
+++ b/po/lt.gmo
Binary files differ
diff --git a/po/lt.po b/po/lt.po
index 5def22b..dc778b2 100644
--- a/po/lt.po
+++ b/po/lt.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base-0.10.15.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2008-03-07 23:43+0200\n"
 "Last-Translator: Gintautas Miliauskas <gintas@akl.lt>\n"
 "Language-Team: Lithuanian <komp_lt@konferencijos.lt>\n"
diff --git a/po/lv.gmo b/po/lv.gmo
index da1b627..75b64aa 100644
--- a/po/lv.gmo
+++ b/po/lv.gmo
Binary files differ
diff --git a/po/lv.po b/po/lv.po
index 9f8be93..efcd13d 100644
--- a/po/lv.po
+++ b/po/lv.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-09-02 12:02-0000\n"
 "Last-Translator: Rihards Priedītis <rprieditis@gmail.com>\n"
 "Language-Team: Latvian <translation-team-lv@lists.sourceforge.net>\n"
diff --git a/po/nb.gmo b/po/nb.gmo
index f267479..93d8f49 100644
--- a/po/nb.gmo
+++ b/po/nb.gmo
Binary files differ
diff --git a/po/nb.po b/po/nb.po
index 51eeb11..94a0313 100644
--- a/po/nb.po
+++ b/po/nb.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.30.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-10-24 21:44+0200\n"
 "Last-Translator: Kjartan Maraas <kmaraas@gnome.org>\n"
 "Language-Team: Norwegian Bokmaal <i18n-nb@lister.ping.uio.no>\n"
diff --git a/po/nl.gmo b/po/nl.gmo
index 6a21696..ae144b7 100644
--- a/po/nl.gmo
+++ b/po/nl.gmo
Binary files differ
diff --git a/po/nl.po b/po/nl.po
index e26364b..8221074 100644
--- a/po/nl.po
+++ b/po/nl.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-27 00:12+0200\n"
 "Last-Translator: Freek de Kruijf <f.de.kruijf@gmail.com>\n"
 "Language-Team: Dutch <vertaling@vrijschrift.org>\n"
diff --git a/po/or.gmo b/po/or.gmo
index a17ceae..6c8b8fb 100644
--- a/po/or.gmo
+++ b/po/or.gmo
Binary files differ
diff --git a/po/or.po b/po/or.po
index f37e3a1..102d938 100644
--- a/po/or.po
+++ b/po/or.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-0.8.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2004-09-27 13:32+0530\n"
 "Last-Translator: Gora Mohanty <gora_mohanty@yahoo.co.in>\n"
 "Language-Team: Oriya <gora_mohanty@yahoo.co.in>\n"
diff --git a/po/pl.gmo b/po/pl.gmo
index dfdf8d8..2fc2d9a 100644
--- a/po/pl.gmo
+++ b/po/pl.gmo
Binary files differ
diff --git a/po/pl.po b/po/pl.po
index 4cefed6..5a51f87 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-26 18:01+0200\n"
 "Last-Translator: Jakub Bogusz <qboosh@pld-linux.org>\n"
 "Language-Team: Polish <translation-team-pl@lists.sourceforge.net>\n"
diff --git a/po/pt_BR.gmo b/po/pt_BR.gmo
index 75a8789..36e41ff 100644
--- a/po/pt_BR.gmo
+++ b/po/pt_BR.gmo
Binary files differ
diff --git a/po/pt_BR.po b/po/pt_BR.po
index 7878cd7..6268cea 100644
--- a/po/pt_BR.po
+++ b/po/pt_BR.po
@@ -9,7 +9,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base-0.10.31.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-01-08 01:02-0300\n"
 "Last-Translator: Fabrício Godoy <skarllot@gmail.com>\n"
 "Language-Team: Brazilian Portuguese <ldp-br@bazar.conectiva.com.br>\n"
diff --git a/po/ro.gmo b/po/ro.gmo
index 323c822..0cfd417 100644
--- a/po/ro.gmo
+++ b/po/ro.gmo
Binary files differ
diff --git a/po/ro.po b/po/ro.po
index 3d01574..d729bc4 100644
--- a/po/ro.po
+++ b/po/ro.po
@@ -5,7 +5,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.29.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-08-16 01:21+0300\n"
 "Last-Translator: Lucian Adrian Grijincu <lucian.grijincu@gmail.com>\n"
 "Language-Team: Romanian <translation-team-ro@lists.sourceforge.net>\n"
diff --git a/po/ru.gmo b/po/ru.gmo
index a986105..9e6a805 100644
--- a/po/ru.gmo
+++ b/po/ru.gmo
Binary files differ
diff --git a/po/ru.po b/po/ru.po
index 4ecc50c..6b50059 100644
--- a/po/ru.po
+++ b/po/ru.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-26 20:30+0400\n"
 "Last-Translator: Yuri Kozlov <yuray@komyakino.ru>\n"
 "Language-Team: Russian <gnu@mx.ru>\n"
diff --git a/po/sk.gmo b/po/sk.gmo
index 6021de7..5d745fb 100644
--- a/po/sk.gmo
+++ b/po/sk.gmo
Binary files differ
diff --git a/po/sk.po b/po/sk.po
index 544fc2d..1c6e92d 100644
--- a/po/sk.po
+++ b/po/sk.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.30.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-11-08 15:34+0100\n"
 "Last-Translator: Peter Tuhársky <tuharsky@misbb.sk>\n"
 "Language-Team: Slovak <sk-i18n@lists.linux.sk>\n"
diff --git a/po/sl.gmo b/po/sl.gmo
index 8aa1e4e..9420d2c 100644
--- a/po/sl.gmo
+++ b/po/sl.gmo
Binary files differ
diff --git a/po/sl.po b/po/sl.po
index 6441b4d..b3b850c 100644
--- a/po/sl.po
+++ b/po/sl.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-26 15:56+0100\n"
 "Last-Translator: Klemen Košir <klemen.kosir@gmx.com>\n"
 "Language-Team: Slovenian <translation-team-sl@lists.sourceforge.net>\n"
diff --git a/po/sq.gmo b/po/sq.gmo
index a4694ca..ef09881 100644
--- a/po/sq.gmo
+++ b/po/sq.gmo
Binary files differ
diff --git a/po/sq.po b/po/sq.po
index b4a4d86..afa28a2 100644
--- a/po/sq.po
+++ b/po/sq.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins 0.8.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2004-08-07 20:29+0200\n"
 "Last-Translator: Laurent Dhima <laurenti@alblinux.net>\n"
 "Language-Team: Albanian <begraj@hotmail.com>\n"
diff --git a/po/sr.gmo b/po/sr.gmo
index 8f8724f..3958042 100644
--- a/po/sr.gmo
+++ b/po/sr.gmo
Binary files differ
diff --git a/po/sr.po b/po/sr.po
index 025619f..ac2e8f0 100644
--- a/po/sr.po
+++ b/po/sr.po
@@ -7,7 +7,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base-0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-12-05 09:10+0200\n"
 "Last-Translator: Мирослав Николић <miroslavnikolic@rocketmail.com>\n"
 "Language-Team: Serbian <gnu@prevod.org>\n"
diff --git a/po/sv.gmo b/po/sv.gmo
index a8dd89a..414b325 100644
--- a/po/sv.gmo
+++ b/po/sv.gmo
Binary files differ
diff --git a/po/sv.po b/po/sv.po
index 01a7e29..59bc4c8 100644
--- a/po/sv.po
+++ b/po/sv.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.28.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-06-07 18:17+0100\n"
 "Last-Translator: Daniel Nylander <po@danielnylander.se>\n"
 "Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n"
diff --git a/po/tr.gmo b/po/tr.gmo
index e79a10b..82f91c2 100644
--- a/po/tr.gmo
+++ b/po/tr.gmo
Binary files differ
diff --git a/po/tr.po b/po/tr.po
index cdc1615..b940ac0 100644
--- a/po/tr.po
+++ b/po/tr.po
@@ -5,7 +5,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-26 19:22+0200\n"
 "Last-Translator: Server Acim <serveracim@gmail.com>\n"
 "Language-Team: Turkish <gnu-tr-u12a@lists.sourceforge.net>\n"
diff --git a/po/uk.gmo b/po/uk.gmo
index 7d7da58..ea9d251 100644
--- a/po/uk.gmo
+++ b/po/uk.gmo
Binary files differ
diff --git a/po/uk.po b/po/uk.po
index 374253a..287cec2 100644
--- a/po/uk.po
+++ b/po/uk.po
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.32.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2011-04-27 17:49+0300\n"
 "Last-Translator: Yuri Chornoivan <yurchor@ukr.net>\n"
 "Language-Team: Ukrainian <translation-team-uk@lists.sourceforge.net>\n"
diff --git a/po/vi.gmo b/po/vi.gmo
index afc335d..84a18fc 100644
--- a/po/vi.gmo
+++ b/po/vi.gmo
Binary files differ
diff --git a/po/vi.po b/po/vi.po
index cbb9601..1bbd398 100644
--- a/po/vi.po
+++ b/po/vi.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.28.2\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2010-04-27 22:51+0930\n"
 "Last-Translator: Clytie Siddall <clytie@riverland.net.au>\n"
 "Language-Team: Vietnamese <vi-VN@googlegroups.com>\n"
diff --git a/po/zh_CN.gmo b/po/zh_CN.gmo
index efb1b34..f94667b 100644
--- a/po/zh_CN.gmo
+++ b/po/zh_CN.gmo
Binary files differ
diff --git a/po/zh_CN.po b/po/zh_CN.po
index 5a15b2c..a8962ba 100644
--- a/po/zh_CN.po
+++ b/po/zh_CN.po
@@ -6,7 +6,7 @@
 msgstr ""
 "Project-Id-Version: gst-plugins-base 0.10.21.3\n"
 "Report-Msgid-Bugs-To: http://bugzilla.gnome.org/\n"
-"POT-Creation-Date: 2012-05-13 16:19+0200\n"
+"POT-Creation-Date: 2012-06-07 16:03+0200\n"
 "PO-Revision-Date: 2009-01-14 12:41+0800\n"
 "Last-Translator: Ji ZhengYu <zhengyuji@gmail.com>\n"
 "Language-Team: Chinese (simplified) <i18n-zh@googlegroups.com>\n"
diff --git a/sys/Makefile.in b/sys/Makefile.in
index 2c44935..af9985e 100644
--- a/sys/Makefile.in
+++ b/sys/Makefile.in
@@ -55,6 +55,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/parallel-subdirs.mak
 subdir = sys
@@ -256,8 +257,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -428,7 +435,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/sys/ximage/Makefile.in b/sys/ximage/Makefile.in
index eb963aa..07ce412 100644
--- a/sys/ximage/Makefile.in
+++ b/sys/ximage/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = sys/ximage
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -278,8 +279,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -450,7 +457,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/sys/xvimage/Makefile.in b/sys/xvimage/Makefile.in
index 742084f..79679b9 100644
--- a/sys/xvimage/Makefile.in
+++ b/sys/xvimage/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = sys/xvimage
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in
@@ -278,8 +279,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -450,7 +457,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/sys/xvimage/xvimagesink.c b/sys/xvimage/xvimagesink.c
index a8fd9ea..7fb457f 100644
--- a/sys/xvimage/xvimagesink.c
+++ b/sys/xvimage/xvimagesink.c
@@ -1562,8 +1562,6 @@
   if (!gst_video_info_from_caps (&info, caps))
     goto invalid_format;
 
-  structure = gst_caps_get_structure (caps, 0);
-
   xvimagesink->fps_n = info.fps_n;
   xvimagesink->fps_d = info.fps_d;
 
diff --git a/tests/Makefile.in b/tests/Makefile.in
index d8480ed..9da8ff8 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = tests
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -250,8 +251,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -422,7 +429,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/check/Makefile.in b/tests/check/Makefile.in
index ce9f103..41f9b13 100644
--- a/tests/check/Makefile.in
+++ b/tests/check/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \
 	$(srcdir)/Makefile.in $(top_srcdir)/common/check.mak
 check_PROGRAMS = $(am__EXEEXT_1) $(am__EXEEXT_2) \
@@ -753,8 +754,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -925,7 +932,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/check/elements/playbin.c b/tests/check/elements/playbin.c
index 924dd5a..26cf665 100644
--- a/tests/check/elements/playbin.c
+++ b/tests/check/elements/playbin.c
@@ -35,6 +35,46 @@
 static GType gst_red_video_src_get_type (void);
 static GType gst_codec_src_get_type (void);
 
+GST_START_TEST (test_uri)
+{
+  GstElement *playbin, *fakesink;
+  gchar *uri;
+
+  fail_unless (gst_element_register (NULL, "redvideosrc", GST_RANK_PRIMARY,
+          gst_red_video_src_get_type ()));
+
+  playbin = gst_element_factory_make ("playbin", "playbin");
+  fail_unless (playbin != NULL, "Failed to create playbin element");
+
+  fakesink = gst_element_factory_make ("fakesink", "fakesink");
+  fail_unless (fakesink != NULL, "Failed to create fakesink element");
+
+  g_object_set (playbin, "video-sink", fakesink, NULL);
+
+  g_object_set (playbin, "uri", "redvideo://", NULL);
+  g_object_get (playbin, "uri", &uri, NULL);
+
+  fail_unless_equals_string (uri, "redvideo://");
+
+  g_object_get (playbin, "current-uri", &uri, NULL);
+  fail_unless_equals_string (uri, NULL);
+
+  fail_unless_equals_int (gst_element_set_state (playbin, GST_STATE_PAUSED),
+      GST_STATE_CHANGE_ASYNC);
+  fail_unless_equals_int (gst_element_get_state (playbin, NULL, NULL, -1),
+      GST_STATE_CHANGE_SUCCESS);
+
+  g_object_get (playbin, "uri", &uri, NULL);
+  fail_unless_equals_string (uri, NULL);
+  g_object_get (playbin, "current-uri", &uri, NULL);
+  fail_unless_equals_string (uri, "redvideo://");
+
+  gst_element_set_state (playbin, GST_STATE_NULL);
+  gst_object_unref (playbin);
+}
+
+GST_END_TEST;
+
 /* make sure the audio sink is not touched for video-only streams */
 GST_START_TEST (test_sink_usage_video_only_stream)
 {
@@ -736,6 +776,7 @@
   suite_add_tcase (s, tc_chain);
 
 #ifndef GST_DISABLE_REGISTRY
+  tcase_add_test (tc_chain, test_uri);
   tcase_add_test (tc_chain, test_sink_usage_video_only_stream);
   tcase_add_test (tc_chain, test_suburi_error_wrongproto);
   tcase_add_test (tc_chain, test_suburi_error_invalidfile);
diff --git a/tests/check/libs/struct_x86_64.h b/tests/check/libs/struct_x86_64.h
index 5d0895d..70a758a 100644
--- a/tests/check/libs/struct_x86_64.h
+++ b/tests/check/libs/struct_x86_64.h
@@ -1,7 +1,7 @@
 
 GstCheckABIStruct list[] = {
   {"GstAppSinkCallbacks", sizeof (GstAppSinkCallbacks), 56},
-  {"GstAppSinkClass", sizeof (GstAppSinkClass), 848},
+  {"GstAppSinkClass", sizeof (GstAppSinkClass), 864},
   {"GstAppSink", sizeof (GstAppSink), 696},
   {"GstAppSrcCallbacks", sizeof (GstAppSrcCallbacks), 56},
   {"GstAppSrcClass", sizeof (GstAppSrcClass), 872},
@@ -13,11 +13,11 @@
   {"GstAudioClock", sizeof (GstAudioClock), 240},
   {"GstAudioFilterClass", sizeof (GstAudioFilterClass), 856},
   {"GstAudioFilter", sizeof (GstAudioFilter), 920},
-  {"GstAudioSinkClass", sizeof (GstAudioSinkClass), 912},
+  {"GstAudioSinkClass", sizeof (GstAudioSinkClass), 928},
   {"GstAudioSink", sizeof (GstAudioSink), 784},
   {"GstAudioSrcClass", sizeof (GstAudioSrcClass), 984},
   {"GstAudioSrc", sizeof (GstAudioSrc), 792},
-  {"GstAudioBaseSinkClass", sizeof (GstAudioBaseSinkClass), 824},
+  {"GstAudioBaseSinkClass", sizeof (GstAudioBaseSinkClass), 840},
   {"GstAudioBaseSink", sizeof (GstAudioBaseSink), 744},
   {"GstAudioBaseSrcClass", sizeof (GstAudioBaseSrcClass), 896},
   {"GstAudioBaseSrc", sizeof (GstAudioBaseSrc), 752},
@@ -73,7 +73,7 @@
   {"GstVideoFilter", sizeof (GstVideoFilter), 864},
   {"GstVideoOrientationInterface", sizeof (GstVideoOrientationInterface), 80},
   {"GstVideoRectangle", sizeof (GstVideoRectangle), 16},
-  {"GstVideoSinkClass", sizeof (GstVideoSinkClass), 816},
+  {"GstVideoSinkClass", sizeof (GstVideoSinkClass), 832},
   {"GstVideoSink", sizeof (GstVideoSink), 696},
   {"GstVideoOverlayInterface", sizeof (GstVideoOverlayInterface), 48},
   {NULL, 0, 0}
diff --git a/tests/check/libs/tag.c b/tests/check/libs/tag.c
index 62ad204..b7ec2bb 100644
--- a/tests/check/libs/tag.c
+++ b/tests/check/libs/tag.c
@@ -209,27 +209,6 @@
 
 GST_END_TEST;
 
-/* is there an easier way to compare two structures / tagslists? */
-static gboolean
-taglists_are_equal (const GstTagList * list_1, const GstTagList * list_2)
-{
-  GstCaps *c_list_1 = gst_caps_new_empty ();
-  GstCaps *c_list_2 = gst_caps_new_empty ();
-  gboolean ret;
-
-  gst_caps_append_structure (c_list_1,
-      gst_structure_copy ((GstStructure *) list_1));
-  gst_caps_append_structure (c_list_2,
-      gst_structure_copy ((GstStructure *) list_2));
-
-  ret = gst_caps_is_equal (c_list_2, c_list_1);
-
-  gst_caps_unref (c_list_1);
-  gst_caps_unref (c_list_2);
-
-  return ret;
-}
-
 GST_START_TEST (test_vorbis_tags)
 {
   GstTagList *list;
@@ -347,7 +326,7 @@
     vendor_id = NULL;
 
     GST_LOG ("new_list = %" GST_PTR_FORMAT, new_list);
-    fail_unless (taglists_are_equal (list, new_list));
+    fail_unless (gst_tag_list_is_equal (list, new_list));
 
     buf2 = gst_tag_list_to_vorbiscomment_buffer (new_list,
         (const guint8 *) "\003vorbis", 7, "libgstunittest");
@@ -360,7 +339,7 @@
     vendor_id = NULL;
 
     GST_LOG ("even_newer_list = %" GST_PTR_FORMAT, even_newer_list);
-    fail_unless (taglists_are_equal (new_list, even_newer_list));
+    fail_unless (gst_tag_list_is_equal (new_list, even_newer_list));
 
     gst_tag_list_free (new_list);
     gst_tag_list_free (even_newer_list);
@@ -466,14 +445,14 @@
     fail_unless (vendor != NULL);
     fail_unless_equals_string (vendor, "foo");
     fail_unless (list != NULL);
-    fail_unless (gst_structure_n_fields ((GstStructure *) list) == 0);
+    fail_unless (gst_tag_list_n_tags (list) == 0);
     g_free (vendor);
     gst_tag_list_free (list);
 
     /* now again without vendor */
     list = gst_tag_list_from_vorbiscomment_buffer (buf, NULL, 0, NULL);
     fail_unless (list != NULL);
-    fail_unless (gst_structure_n_fields ((GstStructure *) list) == 0);
+    fail_unless (gst_tag_list_n_tags (list) == 0);
     gst_tag_list_free (list);
 
     gst_buffer_unref (buf);
@@ -513,7 +492,7 @@
     fail_unless (vendor != NULL);
     fail_unless_equals_string (vendor, "foo");
     fail_unless (list != NULL);
-    fail_unless (gst_structure_n_fields ((GstStructure *) list) == 1);
+    fail_unless (gst_tag_list_n_tags (list) == 1);
     ASSERT_TAG_LIST_HAS_STRING (list, GST_TAG_ARTIST, "foo bar");
     g_free (vendor);
     gst_tag_list_free (list);
@@ -522,7 +501,7 @@
     list = gst_tag_list_from_vorbiscomment_buffer (buf,
         (guint8 *) "\003vorbis", 7, NULL);
     fail_unless (list != NULL);
-    fail_unless (gst_structure_n_fields ((GstStructure *) list) == 1);
+    fail_unless (gst_tag_list_n_tags (list) == 1);
     ASSERT_TAG_LIST_HAS_STRING (list, GST_TAG_ARTIST, "foo bar");
     gst_tag_list_free (list);
 
@@ -1054,7 +1033,7 @@
       if (test_data[i].result_size >= 0) {
         fail_unless (list != NULL);
 
-        result_size = gst_structure_n_fields ((GstStructure *) list);
+        result_size = gst_tag_list_n_tags (list);
         fail_unless (result_size == test_data[i].result_size);
 
         /* check the taglist content */
diff --git a/tests/check/libs/video.c b/tests/check/libs/video.c
index 73778c2..116b795 100644
--- a/tests/check/libs/video.c
+++ b/tests/check/libs/video.c
@@ -358,7 +358,7 @@
     case GST_VIDEO_FORMAT_ABGR:
     case GST_VIDEO_FORMAT_RGB:
     case GST_VIDEO_FORMAT_BGR:
-    case GST_VIDEO_FORMAT_RGB8_PALETTED:
+    case GST_VIDEO_FORMAT_RGB8P:
       return TRUE;
     default:
       g_return_val_if_reached (FALSE);
@@ -396,7 +396,8 @@
     fail_if (gst_video_format_from_string (fmt_str) ==
         GST_VIDEO_FORMAT_UNKNOWN);
   }
-  fail_unless_equals_int (num, num_formats);
+  /* Take into account GST_VIDEO_FORMAT_ENCODED */
+  fail_unless_equals_int (num, num_formats - 1);
 
   gst_caps_unref (caps);
 }
diff --git a/tests/examples/Makefile.in b/tests/examples/Makefile.in
index 8d459c4..ae75b1e 100644
--- a/tests/examples/Makefile.in
+++ b/tests/examples/Makefile.in
@@ -55,6 +55,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
 	$(top_srcdir)/common/parallel-subdirs.mak
 subdir = tests/examples
@@ -256,8 +257,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -428,7 +435,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/app/Makefile.in b/tests/examples/app/Makefile.in
index af7e6b6..9dbfec1 100644
--- a/tests/examples/app/Makefile.in
+++ b/tests/examples/app/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = appsrc_ex$(EXEEXT) appsrc-stream$(EXEEXT) \
 	appsrc-stream2$(EXEEXT) appsrc-ra$(EXEEXT) \
 	appsrc-seekable$(EXEEXT) appsink-src$(EXEEXT)
@@ -290,8 +291,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -462,7 +469,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/audio/Makefile.in b/tests/examples/audio/Makefile.in
index 785b6a9..99c4f7f 100644
--- a/tests/examples/audio/Makefile.in
+++ b/tests/examples/audio/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = $(am__EXEEXT_1)
 subdir = tests/examples/audio
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -257,8 +258,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -429,7 +436,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/dynamic/Makefile.in b/tests/examples/dynamic/Makefile.in
index 0a5c526..1415d91 100644
--- a/tests/examples/dynamic/Makefile.in
+++ b/tests/examples/dynamic/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = addstream$(EXEEXT) codec-select$(EXEEXT) \
 	sprinkle$(EXEEXT) sprinkle2$(EXEEXT) sprinkle3$(EXEEXT)
 subdir = tests/examples/dynamic
@@ -273,8 +274,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -445,7 +452,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/encoding/Makefile.in b/tests/examples/encoding/Makefile.in
index 99b1c82..cb0203d 100644
--- a/tests/examples/encoding/Makefile.in
+++ b/tests/examples/encoding/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = $(am__EXEEXT_1)
 subdir = tests/examples/encoding
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -249,8 +250,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -421,7 +428,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/fft/Makefile.in b/tests/examples/fft/Makefile.in
index 723e468..ec14795 100644
--- a/tests/examples/fft/Makefile.in
+++ b/tests/examples/fft/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = fftrange$(EXEEXT)
 subdir = tests/examples/fft
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -247,8 +248,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -419,7 +426,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/gio/Makefile.in b/tests/examples/gio/Makefile.in
index 98628b1..201e6ae 100644
--- a/tests/examples/gio/Makefile.in
+++ b/tests/examples/gio/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 @HAVE_GTK_TRUE@noinst_PROGRAMS = giosrc-mounting$(EXEEXT)
 subdir = tests/examples/gio
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -250,8 +251,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -422,7 +429,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/overlay/Makefile.in b/tests/examples/overlay/Makefile.in
index c0019fb..ae5c8cf 100644
--- a/tests/examples/overlay/Makefile.in
+++ b/tests/examples/overlay/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 @HAVE_GTK_X11_TRUE@@USE_X_TRUE@am__append_1 = gtk-videooverlay
 @HAVE_QT_TRUE@@USE_X_TRUE@am__append_2 = qt-videooverlay
 @HAVE_QT_GV_TRUE@@USE_X_TRUE@am__append_3 = qtgv-videooverlay
@@ -308,8 +309,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -480,7 +487,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/playback/Makefile.am b/tests/examples/playback/Makefile.am
index 3631606..4bc4e44 100644
--- a/tests/examples/playback/Makefile.am
+++ b/tests/examples/playback/Makefile.am
@@ -4,4 +4,8 @@
 	$(top_builddir)/gst-libs/gst/video/libgstvideo-@GST_API_VERSION@.la \
 	$(GST_LIBS) $(GTK_LIBS) $(LIBM)
 
+if HAVE_GTK_QUARTZ
+  AM_CPPFLAGS = '-xobjective-c'
+endif
+
 AM_CFLAGS = -I$(top_builddir)/gst-libs $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS) $(GTK_CFLAGS)
diff --git a/tests/examples/playback/Makefile.in b/tests/examples/playback/Makefile.in
index 7037b20..0256d20 100644
--- a/tests/examples/playback/Makefile.in
+++ b/tests/examples/playback/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = playback-test$(EXEEXT)
 subdir = tests/examples/playback
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -246,8 +247,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -418,7 +425,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
@@ -426,6 +437,7 @@
 	$(top_builddir)/gst-libs/gst/video/libgstvideo-@GST_API_VERSION@.la \
 	$(GST_LIBS) $(GTK_LIBS) $(LIBM)
 
+@HAVE_GTK_QUARTZ_TRUE@AM_CPPFLAGS = '-xobjective-c'
 AM_CFLAGS = -I$(top_builddir)/gst-libs $(GST_PLUGINS_BASE_CFLAGS) $(GST_BASE_CFLAGS) $(GST_CFLAGS) $(GTK_CFLAGS)
 all: all-am
 
diff --git a/tests/examples/playback/playback-test.c b/tests/examples/playback/playback-test.c
index 5f09acd..c12879e 100644
--- a/tests/examples/playback/playback-test.c
+++ b/tests/examples/playback/playback-test.c
@@ -44,7 +44,7 @@
 #elif defined (GDK_WINDOWING_WIN32)
 #include <gdk/gdkwin32.h>
 #elif defined (GDK_WINDOWING_QUARTZ)
-#include <gdk/gdkquartzwindow.h>
+#include <gdk/gdkquartz.h>
 #endif
 
 #include <gst/video/videooverlay.h>
@@ -171,7 +171,7 @@
   gint64 buffering_left;
   GstState state;
   guint update_id;
-  guint seek_timeout_id;
+  guint seek_timeout_id;        /* Used for scrubbing in paused */
   gulong changed_id;
   guint fill_id;
 
@@ -539,11 +539,6 @@
 seek_cb (GtkRange * range, PlaybackApp * app)
 {
   gint64 real;
-  /* If the timer hasn't expired yet, then the pipeline is running */
-  if (app->play_scrub && app->seek_timeout_id != 0) {
-    GST_DEBUG ("do scrub seek, PAUSED");
-    gst_element_set_state (app->pipeline, GST_STATE_PAUSED);
-  }
 
   real =
       gtk_range_get_value (GTK_RANGE (app->seek_scale)) * app->duration /
@@ -1086,7 +1081,7 @@
     for (i = 0; i < app->n_video; i++) {
       g_signal_emit_by_name (app->pipeline, "get-video-tags", i, &tags);
       if (tags) {
-        str = gst_structure_to_string ((GstStructure *) tags);
+        str = gst_tag_list_to_string (tags);
         g_print ("video %d: %s\n", i, str);
         g_free (str);
       }
@@ -1105,7 +1100,7 @@
     for (i = 0; i < app->n_audio; i++) {
       g_signal_emit_by_name (app->pipeline, "get-audio-tags", i, &tags);
       if (tags) {
-        str = gst_structure_to_string ((GstStructure *) tags);
+        str = gst_tag_list_to_string (tags);
         g_print ("audio %d: %s\n", i, str);
         g_free (str);
       }
@@ -1128,7 +1123,7 @@
       if (tags) {
         const GValue *value;
 
-        str = gst_structure_to_string ((GstStructure *) tags);
+        str = gst_tag_list_to_string (tags);
         g_print ("text %d: %s\n", i, str);
         g_free (str);
 
@@ -2112,7 +2107,7 @@
   app->embed_xid = GDK_WINDOW_HWND (window);
   g_print ("Window realize: video window HWND = %lu\n", app->embed_xid);
 #elif defined (GDK_WINDOWING_QUARTZ)
-  app->embed_xid = gdk_quartz_window_get_nsview (window);
+  app->embed_xid = (guintptr) gdk_quartz_window_get_nsview (window);
   g_print ("Window realize: video window NSView = %p\n", app->embed_xid);
 #elif defined (GDK_WINDOWING_X11)
   app->embed_xid = GDK_WINDOW_XID (window);
diff --git a/tests/examples/playrec/Makefile.in b/tests/examples/playrec/Makefile.in
index 529490a..ca699e2 100644
--- a/tests/examples/playrec/Makefile.in
+++ b/tests/examples/playrec/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = playrec$(EXEEXT)
 subdir = tests/examples/playrec
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -246,8 +247,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -418,7 +425,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/seek/Makefile.in b/tests/examples/seek/Makefile.in
index 78def1a..41d2836 100644
--- a/tests/examples/seek/Makefile.in
+++ b/tests/examples/seek/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = $(am__EXEEXT_2)
 subdir = tests/examples/seek
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -268,8 +269,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -440,7 +447,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/examples/seek/jsseek.c b/tests/examples/seek/jsseek.c
index 5c85f12..69cda4e 100644
--- a/tests/examples/seek/jsseek.c
+++ b/tests/examples/seek/jsseek.c
@@ -1814,7 +1814,7 @@
     for (i = 0; i < n_video; i++) {
       g_signal_emit_by_name (pipeline, "get-video-tags", i, &tags);
       if (tags) {
-        str = gst_structure_to_string ((GstStructure *) tags);
+        str = gst_tag_list_to_string (tags);
         g_print ("video %d: %s\n", i, str);
         g_free (str);
       }
@@ -1831,7 +1831,7 @@
     for (i = 0; i < n_audio; i++) {
       g_signal_emit_by_name (pipeline, "get-audio-tags", i, &tags);
       if (tags) {
-        str = gst_structure_to_string ((GstStructure *) tags);
+        str = gst_tag_list_to_string (tags);
         g_print ("audio %d: %s\n", i, str);
         g_free (str);
       }
@@ -1852,7 +1852,7 @@
       if (tags) {
         const GValue *value;
 
-        str = gst_structure_to_string ((GstStructure *) tags);
+        str = gst_tag_list_to_string (tags);
         g_print ("text %d: %s\n", i, str);
         g_free (str);
 
diff --git a/tests/examples/snapshot/Makefile.in b/tests/examples/snapshot/Makefile.in
index a94ae6d..85aa0f5 100644
--- a/tests/examples/snapshot/Makefile.in
+++ b/tests/examples/snapshot/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = $(am__EXEEXT_2)
 subdir = tests/examples/snapshot
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -244,8 +245,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -416,7 +423,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/files/Makefile.in b/tests/files/Makefile.in
index 52b134b..a083e49 100644
--- a/tests/files/Makefile.in
+++ b/tests/files/Makefile.in
@@ -50,6 +50,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 subdir = tests/files
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -211,8 +212,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -383,7 +390,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/icles/Makefile.in b/tests/icles/Makefile.in
index 274b402..ebc40b4 100644
--- a/tests/icles/Makefile.in
+++ b/tests/icles/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 @HAVE_GTK_X11_TRUE@@USE_X_TRUE@am__append_1 = test-colorkey test-videooverlay
 noinst_PROGRAMS = $(am__EXEEXT_2) $(am__EXEEXT_3) \
 	audio-trickplay$(EXEEXT) playbin-text$(EXEEXT) \
@@ -406,8 +407,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -578,7 +585,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/icles/playback/Makefile.in b/tests/icles/playback/Makefile.in
index 0a12061..05bb122 100644
--- a/tests/icles/playback/Makefile.in
+++ b/tests/icles/playback/Makefile.in
@@ -51,6 +51,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 noinst_PROGRAMS = test$(EXEEXT) decodetest$(EXEEXT) test2$(EXEEXT) \
 	test3$(EXEEXT) test4$(EXEEXT) test5$(EXEEXT) test6$(EXEEXT) \
 	test7$(EXEEXT)
@@ -292,8 +293,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -464,7 +471,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tests/icles/test-box.c b/tests/icles/test-box.c
index 09fd3e7..f5cca9a 100644
--- a/tests/icles/test-box.c
+++ b/tests/icles/test-box.c
@@ -25,7 +25,7 @@
 
 #include <gst/gst.h>
 
-#define CAPS " capsfilter caps=\"video/x-raw-yuv, format=(fourcc)I420, width=(int)640, height=(int)480\" "
+#define CAPS " capsfilter caps=\"video/x-raw, format=(string)I420, width=(int)640, height=(int)480\" "
 
 static GstElement *
 make_pipeline (gint type)
diff --git a/tools/Makefile.in b/tools/Makefile.in
index cd8cf59..b27590f 100644
--- a/tools/Makefile.in
+++ b/tools/Makefile.in
@@ -52,6 +52,7 @@
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
+target_triplet = @target@
 bin_PROGRAMS = gst-discoverer-@GST_API_VERSION@$(EXEEXT)
 subdir = tools
 DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
@@ -284,8 +285,14 @@
 GST_REVISION = @GST_REVISION@
 GST_TOOLS_DIR = @GST_TOOLS_DIR@
 GTKDOC_CHECK = @GTKDOC_CHECK@
+GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@
+GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@
+GTKDOC_MKPDF = @GTKDOC_MKPDF@
+GTKDOC_REBASE = @GTKDOC_REBASE@
 GTK_CFLAGS = @GTK_CFLAGS@
 GTK_LIBS = @GTK_LIBS@
+GTK_QUARTZ_CFLAGS = @GTK_QUARTZ_CFLAGS@
+GTK_QUARTZ_LIBS = @GTK_QUARTZ_LIBS@
 GTK_X11_CFLAGS = @GTK_X11_CFLAGS@
 GTK_X11_LIBS = @GTK_X11_LIBS@
 HAVE_CDPARANOIA = @HAVE_CDPARANOIA@
@@ -456,7 +463,11 @@
 sharedstatedir = @sharedstatedir@
 srcdir = @srcdir@
 sysconfdir = @sysconfdir@
+target = @target@
 target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
diff --git a/tools/gst-discoverer.c b/tools/gst-discoverer.c
index e1a4cd8..f706f55 100644
--- a/tools/gst-discoverer.c
+++ b/tools/gst-discoverer.c
@@ -28,6 +28,7 @@
 
 static gboolean async = FALSE;
 static gboolean silent = FALSE;
+static gboolean show_toc = FALSE;
 static gboolean verbose = FALSE;
 
 typedef struct
@@ -102,7 +103,7 @@
   my_g_string_append_printf (s, depth, "Tags:\n");
   tags = gst_discoverer_stream_info_get_tags (info);
   if (tags) {
-    tmp = gst_structure_to_string ((GstStructure *) tags);
+    tmp = gst_tag_list_to_string (tags);
     my_g_string_append_printf (s, depth, "  %s\n", tmp);
     g_free (tmp);
   } else {
@@ -174,7 +175,7 @@
   my_g_string_append_printf (s, depth, "Tags:\n");
   tags = gst_discoverer_stream_info_get_tags (info);
   if (tags) {
-    tmp = gst_structure_to_string ((GstStructure *) tags);
+    tmp = gst_tag_list_to_string (tags);
     my_g_string_append_printf (s, depth, "  %s\n", tmp);
     g_free (tmp);
   } else {
@@ -226,7 +227,7 @@
   my_g_string_append_printf (s, depth, "Tags:\n");
   tags = gst_discoverer_stream_info_get_tags (info);
   if (tags) {
-    tmp = gst_structure_to_string ((GstStructure *) tags);
+    tmp = gst_tag_list_to_string (tags);
     my_g_string_append_printf (s, depth, "  %s\n", tmp);
     g_free (tmp);
   } else {
@@ -310,10 +311,9 @@
   }
 }
 
-static gboolean
-print_tag_each (GQuark field_id, const GValue * value, gpointer user_data)
+static void
+print_tag (const gchar * tag_name, const GValue * value, gint tab)
 {
-  gint tab = GPOINTER_TO_INT (user_data);
   gchar *ser;
 
   if (G_VALUE_HOLDS_STRING (value))
@@ -332,26 +332,90 @@
   } else
     ser = gst_value_serialize (value);
 
-  g_print ("%*s%s: %s\n", tab, " ",
-      gst_tag_get_nick (g_quark_to_string (field_id)), ser);
+  g_print ("%*s%s: %s\n", tab, " ", gst_tag_get_nick (tag_name), ser);
   g_free (ser);
+}
 
-  return TRUE;
+/* FIXME: this function is almost identical to print_tag() */
+static void
+print_tag_foreach (const GstTagList * tags, const gchar * tag,
+    gpointer user_data)
+{
+  GValue val = { 0, };
+  gchar *str;
+  gint depth = GPOINTER_TO_INT (user_data);
+
+  gst_tag_list_copy_value (&val, tags, tag);
+
+  if (G_VALUE_HOLDS_STRING (&val))
+    str = g_value_dup_string (&val);
+  else
+    str = gst_value_serialize (&val);
+
+  g_print ("%*s%s: %s\n", 2 * depth, " ", gst_tag_get_nick (tag), str);
+  g_free (str);
+
+  g_value_unset (&val);
+}
+
+#define MAX_INDENT 40
+
+static void
+print_toc_entry (gpointer data, gpointer user_data)
+{
+  GstTocEntry *entry = (GstTocEntry *) data;
+  gint depth = GPOINTER_TO_INT (user_data);
+  guint indent = MIN (GPOINTER_TO_UINT (user_data), MAX_INDENT);
+  gint64 start, stop;
+
+  gst_toc_entry_get_start_stop (entry, &start, &stop);
+  g_print ("%*s%s: start: %" GST_TIME_FORMAT " stop: %" GST_TIME_FORMAT "\n",
+      depth, " ", gst_toc_entry_type_get_nick (entry->type),
+      GST_TIME_ARGS (start), GST_TIME_ARGS (stop));
+  indent += 2;
+
+  /* print tags */
+  if (entry->type == GST_TOC_ENTRY_TYPE_CHAPTER)
+    g_print ("%*sTags:\n", 2 * depth, " ");
+  gst_tag_list_foreach (entry->tags, print_tag_foreach,
+      GUINT_TO_POINTER (indent));
+
+  /* loop over sub-toc entries */
+  g_list_foreach (entry->subentries, print_toc_entry,
+      GUINT_TO_POINTER (indent));
 }
 
 static void
 print_properties (GstDiscovererInfo * info, gint tab)
 {
   const GstTagList *tags;
+  const GstToc *toc;
 
   g_print ("%*sDuration: %" GST_TIME_FORMAT "\n", tab + 1, " ",
       GST_TIME_ARGS (gst_discoverer_info_get_duration (info)));
   g_print ("%*sSeekable: %s\n", tab + 1, " ",
       (gst_discoverer_info_get_seekable (info) ? "yes" : "no"));
   if ((tags = gst_discoverer_info_get_tags (info))) {
+    guint num_tags, i;
+
     g_print ("%*sTags: \n", tab + 1, " ");
-    gst_structure_foreach ((const GstStructure *) tags, print_tag_each,
-        GINT_TO_POINTER (tab + 5));
+    num_tags = gst_tag_list_n_tags (tags);
+    for (i = 0; i < num_tags; ++i) {
+      const GValue *val;
+      const gchar *tag_name;
+      guint num_entries, j;
+
+      tag_name = gst_tag_list_nth_tag_name (tags, i);
+      num_entries = gst_tag_list_get_tag_size (tags, tag_name);
+      for (j = 0; j < num_entries; ++j) {
+        val = gst_tag_list_get_value_index (tags, tag_name, j);
+        print_tag (tag_name, val, tab + 5);
+      }
+    }
+  }
+  if (show_toc && (toc = gst_discoverer_info_get_toc (info))) {
+    g_print ("%*sTOC: \n", tab + 1, " ");
+    g_list_foreach (toc->entries, print_toc_entry, GUINT_TO_POINTER (tab + 5));
   }
 }
 
@@ -511,6 +575,8 @@
         "Specify timeout (in seconds, default 10)", "T"},
     /* {"elem", 'e', 0, G_OPTION_ARG_NONE, &elem_seek, */
     /*     "Seek on elements instead of pads", NULL}, */
+    {"toc", 'c', 0, G_OPTION_ARG_NONE, &show_toc,
+        "Output TOC (chapters and editions)", NULL},
     {"verbose", 'v', 0, G_OPTION_ARG_NONE, &verbose,
         "Verbose properties", NULL},
     {NULL}
diff --git a/win32/common/_stdint.h b/win32/common/_stdint.h
index 6e93ec8..4282693 100644
--- a/win32/common/_stdint.h
+++ b/win32/common/_stdint.h
@@ -1,8 +1,8 @@
 #ifndef _GST_PLUGINS_BASE__STDINT_H
 #define _GST_PLUGINS_BASE__STDINT_H 1
 #ifndef _GENERATED_STDINT_H
-#define _GENERATED_STDINT_H "gst-plugins-base 0.11.91"
-/* generated using gnu compiler Debian clang version 3.0-6 (tags/RELEASE_30/final) (based on LLVM 3.0) */
+#define _GENERATED_STDINT_H "gst-plugins-base 0.11.92"
+/* generated using gnu compiler Debian clang version 3.1-4 (branches/release_31) (based on LLVM 3.1) */
 #define _STDINT_HAVE_STDINT_H 1
 #include <stdint.h>
 #endif
diff --git a/win32/common/audio-enumtypes.c b/win32/common/audio-enumtypes.c
index 8e28beb..8095fa5 100644
--- a/win32/common/audio-enumtypes.c
+++ b/win32/common/audio-enumtypes.c
@@ -88,6 +88,22 @@
 }
 
 GType
+gst_audio_pack_flags_get_type (void)
+{
+  static volatile gsize g_define_type_id__volatile = 0;
+  if (g_once_init_enter (&g_define_type_id__volatile)) {
+    static const GEnumValue values[] = {
+      {GST_AUDIO_PACK_FLAG_NONE, "GST_AUDIO_PACK_FLAG_NONE", "none"},
+      {0, NULL, NULL}
+    };
+    GType g_define_type_id =
+        g_enum_register_static ("GstAudioPackFlags", values);
+    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
+  }
+  return g_define_type_id__volatile;
+}
+
+GType
 gst_audio_channel_position_get_type (void)
 {
   static volatile gsize g_define_type_id__volatile = 0;
diff --git a/win32/common/audio-enumtypes.h b/win32/common/audio-enumtypes.h
index ed54c1b..d3c6729 100644
--- a/win32/common/audio-enumtypes.h
+++ b/win32/common/audio-enumtypes.h
@@ -13,6 +13,8 @@
 #define GST_TYPE_AUDIO_FORMAT (gst_audio_format_get_type())
 GType gst_audio_format_flags_get_type (void);
 #define GST_TYPE_AUDIO_FORMAT_FLAGS (gst_audio_format_flags_get_type())
+GType gst_audio_pack_flags_get_type (void);
+#define GST_TYPE_AUDIO_PACK_FLAGS (gst_audio_pack_flags_get_type())
 GType gst_audio_channel_position_get_type (void);
 #define GST_TYPE_AUDIO_CHANNEL_POSITION (gst_audio_channel_position_get_type())
 GType gst_audio_flags_get_type (void);
diff --git a/win32/common/config.h b/win32/common/config.h
index 1845e6f..d1f0395 100644
--- a/win32/common/config.h
+++ b/win32/common/config.h
@@ -87,7 +87,7 @@
 #define GST_PACKAGE_ORIGIN "Unknown package origin"
 
 /* GStreamer package release date/time for plugins as YYYY-MM-DD */
-#define GST_PACKAGE_RELEASE_DATETIME "2012-05-13"
+#define GST_PACKAGE_RELEASE_DATETIME "2012-06-07"
 
 /* Define to enable ALSA (used by alsa). */
 #undef HAVE_ALSA
@@ -103,46 +103,46 @@
    the CoreFoundation framework. */
 #undef HAVE_CFPREFERENCESCOPYAPPVALUE
 
-/* Define if the host CPU is an Alpha */
+/* Define if the target CPU is an Alpha */
 #undef HAVE_CPU_ALPHA
 
-/* Define if the host CPU is an ARM */
+/* Define if the target CPU is an ARM */
 #undef HAVE_CPU_ARM
 
-/* Define if the host CPU is a CRIS */
+/* Define if the target CPU is a CRIS */
 #undef HAVE_CPU_CRIS
 
-/* Define if the host CPU is a CRISv32 */
+/* Define if the target CPU is a CRISv32 */
 #undef HAVE_CPU_CRISV32
 
-/* Define if the host CPU is a HPPA */
+/* Define if the target CPU is a HPPA */
 #undef HAVE_CPU_HPPA
 
-/* Define if the host CPU is an x86 */
+/* Define if the target CPU is an x86 */
 #define HAVE_CPU_I386 1
 
-/* Define if the host CPU is a IA64 */
+/* Define if the target CPU is a IA64 */
 #undef HAVE_CPU_IA64
 
-/* Define if the host CPU is a M68K */
+/* Define if the target CPU is a M68K */
 #undef HAVE_CPU_M68K
 
-/* Define if the host CPU is a MIPS */
+/* Define if the target CPU is a MIPS */
 #undef HAVE_CPU_MIPS
 
-/* Define if the host CPU is a PowerPC */
+/* Define if the target CPU is a PowerPC */
 #undef HAVE_CPU_PPC
 
-/* Define if the host CPU is a 64 bit PowerPC */
+/* Define if the target CPU is a 64 bit PowerPC */
 #undef HAVE_CPU_PPC64
 
-/* Define if the host CPU is a S390 */
+/* Define if the target CPU is a S390 */
 #undef HAVE_CPU_S390
 
-/* Define if the host CPU is a SPARC */
+/* Define if the target CPU is a SPARC */
 #undef HAVE_CPU_SPARC
 
-/* Define if the host CPU is a x86_64 */
+/* Define if the target CPU is a x86_64 */
 #undef HAVE_CPU_X86_64
 
 /* Define if the GNU dcgettext() function is already present or preinstalled.
@@ -313,7 +313,7 @@
 #define PACKAGE_NAME "GStreamer Base Plug-ins"
 
 /* Define to the full name and version of this package. */
-#define PACKAGE_STRING "GStreamer Base Plug-ins 0.11.91"
+#define PACKAGE_STRING "GStreamer Base Plug-ins 0.11.92"
 
 /* Define to the one symbol short name of this package. */
 #define PACKAGE_TARNAME "gst-plugins-base"
@@ -322,7 +322,7 @@
 #undef PACKAGE_URL
 
 /* Define to the version of this package. */
-#define PACKAGE_VERSION "0.11.91"
+#define PACKAGE_VERSION "0.11.92"
 
 /* directory where plugins are located */
 #ifdef _DEBUG
@@ -349,11 +349,14 @@
 /* Define to 1 if you have the ANSI C header files. */
 #undef STDC_HEADERS
 
+/* the target CPU */
+#undef TARGET_CPU
+
 /* "Define if building for android" */
 #undef USE_TREMOLO
 
 /* Version number of package */
-#define VERSION "0.11.91"
+#define VERSION "0.11.92"
 
 /* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
    significant byte first (like Motorola and SPARC, unlike Intel). */
diff --git a/win32/common/libgstaudio.def b/win32/common/libgstaudio.def
index f3e1f50..2e6a7e4 100644
--- a/win32/common/libgstaudio.def
+++ b/win32/common/libgstaudio.def
@@ -118,6 +118,7 @@
 	gst_audio_layout_get_type
 	gst_audio_marshal_VOID__OBJECT_INT
 	gst_audio_marshal_VOID__OBJECT_ULONG
+	gst_audio_pack_flags_get_type
 	gst_audio_reorder_channels
 	gst_audio_ring_buffer_acquire
 	gst_audio_ring_buffer_activate
diff --git a/win32/common/libgstpbutils.def b/win32/common/libgstpbutils.def
index 0e2fcf9..0d81051 100644
--- a/win32/common/libgstpbutils.def
+++ b/win32/common/libgstpbutils.def
@@ -34,6 +34,7 @@
 	gst_discoverer_info_get_streams
 	gst_discoverer_info_get_subtitle_streams
 	gst_discoverer_info_get_tags
+	gst_discoverer_info_get_toc
 	gst_discoverer_info_get_type
 	gst_discoverer_info_get_uri
 	gst_discoverer_info_get_video_streams
@@ -47,6 +48,7 @@
 	gst_discoverer_stream_info_get_previous
 	gst_discoverer_stream_info_get_stream_type_nick
 	gst_discoverer_stream_info_get_tags
+	gst_discoverer_stream_info_get_toc
 	gst_discoverer_stream_info_get_type
 	gst_discoverer_stream_info_list_free
 	gst_discoverer_subtitle_info_get_language
diff --git a/win32/common/libgstvideo.def b/win32/common/libgstvideo.def
index f479927..43c7ab0 100644
--- a/win32/common/libgstvideo.def
+++ b/win32/common/libgstvideo.def
@@ -44,14 +44,16 @@
 	gst_navigation_send_key_event
 	gst_navigation_send_mouse_event
 	gst_video_alignment_reset
-	gst_video_buffer_flags_get_type
 	gst_video_buffer_pool_get_type
 	gst_video_buffer_pool_new
 	gst_video_calculate_display_ratio
+	gst_video_chroma_from_string
 	gst_video_chroma_site_get_type
+	gst_video_chroma_to_string
 	gst_video_codec_frame_get_type
+	gst_video_codec_frame_get_user_data
 	gst_video_codec_frame_ref
-	gst_video_codec_frame_set_hook
+	gst_video_codec_frame_set_user_data
 	gst_video_codec_frame_unref
 	gst_video_codec_state_get_type
 	gst_video_codec_state_ref
@@ -61,6 +63,7 @@
 	gst_video_color_range_get_type
 	gst_video_colorimetry_from_string
 	gst_video_colorimetry_matches
+	gst_video_colorimetry_to_string
 	gst_video_convert_sample
 	gst_video_convert_sample_async
 	gst_video_crop_meta_api_get_type
@@ -114,7 +117,6 @@
 	gst_video_format_to_string
 	gst_video_frame_copy
 	gst_video_frame_copy_plane
-	gst_video_frame_flags_get_type
 	gst_video_frame_map
 	gst_video_frame_map_id
 	gst_video_frame_unmap
@@ -146,7 +148,7 @@
 	gst_video_overlay_prepare_window_handle
 	gst_video_overlay_set_render_rectangle
 	gst_video_overlay_set_window_handle
-	gst_video_parse_caps_palette
+	gst_video_pack_flags_get_type
 	gst_video_sink_center_rect
 	gst_video_sink_get_type
 	gst_video_transfer_function_get_type
diff --git a/win32/common/video-enumtypes.c b/win32/common/video-enumtypes.c
index f3eaef7..d300323 100644
--- a/win32/common/video-enumtypes.c
+++ b/win32/common/video-enumtypes.c
@@ -4,10 +4,13 @@
 #include "video-enumtypes.h"
 
 #include "video.h"
+#include "video-format.h"
+#include "video-color.h"
+#include "video-info.h"
 #include "colorbalance.h"
 #include "navigation.h"
 
-/* enumerations from "video.h" */
+/* enumerations from "video-format.h" */
 GType
 gst_video_format_get_type (void)
 {
@@ -15,6 +18,7 @@
   if (g_once_init_enter (&g_define_type_id__volatile)) {
     static const GEnumValue values[] = {
       {GST_VIDEO_FORMAT_UNKNOWN, "GST_VIDEO_FORMAT_UNKNOWN", "unknown"},
+      {GST_VIDEO_FORMAT_ENCODED, "GST_VIDEO_FORMAT_ENCODED", "encoded"},
       {GST_VIDEO_FORMAT_I420, "GST_VIDEO_FORMAT_I420", "i420"},
       {GST_VIDEO_FORMAT_YV12, "GST_VIDEO_FORMAT_YV12", "yv12"},
       {GST_VIDEO_FORMAT_YUY2, "GST_VIDEO_FORMAT_YUY2", "yuy2"},
@@ -42,23 +46,21 @@
       {GST_VIDEO_FORMAT_GRAY16_BE, "GST_VIDEO_FORMAT_GRAY16_BE", "gray16-be"},
       {GST_VIDEO_FORMAT_GRAY16_LE, "GST_VIDEO_FORMAT_GRAY16_LE", "gray16-le"},
       {GST_VIDEO_FORMAT_v308, "GST_VIDEO_FORMAT_v308", "v308"},
-      {GST_VIDEO_FORMAT_Y800, "GST_VIDEO_FORMAT_Y800", "y800"},
-      {GST_VIDEO_FORMAT_Y16, "GST_VIDEO_FORMAT_Y16", "y16"},
       {GST_VIDEO_FORMAT_RGB16, "GST_VIDEO_FORMAT_RGB16", "rgb16"},
       {GST_VIDEO_FORMAT_BGR16, "GST_VIDEO_FORMAT_BGR16", "bgr16"},
       {GST_VIDEO_FORMAT_RGB15, "GST_VIDEO_FORMAT_RGB15", "rgb15"},
       {GST_VIDEO_FORMAT_BGR15, "GST_VIDEO_FORMAT_BGR15", "bgr15"},
       {GST_VIDEO_FORMAT_UYVP, "GST_VIDEO_FORMAT_UYVP", "uyvp"},
       {GST_VIDEO_FORMAT_A420, "GST_VIDEO_FORMAT_A420", "a420"},
-      {GST_VIDEO_FORMAT_RGB8_PALETTED, "GST_VIDEO_FORMAT_RGB8_PALETTED",
-          "rgb8-paletted"},
+      {GST_VIDEO_FORMAT_RGB8P, "GST_VIDEO_FORMAT_RGB8P", "rgb8p"},
       {GST_VIDEO_FORMAT_YUV9, "GST_VIDEO_FORMAT_YUV9", "yuv9"},
       {GST_VIDEO_FORMAT_YVU9, "GST_VIDEO_FORMAT_YVU9", "yvu9"},
       {GST_VIDEO_FORMAT_IYU1, "GST_VIDEO_FORMAT_IYU1", "iyu1"},
       {GST_VIDEO_FORMAT_ARGB64, "GST_VIDEO_FORMAT_ARGB64", "argb64"},
       {GST_VIDEO_FORMAT_AYUV64, "GST_VIDEO_FORMAT_AYUV64", "ayuv64"},
       {GST_VIDEO_FORMAT_r210, "GST_VIDEO_FORMAT_r210", "r210"},
-      {GST_VIDEO_FORMAT_ENCODED, "GST_VIDEO_FORMAT_ENCODED", "encoded"},
+      {GST_VIDEO_FORMAT_I420_10BE, "GST_VIDEO_FORMAT_I420_10BE", "i420-10be"},
+      {GST_VIDEO_FORMAT_I420_10LE, "GST_VIDEO_FORMAT_I420_10LE", "i420-10le"},
       {0, NULL, NULL}
     };
     GType g_define_type_id = g_enum_register_static ("GstVideoFormat", values);
@@ -68,70 +70,6 @@
 }
 
 GType
-gst_video_format_flags_get_type (void)
-{
-  static volatile gsize g_define_type_id__volatile = 0;
-  if (g_once_init_enter (&g_define_type_id__volatile)) {
-    static const GFlagsValue values[] = {
-      {GST_VIDEO_FORMAT_FLAG_YUV, "GST_VIDEO_FORMAT_FLAG_YUV", "yuv"},
-      {GST_VIDEO_FORMAT_FLAG_RGB, "GST_VIDEO_FORMAT_FLAG_RGB", "rgb"},
-      {GST_VIDEO_FORMAT_FLAG_GRAY, "GST_VIDEO_FORMAT_FLAG_GRAY", "gray"},
-      {GST_VIDEO_FORMAT_FLAG_ALPHA, "GST_VIDEO_FORMAT_FLAG_ALPHA", "alpha"},
-      {GST_VIDEO_FORMAT_FLAG_LE, "GST_VIDEO_FORMAT_FLAG_LE", "le"},
-      {GST_VIDEO_FORMAT_FLAG_PALETTE, "GST_VIDEO_FORMAT_FLAG_PALETTE",
-          "palette"},
-      {GST_VIDEO_FORMAT_FLAG_COMPLEX, "GST_VIDEO_FORMAT_FLAG_COMPLEX",
-          "complex"},
-      {0, NULL, NULL}
-    };
-    GType g_define_type_id =
-        g_flags_register_static ("GstVideoFormatFlags", values);
-    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
-  }
-  return g_define_type_id__volatile;
-}
-
-GType
-gst_video_interlace_mode_get_type (void)
-{
-  static volatile gsize g_define_type_id__volatile = 0;
-  if (g_once_init_enter (&g_define_type_id__volatile)) {
-    static const GEnumValue values[] = {
-      {GST_VIDEO_INTERLACE_MODE_PROGRESSIVE,
-          "GST_VIDEO_INTERLACE_MODE_PROGRESSIVE", "progressive"},
-      {GST_VIDEO_INTERLACE_MODE_INTERLEAVED,
-          "GST_VIDEO_INTERLACE_MODE_INTERLEAVED", "interleaved"},
-      {GST_VIDEO_INTERLACE_MODE_MIXED, "GST_VIDEO_INTERLACE_MODE_MIXED",
-          "mixed"},
-      {GST_VIDEO_INTERLACE_MODE_FIELDS, "GST_VIDEO_INTERLACE_MODE_FIELDS",
-          "fields"},
-      {0, NULL, NULL}
-    };
-    GType g_define_type_id =
-        g_enum_register_static ("GstVideoInterlaceMode", values);
-    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
-  }
-  return g_define_type_id__volatile;
-}
-
-GType
-gst_video_flags_get_type (void)
-{
-  static volatile gsize g_define_type_id__volatile = 0;
-  if (g_once_init_enter (&g_define_type_id__volatile)) {
-    static const GFlagsValue values[] = {
-      {GST_VIDEO_FLAG_NONE, "GST_VIDEO_FLAG_NONE", "none"},
-      {GST_VIDEO_FLAG_VARIABLE_FPS, "GST_VIDEO_FLAG_VARIABLE_FPS",
-          "variable-fps"},
-      {0, NULL, NULL}
-    };
-    GType g_define_type_id = g_flags_register_static ("GstVideoFlags", values);
-    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
-  }
-  return g_define_type_id__volatile;
-}
-
-GType
 gst_video_chroma_site_get_type (void)
 {
   static volatile gsize g_define_type_id__volatile = 0;
@@ -161,6 +99,47 @@
 }
 
 GType
+gst_video_format_flags_get_type (void)
+{
+  static volatile gsize g_define_type_id__volatile = 0;
+  if (g_once_init_enter (&g_define_type_id__volatile)) {
+    static const GFlagsValue values[] = {
+      {GST_VIDEO_FORMAT_FLAG_YUV, "GST_VIDEO_FORMAT_FLAG_YUV", "yuv"},
+      {GST_VIDEO_FORMAT_FLAG_RGB, "GST_VIDEO_FORMAT_FLAG_RGB", "rgb"},
+      {GST_VIDEO_FORMAT_FLAG_GRAY, "GST_VIDEO_FORMAT_FLAG_GRAY", "gray"},
+      {GST_VIDEO_FORMAT_FLAG_ALPHA, "GST_VIDEO_FORMAT_FLAG_ALPHA", "alpha"},
+      {GST_VIDEO_FORMAT_FLAG_LE, "GST_VIDEO_FORMAT_FLAG_LE", "le"},
+      {GST_VIDEO_FORMAT_FLAG_PALETTE, "GST_VIDEO_FORMAT_FLAG_PALETTE",
+          "palette"},
+      {GST_VIDEO_FORMAT_FLAG_COMPLEX, "GST_VIDEO_FORMAT_FLAG_COMPLEX",
+          "complex"},
+      {0, NULL, NULL}
+    };
+    GType g_define_type_id =
+        g_flags_register_static ("GstVideoFormatFlags", values);
+    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
+  }
+  return g_define_type_id__volatile;
+}
+
+GType
+gst_video_pack_flags_get_type (void)
+{
+  static volatile gsize g_define_type_id__volatile = 0;
+  if (g_once_init_enter (&g_define_type_id__volatile)) {
+    static const GEnumValue values[] = {
+      {GST_VIDEO_PACK_FLAG_NONE, "GST_VIDEO_PACK_FLAG_NONE", "none"},
+      {0, NULL, NULL}
+    };
+    GType g_define_type_id =
+        g_enum_register_static ("GstVideoPackFlags", values);
+    g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
+  }
+  return g_define_type_id__volatile;
+}
+
+/* enumerations from "video-color.h" */
+GType
 gst_video_color_range_get_type (void)
 {
   static volatile gsize g_define_type_id__volatile = 0;
@@ -247,6 +226,8 @@
           "GST_VIDEO_COLOR_PRIMARIES_SMPTE170M", "smpte170m"},
       {GST_VIDEO_COLOR_PRIMARIES_SMPTE240M,
           "GST_VIDEO_COLOR_PRIMARIES_SMPTE240M", "smpte240m"},
+      {GST_VIDEO_COLOR_PRIMARIES_FILM, "GST_VIDEO_COLOR_PRIMARIES_FILM",
+          "film"},
       {0, NULL, NULL}
     };
     GType g_define_type_id =
@@ -256,41 +237,44 @@
   return g_define_type_id__volatile;
 }
 
+/* enumerations from "video-info.h" */
 GType
-gst_video_frame_flags_get_type (void)
+gst_video_interlace_mode_get_type (void)
 {
   static volatile gsize g_define_type_id__volatile = 0;
   if (g_once_init_enter (&g_define_type_id__volatile)) {
-    static const GFlagsValue values[] = {
-      {GST_VIDEO_FRAME_FLAG_NONE, "GST_VIDEO_FRAME_FLAG_NONE", "none"},
-      {GST_VIDEO_FRAME_FLAG_TFF, "GST_VIDEO_FRAME_FLAG_TFF", "tff"},
-      {GST_VIDEO_FRAME_FLAG_RFF, "GST_VIDEO_FRAME_FLAG_RFF", "rff"},
-      {GST_VIDEO_FRAME_FLAG_ONEFIELD, "GST_VIDEO_FRAME_FLAG_ONEFIELD",
-          "onefield"},
+    static const GEnumValue values[] = {
+      {GST_VIDEO_INTERLACE_MODE_PROGRESSIVE,
+          "GST_VIDEO_INTERLACE_MODE_PROGRESSIVE", "progressive"},
+      {GST_VIDEO_INTERLACE_MODE_INTERLEAVED,
+          "GST_VIDEO_INTERLACE_MODE_INTERLEAVED", "interleaved"},
+      {GST_VIDEO_INTERLACE_MODE_MIXED, "GST_VIDEO_INTERLACE_MODE_MIXED",
+          "mixed"},
+      {GST_VIDEO_INTERLACE_MODE_FIELDS, "GST_VIDEO_INTERLACE_MODE_FIELDS",
+          "fields"},
       {0, NULL, NULL}
     };
     GType g_define_type_id =
-        g_flags_register_static ("GstVideoFrameFlags", values);
+        g_enum_register_static ("GstVideoInterlaceMode", values);
     g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
   }
   return g_define_type_id__volatile;
 }
 
 GType
-gst_video_buffer_flags_get_type (void)
+gst_video_flags_get_type (void)
 {
   static volatile gsize g_define_type_id__volatile = 0;
   if (g_once_init_enter (&g_define_type_id__volatile)) {
     static const GFlagsValue values[] = {
-      {GST_VIDEO_BUFFER_FLAG_TFF, "GST_VIDEO_BUFFER_FLAG_TFF", "tff"},
-      {GST_VIDEO_BUFFER_FLAG_RFF, "GST_VIDEO_BUFFER_FLAG_RFF", "rff"},
-      {GST_VIDEO_BUFFER_FLAG_ONEFIELD, "GST_VIDEO_BUFFER_FLAG_ONEFIELD",
-          "onefield"},
-      {GST_VIDEO_BUFFER_FLAG_LAST, "GST_VIDEO_BUFFER_FLAG_LAST", "last"},
+      {GST_VIDEO_FLAG_NONE, "GST_VIDEO_FLAG_NONE", "none"},
+      {GST_VIDEO_FLAG_VARIABLE_FPS, "GST_VIDEO_FLAG_VARIABLE_FPS",
+          "variable-fps"},
+      {GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA, "GST_VIDEO_FLAG_PREMULTIPLIED_ALPHA",
+          "premultiplied-alpha"},
       {0, NULL, NULL}
     };
-    GType g_define_type_id =
-        g_flags_register_static ("GstVideoBufferFlags", values);
+    GType g_define_type_id = g_flags_register_static ("GstVideoFlags", values);
     g_once_init_leave (&g_define_type_id__volatile, g_define_type_id);
   }
   return g_define_type_id__volatile;
diff --git a/win32/common/video-enumtypes.h b/win32/common/video-enumtypes.h
index dd22289..6e78a82 100644
--- a/win32/common/video-enumtypes.h
+++ b/win32/common/video-enumtypes.h
@@ -8,17 +8,17 @@
 
 G_BEGIN_DECLS
 
-/* enumerations from "video.h" */
+/* enumerations from "video-format.h" */
 GType gst_video_format_get_type (void);
 #define GST_TYPE_VIDEO_FORMAT (gst_video_format_get_type())
-GType gst_video_format_flags_get_type (void);
-#define GST_TYPE_VIDEO_FORMAT_FLAGS (gst_video_format_flags_get_type())
-GType gst_video_interlace_mode_get_type (void);
-#define GST_TYPE_VIDEO_INTERLACE_MODE (gst_video_interlace_mode_get_type())
-GType gst_video_flags_get_type (void);
-#define GST_TYPE_VIDEO_FLAGS (gst_video_flags_get_type())
 GType gst_video_chroma_site_get_type (void);
 #define GST_TYPE_VIDEO_CHROMA_SITE (gst_video_chroma_site_get_type())
+GType gst_video_format_flags_get_type (void);
+#define GST_TYPE_VIDEO_FORMAT_FLAGS (gst_video_format_flags_get_type())
+GType gst_video_pack_flags_get_type (void);
+#define GST_TYPE_VIDEO_PACK_FLAGS (gst_video_pack_flags_get_type())
+
+/* enumerations from "video-color.h" */
 GType gst_video_color_range_get_type (void);
 #define GST_TYPE_VIDEO_COLOR_RANGE (gst_video_color_range_get_type())
 GType gst_video_color_matrix_get_type (void);
@@ -27,10 +27,12 @@
 #define GST_TYPE_VIDEO_TRANSFER_FUNCTION (gst_video_transfer_function_get_type())
 GType gst_video_color_primaries_get_type (void);
 #define GST_TYPE_VIDEO_COLOR_PRIMARIES (gst_video_color_primaries_get_type())
-GType gst_video_frame_flags_get_type (void);
-#define GST_TYPE_VIDEO_FRAME_FLAGS (gst_video_frame_flags_get_type())
-GType gst_video_buffer_flags_get_type (void);
-#define GST_TYPE_VIDEO_BUFFER_FLAGS (gst_video_buffer_flags_get_type())
+
+/* enumerations from "video-info.h" */
+GType gst_video_interlace_mode_get_type (void);
+#define GST_TYPE_VIDEO_INTERLACE_MODE (gst_video_interlace_mode_get_type())
+GType gst_video_flags_get_type (void);
+#define GST_TYPE_VIDEO_FLAGS (gst_video_flags_get_type())
 
 /* enumerations from "colorbalance.h" */
 GType gst_color_balance_type_get_type (void);