offscreen: cogl_offscreen_new_to_texture now supports GL_TEXTURE_RECTANGLE_ARB
cogl_offscreen_new_to_texture previously bailed out if the given texture's GL target was anything but GL_TEXTURE_2D, but it now also allows foreign GL_TEXTURE_RECTANGLE_ARB textures. Thanks to Owen for reporting this issue, ref: https://bugzilla.gnome.org/show_bug.cgi?id=601032
This commit is contained in:
parent
d3a01e0c96
commit
558b17ee1e
@ -265,7 +265,8 @@ cogl_offscreen_new_to_texture (CoglHandle texhandle)
|
||||
if (!cogl_texture_get_gl_texture (texhandle, &tex_gl_handle, &tex_gl_target))
|
||||
return COGL_INVALID_HANDLE;
|
||||
|
||||
if (tex_gl_target != GL_TEXTURE_2D)
|
||||
if (tex_gl_target != GL_TEXTURE_2D &&
|
||||
tex_gl_target != GL_TEXTURE_RECTANGLE_ARB)
|
||||
return COGL_INVALID_HANDLE;
|
||||
|
||||
/* Create a renderbuffer for stenciling */
|
||||
|
Loading…
Reference in New Issue
Block a user