esphome / esphome/feature-requests

[display] Add drawRoundRect(), fillRoundRect(), drawCircleHelper(), fillCircleHelper()

Open
#2,953 5 comments 3 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
450
Forks
29
PR merge metrics
No merged PRs in 30d

Description

**Describe the problem you have/What new integration you would like**

Hello,
Would it be possible to add those functions into the display component?

it.drawRoundRect(x, y, width, height, corner radius, colour);
it.fillRoundRect(x, y, width, height, corner radius, colour);
it.drawCircleHelper(x, y, radius, corner bitmask, delta (offset from center), colour);
it.fillCircleHelper(x, y, radius, corner bitmask, delta (offset from center), colour);
//bitmask: Mask bit #1 or bit #2 to indicate which quarters of the circle we're doing

Many thanks

**Please describe your use case for this integration and alternatives you've tried:**

I'm planing to reproduce a kind of dashboard similar to the one is Home Assistant to an e-paper screen.
To make the cards, I'd like to have rounded rectangles.
The circle helpers will be used to reproduce the energy distribution card with lines from the solar panels to the home which have a rounded angle.

**Additional context**

[Link to library](http://adafruit.github.io/Adafruit-GFX-Library/html/class_adafruit___g_f_x.html#ab496b247abec724ef80e17a30257972b)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reviewing the display component and the linked Adafruit-GFX API for drawRoundRect(), fillRoundRect(), drawCircleHelper(), and fillCircleHelper(). Done means the display component exposes the four requested functions with the listed arguments and supports the rounded cards and circle-helper use cases described.

Written by the indexing model from the issue text.

Assessment

Domain
computer-graphics, embedded-iot
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.