Public Member Functions | Private Attributes | Static Private Attributes

display::drawing_buffer_key Class Reference

In order to render a hex properly it needs to be rendered per row. More...

#include <display.hpp>

List of all members.

Public Member Functions

 drawing_buffer_key (const map_location &loc, tdrawing_layer layer)
bool operator< (const drawing_buffer_key &rhs) const

Private Attributes

unsigned int key_

Static Private Attributes

static const tdrawing_layer layer_groups []
static const unsigned int max_layer_group = sizeof(display::drawing_buffer_key::layer_groups) / sizeof(display::tdrawing_layer) - 2

Detailed Description

In order to render a hex properly it needs to be rendered per row.

On this row several layers need to be drawn at the same time. Mainly the unit and the background terrain. This is needed since both can spill in the next hex. The foreground terrain needs to be drawn before to avoid decapitation a unit.

In other words: for every layer for every row (starting from the top) for every hex in the row ...

this is modified to: for every layer group for every row (starting from the top) for every layer in the group for every hex in the row ...

* Surfaces are rendered per level in a map. * Per level the items are rendered per location these locations are stored in the drawing order required for units. * every location has a vector with surfaces, each with its own screen coordinate to render at. * every vector element has a vector with surfaces to render.

Definition at line 822 of file display.hpp.


Constructor & Destructor Documentation

display::drawing_buffer_key::drawing_buffer_key ( const map_location loc,
tdrawing_layer  layer 
) [inline]

Member Function Documentation

bool display::drawing_buffer_key::operator< ( const drawing_buffer_key rhs  )  const [inline]

Definition at line 833 of file display.hpp.

References key_.


Member Data Documentation

unsigned int display::drawing_buffer_key::key_ [private]

Definition at line 825 of file display.hpp.

Referenced by drawing_buffer_key(), and operator<().

Initial value:
 {
    LAYER_TERRAIN_BG,
    LAYER_UNIT_FIRST,
    LAYER_UNIT_MOVE_DEFAULT,
    
    LAYER_REACHMAP,
    LAYER_LAST_LAYER
}

Definition at line 827 of file display.hpp.

Referenced by drawing_buffer_key().

Definition at line 828 of file display.hpp.

Referenced by drawing_buffer_key().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Thu May 24 2012 01:13:45 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs