OSDN Git Service

i915: Blit RGBX<->RGBA drawpixels
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 5 Jun 2015 13:33:36 +0000 (14:33 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 8 Jun 2015 16:56:10 +0000 (17:56 +0100)
commitc2d0606827412b710dcaed80268fc665de8c9c5d
tree0de7ecc56a8f5f57391411fd3f8317698a6f135f
parent8da79b8378ae87474d8c47ad955e4833edf98359
i915: Blit RGBX<->RGBA drawpixels

The blitter already has code to accommodate filling in the alpha channel
for BGRX destination formats, so expand this to also allow filling the
alpha channgel in RGBX formats.

More importantly for the next patch is moving the test into its own
function for the purpose of exporting the check to the callers.

v2: Fix alpha expansion as spotted by Alexander with the fix suggested by
Kenneth

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Jason Ekstrand <jason@jlekstrand.net>
Cc: Alexander Monakov <amonakov@gmail.com>
Cc: Kristian Høgsberg <krh@bitplanet.net>
Cc: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by Kenneth Graunke <kenneth@whitecape.org>
Cc: mesa-stable@lists.freedesktop.org
src/mesa/drivers/dri/i965/intel_blit.c