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 |
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.
|
inline |
Definition at line 1296 of file display.cpp.
References BITS_FOR_LAYER, BITS_FOR_LAYER_GROUP, BITS_FOR_X_OVER_2, BITS_FOR_X_PARITY, BITS_FOR_Y, g, key_, layer_groups, MAX_BORDER, max_layer_group, map_location::x, and map_location::y.
|
inline |
Definition at line 999 of file display.hpp.
References key_.
|
private |
Definition at line 991 of file display.hpp.
Referenced by drawing_buffer_key(), and operator<().
|
staticprivate |
Definition at line 993 of file display.hpp.
Referenced by drawing_buffer_key().
|
staticprivate |
Definition at line 994 of file display.hpp.
Referenced by drawing_buffer_key().