Template
104 lines
2.0 KiB
C
104 lines
2.0 KiB
C
|
|
/*!
|
|
************************************************************************
|
|
* \file block.h
|
|
*
|
|
* \brief
|
|
* constant arrays for single block processing
|
|
*
|
|
* \author
|
|
* Inge Lille-Langoy <inge.lille-langoy@telenor.com> \n
|
|
* Telenor Satellite Services \n
|
|
* P.O.Box 6914 St.Olavs plass \n
|
|
* N-0130 Oslo, Norway
|
|
*
|
|
************************************************************************
|
|
*/
|
|
|
|
#ifndef _BLOCK_H_
|
|
#define _BLOCK_H_
|
|
|
|
|
|
#include "global.h"
|
|
|
|
extern int residual_transform_quant_luma_4x4(Macroblock *currMB, ColorPlane pl, int block_x,int block_y, int *coeff_cost, int intra);
|
|
|
|
static const byte QP_SCALE_CR[52]=
|
|
{
|
|
0, 1, 2, 3, 4, 5, 6, 7, 8, 9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,
|
|
28,29,29,30,31,32,32,33,34,34,35,35,36,36,37,37, 37,38,38,38,39,39,39,39
|
|
};
|
|
|
|
//! look up tables for FRExt_chroma support
|
|
static const unsigned char subblk_offset_x[3][8][4] =
|
|
{
|
|
{
|
|
{0, 4, 0, 4},
|
|
{0, 4, 0, 4},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
},
|
|
{
|
|
{0, 4, 0, 4},
|
|
{0, 4, 0, 4},
|
|
{0, 4, 0, 4},
|
|
{0, 4, 0, 4},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
},
|
|
{
|
|
{0, 4, 0, 4},
|
|
{8,12, 8,12},
|
|
{0, 4, 0, 4},
|
|
{8,12, 8,12},
|
|
{0, 4, 0, 4},
|
|
{8,12, 8,12},
|
|
{0, 4, 0, 4},
|
|
{8,12, 8,12}
|
|
}
|
|
};
|
|
|
|
|
|
static const unsigned char subblk_offset_y[3][8][4] =
|
|
{
|
|
{
|
|
{0, 0, 4, 4},
|
|
{0, 0, 4, 4},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0}
|
|
},
|
|
{
|
|
{0, 0, 4, 4},
|
|
{8, 8,12,12},
|
|
{0, 0, 4, 4},
|
|
{8, 8,12,12},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0},
|
|
{0, 0, 0, 0}
|
|
},
|
|
{
|
|
{0, 0, 4, 4},
|
|
{0, 0, 4, 4},
|
|
{8, 8,12,12},
|
|
{8, 8,12,12},
|
|
{0, 0, 4, 4},
|
|
{0, 0, 4, 4},
|
|
{8, 8,12,12},
|
|
{8, 8,12,12}
|
|
}
|
|
};
|
|
|
|
#endif
|
|
|