10 void jpeg_fdct_ifast (DCTELEM
*data
);
12 void j_rev_dct (DCTELEM
*data
);
14 void fdct_mmx(DCTELEM
*block
);
16 void (*av_fdct
)(DCTELEM
*block
);
18 /* pixel operations */
19 #define MAX_NEG_CROP 384
22 extern UINT32 squareTbl
[512];
24 void dsputil_init(void);
26 /* pixel ops : interface with DCT */
28 extern void (*get_pixels
)(DCTELEM
*block
, const UINT8
*pixels
, int line_size
);
29 extern void (*put_pixels_clamped
)(const DCTELEM
*block
, UINT8
*pixels
, int line_size
);
30 extern void (*add_pixels_clamped
)(const DCTELEM
*block
, UINT8
*pixels
, int line_size
);
32 void get_pixels_c(DCTELEM
*block
, const UINT8
*pixels
, int line_size
);
33 void put_pixels_clamped_c(const DCTELEM
*block
, UINT8
*pixels
, int line_size
);
34 void add_pixels_clamped_c(const DCTELEM
*block
, UINT8
*pixels
, int line_size
);
36 /* add and put pixel (decoding) */
37 typedef void (*op_pixels_func
)(UINT8
*block
, const UINT8
*pixels
, int line_size
, int h
);
39 extern op_pixels_func put_pixels_tab
[4];
40 extern op_pixels_func avg_pixels_tab
[4];
41 extern op_pixels_func put_no_rnd_pixels_tab
[4];
42 extern op_pixels_func avg_no_rnd_pixels_tab
[4];
44 /* sub pixel (encoding) */
45 extern void (*sub_pixels_tab
[4])(DCTELEM
*block
, const UINT8
*pixels
, int line_size
, int h
);
47 #define sub_pixels_2(block, pixels, line_size, dxy) \
48 sub_pixels_tab[dxy](block, pixels, line_size, 8)
50 /* motion estimation */
52 typedef int (*op_pixels_abs_func
)(UINT8
*blk1
, UINT8
*blk2
, int line_size
, int h
);
54 extern op_pixels_abs_func pix_abs16x16
;
55 extern op_pixels_abs_func pix_abs16x16_x2
;
56 extern op_pixels_abs_func pix_abs16x16_y2
;
57 extern op_pixels_abs_func pix_abs16x16_xy2
;
59 int pix_abs16x16_c(UINT8
*blk1
, UINT8
*blk2
, int lx
, int h
);
60 int pix_abs16x16_x2_c(UINT8
*blk1
, UINT8
*blk2
, int lx
, int h
);
61 int pix_abs16x16_y2_c(UINT8
*blk1
, UINT8
*blk2
, int lx
, int h
);
62 int pix_abs16x16_xy2_c(UINT8
*blk1
, UINT8
*blk2
, int lx
, int h
);
66 #define MM_MMX 0x0001 /* standard MMX */
67 #define MM_3DNOW 0x0004 /* AMD 3DNOW */
68 #define MM_MMXEXT 0x0002 /* SSE integer functions or AMD MMX ext */
69 #define MM_SSE 0x0008 /* SSE functions */
70 #define MM_SSE2 0x0010 /* PIV SSE2 functions */
76 static inline void emms(void)
78 asm volatile ("emms;");
81 #define __align8 __attribute__ ((aligned (8)))
83 void dsputil_init_mmx(void);