From 5972e9db45cdf6cbfb10ec4f2ef78567f1fc754a Mon Sep 17 00:00:00 2001 From: Matthew Allum Date: Thu, 10 Jul 2008 16:19:09 +0000 Subject: [PATCH] 008-07-10 Matthew Allum * clutter/cogl/gles/cogl-fbo.c: * clutter/cogl/gles/cogl-texture.c: Fix warnings with eglnative build --- gles/cogl-fbo.c | 2 ++ gles/cogl-texture.c | 50 --------------------------------------------- 2 files changed, 2 insertions(+), 50 deletions(-) diff --git a/gles/cogl-fbo.c b/gles/cogl-fbo.c index 242184a3c..022a61c73 100644 --- a/gles/cogl-fbo.c +++ b/gles/cogl-fbo.c @@ -180,6 +180,8 @@ cogl_draw_buffer (CoglBufferTarget target, CoglHandle offscreen) /* Draw to all channels */ GE( glColorMask (GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE) ); + break; + default: break; } diff --git a/gles/cogl-texture.c b/gles/cogl-texture.c index 0f6772324..5673dac82 100644 --- a/gles/cogl-texture.c +++ b/gles/cogl-texture.c @@ -482,20 +482,6 @@ _cogl_texture_download_from_gl (CoglTexture *tex, return TRUE; } -static void -_cogl_texture_set_alignment_for_rowstride (gint rowstride) -{ - gint alignment = 1; - - while ((rowstride & 1) == 0 && alignment < 8) - { - alignment <<= 1; - rowstride >>= 1; - } - - GE( glPixelStorei (GL_UNPACK_ALIGNMENT, alignment) ); -} - static gboolean _cogl_texture_upload_subregion_to_gl (CoglTexture *tex, gint src_x, @@ -866,42 +852,6 @@ _cogl_texture_slices_free (CoglTexture *tex) } } -static gboolean -_cogl_pixel_format_from_gl_internal (GLenum gl_int_format, - CoglPixelFormat *out_format) -{ - /* It doesn't really matter we convert to exact same - format (some have no cogl match anyway) since format - is re-matched against cogl when getting or setting - texture image data. - */ - - switch (gl_int_format) - { - case GL_ALPHA: - - *out_format = COGL_PIXEL_FORMAT_A_8; - return TRUE; - - case GL_LUMINANCE: - - *out_format = COGL_PIXEL_FORMAT_G_8; - return TRUE; - - case GL_RGB: - - *out_format = COGL_PIXEL_FORMAT_RGB_888; - return TRUE; - - case GL_RGBA: - - *out_format = COGL_PIXEL_FORMAT_RGBA_8888; - return TRUE; - } - - return FALSE; -} - static CoglPixelFormat _cogl_pixel_format_to_gl (CoglPixelFormat format, GLenum *out_glintformat,