mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-01-04 14:12:03 +00:00
Use memcpy instead of per-pixel copy loop for rgb lcl format
Originally committed as revision 18997 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
ff8c65f482
commit
bb79016851
@ -432,12 +432,8 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
|
|||||||
case IMGTYPE_RGB24:
|
case IMGTYPE_RGB24:
|
||||||
for (row = height - 1; row >= 0; row--) {
|
for (row = height - 1; row >= 0; row--) {
|
||||||
pixel_ptr = row * c->pic.linesize[0];
|
pixel_ptr = row * c->pic.linesize[0];
|
||||||
for (col = 0; col < width; col++) {
|
memcpy(outptr + pixel_ptr, encoded, 3 * width);
|
||||||
outptr[pixel_ptr++] = encoded[0];
|
encoded += 3 * width;
|
||||||
outptr[pixel_ptr++] = encoded[1];
|
|
||||||
outptr[pixel_ptr++] = encoded[2];
|
|
||||||
encoded += 3;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case IMGTYPE_YUV411:
|
case IMGTYPE_YUV411:
|
||||||
|
Loading…
Reference in New Issue
Block a user