svga: add format conversion for legacy formats

Graphics / Mesa 3D Graphics Library / Mesa - Charmaine Lee [vmware.com] - 10 September 2018 19:07 EDT

This patch extends the format_conversion table to support different view formats on texture buffer. For legacy image formats such as INTENSITY, LUMINANCE, LUMINANCE_ALPHA, special swizzle masks will be used on the red or RG channels.

This fixes piglit test arb_texture_buffer_object-formats fs|vs arb

337a74aa40 svga: add format conversion for legacy formats
src/gallium/drivers/svga/svga_format.c | 647 +++++++++++++-------------
src/gallium/drivers/svga/svga_format.h | 9 +
src/gallium/drivers/svga/svga_shader.c | 90 +++-
src/gallium/drivers/svga/svga_state_sampler.c | 19 +-
4 files changed, 433 insertions(+), 332 deletions(-)

Upstream: cgit.freedesktop.org


  • Share