aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/state_tracker/st_format.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-04-28 11:14:32 +0000
committermarha <marha@users.sourceforge.net>2011-04-28 11:14:32 +0000
commit1840c5631682e0a69ed11487a23a43d45f2d15e1 (patch)
treefe954636044c0057b9f08e76d19489493ff09745 /mesalib/src/mesa/state_tracker/st_format.c
parent2ab09dc03e4ecc726ee7b5528306b0fe3e5b1837 (diff)
parent57a879849643e79d9674198a3a77c59532fb79b4 (diff)
downloadvcxsrv-1840c5631682e0a69ed11487a23a43d45f2d15e1.tar.gz
vcxsrv-1840c5631682e0a69ed11487a23a43d45f2d15e1.tar.bz2
vcxsrv-1840c5631682e0a69ed11487a23a43d45f2d15e1.zip
svn merge ^/branches/released .
Diffstat (limited to 'mesalib/src/mesa/state_tracker/st_format.c')
-rw-r--r--mesalib/src/mesa/state_tracker/st_format.c23
1 files changed, 21 insertions, 2 deletions
diff --git a/mesalib/src/mesa/state_tracker/st_format.c b/mesalib/src/mesa/state_tracker/st_format.c
index 8b3e782a5..32b44b806 100644
--- a/mesalib/src/mesa/state_tracker/st_format.c
+++ b/mesalib/src/mesa/state_tracker/st_format.c
@@ -954,14 +954,24 @@ st_choose_format(struct pipe_screen *screen, GLenum internalFormat,
/* prefer formats in order of data size, choosing 16-bit ones if equal sized */
case GL_RGBA16F_ARB:
+ {
+ static const enum pipe_format formats[] = {
+ PIPE_FORMAT_R16G16B16A16_FLOAT,
+ PIPE_FORMAT_R32G32B32A32_FLOAT
+ };
+ return find_supported_format(screen, formats, Elements(formats),
+ target, sample_count, bindings);
+ }
case GL_RGB16F_ARB:
{
static const enum pipe_format formats[] = {
+ PIPE_FORMAT_R16G16B16_FLOAT,
PIPE_FORMAT_R16G16B16A16_FLOAT,
+ PIPE_FORMAT_R32G32B32_FLOAT,
PIPE_FORMAT_R32G32B32A32_FLOAT
};
return find_supported_format(screen, formats, Elements(formats),
- target, sample_count, bindings);
+ target, sample_count, bindings);
}
case GL_LUMINANCE_ALPHA16F_ARB:
{
@@ -1040,14 +1050,23 @@ st_choose_format(struct pipe_screen *screen, GLenum internalFormat,
/* try a 32-bit format if available, otherwise fallback to a 16-bit one */
case GL_RGBA32F_ARB:
+ {
+ static const enum pipe_format formats[] = {
+ PIPE_FORMAT_R32G32B32A32_FLOAT,
+ PIPE_FORMAT_R16G16B16A16_FLOAT
+ };
+ return find_supported_format(screen, formats, Elements(formats),
+ target, sample_count, bindings);
+ }
case GL_RGB32F_ARB:
{
static const enum pipe_format formats[] = {
+ PIPE_FORMAT_R32G32B32_FLOAT,
PIPE_FORMAT_R32G32B32A32_FLOAT,
PIPE_FORMAT_R16G16B16A16_FLOAT
};
return find_supported_format(screen, formats, Elements(formats),
- target, sample_count, bindings);
+ target, sample_count, bindings);
}
case GL_LUMINANCE_ALPHA32F_ARB:
{