comparison engine/core/video/sdl/sdlimage.h @ 417:14e8087cde2c

Fixed the problem where the opengl renderer was leaving traces on the screen after closing maps in the editor. [t:392] Removed a member variable in SDLImage that was not being used.
author prock@33b003aa-7bff-0310-803a-e67f0ece8222
date Wed, 03 Feb 2010 20:04:39 +0000
parents 90005975cdbb
children ad7969d9460b
comparison
equal deleted inserted replaced
416:a8bb57884723 417:14e8087cde2c
48 void drawLine(const Point& p1, const Point& p2, int r, int g, int b); 48 void drawLine(const Point& p1, const Point& p2, int r, int g, int b);
49 void drawQuad(const Point& p1, const Point& p2, const Point& p3, const Point& p4, int r, int g, int b); 49 void drawQuad(const Point& p1, const Point& p2, const Point& p3, const Point& p4, int r, int g, int b);
50 50
51 protected: 51 protected:
52 void setClipArea(const Rect& cliparea, bool clear); 52 void setClipArea(const Rect& cliparea, bool clear);
53 53
54 private: 54 private:
55 // Call this before rendering 55 // Call this before rendering
56 void finalize(); 56 void finalize();
57 57
58 /** SDL Alpha Optimizer 58 /** SDL Alpha Optimizer
59 * This tries to convert an image with a fake alpha channel 59 * This tries to convert an image with a fake alpha channel
60 * to an RGB image when the channel can be reasonably be replaced 60 * to an RGB image when the channel can be reasonably be replaced
61 * by an colorkey. 61 * by an colorkey.
62 */ 62 */
63 SDL_Surface* optimize(SDL_Surface* surface); 63 SDL_Surface* optimize(SDL_Surface* surface);
64 64
65 void resetSdlimage(); 65 void resetSdlimage();
66 66
67 // SDLSurface used to create the SDLImage. 67 // SDLSurface used to create the SDLImage.
68 Uint8 m_last_alpha; 68 Uint8 m_last_alpha;
69 // Is the surface already optimized for rendering 69 // Is the surface already optimized for rendering
70 bool m_finalized; 70 bool m_finalized;
71 // Wether to try to optimize alpha out ...
72 bool m_optimize_alpha;
73 }; 71 };
74 72
75 } 73 }
76 74
77 #endif 75 #endif