mirror of
https://github.com/glfw/glfw.git
synced 2025-06-15 12:12:16 +00:00
switch to unsigned int which is more correct and more efficient
As suggested by Maato, martinhath, dcousens, and drfuchs. Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
b582cc576e
commit
d70fe3699d
@ -2115,10 +2115,10 @@ void _glfwSetWindowIconX11(_GLFWwindow* window, int count, const GLFWimage* imag
|
||||
|
||||
for (int j = 0; j < images[i].width * images[i].height; j++)
|
||||
{
|
||||
*target++ = (((long)images[i].pixels[j * 4 + 0]) << 16) |
|
||||
(((long)images[i].pixels[j * 4 + 1]) << 8) |
|
||||
(((long)images[i].pixels[j * 4 + 2]) << 0) |
|
||||
(((long)images[i].pixels[j * 4 + 3]) << 24);
|
||||
*target++ = (((unsigned int)images[i].pixels[j * 4 + 0]) << 16) |
|
||||
(((unsigned int)images[i].pixels[j * 4 + 1]) << 8) |
|
||||
(((unsigned int)images[i].pixels[j * 4 + 2]) << 0) |
|
||||
(((unsigned int)images[i].pixels[j * 4 + 3]) << 24);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user