00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #if !defined(_XRB_RENDER_HPP_)
00012 #define _XRB_RENDER_HPP_
00013
00014 #include "xrb.hpp"
00015
00016 #include "xrb_color.hpp"
00017 #include "xrb_gl.hpp"
00018 #include "xrb_matrix2.hpp"
00019 #include "xrb_rect.hpp"
00020 #include "xrb_rendercontext.hpp"
00021 #include "xrb_vector.hpp"
00022 #include "xrb_simpletransform2.hpp"
00023
00024 namespace Xrb
00025 {
00026
00027 class Screen;
00028 class GLTexture;
00029
00058 namespace Render
00059 {
00060
00061
00062
00063
00071 void DrawLine (
00072 RenderContext const &render_context,
00073 FloatVector2 const &from,
00074 FloatVector2 const &to,
00075 Color const &color);
00087 void DrawArrow (
00088 RenderContext const &render_context,
00089 FloatVector2 const &from,
00090 FloatVector2 const &to,
00091 Color const &color);
00108 void DrawPolygon (
00109 RenderContext const &render_context,
00110 FloatVector2 const ¢er,
00111 Float radius,
00112 Float angle,
00113 Color const &color,
00114 Uint32 vertex_count);
00132 void DrawCircle (
00133 RenderContext const &render_context,
00134 FloatMatrix2 const &transformation,
00135 FloatVector2 const ¢er,
00136 Float radius,
00137 Color const &color);
00166 void DrawCircularArc (
00167 RenderContext const &render_context,
00168 FloatMatrix2 const &transformation,
00169 FloatVector2 const ¢er,
00170 Float radius,
00171 Float start_angle,
00172 Float end_angle,
00173 Color const &color);
00174
00175
00176
00177
00178
00185 void DrawScreenRect (
00186 RenderContext const &render_context,
00187 Color const &color,
00188 ScreenCoordRect const &screen_rect);
00198 void DrawScreenRectTexture (
00199 RenderContext const &render_context,
00200 GLTexture const *gl_texture,
00201 ScreenCoordRect const &screen_rect,
00202 FloatSimpleTransform2 const &transformation =
00203 FloatSimpleTransform2::ms_identity);
00204
00205
00206
00207
00208
00220 void SetupTextureUnits (
00221 GLuint gltexture_handle,
00222 Color const &color_mask,
00223 Color const &color_bias);
00224 }
00225
00226 }
00227
00228 #endif // !defined(_XRB_RENDER_HPP_)