From 2870addd15508fdb7a9b7f729d4cb52f44efca64 Mon Sep 17 00:00:00 2001 From: "Petar G. Georgiev" Date: Sat, 10 May 2025 01:04:49 +0530 Subject: [PATCH] freedreno/fdl: Add support for RGB888/BGR888 pipe formats in render buffer creation This enables the rendering of RGB/BGR 24-bit format buffers directly onto the framebuffer. For RGB888, support already exists for vertex and texture formats, so render buffer format support has been added. For BGR888, support for vertex, texture, and render buffer formats has been added. The internal format chosen for both RGB888 and BGR888 is GL_RGB8. Change-Id: I0557389dba05d3b44d7b935f02683df17e41fbd2 Signed-off-by: Petar G. Georgiev Signed-off-by: Lakshman Chandu Kondreddy Part-of: --- src/freedreno/fdl/fd6_format_table.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/freedreno/fdl/fd6_format_table.c b/src/freedreno/fdl/fd6_format_table.c index 55d42538deb..845efbdc6e5 100644 --- a/src/freedreno/fdl/fd6_format_table.c +++ b/src/freedreno/fdl/fd6_format_table.c @@ -127,6 +127,10 @@ static const struct fd6_format formats[PIPE_FORMAT_COUNT] = { VT_(R8G8B8_SINT, 8_8_8_SINT, WZYX), V__(R8G8B8_USCALED, 8_8_8_UINT, WZYX), V__(R8G8B8_SSCALED, 8_8_8_SINT, WZYX), + VT_(B8G8R8_UNORM, 8_8_8_UNORM, WXYZ), + VT_(B8G8R8_SNORM, 8_8_8_SNORM, WXYZ), + VT_(B8G8R8_UINT, 8_8_8_UINT, WXYZ), + VT_(B8G8R8_SINT, 8_8_8_SINT, WXYZ), /* 32-bit */ V__(R32_UNORM, 32_UNORM, WZYX),