Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Corona SDK Vector Circles Antialiasing - does it work?

I have searched a ton and even upgraded to graphics 2.0 since I read that antialiasing of vector shapes was now working in Corona. That being said, everything is still either pixelated (in the simulator and my phone) or polygonal (on my Nexus 7).

I have antialiasing turned on in the config file, but did not change any of my draw circle code:

config.lua

application = {
  content = {
    width = 320,
    height = 480, 
    scale = "letterBox",
    fps = 60,
    antialias = true,
    xalign = "center",
    yalign = "center",

    imageSuffix = {
        ["@2x"] = 2
    }   
  }
}

main.lua

local function newDot (i,j)
  local newCircle = display.newCircle( i*40-20, -60, 15)
  newCircle:setFillColor( .2, .6, .86 )
  return newDot
end

Should this create antialiased circles?

Thanks!

like image 332
jon Avatar asked Oct 21 '22 14:10

jon


1 Answers

You are correct, Corona removed the anti-alias boolean as you found in your link. Graphics 2.0 definitely does not support it.

I would suggest just using an image like you mentioned since there is no longer a way to make the vectors for a circle look as smooth as you would like them to.

like image 181
Evan Avatar answered Oct 30 '22 13:10

Evan