21 |
* along with this program ; if not, write to the Free Software |
* along with this program ; if not, write to the Free Software |
22 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
23 |
* |
* |
24 |
* $Id: mbtransquant.c,v 1.21.2.7 2003-04-10 13:05:54 edgomez Exp $ |
* $Id: mbtransquant.c,v 1.21.2.8 2003-04-13 16:18:09 syskin Exp $ |
25 |
* |
* |
26 |
****************************************************************************/ |
****************************************************************************/ |
27 |
|
|
69 |
|
|
70 |
/* Performs Forward DCT on all blocks */ |
/* Performs Forward DCT on all blocks */ |
71 |
static __inline void |
static __inline void |
72 |
MBfDCT(const MBParam * pParam, |
MBfDCT(const MBParam * const pParam, |
73 |
FRAMEINFO * frame, |
const FRAMEINFO * const frame, |
74 |
MACROBLOCK * pMB, |
MACROBLOCK * const pMB, |
75 |
uint32_t x_pos, |
uint32_t x_pos, |
76 |
uint32_t y_pos, |
uint32_t y_pos, |
77 |
int16_t data[6 * 64]) |
int16_t data[6 * 64]) |
235 |
|
|
236 |
|
|
237 |
static __inline void |
static __inline void |
238 |
MBTrans8to16(const MBParam * pParam, |
MBTrans8to16(const MBParam * const pParam, |
239 |
FRAMEINFO * frame, |
const FRAMEINFO * const frame, |
240 |
MACROBLOCK * pMB, |
const MACROBLOCK * const pMB, |
241 |
const uint32_t x_pos, |
const uint32_t x_pos, |
242 |
const uint32_t y_pos, |
const uint32_t y_pos, |
243 |
int16_t data[6 * 64]) |
int16_t data[6 * 64]) |
247 |
uint32_t next_block = stride * 8; |
uint32_t next_block = stride * 8; |
248 |
int32_t cst; |
int32_t cst; |
249 |
uint8_t *pY_Cur, *pU_Cur, *pV_Cur; |
uint8_t *pY_Cur, *pU_Cur, *pV_Cur; |
250 |
IMAGE *pCurrent = &frame->image; |
const IMAGE * const pCurrent = &frame->image; |
251 |
transfer_operation_8to16_t *transfer_op = NULL; |
transfer_operation_8to16_t *transfer_op = NULL; |
252 |
|
|
253 |
if ((frame->vop_flags & XVID_VOP_REDUCED)) { |
if ((frame->vop_flags & XVID_VOP_REDUCED)) { |
288 |
} |
} |
289 |
|
|
290 |
static __inline void |
static __inline void |
291 |
MBTrans16to8(const MBParam * pParam, |
MBTrans16to8(const MBParam * const pParam, |
292 |
FRAMEINFO * frame, |
const FRAMEINFO * const frame, |
293 |
MACROBLOCK * pMB, |
const MACROBLOCK * const pMB, |
294 |
const uint32_t x_pos, |
const uint32_t x_pos, |
295 |
const uint32_t y_pos, |
const uint32_t y_pos, |
296 |
int16_t data[6 * 64], |
int16_t data[6 * 64], |
302 |
uint32_t stride2 = stride / 2; |
uint32_t stride2 = stride / 2; |
303 |
uint32_t next_block = stride * 8; |
uint32_t next_block = stride * 8; |
304 |
uint32_t cst; |
uint32_t cst; |
305 |
IMAGE *pCurrent = &frame->image; |
const IMAGE * const pCurrent = &frame->image; |
306 |
transfer_operation_16to8_t *transfer_op = NULL; |
transfer_operation_16to8_t *transfer_op = NULL; |
307 |
|
|
308 |
if (pMB->field_dct) { |
if (pMB->field_dct) { |
358 |
****************************************************************************/ |
****************************************************************************/ |
359 |
|
|
360 |
void |
void |
361 |
MBTransQuantIntra(const MBParam * pParam, |
MBTransQuantIntra(const MBParam * const pParam, |
362 |
FRAMEINFO * frame, |
const FRAMEINFO * const frame, |
363 |
MACROBLOCK * pMB, |
MACROBLOCK * const pMB, |
364 |
const uint32_t x_pos, |
const uint32_t x_pos, |
365 |
const uint32_t y_pos, |
const uint32_t y_pos, |
366 |
int16_t data[6 * 64], |
int16_t data[6 * 64], |
388 |
|
|
389 |
|
|
390 |
uint8_t |
uint8_t |
391 |
MBTransQuantInter(const MBParam * pParam, |
MBTransQuantInter(const MBParam * const pParam, |
392 |
FRAMEINFO * frame, |
const FRAMEINFO * const frame, |
393 |
MACROBLOCK * pMB, |
MACROBLOCK * const pMB, |
394 |
const uint32_t x_pos, |
const uint32_t x_pos, |
395 |
const uint32_t y_pos, |
const uint32_t y_pos, |
396 |
int16_t data[6 * 64], |
int16_t data[6 * 64], |