22 |
|
|
23 |
/** MotionEstimation **/ |
/** MotionEstimation **/ |
24 |
|
|
25 |
bool MotionEstimation( |
bool MotionEstimation(MBParam * const pParam, |
26 |
MACROBLOCK * const pMBs, |
FRAMEINFO * const current, |
27 |
MBParam * const pParam, |
FRAMEINFO * const reference, |
|
const IMAGE * const pRef, |
|
28 |
const IMAGE * const pRefH, |
const IMAGE * const pRefH, |
29 |
const IMAGE * const pRefV, |
const IMAGE * const pRefV, |
30 |
const IMAGE * const pRefHV, |
const IMAGE * const pRefHV, |
|
IMAGE * const pCurrent, |
|
31 |
const uint32_t iLimit); |
const uint32_t iLimit); |
32 |
|
|
33 |
|
|
34 |
|
bool SMP_MotionEstimation(MBParam * const pParam, |
35 |
|
FRAMEINFO * const current, |
36 |
|
FRAMEINFO * const reference, |
37 |
|
const IMAGE * const pRefH, |
38 |
|
const IMAGE * const pRefV, |
39 |
|
const IMAGE * const pRefHV, |
40 |
|
const uint32_t iLimit); |
41 |
|
|
42 |
|
|
43 |
|
|
44 |
/** MBMotionCompensation **/ |
/** MBMotionCompensation **/ |
45 |
void MBMotionCompensation( |
void MBMotionCompensation(MACROBLOCK * const pMB, |
|
MACROBLOCK * const pMB, |
|
46 |
const uint32_t j, |
const uint32_t j, |
47 |
const uint32_t i, |
const uint32_t i, |
48 |
const IMAGE * const pRef, |
const IMAGE * const pRef, |
61 |
|
|
62 |
|
|
63 |
void MBTransQuantIntra(const MBParam *pParam, |
void MBTransQuantIntra(const MBParam *pParam, |
64 |
|
FRAMEINFO * frame, |
65 |
MACROBLOCK * pMB, |
MACROBLOCK * pMB, |
66 |
const uint32_t x_pos, /* <-- The x position of the MB to be searched */ |
const uint32_t x_pos, /* <-- The x position of the MB to be searched */ |
67 |
|
|
68 |
const uint32_t y_pos, /* <-- The y position of the MB to be searched */ |
const uint32_t y_pos, /* <-- The y position of the MB to be searched */ |
69 |
|
|
70 |
int16_t data[6*64], /* <-> the data of the MB to be coded */ |
int16_t data[6*64], /* <-> the data of the MB to be coded */ |
71 |
int16_t qcoeff[6*64], /* <-> the quantized DCT coefficients */ |
|
72 |
IMAGE * const pCurrent /* <-> the reconstructed image */ |
int16_t qcoeff[6 * 64] /* <-> the quantized DCT coefficients */ |
|
/* (function will update one MB in it with data from data[]) */ |
|
73 |
); |
); |
74 |
|
|
75 |
|
|
76 |
uint8_t MBTransQuantInter(const MBParam *pParam, /* <-- the parameter for DCT transformation |
uint8_t MBTransQuantInter(const MBParam * pParam, /* <-- the parameter for DCT transformation and Quantization */ |
77 |
and Quantization */ |
|
78 |
|
FRAMEINFO * frame, |
79 |
MACROBLOCK * pMB, |
MACROBLOCK * pMB, |
80 |
const uint32_t x_pos, /* <-- The x position of the MB to be searched */ |
const uint32_t x_pos, /* <-- The x position of the MB to be searched */ |
81 |
|
|
82 |
const uint32_t y_pos, /* <-- The y position of the MB to be searched */ |
const uint32_t y_pos, /* <-- The y position of the MB to be searched */ |
83 |
|
|
84 |
int16_t data[6*64], /* <-> the data of the MB to be coded */ |
int16_t data[6*64], /* <-> the data of the MB to be coded */ |
85 |
int16_t qcoeff[6*64], /* <-> the quantized DCT coefficients */ |
|
86 |
IMAGE * const pCurrent /* <-> the reconstructed image ( function will |
int16_t qcoeff[6 * 64] /* <-> the quantized DCT coefficients */ |
|
update one MB in it with data from data[] ) */ |
|
87 |
); |
); |
88 |
|
|
89 |
|
|
97 |
|
|
98 |
/** MBCoding.c **/ |
/** MBCoding.c **/ |
99 |
|
|
100 |
void MBCoding(const MBParam *pParam, /* <-- the parameter for coding of the bitstream */ |
void MBSkip(Bitstream * bs); /* just the bitstream. Since MB is skipped, no info is needed */ |
101 |
|
|
102 |
|
|
103 |
|
void MBCoding(const FRAMEINFO * frame, /* <-- the parameter for coding of the bitstream */ |
104 |
|
|
105 |
MACROBLOCK *pMB, /* <-- Info of the MB to be coded */ |
MACROBLOCK *pMB, /* <-- Info of the MB to be coded */ |
106 |
|
|
107 |
int16_t qcoeff[6*64], /* <-- the quantized DCT coefficients */ |
int16_t qcoeff[6*64], /* <-- the quantized DCT coefficients */ |
108 |
|
|
109 |
Bitstream * bs, /* <-> the bitstream */ |
Bitstream * bs, /* <-> the bitstream */ |
110 |
|
|
111 |
Statistics * pStat /* <-> statistical data collected for current frame */ |
Statistics * pStat /* <-> statistical data collected for current frame */ |
112 |
); |
); |
113 |
|
|