mirror of
https://github.com/mpv-player/mpv
synced 2025-03-31 15:59:34 +00:00
lavc 4663 / quantizer bias
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@9646 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
169af37678
commit
4e3270d131
@ -3162,6 +3162,24 @@ Note: vqmin should be 8 or larger.
|
||||
.IPs umv
|
||||
unlimited MVs (H.263+ only)
|
||||
Allow encoding of abritarily long MVs.
|
||||
.IPs ibias=<\-256\-256>
|
||||
intra quantizer bias (256 == 1.0)
|
||||
.br
|
||||
mpeg style quantizer default: 96
|
||||
.br
|
||||
h263 style quantizer default: 0
|
||||
.br
|
||||
Note: the h263 MMX quantizer cannot handle positive biases (set vfdct=1or2)
|
||||
the mpeg MMX quantizer cannot handle negative biases (set vfdct=1or2)
|
||||
.IPs pbias=<\-256\-256>
|
||||
inter quantizer bias (256 == 1.0)
|
||||
.br
|
||||
mpeg style quantizer default: 0
|
||||
.br
|
||||
h263 style quantizer default: -64
|
||||
.br
|
||||
Note: the h263 MMX quantizer cannot handle positive biases (set vfdct=1or2)
|
||||
the mpeg MMX quantizer cannot handle negative biases (set vfdct=1or2)
|
||||
.RE
|
||||
.
|
||||
.TP
|
||||
|
@ -120,6 +120,10 @@ static int lavc_param_last_pred= 0;
|
||||
static int lavc_param_pre_me= 1;
|
||||
static int lavc_param_me_subpel_quality= 8;
|
||||
static int lavc_param_me_range= 0;
|
||||
#if LIBAVCODEC_BUILD >= 4663
|
||||
static int lavc_param_ibias= FF_DEFAULT_QUANT_BIAS;
|
||||
static int lavc_param_pbias= FF_DEFAULT_QUANT_BIAS;
|
||||
#endif
|
||||
|
||||
#include "cfgparser.h"
|
||||
|
||||
@ -200,6 +204,10 @@ struct config lavcopts_conf[]={
|
||||
#ifdef CODEC_FLAG_H263P_AIC
|
||||
{"aic", &lavc_param_aic, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_H263P_AIC, NULL},
|
||||
{"umv", &lavc_param_umv, CONF_TYPE_FLAG, 0, 0, CODEC_FLAG_H263P_UMV, NULL},
|
||||
#endif
|
||||
#if LIBAVCODEC_BUILD >= 4663
|
||||
{"ibias", &lavc_param_ibias, CONF_TYPE_INT, CONF_RANGE, -512, 512, NULL},
|
||||
{"pbias", &lavc_param_pbias, CONF_TYPE_INT, CONF_RANGE, -512, 512, NULL},
|
||||
#endif
|
||||
{NULL, NULL, 0, 0, 0, 0, NULL}
|
||||
};
|
||||
@ -295,6 +303,10 @@ static int config(struct vf_instance_s* vf,
|
||||
#if LIBAVCODEC_BUILD >= 4659
|
||||
lavc_venc_context->me_range= lavc_param_me_range;
|
||||
#endif
|
||||
#if LIBAVCODEC_BUILD >= 4663
|
||||
lavc_venc_context->intra_quant_bias= lavc_param_ibias;
|
||||
lavc_venc_context->inter_quant_bias= lavc_param_pbias;
|
||||
#endif
|
||||
|
||||
p= lavc_param_rc_override_string;
|
||||
for(i=0; p; i++){
|
||||
@ -556,7 +568,6 @@ static void uninit(struct vf_instance_s* vf){
|
||||
#if LIBAVCODEC_BUILD >= 4643
|
||||
if(lavc_param_psnr){
|
||||
double f= lavc_venc_context->width*lavc_venc_context->height*255.0*255.0;
|
||||
|
||||
f*= lavc_venc_context->coded_frame->coded_picture_number;
|
||||
|
||||
printf("PSNR: Y:%2.2f, Cb:%2.2f, Cr:%2.2f, All:%2.2f\n",
|
||||
|
Loading…
Reference in New Issue
Block a user