1 // $Id: drawing_request.hpp 4986 2007-04-16 17:48:28Z matzeb $
4 // Copyright (C) 2006 Matthias Braun <matze@braunis.de>
6 // This program is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU General Public License
8 // as published by the Free Software Foundation; either version 2
9 // of the License, or (at your option) any later version.
11 // This program is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
16 // You should have received a copy of the GNU General Public License
17 // along with this program; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19 #ifndef SUPERTUX_DRAWINGREQUEST_H
20 #define SUPERTUX_DRAWINGREQUEST_H
31 #include "math/vector.hpp"
35 // some constants for predefined layer values
37 LAYER_BACKGROUND0 = -300,
38 LAYER_BACKGROUND1 = -200,
39 LAYER_BACKGROUNDTILES = -100,
42 LAYER_FLOATINGOBJECTS = 150,
43 LAYER_FOREGROUNDTILES = 200,
44 LAYER_FOREGROUND0 = 300,
45 LAYER_FOREGROUND1 = 400,
57 : sfactor(GL_SRC_ALPHA), dfactor(GL_ONE_MINUS_SRC_ALPHA)
60 Blend(GLenum s, GLenum d)
61 : sfactor(s), dfactor(d)
71 SURFACE, SURFACE_PART, TEXT, GRADIENT, FILLRECT, INVERSEELLIPSE, DRAW_LIGHTMAP, GETLIGHT
74 struct SurfacePartRequest
76 const Surface* surface;
84 FontAlignment alignment;
87 struct GradientRequest
93 struct FillRectRequest
100 struct InverseEllipseRequest
106 struct DrawingRequest
113 DrawingEffect drawing_effect;
123 color(1.0f, 1.0f, 1.0f, 1.0f)
126 bool operator<(const DrawingRequest& other) const
128 return layer < other.layer;
132 struct GetLightRequest