[Scummvm-cvs-logs] CVS: residual/tinygl clip.cpp,1.3,1.4 light.cpp,1.3,1.4 list.cpp,1.3,1.4 matrix.cpp,1.3,1.4 misc.cpp,1.3,1.4 msghandling.cpp,1.1,1.2 select.cpp,1.3,1.4 texture.cpp,1.3,1.4 zmath.h,1.1,1.2

Pawel Kolodziejski aquadran at users.sourceforge.net
Wed Jan 12 15:01:05 CET 2005


Update of /cvsroot/scummvm/residual/tinygl
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24072/residual/tinygl

Modified Files:
	clip.cpp light.cpp list.cpp matrix.cpp misc.cpp 
	msghandling.cpp select.cpp texture.cpp zmath.h 
Log Message:
fixed some tinygl warnings

Index: clip.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/clip.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- clip.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ clip.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -50,7 +50,7 @@
 
 static void gl_add_select1(GLContext *c,int z1,int z2,int z3)
 {
-  unsigned int min,max;
+  int min,max;
   min=max=z1;
   if (z2<min) min=z2;
   if (z3<min) min=z3;

Index: light.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/light.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- light.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ light.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -36,7 +36,7 @@
     break;
   case TGL_SHININESS:
     m->shininess=v[0];
-    m->shininess_i = (v[0]/128.0f)*SPECULAR_BUFFER_RESOLUTION;
+    m->shininess_i = (int)(v[0]/128.0f)*SPECULAR_BUFFER_RESOLUTION;
     break;
   case TGL_AMBIENT_AND_DIFFUSE:
     for(i=0;i<4;i++)

Index: list.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/list.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- list.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ list.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -150,13 +150,13 @@
 }
 
 /* this opcode is never called directly */
-void glopEndList(GLContext *c,TGLParam *p)
+void glopEndList(GLContext *,TGLParam *)
 {
   assert(0);
 }
 
 /* this opcode is never called directly */
-void glopNextBuffer(GLContext *c,TGLParam *p)
+void glopNextBuffer(GLContext *,TGLParam *)
 {
   assert(0);
 }

Index: matrix.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/matrix.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- matrix.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ matrix.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -54,7 +54,7 @@
   gl_matrix_update(c);
 }
 
-void glopLoadIdentity(GLContext *c,TGLParam *p)
+void glopLoadIdentity(GLContext *c,TGLParam *)
 {
 
   gl_M4_Id(c->matrix_stack_ptr[c->matrix_mode]);
@@ -84,7 +84,7 @@
 }
 
 
-void glopPushMatrix(GLContext *c,TGLParam *p)
+void glopPushMatrix(GLContext *c,TGLParam *)
 {
   int n=c->matrix_mode;
   M4 *m;
@@ -99,7 +99,7 @@
   gl_matrix_update(c);
 }
 
-void glopPopMatrix(GLContext *c,TGLParam *p)
+void glopPopMatrix(GLContext *c,TGLParam *)
 {
   int n=c->matrix_mode;
 

Index: misc.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/misc.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- misc.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ misc.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -129,14 +129,9 @@
   }
 }
 
-void glopHint(GLContext *c,TGLParam *p)
+void glopHint(GLContext *,TGLParam *)
 {
-#if 0
-  int target=p[1].i;
-  int mode=p[2].i;
-
   /* do nothing */
-#endif
 }
 
 void 

Index: msghandling.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/msghandling.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- msghandling.cpp	12 Jan 2005 15:20:02 -0000	1.1
+++ msghandling.cpp	12 Jan 2005 22:59:59 -0000	1.2
@@ -11,42 +11,45 @@
    happens (which might be an indication of an error). *Don't* use it
    when there's internal errors in the code - these should be handled
    by asserts. */
-void
-tgl_warning(const char *format, ...)
-{
 #ifndef NO_DEBUG_OUTPUT
+void tgl_warning(const char *, ...) { }
+#else
+void tgl_warning(const char *format, ...)
+{
   va_list args;
   va_start(args, format);
   fprintf(stderr, "*WARNING* ");
   vfprintf(stderr, format, args);
   va_end(args);
-#endif /* !NO_DEBUG_OUTPUT */
 }
+#endif /* !NO_DEBUG_OUTPUT */
 
 /* This function should be used for debug output only. */
-void
-tgl_trace(const char *format, ...)
-{
 #ifndef NO_DEBUG_OUTPUT
+void tgl_trace(const char *, ...) { }
+#else
+void tgl_trace(const char *format, ...)
+{
   va_list args;
   va_start(args, format);
   fprintf(stderr, "*DEBUG* ");
   vfprintf(stderr, format, args);
   va_end(args);
-#endif /* !NO_DEBUG_OUTPUT */
 }
+#endif /* !NO_DEBUG_OUTPUT */
 
 /* Use this function to output info about things in the code which
    should be fixed (missing handling of special cases, important
    features not implemented, known bugs/buglets, ...). */
-void
-tgl_fixme(const char *format, ...)
-{
 #ifndef NO_DEBUG_OUTPUT
+void tgl_fixme(const char *, ...) { }
+#else
+void tgl_fixme(const char *format, ...)
+{
   va_list args;
   va_start(args, format);
   fprintf(stderr, "*FIXME* ");
   vfprintf(stderr, format, args);
   va_end(args);
-#endif /* !NO_DEBUG_OUTPUT */
 }
+#endif /* !NO_DEBUG_OUTPUT */

Index: select.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/select.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- select.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ select.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -50,7 +50,7 @@
 }
 
 
-void glopInitNames(GLContext *c,TGLParam *p)
+void glopInitNames(GLContext *c,TGLParam *)
 {
   if (c->render_mode == TGL_SELECT) {
     c->name_stack_size=0;
@@ -67,7 +67,7 @@
   }
 }
 
-void glopPopName(GLContext *c,TGLParam *p)
+void glopPopName(GLContext *c,TGLParam *)
 {
   if (c->render_mode == TGL_SELECT) {
     assert(c->name_stack_size>0);

Index: texture.cpp
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/texture.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- texture.cpp	12 Jan 2005 18:00:19 -0000	1.3
+++ texture.cpp	12 Jan 2005 22:59:59 -0000	1.4
@@ -181,7 +181,7 @@
 
 
 /* TODO: not all tests are done */
-void glopTexEnv(GLContext *c,TGLParam *p)
+void glopTexEnv(GLContext *,TGLParam *p)
 {
   int target=p[1].i;
   int pname=p[2].i;
@@ -198,7 +198,7 @@
 }
 
 /* TODO: not all tests are done */
-void glopTexParameter(GLContext *c,TGLParam *p)
+void glopTexParameter(GLContext *,TGLParam *p)
 {
   int target=p[1].i;
   int pname=p[2].i;
@@ -217,7 +217,7 @@
   }
 }
 
-void glopPixelStore(GLContext *c,TGLParam *p)
+void glopPixelStore(GLContext *,TGLParam *p)
 {
   int pname=p[1].i;
   int param=p[2].i;

Index: zmath.h
===================================================================
RCS file: /cvsroot/scummvm/residual/tinygl/zmath.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- zmath.h	12 Jan 2005 15:20:02 -0000	1.1
+++ zmath.h	12 Jan 2005 22:59:59 -0000	1.2
@@ -50,4 +50,4 @@
 
 int gl_Matrix_Inv(float *r,float *m,int n);
 
-#endif  __ZMATH__
+#endif





More information about the Scummvm-git-logs mailing list