projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
97cbb56
)
r300g: fix min/max lod computation
author
Mathias Fröhlich
<mathias.froehlich@gmx.net>
Sat, 28 Aug 2010 16:16:41 +0000
(18:16 +0200)
committer
Marek Olšák
<maraeo@gmail.com>
Sat, 28 Aug 2010 16:17:30 +0000
(18:17 +0200)
src/gallium/drivers/r300/r300_state.c
patch
|
blob
|
history
diff --git
a/src/gallium/drivers/r300/r300_state.c
b/src/gallium/drivers/r300/r300_state.c
index 2240011368730ad901231f55a6f8ab5246b8b6ae..9adaea3235f4194f8e50cb9fc248ad1f8e4c164c 100644
(file)
--- a/
src/gallium/drivers/r300/r300_state.c
+++ b/
src/gallium/drivers/r300/r300_state.c
@@
-1213,8
+1213,8
@@
static void*
/* Unfortunately, r300-r500 don't support floating-point mipmap lods. */
/* We must pass these to the merge function to clamp them properly. */
- sampler->min_lod =
MAX2((unsigned)
state->min_lod, 0);
- sampler->max_lod =
MAX2((unsigned)
ceilf(state->max_lod), 0);
+ sampler->min_lod =
(unsigned)MAX2(
state->min_lod, 0);
+ sampler->max_lod =
(unsigned)MAX2(
ceilf(state->max_lod), 0);
lod_bias = CLAMP((int)(state->lod_bias * 32 + 1), -(1 << 9), (1 << 9) - 1);