Commit ae72cda6 authored by Nick Kurshev's avatar Nick Kurshev

new field for communicating with external postprocessing

Originally committed as revision 652 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 4136dd24
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
#define LIBAVCODEC_VERSION_INT 0x000406 #define LIBAVCODEC_VERSION_INT 0x000406
#define LIBAVCODEC_VERSION "0.4.6" #define LIBAVCODEC_VERSION "0.4.6"
#define LIBAVCODEC_BUILD 4611 #define LIBAVCODEC_BUILD 4612
#define LIBAVCODEC_BUILD_STR "4611" #define LIBAVCODEC_BUILD_STR "4612"
enum CodecID { enum CodecID {
CODEC_ID_NONE, CODEC_ID_NONE,
...@@ -239,7 +239,12 @@ typedef struct AVCodecContext { ...@@ -239,7 +239,12 @@ typedef struct AVCodecContext {
int strict_std_compliance; /* strictly follow the std (MPEG4, ...) */ int strict_std_compliance; /* strictly follow the std (MPEG4, ...) */
float b_quant_offset;/* qscale offset between ips and b frames, not implemented yet */ float b_quant_offset;/* qscale offset between ips and b frames, not implemented yet */
int error_resilience; int error_resilience;
#ifndef MBC
#define MBC 128
#define MBR 96
#endif
int *quant_store; /* field for communicating with external postprocessing */
//FIXME this should be reordered after kabis API is finished ... //FIXME this should be reordered after kabis API is finished ...
/* /*
Note: Below are located reserved fields for further usage Note: Below are located reserved fields for further usage
...@@ -257,7 +262,7 @@ typedef struct AVCodecContext { ...@@ -257,7 +262,7 @@ typedef struct AVCodecContext {
flt_res6,flt_res7,flt_res8,flt_res9,flt_res10,flt_res11; flt_res6,flt_res7,flt_res8,flt_res9,flt_res10,flt_res11;
void void
*ptr_res0,*ptr_res1,*ptr_res2,*ptr_res3,*ptr_res4,*ptr_res5, *ptr_res0,*ptr_res1,*ptr_res2,*ptr_res3,*ptr_res4,*ptr_res5,
*ptr_res6,*ptr_res7,*ptr_res8,*ptr_res9,*ptr_res10,*ptr_res11,*ptr_res12; *ptr_res6,*ptr_res7,*ptr_res8,*ptr_res9,*ptr_res10,*ptr_res11;
unsigned long int unsigned long int
ul_res0,ul_res1,ul_res2,ul_res3,ul_res4,ul_res5, ul_res0,ul_res1,ul_res2,ul_res3,ul_res4,ul_res5,
ul_res6,ul_res7,ul_res8,ul_res9,ul_res10,ul_res11,ul_res12; ul_res6,ul_res7,ul_res8,ul_res9,ul_res10,ul_res11,ul_res12;
...@@ -432,10 +437,6 @@ void avcodec_register_all(void); ...@@ -432,10 +437,6 @@ void avcodec_register_all(void);
void avcodec_flush_buffers(AVCodecContext *avctx); void avcodec_flush_buffers(AVCodecContext *avctx);
#ifdef FF_POSTPROCESS #ifdef FF_POSTPROCESS
#ifndef MBC
#define MBC 128
#define MBR 96
#endif
extern int quant_store[MBR+1][MBC+1]; // [Review] extern int quant_store[MBR+1][MBC+1]; // [Review]
#endif #endif
......
...@@ -1178,8 +1178,11 @@ void MPV_decode_mb(MpegEncContext *s, DCTELEM block[6][64]) ...@@ -1178,8 +1178,11 @@ void MPV_decode_mb(MpegEncContext *s, DCTELEM block[6][64])
mb_y = s->mb_y; mb_y = s->mb_y;
#ifdef FF_POSTPROCESS #ifdef FF_POSTPROCESS
/* Obsolete. Exists for compatibility with mplayer only. */
quant_store[mb_y][mb_x]=s->qscale; quant_store[mb_y][mb_x]=s->qscale;
//printf("[%02d][%02d] %d\n",mb_x,mb_y,s->qscale); //printf("[%02d][%02d] %d\n",mb_x,mb_y,s->qscale);
#else
if(s->avctx->quant_store) s->avctx->quant_store[mb_y*(MBR+1)+mb_x] = s->qscale;
#endif #endif
/* update DC predictors for P macroblocks */ /* update DC predictors for P macroblocks */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment