Yes, that's much more sensible, thanks. -- Chris
On Wed, Feb 6, 2013 at 12:00 PM, Eric Anholt <e...@anholt.net> wrote: > Chris Forbes <chr...@ijw.co.nz> writes: > >> GL_TEXTURE_2D_MULTISAMPLE and GL_TEXTURE_2D_MULTISAMPLE_ARRAY targets >> don't allow filtering state to be set, but the default state fails the >> completeness check for integer formats. >> >> We still care about other reasons the texture might be considered >> incomplete though, so can't skip this entirely like GL_TEXTURE_BUFFER. >> >> Signed-off-by: Chris Forbes <chr...@ijw.co.nz> >> --- >> src/mesa/main/texobj.h | 8 +++++++- >> 1 file changed, 7 insertions(+), 1 deletion(-) >> >> diff --git a/src/mesa/main/texobj.h b/src/mesa/main/texobj.h >> index f86b4eb..f8a935b 100644 >> --- a/src/mesa/main/texobj.h >> +++ b/src/mesa/main/texobj.h >> @@ -107,7 +107,13 @@ _mesa_is_texture_complete(const struct >> gl_texture_object *texObj, >> (sampler->MinFilter != GL_NEAREST && >> sampler->MinFilter != GL_NEAREST_MIPMAP_NEAREST))) { >> /* If the format is integer, only nearest filtering is allowed */ >> - return GL_FALSE; >> + /* ignore this for texture targets that don't have filtering state: >> + * multisample, multisample array, maybe texture buffer (but TBO >> + * bypasses validation entirely) */ >> + if (texObj->Target != GL_TEXTURE_2D_MULTISAMPLE && >> + texObj->Target != GL_TEXTURE_2D_MULTISAMPLE_ARRAY) { >> + return GL_FALSE; >> + } >> } > > In _mesa_initialize_texture_object, we've got target-dependent init of > the MinFilter. Wouldn't it make sense to just set that to NEAREST for > MS textures? _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev