diff options
author | Lucas Stach <[email protected]> | 2017-06-04 21:06:33 +0200 |
---|---|---|
committer | Andres Gomez <[email protected]> | 2017-06-28 20:15:03 +0300 |
commit | acd0a0a9264e94e9569be2783d151fa9b2c3c12e (patch) | |
tree | 306075a9658f0cf4920324d7b304a295fdcb4218 /src/gallium/drivers/etnaviv/etnaviv_screen.c | |
parent | 1ef236050cdda7cf90dd8e9d01bc2fef8bfff80a (diff) |
etnaviv: advertise correct max LOD bias
The maximum LOD bias supported is the same as the max texture level
supported.
Fixes piglit: ext_texture_lod_bias
Fixes: c9e8b49b ("etnaviv: gallium driver for Vivante GPUs")
Cc: [email protected]
Signed-off-by: Lucas Stach <[email protected]>
Reviewed-by: Christian Gmeiner <[email protected]>
(cherry picked from commit 5065549e2a75e2a56cd3bc8b0fbb6c9013e86cb4)
Diffstat (limited to 'src/gallium/drivers/etnaviv/etnaviv_screen.c')
-rw-r--r-- | src/gallium/drivers/etnaviv/etnaviv_screen.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gallium/drivers/etnaviv/etnaviv_screen.c b/src/gallium/drivers/etnaviv/etnaviv_screen.c index 626f7c77898..8b251467691 100644 --- a/src/gallium/drivers/etnaviv/etnaviv_screen.c +++ b/src/gallium/drivers/etnaviv/etnaviv_screen.c @@ -341,6 +341,8 @@ etna_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param) static float etna_screen_get_paramf(struct pipe_screen *pscreen, enum pipe_capf param) { + struct etna_screen *screen = etna_screen(pscreen); + switch (param) { case PIPE_CAPF_MAX_LINE_WIDTH: case PIPE_CAPF_MAX_LINE_WIDTH_AA: @@ -350,7 +352,7 @@ etna_screen_get_paramf(struct pipe_screen *pscreen, enum pipe_capf param) case PIPE_CAPF_MAX_TEXTURE_ANISOTROPY: return 16.0f; case PIPE_CAPF_MAX_TEXTURE_LOD_BIAS: - return 16.0f; + return util_last_bit(screen->specs.max_texture_size); case PIPE_CAPF_GUARD_BAND_LEFT: case PIPE_CAPF_GUARD_BAND_TOP: case PIPE_CAPF_GUARD_BAND_RIGHT: |