From: Ricardo Cruz Date: Tue, 8 Jun 2004 22:21:11 +0000 (+0000) Subject: Replaced uint32_t by Uint32. Has to be done, since *BSD do not ship with stdint.h. X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=b7f4101580f5fc0cbd015c290f589b422d82ed7e;p=supertux.git Replaced uint32_t by Uint32. Has to be done, since *BSD do not ship with stdint.h. Please, remove stdint.h checking from the automake. SVN-Revision: 1449 --- diff --git a/src/screen/drawing_context.cpp b/src/screen/drawing_context.cpp index 642029181..480b8bd79 100644 --- a/src/screen/drawing_context.cpp +++ b/src/screen/drawing_context.cpp @@ -35,7 +35,7 @@ DrawingContext::~DrawingContext() void DrawingContext::draw_surface(const Surface* surface, const Vector& position, - int layer, uint32_t drawing_effect) + int layer, Uint32 drawing_effect) { assert(surface != 0); @@ -52,7 +52,7 @@ DrawingContext::draw_surface(const Surface* surface, const Vector& position, void DrawingContext::draw_surface_part(const Surface* surface, const Vector& source, - const Vector& size, const Vector& dest, int layer, uint32_t drawing_effect) + const Vector& size, const Vector& dest, int layer, Uint32 drawing_effect) { assert(surface != 0); diff --git a/src/screen/drawing_context.h b/src/screen/drawing_context.h index b054e366d..c71fda180 100644 --- a/src/screen/drawing_context.h +++ b/src/screen/drawing_context.h @@ -19,7 +19,6 @@ #ifndef __DRAWINGCONTEXT_H__ #define __DRAWINGCONTEXT_H__ -#include #include #include #include "vector.h" @@ -72,11 +71,11 @@ public: /** Adds a drawing request for a surface into the request list */ void draw_surface(const Surface* surface, const Vector& position, int layer, - uint32_t drawing_effect = NONE_EFFECT); + Uint32 drawing_effect = NONE_EFFECT); /** Adds a drawing request for part of a surface */ void draw_surface_part(const Surface* surface, const Vector& source, const Vector& size, const Vector& dest, int layer, - uint32_t drawing_effect = NONE_EFFECT); + Uint32 drawing_effect = NONE_EFFECT); /** draws a text */ void draw_text(Font* font, const std::string& text, const Vector& position, int layer); @@ -149,7 +148,7 @@ private: struct DrawingRequest { int layer; - uint32_t drawing_effect; + Uint32 drawing_effect; RequestType type; Vector pos; diff --git a/src/screen/texture.cpp b/src/screen/texture.cpp index f7a50e940..c82b10d18 100644 --- a/src/screen/texture.cpp +++ b/src/screen/texture.cpp @@ -448,7 +448,7 @@ SurfaceOpenGL::create_gl(SDL_Surface * surf, GLuint * tex) } int -SurfaceOpenGL::draw(float x, float y, Uint8 alpha, uint32_t effect) +SurfaceOpenGL::draw(float x, float y, Uint8 alpha, Uint32 effect) { float pw = power_of_two(w); float ph = power_of_two(h); @@ -503,7 +503,7 @@ SurfaceOpenGL::draw(float x, float y, Uint8 alpha, uint32_t effect) } int -SurfaceOpenGL::draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, uint32_t effect) +SurfaceOpenGL::draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, Uint32 effect) { float pw = power_of_two(int(this->w)); float ph = power_of_two(int(this->h)); @@ -619,7 +619,7 @@ SurfaceSDL::SurfaceSDL(const std::string& file, int x, int y, int w, int h, int } int -SurfaceSDL::draw(float x, float y, Uint8 alpha, uint32_t effect) +SurfaceSDL::draw(float x, float y, Uint8 alpha, Uint32 effect) { SDL_Rect dest; @@ -671,7 +671,7 @@ SurfaceSDL::draw(float x, float y, Uint8 alpha, uint32_t effect) } int -SurfaceSDL::draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, uint32_t effect) +SurfaceSDL::draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, Uint32 effect) { SDL_Rect src, dest; diff --git a/src/screen/texture.h b/src/screen/texture.h index 84cdc13b9..e39b3ee8b 100644 --- a/src/screen/texture.h +++ b/src/screen/texture.h @@ -27,7 +27,6 @@ #include #endif -#include #include #include "screen.h" #include "vector.h" @@ -116,8 +115,8 @@ public: virtual ~SurfaceImpl(); /** Return 0 on success, -2 if surface needs to be reloaded */ - virtual int draw(float x, float y, Uint8 alpha, uint32_t effect = NONE_EFFECT) = 0; - virtual int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, uint32_t effect = NONE_EFFECT) = 0; + virtual int draw(float x, float y, Uint8 alpha, Uint32 effect = NONE_EFFECT) = 0; + virtual int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, Uint32 effect = NONE_EFFECT) = 0; #if 0 virtual int draw_stretched(float x, float y, int w, int h, Uint8 alpha, bool update) = 0; #endif @@ -134,8 +133,8 @@ public: SurfaceSDL(const std::string& file, int x, int y, int w, int h, int use_alpha); virtual ~SurfaceSDL(); - int draw(float x, float y, Uint8 alpha, uint32_t effect = NONE_EFFECT); - int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, uint32_t effect = NONE_EFFECT); + int draw(float x, float y, Uint8 alpha, Uint32 effect = NONE_EFFECT); + int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, Uint32 effect = NONE_EFFECT); #if 0 int draw_stretched(float x, float y, int w, int h, Uint8 alpha); #endif @@ -153,8 +152,8 @@ public: SurfaceOpenGL(const std::string& file, int x, int y, int w, int h, int use_alpha); virtual ~SurfaceOpenGL(); - int draw(float x, float y, Uint8 alpha, uint32_t effect = NONE_EFFECT); - int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, uint32_t effect = NONE_EFFECT); + int draw(float x, float y, Uint8 alpha, Uint32 effect = NONE_EFFECT); + int draw_part(float sx, float sy, float x, float y, float w, float h, Uint8 alpha, Uint32 effect = NONE_EFFECT); #if 0 int draw_stretched(float x, float y, int w, int h, Uint8 alpha); #endif diff --git a/src/sprite.cpp b/src/sprite.cpp index 68315f193..c6f2ea20a 100644 --- a/src/sprite.cpp +++ b/src/sprite.cpp @@ -75,7 +75,7 @@ Sprite::update(float /*delta*/) void Sprite::draw(DrawingContext& context, const Vector& pos, int layer, - uint32_t drawing_effect) + Uint32 drawing_effect) { time = SDL_GetTicks(); unsigned int frame = get_current_frame(); diff --git a/src/sprite.h b/src/sprite.h index 62dba8f19..80264421d 100644 --- a/src/sprite.h +++ b/src/sprite.h @@ -57,7 +57,7 @@ class Sprite /** Update the sprite and process to the next frame */ void update(float delta); void draw(DrawingContext& context, const Vector& pos, int layer, - uint32_t drawing_effect = NONE_EFFECT); + Uint32 drawing_effect = NONE_EFFECT); int get_current_frame() const; float get_fps() { return fps; } ; diff --git a/src/tile.h b/src/tile.h index d8a86eacb..390d52940 100644 --- a/src/tile.h +++ b/src/tile.h @@ -24,7 +24,6 @@ #include #include #include -#include #include "screen/texture.h" #include "globals.h" #include "lispreader.h" @@ -76,7 +75,7 @@ public: }; /** tile attributes */ - uint32_t attributes; + Uint32 attributes; /** General purpose data attached to a tile (content of a box, type of coin)*/ int data;