template<class C, lcduint_t W, lcduint_t H, uint8_t B>
class NanoEngineTiler< C, W, H, B >
This class template is responsible for holding and updating data about areas to be refreshed on LCD display. It accepts canvas class, tile width in pixels, tile height in pixels and number of bits in tile width as arguments for the template. For example, for 8x8 8-bit RGB tiles the reference should be NanoEngineTiler<NanoCanvas8,8,8,3>, and 3 bits means 3^2 = 8. If you need to have single big buffer, holding the whole content for monochrome display, you can specify something like this NanoEngineTiler<NanoCanvas1,128,64,7>.
Definition at line 80 of file tiler.h.
template<class C, lcduint_t W, lcduint_t H, uint8_t B>
Sets user-defined draw callback. This callback will be called everytime, engine needs to update display content. If callback returns false, engine will not update those area. You always have a way to find out, which area is being updated by engine via NanoEngine<>::canvas::getOffset() and NanoEngine<>::NE_TILE_SIZE.
- Warning
- By default canvas in the engine is initialized with local screen coordinates. So graphics object with [0,0] coordinates will be placed at topleft position on the display. But engine supports also global coordinates, in this case actual object position depends on current engine offset. Refer to worldCoordinates() and localCoordinates().
- Parameters
-
callback | - user-defined draw callback. |
- Note
- you can change draw callback anytime you need.
- See also
- worldCoordinates()
-
localCoordinates()
Definition at line 240 of file tiler.h.
template<class C, lcduint_t W, lcduint_t H, uint8_t B>
Marks for refresh lcd area, which corresponds to specified rectangle in global (World) coordinates. If engine offset is (0,0), then this function refreshes the same area as refresh().
Definition at line 155 of file tiler.h.
template<class C, lcduint_t W, lcduint_t H, uint8_t B>
Marks for refresh lcd area, which corresponds to specified rectangle in global (World) coordinates. If engine offset is (0,0), then this function refreshes the same area as refresh().
Definition at line 165 of file tiler.h.