Skip to content

Commit

Permalink
fix: set default highlight arg to blank buffer
Browse files Browse the repository at this point in the history
when not refreshing the highlight layer, it can corrupt over time,
observed in the `epd2in13b_V3` model. So we refresh it with the blank
buffer even when there are no highlight pixels
  • Loading branch information
loiccoyle committed Jun 16, 2024
1 parent 1e4f8ee commit c6d0b6d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tinyticker/waveshare_lib/_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def clear(self) -> None:

def show(self, image: Image.Image) -> None:
threshold = 20
highlight_buffer = None
highlight_buffer = self._blank
if image.mode == "RGB":
highlight_mask = np.array(image).std(axis=-1) >= threshold
if highlight_mask.any():
Expand Down

0 comments on commit c6d0b6d

Please sign in to comment.