Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

GraphicContext Class Reference

#include <graphic_context.hxx>

Inheritance diagram for GraphicContext:

Inheritance graph
[legend]
List of all members.

Public Member Functions

void draw_circle (const Vector2d &pos, float radius, Color color)
void draw_fill_circle (const Vector2d &pos, float radius, Color color)
void draw_string (const Vector2d &pos, const std::string &str, Color color=Color(0xFFFFFFFF))
void draw_line (const Vector2d &pos1, const Vector2d &pos2, Color color, int wide=0)
void draw_rect (const Vector2d &pos1, const Vector2d &pos2, Color color)
void draw_fill_rect (const Vector2d &pos1, const Vector2d &pos2, Color color)
virtual void draw_lines (std::vector< Line > &lines, Color color, int wide=0)=0
virtual void draw_line (float x1, float y1, float x2, float y2, Color color, int wide=0)=0
virtual void draw_rect (float x1, float y1, float x2, float y2, Color color)=0
virtual void draw_circle (float x, float y, float radius, Color color)=0
virtual void draw_circles (std::vector< Circle > &circles, Color color)=0
virtual void draw_fill_circle (float x, float y, float radius, Color color)=0
virtual void draw_fill_rect (float x1, float y1, float x2, float y2, Color color)=0
virtual void draw_string (float x, float y, const std::string &str, Color color=Color(0xFFFFFFFF))=0
virtual void draw_string_centered (float x, float y, const std::string &str, Color color=Color(0xFFFFFFFF))=0
virtual void set_clip_rect (int x1_, int y1_, int x2_, int y2_)=0
virtual int get_width ()=0
virtual int get_height ()=0
virtual void clear ()=0
virtual void flip ()=0
virtual void real_flip ()
virtual void flip (int x1, int y1, int x2, int y2)=0

Detailed Description

Graphic abstraction interface

Definition at line 30 of file graphic_context.hxx.


Member Function Documentation

virtual void GraphicContext::clear   [pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by ZoomGraphicContext::clear(), and GUIManager::run_once().

virtual void GraphicContext::draw_circle float    x,
float    y,
float    radius,
Color    color
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

void GraphicContext::draw_circle const Vector2d   pos,
float    radius,
Color    color
[inline]
 

Definition at line 45 of file graphic_context.hxx.

References Vector2d::x, and Vector2d::y.

Referenced by ZoomGraphicContext::draw_circle(), and WorldViewSelectTool::draw_foreground().

virtual void GraphicContext::draw_circles std::vector< Circle > &    circles,
Color    color
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by ZoomGraphicContext::draw_circles().

virtual void GraphicContext::draw_fill_circle float    x,
float    y,
float    radius,
Color    color
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

void GraphicContext::draw_fill_circle const Vector2d   pos,
float    radius,
Color    color
[inline]
 

Definition at line 50 of file graphic_context.hxx.

References Vector2d::x, and Vector2d::y.

Referenced by Particle::draw(), ZoomGraphicContext::draw_fill_circle(), and Particle::draw_highlight().

virtual void GraphicContext::draw_fill_rect float    x1,
float    y1,
float    x2,
float    y2,
Color    color
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

void GraphicContext::draw_fill_rect const Vector2d   pos1,
const Vector2d   pos2,
Color    color
[inline]
 

Definition at line 74 of file graphic_context.hxx.

References Vector2d::x, and Vector2d::y.

Referenced by WorldButton::draw(), RectCollider::draw(), GUINewFileButton::draw(), GUIDirectoryButton::draw(), GUIChildManager::draw(), GUIButton::draw(), GUIGenericButton::draw_content(), GUISlowMoButton::draw_content(), GUIRunButton::draw_content(), and ZoomGraphicContext::draw_fill_rect().

virtual void GraphicContext::draw_line float    x1,
float    y1,
float    x2,
float    y2,
Color    color,
int    wide = 0
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

void GraphicContext::draw_line const Vector2d   pos1,
const Vector2d   pos2,
Color    color,
int    wide = 0
[inline]
 

Definition at line 60 of file graphic_context.hxx.

References Vector2d::x, and Vector2d::y.

Referenced by ZoomGraphicContext::draw_line().

virtual void GraphicContext::draw_lines std::vector< Line > &    lines,
Color    color,
int    wide = 0
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by ZoomGraphicContext::draw_lines().

virtual void GraphicContext::draw_rect float    x1,
float    y1,
float    x2,
float    y2,
Color    color
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

void GraphicContext::draw_rect const Vector2d   pos1,
const Vector2d   pos2,
Color    color
[inline]
 

Definition at line 65 of file graphic_context.hxx.

References Vector2d::x, and Vector2d::y.

Referenced by WorldButton::draw(), RectCollider::draw(), GUINewFileButton::draw(), GUIDirectoryButton::draw(), GUIChildManager::draw(), GUIButton::draw_border_hover(), GUIButton::draw_border_normal(), GUIButton::draw_border_pressed(), RectCollider::draw_highlight(), and ZoomGraphicContext::draw_rect().

virtual void GraphicContext::draw_string float    x,
float    y,
const std::string &    str,
Color    color = Color(0xFFFFFFFF)
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

void GraphicContext::draw_string const Vector2d   pos,
const std::string &    str,
Color    color = Color (0xFFFFFFFF)
[inline]
 

Definition at line 55 of file graphic_context.hxx.

References Vector2d::x, and Vector2d::y.

Referenced by WorldViewComponent::draw(), WorldButton::draw(), GUINewFileButton::draw(), GUILabel::draw(), GUIDirectoryButton::draw(), Particle::draw_infos(), WorldGUIManager::draw_overlay(), SaveGUIManager::draw_overlay(), LoadGUIManager::draw_overlay(), GUIFileManager::draw_overlay(), and ZoomGraphicContext::draw_string().

virtual void GraphicContext::draw_string_centered float    x,
float    y,
const std::string &    str,
Color    color = Color(0xFFFFFFFF)
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by GUIButton::draw_content(), and ZoomGraphicContext::draw_string_centered().

virtual void GraphicContext::flip int    x1,
int    y1,
int    x2,
int    y2
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

virtual void GraphicContext::flip   [pure virtual]
 

FIXME: flip should be handled outsite of GraphicContext

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by ZoomGraphicContext::flip(), and GUIManager::run_once().

virtual int GraphicContext::get_height   [pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by WorldViewComponent::draw(), WorldGUIManager::draw_overlay(), SaveGUIManager::draw_overlay(), LoadGUIManager::draw_overlay(), ZoomGraphicContext::unlock(), zoom_in_callback(), zoom_out_callback(), and ZoomGraphicContext::ZoomGraphicContext().

virtual int GraphicContext::get_width   [pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by ZoomGraphicContext::unlock(), zoom_in_callback(), zoom_out_callback(), and ZoomGraphicContext::ZoomGraphicContext().

virtual void GraphicContext::real_flip   [inline, virtual]
 

Reimplemented in X11Display.

Definition at line 99 of file graphic_context.hxx.

virtual void GraphicContext::set_clip_rect int    x1_,
int    y1_,
int    x2_,
int    y2_
[pure virtual]
 

Implemented in GlutDisplay, X11Display, and ZoomGraphicContext.

Referenced by ZoomGraphicContext::lock(), ZoomGraphicContext::set_clip_rect(), and ZoomGraphicContext::unlock().


The documentation for this class was generated from the following file:
Generated on Thu Jul 24 10:25:16 2003 for Construo by doxygen1.3-rc3