Implement crop mode for cover image on sleep screen.

This commit is contained in:
Jonas Diemer
2026-01-03 13:48:46 +01:00
parent 5fdf23f1d2
commit a99ad3b6cd
6 changed files with 44 additions and 16 deletions

View File

@@ -257,6 +257,7 @@ BmpReaderError Bitmap::parseHeaders() {
}
// packed 2bpp output, 0 = black, 1 = dark gray, 2 = light gray, 3 = white
// TODO: This seems to only work sequentially, rowY is mostly ignored
BmpReaderError Bitmap::readRow(uint8_t* data, uint8_t* rowBuffer, int rowY) const {
// Note: rowBuffer should be pre-allocated by the caller to size 'rowBytes'
if (file.read(rowBuffer, rowBytes) != rowBytes) return BmpReaderError::ShortReadRow;