mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-07-30 18:19:08 -04:00
ILI9341 read_pixels().
Improves on / abstracts prior interface, which just handed back uint16_ts from the LCD's parallel interface.
This commit is contained in:
parent
bdaa13c103
commit
77eb0c5d24
2 changed files with 42 additions and 0 deletions
|
@ -65,6 +65,14 @@ public:
|
|||
draw_pixels(r, colors.data(), colors.size());
|
||||
}
|
||||
|
||||
template<size_t N>
|
||||
void read_pixels(
|
||||
const ui::Rect r,
|
||||
std::array<ui::ColorRGB888, N>& colors
|
||||
) {
|
||||
read_pixels(r, colors.data(), colors.size());
|
||||
}
|
||||
|
||||
void draw_bitmap(
|
||||
const ui::Point p,
|
||||
const ui::Size size,
|
||||
|
@ -101,6 +109,7 @@ private:
|
|||
scroll_t scroll_state;
|
||||
|
||||
void draw_pixels(const ui::Rect r, const ui::Color* const colors, const size_t count);
|
||||
void read_pixels(const ui::Rect r, ui::ColorRGB888* const colors, const size_t count);
|
||||
};
|
||||
|
||||
} /* namespace lcd */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue