diff options
author | Marek Olšák <[email protected]> | 2011-03-07 02:03:52 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2011-03-08 23:52:37 +0100 |
commit | 7d16e2c0cd70dc5a23b746dbc8e44c58366b5353 (patch) | |
tree | dd8767ec968eebe4f8a75c0d53c4537e69a2d088 /src/mesa/main/texfetch.c | |
parent | 12fa91b6753dccbd3aa12c570d1f1e55c7dc0582 (diff) |
mesa: add EXT_texture_compression_latc
The encoding/decoding algorithms are shared with RGTC.
Thanks to some magic with the base format, the RGTC texstore functions work
for LATC too.
swrast passes the related piglit tests besides two things:
- The alpha channel is wrong (it's always 1), however the incorrect alpha
channel makes some other tests fail too, so I guess it's unrelated to LATC.
- Signed LATC fetches aren't correct yet (signed values are clamped to [0,1]),
however RGTC has the same problem.
Further testing (with other of my patches) shows that hardware drivers
and softpipe work.
BTW, ETQW uses this extension.
Diffstat (limited to 'src/mesa/main/texfetch.c')
-rw-r--r-- | src/mesa/main/texfetch.c | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/mesa/main/texfetch.c b/src/mesa/main/texfetch.c index 550597e1cdf..988a7e05468 100644 --- a/src/mesa/main/texfetch.c +++ b/src/mesa/main/texfetch.c @@ -786,6 +786,34 @@ texfetch_funcs[MESA_FORMAT_COUNT] = NULL, NULL }, + { + MESA_FORMAT_L_LATC1, + NULL, + _mesa_fetch_texel_2d_f_l_latc1, + NULL, + NULL + }, + { + MESA_FORMAT_SIGNED_L_LATC1, + NULL, + _mesa_fetch_texel_2d_f_signed_l_latc1, + NULL, + NULL + }, + { + MESA_FORMAT_LA_LATC2, + NULL, + _mesa_fetch_texel_2d_f_la_latc2, + NULL, + NULL + }, + { + MESA_FORMAT_SIGNED_LA_LATC2, + NULL, + _mesa_fetch_texel_2d_f_signed_la_latc2, + NULL, + NULL + }, }; |