This commit is contained in:
邹宗楠
2022-10-17 14:06:23 +08:00
parent 0695aa132c
commit 53fe97cbc1
49 changed files with 78 additions and 225 deletions

View File

@@ -32,7 +32,6 @@ func (c *Coordinate) GetMapKey() int64 {
func GetRound4Radius(lng, lat float64, gridWith int) (roundLng, roundLat int) {
lng2, _ := jxutils.ConvertDistanceToLogLat(lng, lat, float64(gridWith), 90)
_, lat2 := jxutils.ConvertDistanceToLogLat(lng, lat, float64(gridWith), 0)
// globals.SugarLogger.Debugf("GetRound4Radius gridWith:%d, lng:%f, lat:%f, lng2:%f, lat2:%f", gridWith, lng, lat, lng2, lat2)
return jxutils.StandardCoordinate2Int(math.Abs(lng2 - lng)), jxutils.StandardCoordinate2Int(math.Abs(lat2 - lat))
}