xietao Posted June 3, 2025 Report Posted June 3, 2025 Here's my code: gdispGFillCircle(g, 120, 120, 30, HTML2COLOR(0xFF8D1A)); And Anti-aliasing is turned on. #define GDISP_NEED_ANTIALIAS GFXON
Joel Bodenmann Posted June 3, 2025 Report Posted June 3, 2025 Hi, Can you please provide more details? What do you consider to be defective?
xietao Posted June 4, 2025 Author Report Posted June 4, 2025 11 hours ago, Joel Bodenmann said: Hi, Can you please provide more details? What do you consider to be defective? As you can see, the resulting circle has some missing corners, how should I fix it?
inmarket Posted June 4, 2025 Report Posted June 4, 2025 Anti-aliasing is something that is currently only supported by font rendering. Circles (or any drawing operation other than fonts) are never anti-aliased. The reason for this is the amount of code and the complexity in the drawing operations make it not suitable for such a small graphics library as uGFX. Anti-aliasing operations are also very slow for most of the displays uGFX support because it requires reading back from the display frame-buffer, an operation that is very slow on many devices. Of-course, if your display is not capable of read-back (and many aren't), anti-aliasing will not work at all, even for fonts. If you want to anti-alias your circle, a would suggest drawing a circle 1 pixel larger diameter in a color that is a blend between the circle color and the background color. Then draw you circle on top of that. That will have the effect of filling in the edge pixels.
Timmy Brolin Posted June 27, 2025 Report Posted June 27, 2025 Or make the circle an image. If you have the flash memory to spare.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now