vc4: Fix clear color setup for RGB565.

The util_pack_color() thing only sets up the low bits of the union, so
only return them, too.  Fixes intermittent failure on
fbo-alphatest-formats and es3conform's framebuffer-objects test under
simulation.
This commit is contained in:
Eric Anholt
2015-01-11 10:58:58 +13:00
parent 355156d2f7
commit c122662984
+4 -1
View File
@@ -288,7 +288,10 @@ pack_rgba(enum pipe_format format, const float *rgba)
{
union util_color uc;
util_pack_color(rgba, format, &uc);
return uc.ui[0];
if (util_format_get_blocksize(format) == 2)
return uc.us;
else
return uc.ui[0];
}
static void