mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-28 16:50:10 +01:00
mesa: fix SRGB alpha channel value in pack_float_R8G8B8X8_SRGB
Jason pointed out the bug on review adding new formats, but the existing format also appears to have the bug, so use 255 as the max, these are SRGB no SNORM. Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
ecc48f83c8
commit
9ea045e85e
1 changed files with 1 additions and 1 deletions
|
|
@ -1713,7 +1713,7 @@ pack_float_R8G8B8X8_SRGB(const GLfloat src[4], void *dst)
|
|||
GLubyte r = util_format_linear_float_to_srgb_8unorm(src[RCOMP]);
|
||||
GLubyte g = util_format_linear_float_to_srgb_8unorm(src[GCOMP]);
|
||||
GLubyte b = util_format_linear_float_to_srgb_8unorm(src[BCOMP]);
|
||||
*d = PACK_COLOR_8888(127, b, g, r);
|
||||
*d = PACK_COLOR_8888(255, b, g, r);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue