mirror of
https://github.com/hyprwm/hyprpicker.git
synced 2024-12-22 22:29:49 +01:00
fix clang build (#24)
This commit is contained in:
parent
6dc7f3321e
commit
ef6009f71c
1 changed files with 2 additions and 2 deletions
|
@ -344,7 +344,7 @@ CColor CHyprpicker::getColorFromPixel(CLayerSurface* pLS, Vector2D pix) {
|
||||||
unsigned char green;
|
unsigned char green;
|
||||||
unsigned char red;
|
unsigned char red;
|
||||||
unsigned char alpha;
|
unsigned char alpha;
|
||||||
}* px = (struct pixel*)(pLS->screenBuffer.data + (int)pix.y * (int)pLS->screenBuffer.pixelSize.x * 4 + (int)pix.x * 4);
|
}* px = (struct pixel*)((char*)pLS->screenBuffer.data + (int)pix.y * (int)pLS->screenBuffer.pixelSize.x * 4 + (int)pix.x * 4);
|
||||||
|
|
||||||
return CColor{(uint8_t)px->red, (uint8_t)px->green, (uint8_t)px->blue, (uint8_t)px->alpha};
|
return CColor{(uint8_t)px->red, (uint8_t)px->green, (uint8_t)px->blue, (uint8_t)px->alpha};
|
||||||
}
|
}
|
Loading…
Reference in a new issue