我正在使用谷歌地图,我在其中使用以下代码创建了圆圈,但我的圆圈的边界是不规则的。我的问题是如何让它像 MKCircle 一样平滑
let circ = GMSCircle(position: circleCentreCoordinate, radius: CLLocationDistance(radius))
circ.fillColor = UIColor.purple.withAlphaComponent(0.2)
circ.strokeColor = UIColor.purple.withAlphaComponent(0.7)
circ.strokeWidth = 2
circ.map = self.mapView
let update = GMSCameraUpdate.fit(circ.bounds())
mapView.animate(with: update)
当我的半径是 30 米时,它会像这样显示我
当半径为 200+ 米时,它就像
最佳答案
此问题出现在 GoogleMap 3.1.0 中,更新到 GoogleMap 3.3.0,这将解决您的问题。
关于ios - Swift iOS 中的 GMSCircle 不规则边框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56555666/