Gunther Active Member Licensed User Longtime User Jan 21, 2019 #1 Hello, as you may see here in the screenshot the edges are very steppy althrough the original PNG of the green circle has a proper edge. Any way to smoothen that edges? The PNG is loaded via Tiled to the body with alias set to 1 degree. The yellow one behind is added by painting a bc and added to the Graphcache. And this is looking fine. Code: Copy bc.Initialize(bmp.Width, bmp.Height) bc.CopyPixelsFromBitmap(bmp) bc.BuildPatternCache(IgnoreSemiTransparent) ' < ---- not available Last edited: Jan 21, 2019
Hello, as you may see here in the screenshot the edges are very steppy althrough the original PNG of the green circle has a proper edge. Any way to smoothen that edges? The PNG is loaded via Tiled to the body with alias set to 1 degree. The yellow one behind is added by painting a bc and added to the Graphcache. And this is looking fine. Code: Copy bc.Initialize(bmp.Width, bmp.Height) bc.CopyPixelsFromBitmap(bmp) bc.BuildPatternCache(IgnoreSemiTransparent) ' < ---- not available
Erel B4X founder Staff member Licensed User Longtime User Jan 22, 2019 #2 BuildPatternCache was replaced with more powerful features. You don't need it. Antialias should be checked in Tiled. If it doesn't help then please upload the project.
BuildPatternCache was replaced with more powerful features. You don't need it. Antialias should be checked in Tiled. If it doesn't help then please upload the project.
Gunther Active Member Licensed User Longtime User Jan 22, 2019 #3 Hi, here is the TestProject. One ball is rotating the other is fixed to compare. AntiAlias is enabled for both. With "Q" you may change the background color. Try to get a bright one (yellow or so) Attachments TestProject.zip TestProject.zip 32.9 KB · Views: 754
Hi, here is the TestProject. One ball is rotating the other is fixed to compare. AntiAlias is enabled for both. With "Q" you may change the background color. Try to get a bright one (yellow or so)
Erel B4X founder Staff member Licensed User Longtime User Jan 22, 2019 #4 The image is antialiased. This means that when you rotate it the semitransparent border is rotated as well and the result is not smooth. The semitransparent edge matches a specific layout which is not kept during rotation. You will get better results with an image without antialiasing and with a lighter border. Though it will not be as sharp as drawing the circle yourself.
The image is antialiased. This means that when you rotate it the semitransparent border is rotated as well and the result is not smooth. The semitransparent edge matches a specific layout which is not kept during rotation. You will get better results with an image without antialiasing and with a lighter border. Though it will not be as sharp as drawing the circle yourself.
Gunther Active Member Licensed User Longtime User Jan 22, 2019 #5 Thanks, you mentioned something like this already in the AngryBirds Example concerning the Hook but without the rotation impact. Last edited: Jan 22, 2019
Thanks, you mentioned something like this already in the AngryBirds Example concerning the Hook but without the rotation impact.