Remove draw_text from renderer.hpp and lightmap.hpp since text drawing is done in...
authorTim Goya <tuxdev103@gmail.com>
Sat, 25 Aug 2007 21:56:34 +0000 (21:56 +0000)
committerTim Goya <tuxdev103@gmail.com>
Sat, 25 Aug 2007 21:56:34 +0000 (21:56 +0000)
SVN-Revision: 5158

src/video/drawing_context.cpp
src/video/gl_lightmap.cpp
src/video/gl_renderer.cpp
src/video/lightmap.hpp
src/video/renderer.hpp
src/video/sdl_lightmap.cpp
src/video/sdl_renderer.cpp

index de45b4f..7ca3e26 100644 (file)
@@ -346,7 +346,11 @@ DrawingContext::handle_drawing_requests(DrawingRequests& requests)
             renderer->draw_gradient(request);
             break;
           case TEXT:
-            renderer->draw_text(request);
+            {
+              const TextRequest* textrequest = (TextRequest*) request.request_data;
+              textrequest->font->draw(renderer, textrequest->text, request.pos,
+                  textrequest->alignment, request.drawing_effect, request.alpha);
+            }
             break;
           case FILLRECT:
             renderer->draw_filled_rect(request);
@@ -368,7 +372,11 @@ DrawingContext::handle_drawing_requests(DrawingRequests& requests)
             lightmap->draw_gradient(request);
             break;
           case TEXT:
-            lightmap->draw_text(request);
+            {
+              const TextRequest* textrequest = (TextRequest*) request.request_data;
+              textrequest->font->draw(renderer, textrequest->text, request.pos,
+                  textrequest->alignment, request.drawing_effect, request.alpha);
+            }
             break;
           case FILLRECT:
             lightmap->draw_filled_rect(request);
index 537a6a9..014fb73 100644 (file)
@@ -266,15 +266,6 @@ namespace GL
   }
 
   void
-  Lightmap::draw_text(const DrawingRequest& /*request*/)
-  {
-    //const TextRequest* textrequest = (TextRequest*) request.request_data;
-
-    //textrequest->font->draw(textrequest->text, request.pos,
-    //    textrequest->alignment, request.drawing_effect, request.alpha);
-  }
-
-  void
   Lightmap::draw_filled_rect(const DrawingRequest& request)
   {
     const FillRectRequest* fillrectrequest
index 6fb6480..3eee8f1 100644 (file)
@@ -236,15 +236,6 @@ namespace GL
   }
 
   void
-  Renderer::draw_text(const DrawingRequest& request)
-  {
-    const TextRequest* textrequest = (TextRequest*) request.request_data;
-
-    textrequest->font->draw(this, textrequest->text, request.pos,
-        textrequest->alignment, request.drawing_effect, request.alpha);
-  }
-
-  void
   Renderer::draw_filled_rect(const DrawingRequest& request)
   {
     const FillRectRequest* fillrectrequest
index bca28d4..049b21e 100644 (file)
@@ -49,7 +49,6 @@ public:
   virtual void do_draw() = 0;
   virtual void draw_surface(const DrawingRequest& request) = 0;
   virtual void draw_surface_part(const DrawingRequest& request) = 0;
-  virtual void draw_text(const DrawingRequest& request) = 0;
   virtual void draw_gradient(const DrawingRequest& request) = 0;
   virtual void draw_filled_rect(const DrawingRequest& request) = 0;
   virtual void get_light(const DrawingRequest& request) const = 0;
index c1f10bf..2bd96d7 100644 (file)
@@ -46,7 +46,6 @@ public:
 
   virtual void draw_surface(const DrawingRequest& request) = 0;
   virtual void draw_surface_part(const DrawingRequest& request) = 0;
-  virtual void draw_text(const DrawingRequest& request) = 0;
   virtual void draw_gradient(const DrawingRequest& request) = 0;
   virtual void draw_filled_rect(const DrawingRequest& request)= 0;
   virtual void do_take_screenshot() = 0;
index d8bdcde..8e7c70f 100644 (file)
@@ -562,15 +562,6 @@ namespace SDL
   }
 
   void
-  Lightmap::draw_text(const DrawingRequest& /*request*/)
-  {
-    //const TextRequest* textrequest = (TextRequest*) request.request_data;
-
-    //textrequest->font->draw(textrequest->text, request.pos,
-    //    textrequest->alignment, request.drawing_effect, request.alpha);
-  }
-
-  void
   Lightmap::draw_filled_rect(const DrawingRequest& request)
   {
     const FillRectRequest* fillrectrequest
index fecf7ea..dede6c8 100644 (file)
@@ -369,15 +369,6 @@ namespace SDL
   }
 
   void
-  Renderer::draw_text(const DrawingRequest& request)
-  {
-    const TextRequest* textrequest = (TextRequest*) request.request_data;
-
-    textrequest->font->draw(this, textrequest->text, request.pos,
-        textrequest->alignment, request.drawing_effect, request.alpha);
-  }
-
-  void
   Renderer::draw_filled_rect(const DrawingRequest& request)
   {
     const FillRectRequest* fillrectrequest