mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-06-29 17:33:08 +03:00
Not needed since memcpy is used here
This commit is contained in:
parent
cfce566d17
commit
dc53356c1a
|
@ -258,16 +258,6 @@ void
|
||||||
ImagingPackRGB(UINT8 *out, const UINT8 *in, int pixels) {
|
ImagingPackRGB(UINT8 *out, const UINT8 *in, int pixels) {
|
||||||
int i = 0;
|
int i = 0;
|
||||||
/* RGB triplets */
|
/* RGB triplets */
|
||||||
#ifdef __sparc
|
|
||||||
/* SPARC CPUs cannot read integers from nonaligned addresses. */
|
|
||||||
for (; i < pixels; i++) {
|
|
||||||
out[0] = in[R];
|
|
||||||
out[1] = in[G];
|
|
||||||
out[2] = in[B];
|
|
||||||
out += 3;
|
|
||||||
in += 4;
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
for (; i < pixels - 1; i++) {
|
for (; i < pixels - 1; i++) {
|
||||||
memcpy(out, in + i * 4, 4);
|
memcpy(out, in + i * 4, 4);
|
||||||
out += 3;
|
out += 3;
|
||||||
|
@ -278,7 +268,6 @@ ImagingPackRGB(UINT8 *out, const UINT8 *in, int pixels) {
|
||||||
out[2] = in[i * 4 + B];
|
out[2] = in[i * 4 + B];
|
||||||
out += 3;
|
out += 3;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
Loading…
Reference in New Issue
Block a user