Some fixes after the x264 update.
From Brad. "theoretically ok" ajacoutot@
This commit is contained in:
parent
1c274146f6
commit
76091f6c3b
@ -1,10 +1,10 @@
|
||||
# $OpenBSD: Makefile,v 1.45 2009/01/29 11:30:27 sthen Exp $
|
||||
# $OpenBSD: Makefile,v 1.46 2009/04/14 19:52:08 kili Exp $
|
||||
|
||||
COMMENT= audio/video converter and streamer with bktr(4) support
|
||||
|
||||
V= 20080620
|
||||
DISTNAME= ffmpeg-svn-${V}
|
||||
PKGNAME= ffmpeg-${V}p7
|
||||
PKGNAME= ffmpeg-${V}p8
|
||||
SHARED_LIBS= avutil 6.0 \
|
||||
avcodec 13.0 \
|
||||
avformat 12.0 \
|
||||
@ -32,7 +32,7 @@ LIB_DEPENDS= SDL.>=4::devel/sdl \
|
||||
mp3lame.>=0.1::audio/lame \
|
||||
vorbis.>=4.0,vorbisenc.>=2.0::audio/libvorbis \
|
||||
a52::audio/liba52 \
|
||||
x264.>=1::multimedia/x264 \
|
||||
x264.>=3::multimedia/x264 \
|
||||
theora::multimedia/libtheora \
|
||||
Imlib2::graphics/imlib2 \
|
||||
bz2.>=10::archivers/bzip2
|
||||
|
29
graphics/ffmpeg/patches/patch-libavcodec_libx264_c
Normal file
29
graphics/ffmpeg/patches/patch-libavcodec_libx264_c
Normal file
@ -0,0 +1,29 @@
|
||||
$OpenBSD: patch-libavcodec_libx264_c,v 1.3 2009/04/14 19:52:08 kili Exp $
|
||||
--- libavcodec/libx264.c.orig Sun Jan 4 00:08:43 2009
|
||||
+++ libavcodec/libx264.c Sun Jan 4 00:10:43 2009
|
||||
@@ -162,7 +162,7 @@ X264_init(AVCodecContext *avctx)
|
||||
|
||||
x4->params.i_bframe = avctx->max_b_frames;
|
||||
x4->params.b_cabac = avctx->coder_type == FF_CODER_TYPE_AC;
|
||||
- x4->params.b_bframe_adaptive = avctx->b_frame_strategy;
|
||||
+ x4->params.i_bframe_adaptive = avctx->b_frame_strategy;
|
||||
x4->params.i_bframe_bias = avctx->bframebias;
|
||||
x4->params.b_bframe_pyramid = avctx->flags2 & CODEC_FLAG2_BPYRAMID;
|
||||
avctx->has_b_frames= avctx->flags2 & CODEC_FLAG2_BPYRAMID ? 2 : !!avctx->max_b_frames;
|
||||
@@ -227,8 +227,6 @@ X264_init(AVCodecContext *avctx)
|
||||
x4->params.analyse.i_me_range = avctx->me_range;
|
||||
x4->params.analyse.i_subpel_refine = avctx->me_subpel_quality;
|
||||
|
||||
- x4->params.analyse.b_bidir_me = avctx->bidir_refine > 0;
|
||||
- x4->params.analyse.b_bframe_rdo = avctx->flags2 & CODEC_FLAG2_BRDO;
|
||||
x4->params.analyse.b_mixed_references =
|
||||
avctx->flags2 & CODEC_FLAG2_MIXED_REFS;
|
||||
x4->params.analyse.b_chroma_me = avctx->me_cmp & FF_CMP_CHROMA;
|
||||
@@ -253,7 +251,6 @@ X264_init(AVCodecContext *avctx)
|
||||
x4->params.rc.f_ip_factor = 1/fabs(avctx->i_quant_factor);
|
||||
x4->params.rc.f_pb_factor = avctx->b_quant_factor;
|
||||
x4->params.analyse.i_chroma_qp_offset = avctx->chromaoffset;
|
||||
- x4->params.rc.psz_rc_eq = avctx->rc_eq;
|
||||
|
||||
x4->params.analyse.b_psnr = avctx->flags & CODEC_FLAG_PSNR;
|
||||
x4->params.i_log_level = X264_LOG_DEBUG;
|
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.15 2009/04/11 14:37:21 ajacoutot Exp $
|
||||
# $OpenBSD: Makefile,v 1.16 2009/04/14 19:52:08 kili Exp $
|
||||
|
||||
COMMENT-main = multimedia framework - plugins bad
|
||||
COMMENT-tremor = multimedia framework - tremor plugin
|
||||
@ -35,7 +35,7 @@ PKGNAME-swf = gstreamer-flash-$Vp2
|
||||
PKGNAME-meta = gstreamer-meta-$Vp3
|
||||
PKGNAME-sndfile = gstreamer-sndfile-$Vp3
|
||||
PKGNAME-real = gstreamer-real-$Vp3
|
||||
PKGNAME-x264 = gstreamer-x264-$Vp1
|
||||
PKGNAME-x264 = gstreamer-x264-$Vp2
|
||||
PKGNAME-mplex = gstreamer-mplex-$Vp1
|
||||
|
||||
MULTI_PACKAGES = -main -tremor -musepack -faac -faad -xvid -sdl -bz2 \
|
||||
|
@ -0,0 +1,15 @@
|
||||
$OpenBSD: patch-ext_x264_gstx264enc_c,v 1.1 2009/04/14 19:52:08 kili Exp $
|
||||
--- ext/x264/gstx264enc.c.orig Sun Jan 4 01:07:03 2009
|
||||
+++ ext/x264/gstx264enc.c Sun Jan 4 01:08:50 2009
|
||||
@@ -594,7 +594,11 @@ gst_x264_enc_init_encoder (GstX264Enc * encoder)
|
||||
encoder->x264param.i_frame_reference = encoder->ref;
|
||||
encoder->x264param.i_bframe = encoder->bframes;
|
||||
encoder->x264param.b_bframe_pyramid = encoder->b_pyramid;
|
||||
+#if X264_BUILD < 63
|
||||
encoder->x264param.b_bframe_adaptive = 0;
|
||||
+#else
|
||||
+ encoder->x264param.i_bframe_adaptive = 0;
|
||||
+#endif
|
||||
encoder->x264param.b_deblocking_filter = 1;
|
||||
encoder->x264param.i_deblocking_filter_alphac0 = 0;
|
||||
encoder->x264param.i_deblocking_filter_beta = 0;
|
@ -0,0 +1,11 @@
|
||||
$OpenBSD: patch-ext_x264_gstx264enc_h,v 1.1 2009/04/14 19:52:08 kili Exp $
|
||||
--- ext/x264/gstx264enc.h.orig Mon Mar 9 12:30:00 2009
|
||||
+++ ext/x264/gstx264enc.h Mon Mar 9 12:30:12 2009
|
||||
@@ -23,6 +23,7 @@
|
||||
|
||||
#include <gst/gst.h>
|
||||
#include <_stdint.h>
|
||||
+#include <inttypes.h>
|
||||
#include <x264.h>
|
||||
|
||||
G_BEGIN_DECLS
|
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.147 2009/03/17 08:24:33 sthen Exp $
|
||||
# $OpenBSD: Makefile,v 1.148 2009/04/14 19:52:08 kili Exp $
|
||||
|
||||
# May not be hard to add more.
|
||||
ONLY_FOR_ARCHS= amd64 i386 powerpc sparc64 arm
|
||||
@ -9,7 +9,7 @@ V= 1.0rc2
|
||||
N= mplayer
|
||||
DISTNAME= MPlayer-${V}
|
||||
DIST_SUBDIR= ${N}
|
||||
PKGNAME= ${N}-${V}p21
|
||||
PKGNAME= ${N}-${V}p22
|
||||
CATEGORIES= x11 multimedia
|
||||
EXTRACT_SUFX= .tar.bz2
|
||||
|
||||
|
29
x11/mplayer/patches/patch-libavcodec_libx264_c
Normal file
29
x11/mplayer/patches/patch-libavcodec_libx264_c
Normal file
@ -0,0 +1,29 @@
|
||||
$OpenBSD: patch-libavcodec_libx264_c,v 1.1 2009/04/14 19:52:08 kili Exp $
|
||||
--- libavcodec/libx264.c.orig Sun Jan 4 00:43:21 2009
|
||||
+++ libavcodec/libx264.c Sun Jan 4 00:44:24 2009
|
||||
@@ -162,7 +162,7 @@ X264_init(AVCodecContext *avctx)
|
||||
|
||||
x4->params.i_bframe = avctx->max_b_frames;
|
||||
x4->params.b_cabac = avctx->coder_type == FF_CODER_TYPE_AC;
|
||||
- x4->params.b_bframe_adaptive = avctx->b_frame_strategy;
|
||||
+ x4->params.i_bframe_adaptive = avctx->b_frame_strategy;
|
||||
x4->params.i_bframe_bias = avctx->bframebias;
|
||||
x4->params.b_bframe_pyramid = (avctx->flags2 & CODEC_FLAG2_BPYRAMID);
|
||||
avctx->has_b_frames= (avctx->flags2 & CODEC_FLAG2_BPYRAMID) ? 2 : !!avctx->max_b_frames;
|
||||
@@ -225,8 +225,6 @@ X264_init(AVCodecContext *avctx)
|
||||
x4->params.analyse.i_me_range = avctx->me_range;
|
||||
x4->params.analyse.i_subpel_refine = avctx->me_subpel_quality;
|
||||
|
||||
- x4->params.analyse.b_bidir_me = (avctx->bidir_refine > 0);
|
||||
- x4->params.analyse.b_bframe_rdo = (avctx->flags2 & CODEC_FLAG2_BRDO);
|
||||
x4->params.analyse.b_mixed_references =
|
||||
(avctx->flags2 & CODEC_FLAG2_MIXED_REFS);
|
||||
x4->params.analyse.b_chroma_me = (avctx->me_cmp & FF_CMP_CHROMA);
|
||||
@@ -251,7 +249,6 @@ X264_init(AVCodecContext *avctx)
|
||||
x4->params.rc.f_ip_factor = 1/fabs(avctx->i_quant_factor);
|
||||
x4->params.rc.f_pb_factor = avctx->b_quant_factor;
|
||||
x4->params.analyse.i_chroma_qp_offset = avctx->chromaoffset;
|
||||
- x4->params.rc.psz_rc_eq = avctx->rc_eq;
|
||||
|
||||
x4->params.analyse.b_psnr = (avctx->flags & CODEC_FLAG_PSNR);
|
||||
x4->params.i_log_level = X264_LOG_DEBUG;
|
@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.78 2009/01/16 04:11:18 jakemsr Exp $
|
||||
# $OpenBSD: Makefile,v 1.79 2009/04/14 19:52:08 kili Exp $
|
||||
|
||||
SHARED_ONLY= Yes
|
||||
|
||||
@ -6,7 +6,7 @@ COMMENT-main= videolan client; multimedia player
|
||||
|
||||
V= 0.8.6i
|
||||
DISTNAME= vlc-${V}
|
||||
PKGNAME-main= ${DISTNAME}p3
|
||||
PKGNAME-main= ${DISTNAME}p4
|
||||
CATEGORIES= x11
|
||||
MASTER_SITES= http://download.videolan.org/pub/videolan/vlc/${V}/
|
||||
|
||||
|
118
x11/vlc/patches/patch-modules_codec_x264_c
Normal file
118
x11/vlc/patches/patch-modules_codec_x264_c
Normal file
@ -0,0 +1,118 @@
|
||||
$OpenBSD: patch-modules_codec_x264_c,v 1.1 2009/04/14 19:52:08 kili Exp $
|
||||
--- modules/codec/x264.c.orig Tue Jul 8 16:59:23 2008
|
||||
+++ modules/codec/x264.c Sun Mar 8 23:36:34 2009
|
||||
@@ -29,6 +29,7 @@
|
||||
#include <vlc/sout.h>
|
||||
#include <vlc/decoder.h>
|
||||
|
||||
+#include <inttypes.h>
|
||||
#include <x264.h>
|
||||
|
||||
#define SOUT_CFG_PREFIX "sout-x264-"
|
||||
@@ -72,8 +73,14 @@ static void Close( vlc_object_t * );
|
||||
"P-frames. Range 1 to 16." )
|
||||
|
||||
#define B_ADAPT_TEXT N_("Adaptive B-frame decision")
|
||||
+#if X264_BUILD >= 63
|
||||
#define B_ADAPT_LONGTEXT N_( "Force the specified number of " \
|
||||
+ "consecutive B-frames to be used, except possibly before an I-frame." \
|
||||
+ "Range 0 to 2." )
|
||||
+#else
|
||||
+#define B_ADAPT_LONGTEXT N_( "Force the specified number of " \
|
||||
"consecutive B-frames to be used, except possibly before an I-frame." )
|
||||
+#endif
|
||||
|
||||
#define B_BIAS_TEXT N_("Influence (bias) B-frames usage")
|
||||
#define B_BIAS_LONGTEXT N_( "Bias the choice to use B-frames. Positive values " \
|
||||
@@ -214,7 +221,12 @@ static void Close( vlc_object_t * );
|
||||
|
||||
#define SUBME_TEXT N_("Subpixel motion estimation and partition decision " \
|
||||
"quality")
|
||||
-#if X264_BUILD >= 46 /* r477 */
|
||||
+#if X264_BUILD >= 65
|
||||
+#define SUBME_MAX 9
|
||||
+#define SUBME_LONGTEXT N_( "This parameter controls quality versus speed " \
|
||||
+ "tradeoffs involved in the motion estimation decision process " \
|
||||
+ "(lower = quicker and higher = better quality). Range 1 to 9." )
|
||||
+#elif X264_BUILD >= 46 /* r477 */
|
||||
#define SUBME_MAX 7
|
||||
#define SUBME_LONGTEXT N_( "This parameter controls quality versus speed " \
|
||||
"tradeoffs involved in the motion estimation decision process " \
|
||||
@@ -356,10 +368,16 @@ vlc_module_begin();
|
||||
BFRAMES_LONGTEXT, VLC_FALSE );
|
||||
change_integer_range( 0, 16 );
|
||||
|
||||
-#if X264_BUILD >= 0x0013 /* r137 */
|
||||
+#if X264_BUILD >= 63
|
||||
+ add_integer( SOUT_CFG_PREFIX "b-adapt", 1, NULL, B_ADAPT_TEXT,
|
||||
+ B_ADAPT_LONGTEXT, VLC_FALSE );
|
||||
+ change_integer_range( 0, 2 );
|
||||
+#elif X264_BUILD >= 0x0013 /* r137 */
|
||||
add_bool( SOUT_CFG_PREFIX "b-adapt", 1, NULL, B_ADAPT_TEXT,
|
||||
B_ADAPT_LONGTEXT, VLC_FALSE );
|
||||
+#endif
|
||||
|
||||
+#if X264_BUILD >= 0x0013 /* r137 */
|
||||
add_integer( SOUT_CFG_PREFIX "b-bias", 0, NULL, B_BIAS_TEXT,
|
||||
B_BIAS_LONGTEXT, VLC_FALSE );
|
||||
change_integer_range( -100, 100 );
|
||||
@@ -494,7 +512,7 @@ vlc_module_begin();
|
||||
change_integer_range( 1, SUBME_MAX );
|
||||
add_deprecated( SOUT_CFG_PREFIX "subpel", VLC_FALSE ); /* Deprecated since 0.8.5 */
|
||||
|
||||
-#if X264_BUILD >= 41 /* r368 */
|
||||
+#if X264_BUILD >= 41 && X264_BUILD < 65 /* r368 */
|
||||
add_bool( SOUT_CFG_PREFIX "b-rdo", 0, NULL, B_RDO_TEXT,
|
||||
B_RDO_LONGTEXT, VLC_FALSE );
|
||||
#endif
|
||||
@@ -509,7 +527,7 @@ vlc_module_begin();
|
||||
CHROMA_ME_LONGTEXT, VLC_FALSE );
|
||||
#endif
|
||||
|
||||
-#if X264_BUILD >= 43 /* r390 */
|
||||
+#if X264_BUILD >= 43 && X264_BUILD < 65 /* r390 */
|
||||
add_bool( SOUT_CFG_PREFIX "bime", 0, NULL, BIME_TEXT,
|
||||
BIME_LONGTEXT, VLC_FALSE );
|
||||
#endif
|
||||
@@ -890,7 +908,11 @@ static int Open ( vlc_object_t *p_this )
|
||||
|
||||
#if X264_BUILD >= 0x0013
|
||||
var_Get( p_enc, SOUT_CFG_PREFIX "b-adapt", &val );
|
||||
+#if X264_BUILD >= 63
|
||||
+ p_sys->param.i_bframe_adaptive = val.i_int;
|
||||
+#else
|
||||
p_sys->param.b_bframe_adaptive = val.b_bool;
|
||||
+#endif
|
||||
|
||||
var_Get( p_enc, SOUT_CFG_PREFIX "b-bias", &val );
|
||||
if( val.i_int >= -100 && val.i_int <= 100 )
|
||||
@@ -930,7 +952,7 @@ static int Open ( vlc_object_t *p_this )
|
||||
p_sys->param.analyse.i_trellis = val.i_int;
|
||||
#endif
|
||||
|
||||
-#if X264_BUILD >= 41
|
||||
+#if X264_BUILD >= 41 && X264_BUILD < 65
|
||||
var_Get( p_enc, SOUT_CFG_PREFIX "b-rdo", &val );
|
||||
p_sys->param.analyse.b_bframe_rdo = val.b_bool;
|
||||
#endif
|
||||
@@ -940,7 +962,7 @@ static int Open ( vlc_object_t *p_this )
|
||||
p_sys->param.analyse.b_fast_pskip = val.b_bool;
|
||||
#endif
|
||||
|
||||
-#if X264_BUILD >= 43
|
||||
+#if X264_BUILD >= 43 && X264_BUILD < 65
|
||||
var_Get( p_enc, SOUT_CFG_PREFIX "bime", &val );
|
||||
p_sys->param.analyse.b_bidir_me = val.b_bool;
|
||||
#endif
|
||||
@@ -965,9 +987,11 @@ static int Open ( vlc_object_t *p_this )
|
||||
if( val.i_int >= 0 && val.i_int <= 32 )
|
||||
p_sys->param.analyse.i_luma_deadzone[1] = val.i_int;
|
||||
|
||||
+#if X264_BUILD <= 65
|
||||
var_Get( p_enc, SOUT_CFG_PREFIX "direct-8x8", &val );
|
||||
if( val.i_int >= -1 && val.i_int <= 1 )
|
||||
p_sys->param.analyse.i_direct_8x8_inference = val.i_int;
|
||||
+#endif
|
||||
#endif
|
||||
|
||||
var_Get( p_enc, SOUT_CFG_PREFIX "asm", &val );
|
Loading…
Reference in New Issue
Block a user