#
# patch -p1 < contrib/supertux-nogl.diff
#
-# This patch works for revision 3294. It may break for later revisions.
+# This patch works for revision 3321. It may break for later revisions.
#
# -----------------------------------------------------------------------------
diff -Naur supertux/INSTALL supertux-nogl/INSTALL
AC_CONFIG_SRCDIR([src/main.cpp])
AC_CONFIG_AUX_DIR([mk/autoconf])
AC_CANONICAL_TARGET
-@@ -105,6 +105,14 @@
+@@ -112,6 +105,14 @@
[AC_MSG_ERROR([Please install SDLImage >= 1.2.1])],
[$SDL_CFLAGS], [$SDL_LIBS])
NP_FINDLIB([PHYSFS], [physfs], [physfs >= 1.0.0],
NP_LANG_PROGRAM([
#include <stdio.h>
-@@ -124,11 +132,6 @@
+@@ -131,11 +132,6 @@
[AC_MSG_ERROR([Please intall OpenAL])],
[], [])
#include <physfs.h>
#include <SDL.h>
#include <SDL_image.h>
--#include <SDL_opengl.h>
+-#include <GL/gl.h>
#include "gameconfig.hpp"
#include "resources.hpp"
-@@ -266,44 +265,6 @@
+@@ -269,44 +265,6 @@
;
}
void init_video()
{
if(texture_manager != NULL)
-@@ -314,7 +275,7 @@
+@@ -317,7 +275,7 @@
SDL_GL_SetAttribute(SDL_GL_GREEN_SIZE, 5);
SDL_GL_SetAttribute(SDL_GL_BLUE_SIZE, 5);
if(config->use_fullscreen)
flags |= SDL_FULLSCREEN;
int width = config->screenwidth;
-@@ -344,24 +305,6 @@
+@@ -347,24 +305,6 @@
}
#endif
diff -Naur supertux/src/video/drawing_context.cpp supertux-nogl/src/video/drawing_context.cpp
--- supertux/src/video/drawing_context.cpp 2006-03-31 04:18:01.000000000 +0200
+++ supertux-nogl/src/video/drawing_context.cpp 2006-04-07 04:11:49.000000000 +0200
-@@ -22,8 +22,6 @@
+@@ -22,7 +22,6 @@
#include <cassert>
#include <iostream>
#include <SDL_image.h>
-#include <GL/gl.h>
--#include <GL/glu.h>
#include "drawing_context.hpp"
#include "surface.hpp"
-@@ -49,30 +47,20 @@
+@@ -48,30 +47,20 @@
{
screen = SDL_GetVideoSurface();
assert(surface != 0);
DrawingRequest request;
-@@ -97,6 +85,8 @@
+@@ -96,6 +85,8 @@
DrawingContext::draw_surface_part(const Surface* surface, const Vector& source,
const Vector& size, const Vector& dest, int layer)
{
assert(surface != 0);
DrawingRequest request;
-@@ -136,6 +126,8 @@
+@@ -135,6 +126,8 @@
DrawingContext::draw_text(const Font* font, const std::string& text,
const Vector& position, FontAlignment alignment, int layer)
{
DrawingRequest request;
request.type = TEXT;
-@@ -157,6 +149,8 @@
+@@ -156,6 +149,8 @@
DrawingContext::draw_center_text(const Font* font, const std::string& text,
const Vector& position, int layer)
{
draw_text(font, text, Vector(position.x + SCREEN_WIDTH/2, position.y),
CENTER_ALLIGN, layer);
}
-@@ -164,6 +158,8 @@
+@@ -163,6 +158,8 @@
void
DrawingContext::draw_gradient(const Color& top, const Color& bottom, int layer)
{
DrawingRequest request;
request.type = GRADIENT;
-@@ -185,6 +181,8 @@
+@@ -184,6 +181,8 @@
DrawingContext::draw_filled_rect(const Vector& topleft, const Vector& size,
const Color& color, int layer)
{
DrawingRequest request;
request.type = FILLRECT;
-@@ -218,23 +216,55 @@
+@@ -217,23 +216,55 @@
delete surfacepartrequest;
}
delete gradientrequest;
}
-@@ -260,17 +290,12 @@
+@@ -259,17 +290,12 @@
float w = fillrectrequest->size.x;
float h = fillrectrequest->size.y;
delete fillrectrequest;
}
-@@ -285,66 +310,10 @@
+@@ -284,66 +310,10 @@
transformstack.clear();
target_stack.clear();
}
void
-@@ -433,9 +402,5 @@
+@@ -432,9 +402,5 @@
DrawingContext::set_target(Target target)
{
this->target = target;