summaryrefslogtreecommitdiff
path: root/src/mesa/main/samplerobj.c
diff options
context:
space:
mode:
authorSamuel Iglesias Gonsalvez <siglesias@igalia.com>2014-12-11 23:34:14 +0100
committerIago Toral Quiroga <itoral@igalia.com>2015-01-13 12:19:32 +0100
commitd8d59202af1d409ad2e10c2893612ff6fa05d3a2 (patch)
treeb5e6f4795381c74b63da7625ce72a34ee877b267 /src/mesa/main/samplerobj.c
parent8e49a3e028b9526d2ab7662a9f6683a72b6b6787 (diff)
main: round floating-point value to nearest integer in glGetTexParameteriv()
Previously, a cast was done to convert from float to int but there were rounding errors. The spec specificies in Data Conversion chapter that Floating-point values are rounded to the nearest integer. This patch fixes the following 8 dEQP tests: dEQP-GLES3.functional.state_query.texture.texture_2d_texture_min_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_2d_texture_max_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_3d_texture_min_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_3d_texture_max_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_2d_array_texture_min_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_2d_array_texture_max_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_cube_map_texture_min_lod_gettexparameteri dEQP-GLES3.functional.state_query.texture.texture_cube_map_texture_max_lod_gettexparameteri Signed-off-by: Samuel Iglesias Gonsalvez <siglesias@igalia.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Diffstat (limited to 'src/mesa/main/samplerobj.c')
0 files changed, 0 insertions, 0 deletions