Sprite quality with circle

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By dabrain34
:warning: Old Version Published before Godot 3 was released.

Dear all,

I’m using 2D sprite node with a png of a plain circle and the render quality is quite bad. Does someone know how I could improve the rendering?
https://postimg.org/image/d6tar07d1/

It seems to be related to transparency, color used(white) and format. Is there any better format than png to use ?

dabrain34 | 2016-11-30 21:35

I found a way to workaround the issue. My png was owning a circle with the same diameter as the picture size. When I enlarge the size of my picture, the artifacts disappears. Can we consider this as a bug in godot rendering ?
But I still have a kind of black border when the color behind is lighter ( such as white circle on yellow)

http://hpics.li/b890c42

dabrain34 | 2016-11-30 22:09

Is the first picture taken on a sprite seen smaller as it really is? In that case the renderer is going to discard some pixels. You could try to toggle mipmaps and filter, to see if it improves?

Also, it’s not that clear, do you actually don’t want the black borders?
The docs have a section about it http://docs.godotengine.org/en/stable/tutorials/asset_pipeline/importing_textures.html#blending-artifacts

Zylann | 2016-11-30 23:54

Could be a texture filter thing (like mipmapping), that thing use to affect edges, check the texture options (edit or the arrow right of the texture property).

That can be some png exporting option issue too (like alpha values), but can’t be sure, try playing with both (export options of your editor and texture options).

eons | 2016-11-30 23:55

Yes that’s what i noticed. It would be nice to find the right combination. I’m surprised nobody noticed it before …

dabrain34 | 2016-12-01 15:37