summaryrefslogtreecommitdiffstats
path: root/stream/tvi_v4l.c
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-06-05 14:27:54 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2007-06-05 14:27:54 +0000
commit6a09e8e2ed913cb44d74cac9c9e7a4cf7f4a18c1 (patch)
treeef08af22a70727d8ee9a902f622cf1d5042f5344 /stream/tvi_v4l.c
parentac87b4a173d2aee564e7cdca3037f101d946fbad (diff)
downloadmpv-6a09e8e2ed913cb44d74cac9c9e7a4cf7f4a18c1.tar.bz2
mpv-6a09e8e2ed913cb44d74cac9c9e7a4cf7f4a18c1.tar.xz
Replace implicit use of fast_memcpy via macro by explicit use to allow
for future optimization. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23475 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream/tvi_v4l.c')
-rw-r--r--stream/tvi_v4l.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/stream/tvi_v4l.c b/stream/tvi_v4l.c
index 3d19122868..63c4fac471 100644
--- a/stream/tvi_v4l.c
+++ b/stream/tvi_v4l.c
@@ -1416,9 +1416,9 @@ static inline void copy_frame(priv_t *priv, unsigned char *dest, unsigned char *
}
// YV12 uses VIDEO_PALETTE_YUV420P, but the planes are swapped
if (priv->format == IMGFMT_YV12) {
- memcpy(dest, source, priv->width * priv->height);
- memcpy(dest+priv->width * priv->height*5/4, source+priv->width * priv->height, priv->width * priv->height/4);
- memcpy(dest+priv->width * priv->height, source+priv->width * priv->height*5/4, priv->width * priv->height/4);
+ fast_memcpy(dest, source, priv->width * priv->height);
+ fast_memcpy(dest+priv->width * priv->height*5/4, source+priv->width * priv->height, priv->width * priv->height/4);
+ fast_memcpy(dest+priv->width * priv->height, source+priv->width * priv->height*5/4, priv->width * priv->height/4);
return;
}
@@ -1429,7 +1429,7 @@ static inline void copy_frame(priv_t *priv, unsigned char *dest, unsigned char *
case VIDEO_PALETTE_RGB565:
sptr = source + (priv->height-1)*priv->bytesperline;
for (i = 0; i < priv->height; i++) {
- memcpy(dest, sptr, priv->bytesperline);
+ fast_memcpy(dest, sptr, priv->bytesperline);
dest += priv->bytesperline;
sptr -= priv->bytesperline;
}
@@ -1437,7 +1437,7 @@ static inline void copy_frame(priv_t *priv, unsigned char *dest, unsigned char *
case VIDEO_PALETTE_UYVY:
case VIDEO_PALETTE_YUV420P:
default:
- memcpy(dest, source, priv->bytesperline * priv->height);
+ fast_memcpy(dest, source, priv->bytesperline * priv->height);
}
}
@@ -1665,7 +1665,7 @@ static double grab_video_frame(priv_t *priv, char *buffer, int len)
pthread_mutex_lock(&priv->video_buffer_mutex);
interval = (double)priv->video_timebuffer[priv->video_head]*1e-6;
- memcpy(buffer, priv->video_ringbuffer[priv->video_head], len);
+ fast_memcpy(buffer, priv->video_ringbuffer[priv->video_head], len);
priv->video_cnt--;
priv->video_head = (priv->video_head+1)%priv->video_buffer_size_current;
pthread_mutex_unlock(&priv->video_buffer_mutex);
@@ -1766,7 +1766,7 @@ static double grab_audio_frame(priv_t *priv, char *buffer, int len)
while (priv->audio_head == priv->audio_tail) {
usleep(10000);
}
- memcpy(buffer, priv->audio_ringbuffer+priv->audio_head*priv->audio_in.blocksize, len);
+ fast_memcpy(buffer, priv->audio_ringbuffer+priv->audio_head*priv->audio_in.blocksize, len);
priv->audio_head = (priv->audio_head+1) % priv->audio_buffer_size;
priv->audio_cnt--;
priv->audio_sent_blocks_total++;