x264-dsp
dct.h
1 /*****************************************************************************
2  * dct.h: transform and zigzag
3  *****************************************************************************/
4 
5 #ifndef X264_DCT_H
6 #define X264_DCT_H
7 
8 typedef struct
9 {
10  // pix1 stride = FENC_STRIDE
11  // pix2 stride = FDEC_STRIDE
12  // p_dst stride = FDEC_STRIDE
13  void (*sub4x4_dct)(dctcoef dct[16], pixel *pix1, pixel *pix2); /* 4x4 dct */
14  void (*add4x4_idct)(pixel *p_dst, dctcoef dct[16]); /* 4x4 idct */
15 
16  void (*sub8x8_dct)(dctcoef dct[4][16], pixel *pix1, pixel *pix2); /* 8x8 dct */
17  void (*sub8x8_dct_dc)(dctcoef dct[4], pixel *pix1, pixel *pix2); /* 8x8 dct dc (hadamard) */
18  void (*add8x8_idct)(pixel *p_dst, dctcoef dct[4][16]); /* 8x8 idct */
19  void (*add8x8_idct_dc)(pixel *p_dst, dctcoef dct[4]); /* 8x8 idct dc (hadamard) */
20 
21  void (*sub16x16_dct)(dctcoef dct[16][16], pixel *pix1, pixel *pix2); /* 16x16 dct */
22  void (*add16x16_idct)(pixel *p_dst, dctcoef dct[16][16]); /* 16x16 idct */
23  void (*add16x16_idct_dc)(pixel *p_dst, dctcoef dct[16]); /* 16x16 idct dc (hadamard) */
24 
25  /* dct2x2dc is defined in macroblock.c as inline function */
26  void (*dct4x4dc)(dctcoef d[16]); /* 4x4 hadamard transform */
27  void (*idct4x4dc)(dctcoef d[16]); /* 4x4 inverse hadamard transform */
29 
30 typedef struct
31 {
32  void (*scan_4x4)(dctcoef level[16], dctcoef dct[16]);
34 
35 void x264_dct_init(int cpu, x264_dct_function_t *dctf);
36 void x264_zigzag_init(int cpu, x264_zigzag_function_t *zigzagf);
37 
38 #endif
Definition: dct.h:9
Definition: dct.h:31