The Battle for Wesnoth  1.13.4+dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Public Member Functions | Private Attributes | Static Private Attributes | List of all members
display::drawing_buffer_key Class Reference

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

#include <display.hpp>

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 ...

Definition at line 988 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 999 of file display.hpp.

References key_.

Member Data Documentation

unsigned int display::drawing_buffer_key::key_
private

Definition at line 991 of file display.hpp.

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

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

Definition at line 994 of file display.hpp.

Referenced by drawing_buffer_key().


The documentation for this class was generated from the following files: