[Mesa-dev] [PATCH 16/22] st/mesa: Handle BGR[A/X]1010102 formats.

2017-12-15 Thread Mario Kleiner
Signed-off-by: Mario Kleiner 
Reviewed-by: Marek Olšák 
---
 src/mesa/state_tracker/st_cb_fbo.c | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/src/mesa/state_tracker/st_cb_fbo.c 
b/src/mesa/state_tracker/st_cb_fbo.c
index e2303b4..a982f87 100644
--- a/src/mesa/state_tracker/st_cb_fbo.c
+++ b/src/mesa/state_tracker/st_cb_fbo.c
@@ -286,6 +286,12 @@ st_new_renderbuffer_fb(enum pipe_format format, int 
samples, boolean sw)
strb->software = sw;
 
switch (format) {
+   case PIPE_FORMAT_B10G10R10A2_UNORM:
+  strb->Base.InternalFormat = GL_RGB10_A2;
+  break;
+   case PIPE_FORMAT_B10G10R10X2_UNORM:
+  strb->Base.InternalFormat = GL_RGB10;
+  break;
case PIPE_FORMAT_R8G8B8A8_UNORM:
case PIPE_FORMAT_B8G8R8A8_UNORM:
case PIPE_FORMAT_A8R8G8B8_UNORM:
-- 
2.7.4

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


[Mesa-dev] [PATCH 16/22] st/mesa: Handle BGR[A/X]1010102 formats.

2017-11-28 Thread Mario Kleiner
Signed-off-by: Mario Kleiner 
---
 src/mesa/state_tracker/st_cb_fbo.c | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/src/mesa/state_tracker/st_cb_fbo.c 
b/src/mesa/state_tracker/st_cb_fbo.c
index e2303b4..a982f87 100644
--- a/src/mesa/state_tracker/st_cb_fbo.c
+++ b/src/mesa/state_tracker/st_cb_fbo.c
@@ -286,6 +286,12 @@ st_new_renderbuffer_fb(enum pipe_format format, int 
samples, boolean sw)
strb->software = sw;
 
switch (format) {
+   case PIPE_FORMAT_B10G10R10A2_UNORM:
+  strb->Base.InternalFormat = GL_RGB10_A2;
+  break;
+   case PIPE_FORMAT_B10G10R10X2_UNORM:
+  strb->Base.InternalFormat = GL_RGB10;
+  break;
case PIPE_FORMAT_R8G8B8A8_UNORM:
case PIPE_FORMAT_B8G8R8A8_UNORM:
case PIPE_FORMAT_A8R8G8B8_UNORM:
-- 
2.7.4

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev