diff options
author | Brian Paul <brianp@vmware.com> | 2009-08-27 09:14:09 -0600 |
---|---|---|
committer | Brian Paul <brianp@vmware.com> | 2009-08-27 09:14:09 -0600 |
commit | 44e86dde6dfe934acc0d50aad10e0f2cb390e47b (patch) | |
tree | a5be3772dc9aacb76771e782cb0266257bfc796a /src/gallium/auxiliary/util/u_gen_mipmap.c | |
parent | 8d0bdfa4335ea07a747f53635a57414d15c234b7 (diff) | |
parent | 32f95f8c173155ca30e77c345a68b0d3336ddbed (diff) |
Merge branch 'mesa_7_5_branch'
Diffstat (limited to 'src/gallium/auxiliary/util/u_gen_mipmap.c')
-rw-r--r-- | src/gallium/auxiliary/util/u_gen_mipmap.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/gallium/auxiliary/util/u_gen_mipmap.c b/src/gallium/auxiliary/util/u_gen_mipmap.c index edc37561ab..f06c0e463d 100644 --- a/src/gallium/auxiliary/util/u_gen_mipmap.c +++ b/src/gallium/auxiliary/util/u_gen_mipmap.c @@ -917,11 +917,19 @@ static void format_to_type_comps(enum pipe_format pformat, enum dtype *datatype, uint *comps) { + /* XXX I think this could be implemented in terms of the pf_*() functions */ switch (pformat) { case PIPE_FORMAT_A8R8G8B8_UNORM: case PIPE_FORMAT_X8R8G8B8_UNORM: case PIPE_FORMAT_B8G8R8A8_UNORM: case PIPE_FORMAT_B8G8R8X8_UNORM: + case PIPE_FORMAT_R8G8B8A8_SRGB: + case PIPE_FORMAT_R8G8B8X8_SRGB: + case PIPE_FORMAT_A8R8G8B8_SRGB: + case PIPE_FORMAT_X8R8G8B8_SRGB: + case PIPE_FORMAT_B8G8R8A8_SRGB: + case PIPE_FORMAT_B8G8R8X8_SRGB: + case PIPE_FORMAT_R8G8B8_SRGB: *datatype = DTYPE_UBYTE; *comps = 4; return; @@ -938,12 +946,14 @@ format_to_type_comps(enum pipe_format pformat, *comps = 3; return; case PIPE_FORMAT_L8_UNORM: + case PIPE_FORMAT_L8_SRGB: case PIPE_FORMAT_A8_UNORM: case PIPE_FORMAT_I8_UNORM: *datatype = DTYPE_UBYTE; *comps = 1; return; case PIPE_FORMAT_A8L8_UNORM: + case PIPE_FORMAT_A8L8_SRGB: *datatype = DTYPE_UBYTE; *comps = 2; return; |