1
0
Fork 0

cogl: Use #ifdef GL around GL_TEXTURE_RECTANGLE_ARB

Commit 558b17ee1e added support for rectangle textures to the
framebuffer code. Under GLES there is no GL_TEXTURE_RECTANGLE_ARB
definition so this was breaking the build. The rest of Cogl uses
ifdef's around that constant so we should do the same here.
This commit is contained in:
Neil Roberts 2009-12-02 21:54:22 +00:00
parent 59d84f7806
commit 7f58c14dcd

View file

@ -265,8 +265,11 @@ 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 &&
tex_gl_target != GL_TEXTURE_RECTANGLE_ARB)
if (tex_gl_target != GL_TEXTURE_2D
#ifdef HAVE_COGL_GL
&& tex_gl_target != GL_TEXTURE_RECTANGLE_ARB
#endif
)
return COGL_INVALID_HANDLE;
/* Create a renderbuffer for stenciling */