changeset 16879:6ea220b10e8e

More consistent and sane types. Also avoids some gcc 4 warnings.
author reimar
date Mon, 31 Oct 2005 13:56:16 +0000
parents 865ba529e6fd
children 1267964a4dfa
files libvo/gl_common.c libvo/gl_common.h libvo/vo_gl.c
diffstat 3 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/gl_common.c	Mon Oct 31 08:41:41 2005 +0000
+++ b/libvo/gl_common.c	Mon Oct 31 13:56:16 2005 +0000
@@ -154,7 +154,7 @@
  * \return 1 if format is supported by OpenGL, 0 if not.
  * \ingroup gltexture
  */
-int glFindFormat(uint32_t fmt, uint32_t *bpp, GLint *gl_texfmt,
+int glFindFormat(uint32_t fmt, int *bpp, GLint *gl_texfmt,
                   GLenum *gl_format, GLenum *gl_type)
 {
   int supported = 1;
@@ -478,7 +478,7 @@
  * \ingroup gltexture
  */
 void glUploadTex(GLenum target, GLenum format, GLenum type,
-                 const char *data, int stride,
+                 const void *data, int stride,
                  int x, int y, int w, int h, int slice) {
   int y_max = y + h;
   if (w <= 0 || h <= 0) return;
--- a/libvo/gl_common.h	Mon Oct 31 08:41:41 2005 +0000
+++ b/libvo/gl_common.h	Mon Oct 31 13:56:16 2005 +0000
@@ -184,7 +184,7 @@
 
 const char *glValName(GLint value);
 
-int glFindFormat(uint32_t format, uint32_t *bpp, GLint *gl_texfmt,
+int glFindFormat(uint32_t format, int *bpp, GLint *gl_texfmt,
                   GLenum *gl_format, GLenum *gl_type);
 int glFmt2bpp(GLenum format, GLenum type);
 void glCreateClearTex(GLenum target, GLenum fmt, GLint filter,
@@ -192,7 +192,7 @@
 int glCreatePPMTex(GLenum target, GLenum fmt, GLint filter,
                    FILE *f, int *width, int *height, int *maxval);
 void glUploadTex(GLenum target, GLenum format, GLenum type,
-                 const char *data, int stride,
+                 const void *data, int stride,
                  int x, int y, int w, int h, int slice);
 void glDrawTex(GLfloat x, GLfloat y, GLfloat w, GLfloat h,
                GLfloat tx, GLfloat ty, GLfloat tw, GLfloat th,
--- a/libvo/vo_gl.c	Mon Oct 31 08:41:41 2005 +0000
+++ b/libvo/vo_gl.c	Mon Oct 31 13:56:16 2005 +0000
@@ -88,8 +88,8 @@
 static int eq_ggamma = 0;
 static int eq_bgamma = 0;
 
-static uint32_t texture_width;
-static uint32_t texture_height;
+static int texture_width;
+static int texture_height;
 
 static unsigned int slice_height = 1;
 
@@ -615,7 +615,7 @@
 }
 
 static uint32_t draw_image(mp_image_t *mpi) {
-  char *data = mpi->planes[0];
+  unsigned char *data = mpi->planes[0];
   int slice = slice_height;
   if (mpi->flags & MP_IMGFLAG_DRAW_CALLBACK)
     return VO_TRUE;