[Scummvm-cvs-logs] SF.net SVN: scummvm:[34670] residual/trunk

aquadran at users.sourceforge.net aquadran at users.sourceforge.net
Sun Sep 28 21:09:27 CEST 2008


Revision: 34670
          http://scummvm.svn.sourceforge.net/scummvm/?rev=34670&view=rev
Author:   aquadran
Date:     2008-09-28 19:09:23 +0000 (Sun, 28 Sep 2008)

Log Message:
-----------
replace tinygl tgl_fatal_error with error()

Modified Paths:
--------------
    residual/trunk/dists/msvc7/residual.vcproj
    residual/trunk/dists/msvc71/residual.vcproj
    residual/trunk/dists/msvc8/residual.vcproj
    residual/trunk/dists/msvc9/residual.vcproj
    residual/trunk/dists/xcode/residual.xcodeproj/project.pbxproj
    residual/trunk/engine/tinygl/get.cpp
    residual/trunk/engine/tinygl/list.cpp
    residual/trunk/engine/tinygl/misc.cpp
    residual/trunk/engine/tinygl/module.mk
    residual/trunk/engine/tinygl/specbuf.cpp
    residual/trunk/engine/tinygl/texture.cpp
    residual/trunk/engine/tinygl/vertex.cpp
    residual/trunk/engine/tinygl/zgl.h

Removed Paths:
-------------
    residual/trunk/engine/tinygl/error.cpp

Modified: residual/trunk/dists/msvc7/residual.vcproj
===================================================================
--- residual/trunk/dists/msvc7/residual.vcproj	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/dists/msvc7/residual.vcproj	2008-09-28 19:09:23 UTC (rev 34670)
@@ -558,9 +558,6 @@
 					RelativePath="..\..\engine\tinygl\clip.cpp">
 				</File>
 				<File
-					RelativePath="..\..\engine\tinygl\error.cpp">
-				</File>
-				<File
 					RelativePath="..\..\engine\tinygl\get.cpp">
 				</File>
 				<File

Modified: residual/trunk/dists/msvc71/residual.vcproj
===================================================================
--- residual/trunk/dists/msvc71/residual.vcproj	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/dists/msvc71/residual.vcproj	2008-09-28 19:09:23 UTC (rev 34670)
@@ -572,9 +572,6 @@
 					RelativePath="..\..\engine\tinygl\clip.cpp">
 				</File>
 				<File
-					RelativePath="..\..\engine\tinygl\error.cpp">
-				</File>
-				<File
 					RelativePath="..\..\engine\tinygl\get.cpp">
 				</File>
 				<File

Modified: residual/trunk/dists/msvc8/residual.vcproj
===================================================================
--- residual/trunk/dists/msvc8/residual.vcproj	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/dists/msvc8/residual.vcproj	2008-09-28 19:09:23 UTC (rev 34670)
@@ -783,10 +783,6 @@
 					>
 				</File>
 				<File
-					RelativePath="..\..\engine\tinygl\error.cpp"
-					>
-				</File>
-				<File
 					RelativePath="..\..\engine\tinygl\get.cpp"
 					>
 				</File>

Modified: residual/trunk/dists/msvc9/residual.vcproj
===================================================================
--- residual/trunk/dists/msvc9/residual.vcproj	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/dists/msvc9/residual.vcproj	2008-09-28 19:09:23 UTC (rev 34670)
@@ -788,10 +788,6 @@
 					>
 				</File>
 				<File
-					RelativePath="..\..\engine\tinygl\error.cpp"
-					>
-				</File>
-				<File
 					RelativePath="..\..\engine\tinygl\get.cpp"
 					>
 				</File>

Modified: residual/trunk/dists/xcode/residual.xcodeproj/project.pbxproj
===================================================================
--- residual/trunk/dists/xcode/residual.xcodeproj/project.pbxproj	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/dists/xcode/residual.xcodeproj/project.pbxproj	2008-09-28 19:09:23 UTC (rev 34670)
@@ -84,7 +84,6 @@
 		289EEF1A0D8921F600521A80 /* arrays.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEB40D8921F600521A80 /* arrays.cpp */; };
 		289EEF1B0D8921F600521A80 /* clear.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEB50D8921F600521A80 /* clear.cpp */; };
 		289EEF1C0D8921F600521A80 /* clip.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEB60D8921F600521A80 /* clip.cpp */; };
-		289EEF1D0D8921F600521A80 /* error.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEB70D8921F600521A80 /* error.cpp */; };
 		289EEF1E0D8921F600521A80 /* get.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEB80D8921F600521A80 /* get.cpp */; };
 		289EEF1F0D8921F600521A80 /* image_util.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEBA0D8921F600521A80 /* image_util.cpp */; };
 		289EEF200D8921F600521A80 /* init.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 289EEEBB0D8921F600521A80 /* init.cpp */; };
@@ -291,7 +290,6 @@
 		289EEEB40D8921F600521A80 /* arrays.cpp */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.cpp.cpp; path = arrays.cpp; sourceTree = "<group>"; };
 		289EEEB50D8921F600521A80 /* clear.cpp */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.cpp.cpp; path = clear.cpp; sourceTree = "<group>"; };
 		289EEEB60D8921F600521A80 /* clip.cpp */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.cpp.cpp; path = clip.cpp; sourceTree = "<group>"; };
-		289EEEB70D8921F600521A80 /* error.cpp */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.cpp.cpp; path = error.cpp; sourceTree = "<group>"; };
 		289EEEB80D8921F600521A80 /* get.cpp */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.cpp.cpp; path = get.cpp; sourceTree = "<group>"; };
 		289EEEB90D8921F600521A80 /* gl.h */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.c.h; path = gl.h; sourceTree = "<group>"; };
 		289EEEBA0D8921F600521A80 /* image_util.cpp */ = {isa = PBXFileReference; fileEncoding = 5; lastKnownFileType = sourcecode.cpp.cpp; path = image_util.cpp; sourceTree = "<group>"; };
@@ -667,7 +665,6 @@
 				289EEEB40D8921F600521A80 /* arrays.cpp */,
 				289EEEB50D8921F600521A80 /* clear.cpp */,
 				289EEEB60D8921F600521A80 /* clip.cpp */,
-				289EEEB70D8921F600521A80 /* error.cpp */,
 				289EEEB80D8921F600521A80 /* get.cpp */,
 				289EEEB90D8921F600521A80 /* gl.h */,
 				289EEEBA0D8921F600521A80 /* image_util.cpp */,
@@ -861,7 +858,6 @@
 				289EEF1A0D8921F600521A80 /* arrays.cpp in Sources */,
 				289EEF1B0D8921F600521A80 /* clear.cpp in Sources */,
 				289EEF1C0D8921F600521A80 /* clip.cpp in Sources */,
-				289EEF1D0D8921F600521A80 /* error.cpp in Sources */,
 				289EEF1E0D8921F600521A80 /* get.cpp in Sources */,
 				289EEF1F0D8921F600521A80 /* image_util.cpp in Sources */,
 				289EEF200D8921F600521A80 /* init.cpp in Sources */,

Deleted: residual/trunk/engine/tinygl/error.cpp
===================================================================
--- residual/trunk/engine/tinygl/error.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/error.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -1,17 +0,0 @@
-
-#include <stdarg.h>
-
-#include "engine/tinygl/zgl.h"
-
-void gl_fatal_error(const char *format, ...) {
-	va_list ap;
-
-	va_start(ap, format);
-
-	fprintf(stderr, "TinyGL: fatal error: ");
-	vfprintf(stderr, format,ap);
-	fprintf(stderr, "\n");
-	exit(1);
-
-	va_end(ap);
-}

Modified: residual/trunk/engine/tinygl/get.cpp
===================================================================
--- residual/trunk/engine/tinygl/get.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/get.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -27,7 +27,7 @@
 		*params = MAX_TEXTURE_STACK_DEPTH;
 		break;
 	default:
-		gl_fatal_error("glGet: option not implemented");
+		error("glGet: option not implemented");
 		break;
 	}
 }

Modified: residual/trunk/engine/tinygl/list.cpp
===================================================================
--- residual/trunk/engine/tinygl/list.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/list.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -155,7 +155,7 @@
 	list = p[1].ui;
 	l = find_list(c, list);
 	if (!l)
-		gl_fatal_error("list %d not defined", list);
+		error("list %d not defined", list);
 	p = l->first_op_buffer->ops;
 
 	while (1) {

Modified: residual/trunk/engine/tinygl/misc.cpp
===================================================================
--- residual/trunk/engine/tinygl/misc.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/misc.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -18,13 +18,13 @@
 		ysize_req = ymin + ysize;
 
 		if (c->gl_resize_viewport && c->gl_resize_viewport(c, &xsize_req, &ysize_req) != 0) {
-			gl_fatal_error("glViewport: error while resizing display");
+			error("glViewport: error while resizing display");
 		}
 
 		xsize = xsize_req - xmin;
 		ysize = ysize_req - ymin;
 		if (xsize <= 0 || ysize <= 0) {
-			gl_fatal_error("glViewport: size too small");
+			error("glViewport: size too small");
 		}
 
 		c->viewport.xmin = xmin;

Modified: residual/trunk/engine/tinygl/module.mk
===================================================================
--- residual/trunk/engine/tinygl/module.mk	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/module.mk	2008-09-28 19:09:23 UTC (rev 34670)
@@ -5,7 +5,6 @@
 	arrays.o \
 	clear.o \
 	clip.o \
-	error.o \
 	get.o \
 	image_util.o \
 	init.o \

Modified: residual/trunk/engine/tinygl/specbuf.cpp
===================================================================
--- residual/trunk/engine/tinygl/specbuf.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/specbuf.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -29,7 +29,7 @@
 		// create new buffer
 		GLSpecBuf *buf = (GLSpecBuf *)gl_malloc(sizeof(GLSpecBuf));
 		if (!buf)
-			gl_fatal_error("could not allocate specular buffer");
+			error("could not allocate specular buffer");
 		c->specbuf_num_buffers++;
 		buf->next = c->specbuf_first;
 		c->specbuf_first = buf;

Modified: residual/trunk/engine/tinygl/texture.cpp
===================================================================
--- residual/trunk/engine/tinygl/texture.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/texture.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -128,7 +128,7 @@
 
 	if (!(target == TGL_TEXTURE_2D && level == 0 && components == 3 && border == 0
 				&& format == TGL_RGBA && type == TGL_UNSIGNED_BYTE)) {
-		gl_fatal_error("glTexImage2D: combination of parameters not handled");
+		error("glTexImage2D: combination of parameters not handled");
 	}
 
 	do_free = 0;
@@ -165,7 +165,7 @@
 
 	if (target != TGL_TEXTURE_ENV) {
 error:
-		gl_fatal_error("glTexParameter: unsupported option");
+		error("glTexParameter: unsupported option");
 	}
 
 	if (pname != TGL_TEXTURE_ENV_MODE)
@@ -183,7 +183,7 @@
 
 	if (target != TGL_TEXTURE_2D) {
 error:
-		gl_fatal_error("glTexParameter: unsupported option");
+		error("glTexParameter: unsupported option");
 	}
 
 	switch (pname) {
@@ -202,6 +202,6 @@
 	int param = p[2].i;
 
 	if (pname != TGL_UNPACK_ALIGNMENT || param != 1) {
-		gl_fatal_error("glPixelStore: unsupported option");
+		error("glPixelStore: unsupported option");
 	}
 }

Modified: residual/trunk/engine/tinygl/vertex.cpp
===================================================================
--- residual/trunk/engine/tinygl/vertex.cpp	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/vertex.cpp	2008-09-28 19:09:23 UTC (rev 34670)
@@ -205,7 +205,7 @@
 		c->vertex_max <<= 1;	// just double size
 		newarray = (GLVertex *)gl_malloc(sizeof(GLVertex) * c->vertex_max);
 		if (!newarray) {
-			gl_fatal_error("unable to allocate GLVertex array.");
+			error("unable to allocate GLVertex array.");
 		}
 		memcpy(newarray, c->vertex, n * sizeof(GLVertex));
 		gl_free(c->vertex);
@@ -319,7 +319,7 @@
 	case TGL_POLYGON:
 		break;
     default:
-		gl_fatal_error("glBegin: type %x not handled", c->begin_type);
+		error("glBegin: type %x not handled", c->begin_type);
 	}
 
 	c->vertex_n = n;

Modified: residual/trunk/engine/tinygl/zgl.h
===================================================================
--- residual/trunk/engine/tinygl/zgl.h	2008-09-28 18:12:01 UTC (rev 34669)
+++ residual/trunk/engine/tinygl/zgl.h	2008-09-28 19:09:23 UTC (rev 34670)
@@ -306,8 +306,6 @@
 
 GLContext *gl_get_context();
 
-void gl_fatal_error(const char *format, ...);
-
 // specular buffer "api"
 GLSpecBuf *specbuf_get_buffer(GLContext *c, const int shininess_i, const float shininess);
 


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list