diff --git a/gl/cogl-texture.c b/gl/cogl-texture.c index 215e14c78..ad25195f9 100644 --- a/gl/cogl-texture.c +++ b/gl/cogl-texture.c @@ -1600,6 +1600,8 @@ cogl_texture_new_from_foreign (GLuint gl_handle, g_array_append_val (tex->slice_gl_handles, gl_handle); + tex->first_pixels = NULL; + return _cogl_texture_handle_new (tex); } diff --git a/gles/cogl-texture.c b/gles/cogl-texture.c index 1929184c0..d650b7015 100644 --- a/gles/cogl-texture.c +++ b/gles/cogl-texture.c @@ -1676,6 +1676,8 @@ cogl_texture_new_from_foreign (GLuint gl_handle, g_array_append_val (tex->slice_gl_handles, gl_handle); + tex->first_pixels = NULL; + return _cogl_texture_handle_new (tex); }