19 #ifndef MPLAYER_FASTMEMCPY_H
20 #define MPLAYER_FASTMEMCPY_H
29 #if ! defined(CONFIG_FASTMEMCPY) || ! (HAVE_MMX || HAVE_MMX2 || HAVE_AMD3DNOW )
30 #define mem2agpcpy(a,b,c) memcpy(a,b,c)
31 #define fast_memcpy(a,b,c) memcpy(a,b,c)
34 static inline void *
mem2agpcpy_pic(
void * dst,
const void *
src,
int bytesPerLine,
int height,
int dstStride,
int srcStride)
39 if(dstStride == srcStride)
42 src = (
const uint8_t*)src + (height-1)*srcStride;
43 dst = (
uint8_t*)dst + (height-1)*dstStride;
44 srcStride = -srcStride;
54 src = (
const uint8_t*)src + srcStride;
55 dst = (
uint8_t*)dst + dstStride;
62 #define memcpy_pic(d, s, b, h, ds, ss) memcpy_pic2(d, s, b, h, ds, ss, 0)
63 #define my_memcpy_pic(d, s, b, h, ds, ss) memcpy_pic2(d, s, b, h, ds, ss, 1)
70 int bytesPerLine,
int height,
71 int dstStride,
int srcStride,
int limit2width)
76 if(!limit2width && dstStride == srcStride)
79 src = (
const uint8_t*)src + (height-1)*srcStride;
80 dst = (
uint8_t*)dst + (height-1)*dstStride;
81 srcStride = -srcStride;
91 src = (
const uint8_t*)src + srcStride;
92 dst = (
uint8_t*)dst + dstStride;