mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-11 00:04:24 +00:00
This commit is contained in:
parent
dd5c30d2d7
commit
50a0f18e6a
2 changed files with 2 additions and 1 deletions
|
|
@ -357,7 +357,7 @@ namespace
|
|||
case FT_PIXEL_MODE_BGRA:
|
||||
{
|
||||
// FIXME: Converting pre-multiplied alpha to straight. Doesn't smell good.
|
||||
#define DE_MULTIPLY(color, alpha) (ImU32)(255.0f * (float)color / (float)alpha + 0.5f)
|
||||
#define DE_MULTIPLY(color, alpha) ImMin((ImU32)(255.0f * (float)color / (float)(alpha + FLT_MIN) + 0.5f), 255u)
|
||||
if (multiply_table == nullptr)
|
||||
{
|
||||
for (uint32_t y = 0; y < h; y++, src += src_pitch, dst += dst_pitch)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue