mirror of
https://github.com/mpv-player/mpv
synced 2025-01-24 19:37:30 +01:00
passing qscale_type around so the pp code can fix the mpeg2 <<1 thing
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@9926 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
cb961f6600
commit
40a073bea4
@ -76,6 +76,7 @@ typedef struct mp_image_s {
|
||||
char * qscale;
|
||||
int qstride;
|
||||
int pict_type; // 0->unknown, 1->I, 2->P, 3->B
|
||||
int qscale_type; // 0->mpeg1/4/h263, 1->mpeg2
|
||||
int num_planes;
|
||||
/* these are only used by planar formats Y,U(Cb),V(Cr) */
|
||||
int chroma_width;
|
||||
|
@ -662,6 +662,7 @@ static mp_image_t* decode(sh_video_t *sh,void* data,int len,int flags){
|
||||
mpi->qscale =pic->qscale_table;
|
||||
mpi->qstride=pic->qstride;
|
||||
mpi->pict_type=pic->pict_type;
|
||||
mpi->qscale_type= pic->qscale_type;
|
||||
|
||||
return mpi;
|
||||
}
|
||||
|
@ -150,6 +150,7 @@ static mp_image_t* decode(sh_video_t *sh,void* data,int len,int flags){
|
||||
mpeg2dec->decoder.quant_store=mpi->qscale;
|
||||
mpeg2dec->decoder.quant_stride=mpi->qstride;
|
||||
mpi->pict_type=type; // 1->I, 2->P, 3->B
|
||||
mpi->qscale_type= 1;
|
||||
#endif
|
||||
|
||||
if(mpi->flags&MP_IMGFLAG_DRAW_CALLBACK &&
|
||||
|
@ -129,7 +129,7 @@ static int put_image(struct vf_instance_s* vf, mp_image_t *mpi){
|
||||
(mpi->w+7)&(~7),mpi->h,
|
||||
mpi->qscale, mpi->qstride,
|
||||
vf->priv->ppMode[ vf->priv->pp ], vf->priv->context,
|
||||
mpi->pict_type);
|
||||
mpi->pict_type | (mpi->qscale_type ? PP_PICT_TYPE_QP2 : 0));
|
||||
}
|
||||
return vf_next_put_image(vf,vf->priv->dmpi);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user