add multilib aware gst-plugins
git-svn-id: https://svn.disconnected-by-peer.at/svn/linamh/trunk/linamh@2776 6952d904-891a-0410-993b-d76249ca496b
This commit is contained in:
233
media-plugins/gst-plugins-ffmpeg/files/0.10.5/lavc.patch
Normal file
233
media-plugins/gst-plugins-ffmpeg/files/0.10.5/lavc.patch
Normal file
@@ -0,0 +1,233 @@
|
||||
Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcfg.c
|
||||
===================================================================
|
||||
--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegcfg.c
|
||||
+++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcfg.c
|
||||
@@ -272,7 +272,9 @@ gst_ffmpeg_flags_get_type (void)
|
||||
{CODEC_FLAG_GRAY, "Only decode/encode grayscale", "gray"},
|
||||
{CODEC_FLAG_NORMALIZE_AQP,
|
||||
"Normalize Adaptive Quantization (masking, etc)", "aqp"},
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
{CODEC_FLAG_TRELLIS_QUANT, "Trellis Quantization", "trellis"},
|
||||
+#endif
|
||||
{CODEC_FLAG_GLOBAL_HEADER,
|
||||
"Global headers in extradata instead of every keyframe",
|
||||
"global-headers"},
|
||||
@@ -669,6 +671,11 @@ gst_ffmpeg_cfg_init ()
|
||||
"Prediction Method",
|
||||
GST_TYPE_FFMPEG_PRED_METHOD, FF_PRED_LEFT, G_PARAM_READWRITE);
|
||||
gst_ffmpeg_add_pspec (pspec, config.prediction_method, FALSE, huffyuv, NULL);
|
||||
+#if LIBAVCODEC_VERSION_INT >= ((52<<16)+(0<<8)+0)
|
||||
+ pspec = g_param_spec_int ("trellis", "Trellis Quantization",
|
||||
+ "Trellis RD quantization", 0, 1, 1, G_PARAM_READWRITE);
|
||||
+ gst_ffmpeg_add_pspec (pspec, config.trellis, FALSE, mpeg, NULL);
|
||||
+#endif
|
||||
}
|
||||
|
||||
/* ==== END CONFIGURATION SECTION ==== */
|
||||
Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcodecmap.c
|
||||
===================================================================
|
||||
--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegcodecmap.c
|
||||
+++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegcodecmap.c
|
||||
@@ -332,7 +332,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"depth", G_TYPE_INT, context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "depth", G_TYPE_INT, context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -511,7 +515,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
caps = gst_ff_vid_caps_new (context, codec_id, "video/x-huffyuv", NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"bpp", G_TYPE_INT, context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "bpp", G_TYPE_INT, context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -627,7 +635,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
"layout", G_TYPE_STRING, "microsoft", NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"depth", G_TYPE_INT, (gint) context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "depth", G_TYPE_INT, (gint) context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
} else {
|
||||
gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 1, 64, NULL);
|
||||
}
|
||||
@@ -638,7 +650,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
"layout", G_TYPE_STRING, "quicktime", NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"depth", G_TYPE_INT, (gint) context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "depth", G_TYPE_INT, (gint) context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
} else {
|
||||
gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 1, 64, NULL);
|
||||
}
|
||||
@@ -688,7 +704,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
caps = gst_ff_vid_caps_new (context, codec_id, "video/x-camtasia", NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"depth", G_TYPE_INT, (gint) context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "depth", G_TYPE_INT, (gint) context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
} else {
|
||||
gst_caps_set_simple (caps, "depth", GST_TYPE_INT_RANGE, 8, 32, NULL);
|
||||
}
|
||||
@@ -1026,7 +1046,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
caps = gst_ff_aud_caps_new (context, codec_id, "audio/x-alac", NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"samplesize", G_TYPE_INT, context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "samplesize", G_TYPE_INT, context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -1049,7 +1073,11 @@ gst_ffmpeg_codecid_to_caps (enum CodecID
|
||||
caps = gst_ff_aud_caps_new (context, codec_id, "audio/x-tta", NULL);
|
||||
if (context) {
|
||||
gst_caps_set_simple (caps,
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
"samplesize", G_TYPE_INT, context->bits_per_sample, NULL);
|
||||
+#else
|
||||
+ "samplesize", G_TYPE_INT, context->bits_per_coded_sample, NULL);
|
||||
+#endif
|
||||
}
|
||||
break;
|
||||
case CODEC_ID_VORBIS:
|
||||
@@ -1416,7 +1444,11 @@ gst_ffmpeg_caps_to_pixfmt (const GstCaps
|
||||
|
||||
gst_structure_get_int (structure, "width", &context->width);
|
||||
gst_structure_get_int (structure, "height", &context->height);
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
gst_structure_get_int (structure, "bpp", &context->bits_per_sample);
|
||||
+#else
|
||||
+ gst_structure_get_int (structure, "bpp", &context->bits_per_coded_sample);
|
||||
+#endif
|
||||
|
||||
fps = gst_structure_get_value (structure, "framerate");
|
||||
if (fps != NULL && GST_VALUE_HOLDS_FRACTION (fps)) {
|
||||
@@ -1647,7 +1679,11 @@ gst_ffmpeg_caps_with_codecid (enum Codec
|
||||
gint depth;
|
||||
|
||||
if (gst_structure_get_int (str, "depth", &depth)) {
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
context->bits_per_sample = depth;
|
||||
+#else
|
||||
+ context->bits_per_coded_sample = depth;
|
||||
+#endif
|
||||
} else {
|
||||
GST_WARNING ("No depth field in caps %" GST_PTR_FORMAT, caps);
|
||||
}
|
||||
@@ -1680,7 +1716,11 @@ gst_ffmpeg_caps_with_codecid (enum Codec
|
||||
context->bit_rate = bitrate;
|
||||
}
|
||||
case CODEC_ID_ALAC:
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
gst_structure_get_int (str, "samplesize", &context->bits_per_sample);
|
||||
+#else
|
||||
+ gst_structure_get_int (str, "samplesize", &context->bits_per_coded_sample);
|
||||
+#endif
|
||||
break;
|
||||
|
||||
case CODEC_ID_DVVIDEO:
|
||||
Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegdec.c
|
||||
===================================================================
|
||||
--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegdec.c
|
||||
+++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegdec.c
|
||||
@@ -696,7 +696,11 @@ gst_ffmpegdec_setcaps (GstPad * pad, Gst
|
||||
|
||||
/* workaround encoder bugs */
|
||||
ffmpegdec->context->workaround_bugs |= FF_BUG_AUTODETECT;
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
ffmpegdec->context->error_resilience = 1;
|
||||
+#else
|
||||
+ ffmpegdec->context->error_recognition = 1;
|
||||
+#endif
|
||||
|
||||
/* for slow cpus */
|
||||
ffmpegdec->context->lowres = ffmpegdec->lowres;
|
||||
@@ -2423,7 +2427,7 @@ gst_ffmpegdec_register (GstPlugin * plug
|
||||
AVCodec *in_plugin;
|
||||
gint rank;
|
||||
|
||||
- in_plugin = first_avcodec;
|
||||
+ in_plugin = av_codec_next(NULL);
|
||||
|
||||
GST_LOG ("Registering decoders");
|
||||
|
||||
@@ -2545,7 +2549,7 @@ gst_ffmpegdec_register (GstPlugin * plug
|
||||
gst_caps_unref (sinkcaps);
|
||||
if (srccaps)
|
||||
gst_caps_unref (srccaps);
|
||||
- in_plugin = in_plugin->next;
|
||||
+ in_plugin = av_codec_next(in_plugin);
|
||||
}
|
||||
|
||||
GST_LOG ("Finished Registering decoders");
|
||||
Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegenc.c
|
||||
===================================================================
|
||||
--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegenc.c
|
||||
+++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegenc.c
|
||||
@@ -306,8 +306,8 @@ gst_ffmpegenc_getcaps (GstPad * pad)
|
||||
/* set some default properties */
|
||||
ctx->width = DEFAULT_WIDTH;
|
||||
ctx->height = DEFAULT_HEIGHT;
|
||||
- ctx->time_base.num = DEFAULT_FRAME_RATE_BASE;
|
||||
- ctx->time_base.den = 25 * DEFAULT_FRAME_RATE_BASE;
|
||||
+ ctx->time_base.num = 1;
|
||||
+ ctx->time_base.den = 25;
|
||||
ctx->bit_rate = DEFAULT_VIDEO_BITRATE;
|
||||
/* makes it silent */
|
||||
ctx->strict_std_compliance = -1;
|
||||
@@ -391,7 +391,9 @@ gst_ffmpegenc_setcaps (GstPad * pad, Gst
|
||||
|
||||
/* RTP payload used for GOB production (for Asterisk) */
|
||||
if (ffmpegenc->rtp_payload_size) {
|
||||
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
|
||||
ffmpegenc->context->rtp_mode = 1;
|
||||
+#endif
|
||||
ffmpegenc->context->rtp_payload_size = ffmpegenc->rtp_payload_size;
|
||||
}
|
||||
|
||||
@@ -944,13 +946,13 @@ gst_ffmpegenc_register (GstPlugin * plug
|
||||
GType type;
|
||||
AVCodec *in_plugin;
|
||||
|
||||
- in_plugin = first_avcodec;
|
||||
|
||||
GST_LOG ("Registering encoders");
|
||||
|
||||
/* build global ffmpeg param/property info */
|
||||
gst_ffmpeg_cfg_init ();
|
||||
|
||||
+ in_plugin = av_codec_next(NULL);
|
||||
while (in_plugin) {
|
||||
gchar *type_name;
|
||||
GstCaps *srccaps = NULL, *sinkcaps = NULL;
|
||||
@@ -1027,7 +1029,7 @@ gst_ffmpegenc_register (GstPlugin * plug
|
||||
gst_caps_unref (sinkcaps);
|
||||
if (srccaps)
|
||||
gst_caps_unref (srccaps);
|
||||
- in_plugin = in_plugin->next;
|
||||
+ in_plugin = av_codec_next(in_plugin);
|
||||
}
|
||||
|
||||
GST_LOG ("Finished registering encoders");
|
||||
15
media-plugins/gst-plugins-ffmpeg/files/0.10.5/offset.patch
Normal file
15
media-plugins/gst-plugins-ffmpeg/files/0.10.5/offset.patch
Normal file
@@ -0,0 +1,15 @@
|
||||
Index: gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegprotocol.c
|
||||
===================================================================
|
||||
--- gst-ffmpeg-0.10.4.orig/ext/ffmpeg/gstffmpegprotocol.c
|
||||
+++ gst-ffmpeg-0.10.4/ext/ffmpeg/gstffmpegprotocol.c
|
||||
@@ -175,8 +175,8 @@ gst_ffmpegdata_write (URLContext * h, un
|
||||
return size;
|
||||
}
|
||||
|
||||
-static offset_t
|
||||
-gst_ffmpegdata_seek (URLContext * h, offset_t pos, int whence)
|
||||
+static int64_t
|
||||
+gst_ffmpegdata_seek (URLContext * h, int64_t pos, int whence)
|
||||
{
|
||||
GstProtocolInfo *info;
|
||||
guint64 newpos;
|
||||
@@ -0,0 +1,72 @@
|
||||
diff -NrU5 gst-ffmpeg-0.10.5.orig/configure gst-ffmpeg-0.10.5/configure
|
||||
--- gst-ffmpeg-0.10.5.orig/configure 2008-10-14 15:37:05.000000000 +0200
|
||||
+++ gst-ffmpeg-0.10.5/configure 2008-10-14 15:38:00.000000000 +0200
|
||||
@@ -17231,68 +17231,10 @@
|
||||
_ACEOF
|
||||
|
||||
HAVE_FFMPEG_UNINSTALLED=0
|
||||
{ $as_echo "$as_me:$LINENO: Using system-installed FFMpeg code" >&5
|
||||
$as_echo "$as_me: Using system-installed FFMpeg code" >&6;}
|
||||
- { $as_echo "$as_me:$LINENO: WARNING:
|
||||
- ======================================================================
|
||||
- WARNING: you have chosen to build gst-ffmpeg against a random
|
||||
- external version of ffmpeg instead of building it against the tested
|
||||
- internal ffmpeg snapshot that is included with gst-ffmpeg.
|
||||
-
|
||||
- This is a very bad idea. So bad in fact that words cannot express
|
||||
- just how bad it is. Suffice to say that it is BAD.
|
||||
-
|
||||
- The GStreamer developers cannot and will not support a gst-ffmpeg
|
||||
- built this way. Any bug reports that indicate there is an external
|
||||
- version of ffmpeg involved will be closed immediately without further
|
||||
- investigation.
|
||||
-
|
||||
- The reason such a setup can't be supported is that the ffmpeg API
|
||||
- and ABI is in constant flux, yet there aren't any official releases
|
||||
- of the ffmpeg library to develop against. This makes it impossible
|
||||
- to guarantee that gst-ffmpeg will work reliably, or even compile,
|
||||
- with a randomly picked version ffmpeg. Even if gst-ffmpeg compiles
|
||||
- and superficially appears to work fine against your chosen external
|
||||
- ffmpeg version, that might just not be the case on other systems, or
|
||||
- even the same system at a later time, or when using decoders,
|
||||
- encoders, demuxers or muxers that have not been tested.
|
||||
-
|
||||
- Please do not create or distribute binary packages of gst-ffmpeg
|
||||
- that link against an external ffmpeg. Thank you!
|
||||
- ======================================================================
|
||||
- " >&5
|
||||
-$as_echo "$as_me: WARNING:
|
||||
- ======================================================================
|
||||
- WARNING: you have chosen to build gst-ffmpeg against a random
|
||||
- external version of ffmpeg instead of building it against the tested
|
||||
- internal ffmpeg snapshot that is included with gst-ffmpeg.
|
||||
-
|
||||
- This is a very bad idea. So bad in fact that words cannot express
|
||||
- just how bad it is. Suffice to say that it is BAD.
|
||||
-
|
||||
- The GStreamer developers cannot and will not support a gst-ffmpeg
|
||||
- built this way. Any bug reports that indicate there is an external
|
||||
- version of ffmpeg involved will be closed immediately without further
|
||||
- investigation.
|
||||
-
|
||||
- The reason such a setup can't be supported is that the ffmpeg API
|
||||
- and ABI is in constant flux, yet there aren't any official releases
|
||||
- of the ffmpeg library to develop against. This makes it impossible
|
||||
- to guarantee that gst-ffmpeg will work reliably, or even compile,
|
||||
- with a randomly picked version ffmpeg. Even if gst-ffmpeg compiles
|
||||
- and superficially appears to work fine against your chosen external
|
||||
- ffmpeg version, that might just not be the case on other systems, or
|
||||
- even the same system at a later time, or when using decoders,
|
||||
- encoders, demuxers or muxers that have not been tested.
|
||||
-
|
||||
- Please do not create or distribute binary packages of gst-ffmpeg
|
||||
- that link against an external ffmpeg. Thank you!
|
||||
- ======================================================================
|
||||
- " >&2;}
|
||||
-
|
||||
- sleep 15
|
||||
else
|
||||
|
||||
source "$srcdir/ffmpegrev"
|
||||
|
||||
{ $as_echo "$as_me:$LINENO: Using ffmpeg revision $FFMPEG_REVISION" >&5
|
||||
@@ -0,0 +1,72 @@
|
||||
diff -NrU5 gst-ffmpeg-0.10.6.orig/configure gst-ffmpeg-0.10.6/configure
|
||||
--- gst-ffmpeg-0.10.6.orig/configure 2008-12-05 23:57:18.000000000 +0100
|
||||
+++ gst-ffmpeg-0.10.6/configure 2008-12-06 00:02:04.000000000 +0100
|
||||
@@ -17130,68 +17130,10 @@
|
||||
_ACEOF
|
||||
|
||||
HAVE_FFMPEG_UNINSTALLED=0
|
||||
{ echo "$as_me:$LINENO: Using system-installed FFMpeg code" >&5
|
||||
echo "$as_me: Using system-installed FFMpeg code" >&6;}
|
||||
- { echo "$as_me:$LINENO: WARNING:
|
||||
- ======================================================================
|
||||
- WARNING: you have chosen to build gst-ffmpeg against a random
|
||||
- external version of ffmpeg instead of building it against the tested
|
||||
- internal ffmpeg snapshot that is included with gst-ffmpeg.
|
||||
-
|
||||
- This is a very bad idea. So bad in fact that words cannot express
|
||||
- just how bad it is. Suffice to say that it is BAD.
|
||||
-
|
||||
- The GStreamer developers cannot and will not support a gst-ffmpeg
|
||||
- built this way. Any bug reports that indicate there is an external
|
||||
- version of ffmpeg involved will be closed immediately without further
|
||||
- investigation.
|
||||
-
|
||||
- The reason such a setup can't be supported is that the ffmpeg API
|
||||
- and ABI is in constant flux, yet there aren't any official releases
|
||||
- of the ffmpeg library to develop against. This makes it impossible
|
||||
- to guarantee that gst-ffmpeg will work reliably, or even compile,
|
||||
- with a randomly picked version ffmpeg. Even if gst-ffmpeg compiles
|
||||
- and superficially appears to work fine against your chosen external
|
||||
- ffmpeg version, that might just not be the case on other systems, or
|
||||
- even the same system at a later time, or when using decoders,
|
||||
- encoders, demuxers or muxers that have not been tested.
|
||||
-
|
||||
- Please do not create or distribute binary packages of gst-ffmpeg
|
||||
- that link against an external ffmpeg. Thank you!
|
||||
- ======================================================================
|
||||
- " >&5
|
||||
-echo "$as_me: WARNING:
|
||||
- ======================================================================
|
||||
- WARNING: you have chosen to build gst-ffmpeg against a random
|
||||
- external version of ffmpeg instead of building it against the tested
|
||||
- internal ffmpeg snapshot that is included with gst-ffmpeg.
|
||||
-
|
||||
- This is a very bad idea. So bad in fact that words cannot express
|
||||
- just how bad it is. Suffice to say that it is BAD.
|
||||
-
|
||||
- The GStreamer developers cannot and will not support a gst-ffmpeg
|
||||
- built this way. Any bug reports that indicate there is an external
|
||||
- version of ffmpeg involved will be closed immediately without further
|
||||
- investigation.
|
||||
-
|
||||
- The reason such a setup can't be supported is that the ffmpeg API
|
||||
- and ABI is in constant flux, yet there aren't any official releases
|
||||
- of the ffmpeg library to develop against. This makes it impossible
|
||||
- to guarantee that gst-ffmpeg will work reliably, or even compile,
|
||||
- with a randomly picked version ffmpeg. Even if gst-ffmpeg compiles
|
||||
- and superficially appears to work fine against your chosen external
|
||||
- ffmpeg version, that might just not be the case on other systems, or
|
||||
- even the same system at a later time, or when using decoders,
|
||||
- encoders, demuxers or muxers that have not been tested.
|
||||
-
|
||||
- Please do not create or distribute binary packages of gst-ffmpeg
|
||||
- that link against an external ffmpeg. Thank you!
|
||||
- ======================================================================
|
||||
- " >&2;}
|
||||
-
|
||||
- sleep 15
|
||||
else
|
||||
|
||||
source "$srcdir/ffmpegrev"
|
||||
|
||||
{ echo "$as_me:$LINENO: Using ffmpeg revision $FFMPEG_REVISION" >&5
|
||||
Reference in New Issue
Block a user