xietao Posted Tuesday at 08:25 AM Report Posted Tuesday at 08:25 AM 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 Tuesday at 03:18 PM Report Posted Tuesday at 03:18 PM Hi, Can you please provide more details? What do you consider to be defective?
xietao Posted Wednesday at 02:51 AM Author Report Posted Wednesday at 02:51 AM 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 Wednesday at 08:35 PM Report Posted Wednesday at 08:35 PM 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.
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