The intention here is to allow "base complete" instead of "mipmap
complete" as long as we're only copying from the base level (which
is usually 0, but not always).

Signed-off-by: Kenneth Graunke <kenn...@whitecape.org>
---
 src/mesa/main/copyimage.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/main/copyimage.c b/src/mesa/main/copyimage.c
index cf25159e880..d10bf8cc61c 100644
--- a/src/mesa/main/copyimage.c
+++ b/src/mesa/main/copyimage.c
@@ -151,7 +151,7 @@ prepare_target(struct gl_context *ctx, GLuint name, GLenum 
target,
 
       _mesa_test_texobj_completeness(ctx, texObj);
       if (!texObj->_BaseComplete ||
-          (level != 0 && !texObj->_MipmapComplete)) {
+          (level != texObj->BaseLevel && !texObj->_MipmapComplete)) {
          _mesa_error(ctx, GL_INVALID_OPERATION,
                      "glCopyImageSubData(%sName incomplete)", dbg_prefix);
          return false;
-- 
2.11.0

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to