Documentation ¶
Index ¶
- Constants
- Variables
- func X_baseCellIsCwOffset(tls *libc.TLS, baseCell int32, testFace int32) uint8
- func X_baseCellToCCWrot60(tls *libc.TLS, baseCell int32, face int32) int32
- func X_baseCellToFaceIjk(tls *libc.TLS, baseCell int32, h uintptr)
- func X_downAp3(tls *libc.TLS, ijk uintptr)
- func X_downAp3r(tls *libc.TLS, ijk uintptr)
- func X_downAp7(tls *libc.TLS, ijk uintptr)
- func X_downAp7r(tls *libc.TLS, ijk uintptr)
- func X_faceIjkPentToCellBoundary(tls *libc.TLS, h uintptr, res int32, start int32, length int32, g uintptr)
- func X_faceIjkPentToVerts(tls *libc.TLS, fijk uintptr, res uintptr, fijkVerts uintptr)
- func X_faceIjkToBaseCell(tls *libc.TLS, h uintptr) int32
- func X_faceIjkToBaseCellCCWrot60(tls *libc.TLS, h uintptr) int32
- func X_faceIjkToCellBoundary(tls *libc.TLS, h uintptr, res int32, start int32, length int32, g uintptr)
- func X_faceIjkToGeo(tls *libc.TLS, h uintptr, res int32, g uintptr)
- func X_faceIjkToVerts(tls *libc.TLS, fijk uintptr, res uintptr, fijkVerts uintptr)
- func X_geoAzDistanceRads(tls *libc.TLS, p1 uintptr, az float64, distance float64, p2 uintptr)
- func X_geoAzimuthRads(tls *libc.TLS, p1 uintptr, p2 uintptr) float64
- func X_geoToClosestFace(tls *libc.TLS, g uintptr, face uintptr, sqd uintptr)
- func X_geoToFaceIjk(tls *libc.TLS, g uintptr, res int32, h uintptr)
- func X_geoToHex2d(tls *libc.TLS, g uintptr, res int32, face uintptr, v uintptr)
- func X_geoToVec3d(tls *libc.TLS, geo uintptr, v uintptr)
- func X_getBaseCellNeighbor(tls *libc.TLS, baseCell int32, dir TDirection) int32
- func X_h3ToFaceIjkWithInitializedFijk(tls *libc.TLS, h TH3Index, fijk uintptr) int32
- func X_hex2dToCoordIJK(tls *libc.TLS, v uintptr, h uintptr)
- func X_hex2dToGeo(tls *libc.TLS, v uintptr, face int32, res int32, substrate int32, g uintptr)
- func X_hexRadiusKm(tls *libc.TLS, h3Index TH3Index) float64
- func X_ijkAdd(tls *libc.TLS, h1 uintptr, h2 uintptr, sum uintptr)
- func X_ijkMatches(tls *libc.TLS, c1 uintptr, c2 uintptr) int32
- func X_ijkNormalize(tls *libc.TLS, c uintptr)
- func X_ijkNormalizeCouldOverflow(tls *libc.TLS, ijk uintptr) uint8
- func X_ijkRotate60ccw(tls *libc.TLS, ijk uintptr)
- func X_ijkRotate60cw(tls *libc.TLS, ijk uintptr)
- func X_ijkScale(tls *libc.TLS, c uintptr, factor int32)
- func X_ijkSub(tls *libc.TLS, h1 uintptr, h2 uintptr, diff uintptr)
- func X_ijkToHex2d(tls *libc.TLS, h uintptr, v uintptr)
- func X_initVertexNode(tls *libc.TLS, node uintptr, fromVtx uintptr, toVtx uintptr)
- func X_isBaseCellPentagon(tls *libc.TLS, baseCell int32) int32
- func X_isBaseCellPolarPentagon(tls *libc.TLS, baseCell int32) uint8
- func X_neighbor(tls *libc.TLS, ijk uintptr, digit TDirection)
- func X_pointSquareDist(tls *libc.TLS, v1 uintptr, v2 uintptr) float64
- func X_posAngleRads(tls *libc.TLS, rads float64) float64
- func X_setGeoRads(tls *libc.TLS, p uintptr, latRads float64, lngRads float64)
- func X_setIJK(tls *libc.TLS, ijk uintptr, i int32, j int32, k int32)
- func X_square(tls *libc.TLS, x float64) float64
- func X_upAp7(tls *libc.TLS, ijk uintptr)
- func X_upAp7r(tls *libc.TLS, ijk uintptr)
- func X_v2dAlmostEquals(tls *libc.TLS, v1 uintptr, v2 uintptr) uint8
- func X_v2dIntersect(tls *libc.TLS, p0 uintptr, p1 uintptr, p2 uintptr, p3 uintptr, inter uintptr)
- func X_v2dMag(tls *libc.TLS, v uintptr) float64
- func X_vertexGraphToLinkedGeo(tls *libc.TLS, graph uintptr, out uintptr)
- func XaddLinkedCoord(tls *libc.TLS, loop uintptr, vertex uintptr) uintptr
- func XaddLinkedLoop(tls *libc.TLS, polygon uintptr, loop uintptr) uintptr
- func XaddNewLinkedLoop(tls *libc.TLS, polygon uintptr) uintptr
- func XaddNewLinkedPolygon(tls *libc.TLS, polygon uintptr) uintptr
- func XaddVertexNode(tls *libc.TLS, graph uintptr, fromVtx uintptr, toVtx uintptr) uintptr
- func XbboxCenter(tls *libc.TLS, bbox uintptr, center uintptr)
- func XbboxContains(tls *libc.TLS, bbox uintptr, point uintptr) uint8
- func XbboxEquals(tls *libc.TLS, b1 uintptr, b2 uintptr) uint8
- func XbboxFromGeoLoop(tls *libc.TLS, loop uintptr, bbox uintptr)
- func XbboxFromLinkedGeoLoop(tls *libc.TLS, loop uintptr, bbox uintptr)
- func XbboxIsTransmeridian(tls *libc.TLS, bbox uintptr) uint8
- func XbboxesFromGeoPolygon(tls *libc.TLS, polygon uintptr, bboxes uintptr)
- func XconstrainLat(tls *libc.TLS, lat float64) float64
- func XconstrainLng(tls *libc.TLS, lng float64) float64
- func XcountLinkedCoords(tls *libc.TLS, loop uintptr) int32
- func XcountLinkedLoops(tls *libc.TLS, polygon uintptr) int32
- func XcountLinkedPolygons(tls *libc.TLS, polygon uintptr) int32
- func XcubeToIjk(tls *libc.TLS, ijk uintptr)
- func XdegsToRads(tls *libc.TLS, degrees float64) float64
- func XdestroyLinkedGeoLoop(tls *libc.TLS, loop uintptr)
- func XdestroyLinkedMultiPolygon(tls *libc.TLS, polygon uintptr)
- func XdestroyVertexGraph(tls *libc.TLS, graph uintptr)
- func XfindNodeForEdge(tls *libc.TLS, graph uintptr, fromVtx uintptr, toVtx uintptr) uintptr
- func XfindNodeForVertex(tls *libc.TLS, graph uintptr, fromVtx uintptr) uintptr
- func XfirstVertexNode(tls *libc.TLS, graph uintptr) uintptr
- func Xfmax(tls *libc.TLS, a, b float64) float64
- func Xfmin(tls *libc.TLS, a, b float64) float64
- func XgeoAlmostEqual(tls *libc.TLS, p1 uintptr, p2 uintptr) uint8
- func XgeoAlmostEqualThreshold(tls *libc.TLS, p1 uintptr, p2 uintptr, threshold float64) uint8
- func XgetBaseCellNumber(tls *libc.TLS, h TH3Index) int32
- func XgetResolution(tls *libc.TLS, h TH3Index) int32
- func XgreatCircleDistanceKm(tls *libc.TLS, a uintptr, b uintptr) float64
- func XgreatCircleDistanceM(tls *libc.TLS, a uintptr, b uintptr) float64
- func XgreatCircleDistanceRads(tls *libc.TLS, a uintptr, b uintptr) float64
- func XijkDistance(tls *libc.TLS, c1 uintptr, c2 uintptr) int32
- func XijkToCube(tls *libc.TLS, ijk uintptr)
- func XijkToIj(tls *libc.TLS, ijk uintptr, ij uintptr)
- func XinitVertexGraph(tls *libc.TLS, graph uintptr, numBuckets int32, res int32)
- func XisClockwiseGeoLoop(tls *libc.TLS, loop uintptr) uint8
- func XisClockwiseLinkedGeoLoop(tls *libc.TLS, loop uintptr) uint8
- func XisPentagon(tls *libc.TLS, h TH3Index) int32
- func XisResClassIII(tls *libc.TLS, h TH3Index) int32
- func XisResolutionClassIII(tls *libc.TLS, res int32) int32
- func XisValidCell(tls *libc.TLS, h TH3Index) int32
- func XisValidDirectedEdge(tls *libc.TLS, edge TH3Index) int32
- func XisValidVertex(tls *libc.TLS, vertex TH3Index) int32
- func XisXfinite(tls *libc.TLS, f float64) uint8
- func XiterStepChild(tls *libc.TLS, it uintptr)
- func XiterStepRes(tls *libc.TLS, itR uintptr)
- func Xlroundl(tls *libc.TLS, a float64) float64
- func XpentagonCount(tls *libc.TLS) int32
- func XpointInsideGeoLoop(tls *libc.TLS, loop uintptr, bbox uintptr, coord uintptr) uint8
- func XpointInsideLinkedGeoLoop(tls *libc.TLS, loop uintptr, bbox uintptr, coord uintptr) uint8
- func XpointInsidePolygon(tls *libc.TLS, geoPolygon uintptr, bboxes uintptr, coord uintptr) uint8
- func XradsToDegs(tls *libc.TLS, radians float64) float64
- func XremoveVertexNode(tls *libc.TLS, graph uintptr, node uintptr) int32
- func Xres0CellCount(tls *libc.TLS) int32
- func XsetGeoDegs(tls *libc.TLS, p uintptr, latDegs float64, lngDegs float64)
- func XsetH3Index(tls *libc.TLS, hp uintptr, res int32, baseCell int32, initDigit TDirection)
- func XtriangleArea(tls *libc.TLS, a uintptr, b uintptr, c uintptr) float64
- func XtriangleEdgeLengthsToArea(tls *libc.TLS, a float64, b float64, c float64) float64
- func XvertexNumForDirection(tls *libc.TLS, origin TH3Index, direction TDirection) int32
- type SLinkedGeoLoop
- type SLinkedGeoPolygon
- type SLinkedLatLng
- type SVertexNode
- type S_G_fpos64_t
- type S_G_fpos_t
- type S_IO_FILE
- type S__locale_struct
- type S__pthread_cond_s
- type S__pthread_internal_list
- type S__pthread_internal_slist
- type S__pthread_mutex_s
- type S__pthread_rwlock_arch_t
- type Sdrand48_data
- type Spthread_attr_t
- type Srandom_data
- type Stimespec
- type Stimeval
- type TBBox
- type TBaseCellData
- type TBaseCellRotation
- type TCellBoundary
- type TCoordIJ
- type TCoordIJK
- type TDirection
- func X_getBaseCellDirection(tls *libc.TLS, originBaseCell int32, neighboringBaseCell int32) TDirection
- func X_h3LeadingNonZeroDigit(tls *libc.TLS, h TH3Index) TDirection
- func X_rotate60ccw(tls *libc.TLS, digit TDirection) TDirection
- func X_rotate60cw(tls *libc.TLS, digit TDirection) TDirection
- func X_unitIjkToDigit(tls *libc.TLS, ijk uintptr) TDirection
- func XdirectionForNeighbor(tls *libc.TLS, origin TH3Index, destination TH3Index) TDirection
- func XdirectionForVertexNum(tls *libc.TLS, origin TH3Index, vertexNum int32) TDirection
- type TFILE
- type TFaceIJK
- type TFaceOrientIJK
- type TGeoLoop
- type TGeoMultiPolygon
- type TGeoPolygon
- type TH3Error
- func X_getEdgeHexagons(tls *libc.TLS, geoloop uintptr, numHexagons Tint64_t, res int32, ...) TH3Error
- func X_gridDiskDistancesInternal(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr, ...) TH3Error
- func X_h3ToFaceIjk(tls *libc.TLS, h TH3Index, fijk uintptr) TH3Error
- func X_upAp7Checked(tls *libc.TLS, ijk uintptr) TH3Error
- func X_upAp7rChecked(tls *libc.TLS, ijk uintptr) TH3Error
- func XareNeighborCells(tls *libc.TLS, origin TH3Index, destination TH3Index, out uintptr) TH3Error
- func XbboxHexEstimate(tls *libc.TLS, bbox uintptr, res int32, out uintptr) TH3Error
- func XcellAreaKm2(tls *libc.TLS, cell TH3Index, out uintptr) TH3Error
- func XcellAreaM2(tls *libc.TLS, cell TH3Index, out uintptr) TH3Error
- func XcellAreaRads2(tls *libc.TLS, cell TH3Index, out uintptr) TH3Error
- func XcellToBoundary(tls *libc.TLS, h3 TH3Index, cb uintptr) TH3Error
- func XcellToCenterChild(tls *libc.TLS, h TH3Index, childRes int32, child uintptr) TH3Error
- func XcellToChildPos(tls *libc.TLS, child TH3Index, parentRes int32, out uintptr) TH3Error
- func XcellToChildren(tls *libc.TLS, h TH3Index, childRes int32, children uintptr) TH3Error
- func XcellToChildrenSize(tls *libc.TLS, h TH3Index, childRes int32, out uintptr) TH3Error
- func XcellToLatLng(tls *libc.TLS, h3 TH3Index, g uintptr) TH3Error
- func XcellToLocalIj(tls *libc.TLS, origin TH3Index, h3 TH3Index, mode Tuint32_t, out uintptr) TH3Error
- func XcellToLocalIjk(tls *libc.TLS, origin TH3Index, h3 TH3Index, out uintptr) TH3Error
- func XcellToParent(tls *libc.TLS, h TH3Index, parentRes int32, out uintptr) TH3Error
- func XcellToVertex(tls *libc.TLS, cell TH3Index, vertexNum int32, out uintptr) TH3Error
- func XcellToVertexes(tls *libc.TLS, cell TH3Index, vertexes uintptr) TH3Error
- func XcellsToDirectedEdge(tls *libc.TLS, origin TH3Index, destination TH3Index, out uintptr) TH3Error
- func XcellsToLinkedMultiPolygon(tls *libc.TLS, h3Set uintptr, numHexes int32, out uintptr) TH3Error
- func XchildPosToCell(tls *libc.TLS, childPos Tint64_t, parent TH3Index, childRes int32, ...) TH3Error
- func XcompactCells(tls *libc.TLS, h3Set uintptr, compactedSet uintptr, numHexes Tint64_t) TH3Error
- func XdirectedEdgeToBoundary(tls *libc.TLS, edge TH3Index, cb uintptr) TH3Error
- func XdirectedEdgeToCells(tls *libc.TLS, edge TH3Index, originDestination uintptr) TH3Error
- func XedgeLengthKm(tls *libc.TLS, edge TH3Index, length uintptr) TH3Error
- func XedgeLengthM(tls *libc.TLS, edge TH3Index, length uintptr) TH3Error
- func XedgeLengthRads(tls *libc.TLS, edge TH3Index, length uintptr) TH3Error
- func XgetDirectedEdgeDestination(tls *libc.TLS, edge TH3Index, out uintptr) TH3Error
- func XgetDirectedEdgeOrigin(tls *libc.TLS, edge TH3Index, out uintptr) TH3Error
- func XgetHexagonAreaAvgKm2(tls *libc.TLS, res int32, out uintptr) TH3Error
- func XgetHexagonAreaAvgM2(tls *libc.TLS, res int32, out uintptr) TH3Error
- func XgetHexagonEdgeLengthAvgKm(tls *libc.TLS, res int32, out uintptr) TH3Error
- func XgetHexagonEdgeLengthAvgM(tls *libc.TLS, res int32, out uintptr) TH3Error
- func XgetIcosahedronFaces(tls *libc.TLS, h3 TH3Index, out uintptr) TH3Error
- func XgetNumCells(tls *libc.TLS, res int32, out uintptr) TH3Error
- func XgetPentagons(tls *libc.TLS, res int32, out uintptr) TH3Error
- func XgetRes0Cells(tls *libc.TLS, out uintptr) TH3Error
- func XgridDisk(tls *libc.TLS, origin TH3Index, k int32, out uintptr) TH3Error
- func XgridDiskDistances(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr) TH3Error
- func XgridDiskDistancesSafe(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr) TH3Error
- func XgridDiskDistancesUnsafe(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr) TH3Error
- func XgridDiskUnsafe(tls *libc.TLS, origin TH3Index, k int32, out uintptr) TH3Error
- func XgridDisksUnsafe(tls *libc.TLS, h3Set uintptr, length int32, k int32, out uintptr) TH3Error
- func XgridDistance(tls *libc.TLS, origin TH3Index, h3 TH3Index, out uintptr) TH3Error
- func XgridPathCells(tls *libc.TLS, start TH3Index, end TH3Index, out uintptr) TH3Error
- func XgridPathCellsSize(tls *libc.TLS, start TH3Index, end TH3Index, size uintptr) TH3Error
- func XgridRingUnsafe(tls *libc.TLS, origin TH3Index, k int32, out uintptr) TH3Error
- func Xh3NeighborRotations(tls *libc.TLS, origin TH3Index, dir TDirection, rotations uintptr, out uintptr) TH3Error
- func Xh3SetToVertexGraph(tls *libc.TLS, h3Set uintptr, numHexes int32, graph uintptr) TH3Error
- func Xh3ToString(tls *libc.TLS, h TH3Index, str uintptr, sz Tsize_t) TH3Error
- func XijToIjk(tls *libc.TLS, ij uintptr, ijk uintptr) TH3Error
- func XlatLngToCell(tls *libc.TLS, g uintptr, res int32, out uintptr) TH3Error
- func XlineHexEstimate(tls *libc.TLS, origin uintptr, destination uintptr, res int32, out uintptr) TH3Error
- func XlocalIjToCell(tls *libc.TLS, origin TH3Index, ij uintptr, mode Tuint32_t, out uintptr) TH3Error
- func XlocalIjkToCell(tls *libc.TLS, origin TH3Index, ijk uintptr, out uintptr) TH3Error
- func XmaxFaceCount(tls *libc.TLS, h3 TH3Index, out uintptr) TH3Error
- func XmaxGridDiskSize(tls *libc.TLS, k int32, out uintptr) TH3Error
- func XmaxPolygonToCellsSize(tls *libc.TLS, geoPolygon uintptr, res int32, flags Tuint32_t, out uintptr) TH3Error
- func XnormalizeMultiPolygon(tls *libc.TLS, root uintptr) TH3Error
- func XoriginToDirectedEdges(tls *libc.TLS, origin TH3Index, edges uintptr) TH3Error
- func XpolygonToCells(tls *libc.TLS, geoPolygon uintptr, res int32, flags Tuint32_t, out uintptr) TH3Error
- func XstringToH3(tls *libc.TLS, str uintptr, out uintptr) TH3Error
- func XuncompactCells(tls *libc.TLS, compactedSet uintptr, numCompacted Tint64_t, outSet uintptr, ...) TH3Error
- func XuncompactCellsSize(tls *libc.TLS, compactedSet uintptr, numCompacted Tint64_t, res int32, ...) TH3Error
- func XvertexToLatLng(tls *libc.TLS, vertex TH3Index, coord uintptr) TH3Error
- type TH3ErrorCodes
- type TH3Index
- func X_faceIjkToH3(tls *libc.TLS, fijk uintptr, res int32) TH3Index
- func X_h3Rotate60ccw(tls *libc.TLS, h TH3Index) TH3Index
- func X_h3Rotate60cw(tls *libc.TLS, h TH3Index) TH3Index
- func X_h3RotatePent60ccw(tls *libc.TLS, h TH3Index) TH3Index
- func X_h3RotatePent60cw(tls *libc.TLS, h TH3Index) TH3Index
- func X_zeroIndexDigits(tls *libc.TLS, h TH3Index, start int32, end int32) TH3Index
- func XmakeDirectChild(tls *libc.TLS, h TH3Index, cellNumber int32) TH3Index
- type TIterCellsChildren
- type TIterCellsResolution
- type TLatLng
- type TLinkedGeoLoop
- type TLinkedGeoPolygon
- type TLinkedLatLng
- type TOverage
- type TPentagonDirectionFaces
- type TVec2d
- type TVec3d
- type TVertexGraph
- type TVertexNode
- type T__FILE
- type T__atomic_wide_counter
- type T__blkcnt64_t
- type T__blkcnt_t
- type T__blksize_t
- type T__builtin_va_list
- type T__caddr_t
- type T__clock_t
- type T__clockid_t
- type T__compar_fn_t
- type T__daddr_t
- type T__dev_t
- type T__fd_mask
- type T__float128
- type T__fpos64_t
- type T__fpos_t
- type T__fsblkcnt64_t
- type T__fsblkcnt_t
- type T__fsfilcnt64_t
- type T__fsfilcnt_t
- type T__fsid_t
- type T__fsword_t
- type T__gid_t
- type T__gnuc_va_list
- type T__gwchar_t
- type T__id_t
- type T__ino64_t
- type T__ino_t
- type T__int128_t
- type T__int16_t
- type T__int32_t
- type T__int64_t
- type T__int8_t
- type T__int_least16_t
- type T__int_least32_t
- type T__int_least64_t
- type T__int_least8_t
- type T__intmax_t
- type T__intptr_t
- type T__key_t
- type T__locale_t
- type T__loff_t
- type T__mbstate_t
- type T__mode_t
- type T__nlink_t
- type T__off64_t
- type T__off_t
- type T__once_flag
- type T__pid_t
- type T__pthread_list_t
- type T__pthread_slist_t
- type T__quad_t
- type T__rlim64_t
- type T__rlim_t
- type T__sig_atomic_t
- type T__sigset_t
- type T__socklen_t
- type T__ssize_t
- type T__suseconds64_t
- type T__suseconds_t
- type T__syscall_slong_t
- type T__syscall_ulong_t
- type T__thrd_t
- type T__time_t
- type T__timer_t
- type T__tss_t
- type T__u_char
- type T__u_int
- type T__u_long
- type T__u_quad_t
- type T__u_short
- type T__uid_t
- type T__uint128_t
- type T__uint16_t
- type T__uint32_t
- type T__uint64_t
- type T__uint8_t
- type T__uint_least16_t
- type T__uint_least32_t
- type T__uint_least64_t
- type T__uint_least8_t
- type T__uintmax_t
- type T__useconds_t
- type Tblkcnt_t
- type Tblksize_t
- type Tcaddr_t
- type Tclock_t
- type Tclockid_t
- type Tdaddr_t
- type Tdev_t
- type Tdiv_t
- type Tdouble_t
- type Tfd_mask
- type Tfd_set
- type Tfloat_t
- type Tfpos_t
- type Tfsblkcnt_t
- type Tfsfilcnt_t
- type Tfsid_t
- type Tgid_t
- type Tid_t
- type Timaxdiv_t
- type Tino_t
- type Tint16_t
- type Tint32_t
- type Tint64_t
- type Tint8_t
- type Tint_fast16_t
- type Tint_fast32_t
- type Tint_fast64_t
- type Tint_fast8_t
- type Tint_least16_t
- type Tint_least32_t
- type Tint_least64_t
- type Tint_least8_t
- type Tintmax_t
- type Tintptr_t
- type Tkey_t
- type Tldiv_t
- type Tlldiv_t
- type Tlocale_t
- type Tloff_t
- type Tmode_t
- type Tnlink_t
- type Toff_t
- type Tpid_t
- type Tpthread_attr_t
- type Tpthread_barrier_t
- type Tpthread_barrierattr_t
- type Tpthread_cond_t
- type Tpthread_condattr_t
- type Tpthread_key_t
- type Tpthread_mutex_t
- type Tpthread_mutexattr_t
- type Tpthread_once_t
- type Tpthread_rwlock_t
- type Tpthread_rwlockattr_t
- type Tpthread_spinlock_t
- type Tpthread_t
- type Tptrdiff_t
- type Tquad_t
- type Tregister_t
- type Tsigset_t
- type Tsize_t
- type Tssize_t
- type Tsuseconds_t
- type Ttime_t
- type Ttimer_t
- type Tu_char
- type Tu_int
- type Tu_int16_t
- type Tu_int32_t
- type Tu_int64_t
- type Tu_int8_t
- type Tu_long
- type Tu_quad_t
- type Tu_short
- type Tuid_t
- type Tuint
- type Tuint16_t
- type Tuint32_t
- type Tuint64_t
- type Tuint8_t
- type Tuint_fast16_t
- type Tuint_fast32_t
- type Tuint_fast64_t
- type Tuint_fast8_t
- type Tuint_least16_t
- type Tuint_least32_t
- type Tuint_least64_t
- type Tuint_least8_t
- type Tuintmax_t
- type Tuintptr_t
- type Tulong
- type Tushort
- type Tva_list
- type Twchar_t
Constants ¶
const ( DALGOS_H = 0 // algos.h:21:1: DALLOC_H = 0 // alloc.h:25:1: DBASECELLS_H = 0 // baseCells.h:21:1: DBBOX_H = 0 // bbox.h:21:1: DBIG_ENDIAN = 4321 // endian.h:28:1: DBUFSIZ = 8192 // stdio.h:99:1: DBYTE_ORDER = 1234 // endian.h:30:1: DCONSTANTS_H = 0 // constants.h:21:1: DCOORDIJK_H = 0 // coordijk.h:31:1: DDBL_DECIMAL_DIG = 17 // float.h:220:1: DDBL_DIG = 15 // float.h:54:1: DDBL_HAS_SUBNORM = 1 // float.h:228:1: DDBL_MANT_DIG = 53 // float.h:40:1: DDBL_MAX_10_EXP = 308 // float.h:94:1: DDBL_MAX_EXP = 1024 // float.h:82:1: DDBL_MIN_10_EXP = -307 // float.h:74:1: DDBL_MIN_EXP = -1021 // float.h:62:1: DDECIMAL_DIG = 21 // float.h:209:1: DDECLSPEC = 0 // h3api.h:49:1: DEARTH_RADIUS_KM = 6371.007180918475 // constants.h:59:1: DEOF = -1 // stdio.h:104:1: DEPSILON = 0.0000000000000001 // constants.h:42:1: DEPSILON_DEG = .000000001 // latLng.h:31:1: DEPSILON_RAD = 0 // latLng.h:33:1: DEXIT_FAILURE = 1 // stdlib.h:92:1: DEXIT_SUCCESS = 0 // stdlib.h:93:1: DFACEIJK_H = 0 // faceijk.h:25:1: DFD_SETSIZE = 1024 // select.h:73:1: DFILENAME_MAX = 4096 // stdio_lim.h:27:1: DFLT_DECIMAL_DIG = 9 // float.h:219:1: DFLT_DIG = 6 // float.h:53:1: DFLT_EPSILON = 0 // float.h:113:1: DFLT_EVAL_METHOD = 0 // float.h:197:1: DFLT_HAS_SUBNORM = 1 // float.h:227:1: DFLT_MANT_DIG = 24 // float.h:39:1: DFLT_MAX = 0 // float.h:104:1: DFLT_MAX_10_EXP = 38 // float.h:93:1: DFLT_MAX_EXP = 128 // float.h:81:1: DFLT_MIN = 0 // float.h:121:1: DFLT_MIN_10_EXP = -37 // float.h:73:1: DFLT_MIN_EXP = -125 // float.h:61:1: DFLT_RADIX = 2 // float.h:33:1: DFLT_ROUNDS = 1 // float.h:128:1: DFLT_TRUE_MIN = 0 // float.h:235:1: DFOPEN_MAX = 16 // stdio_lim.h:37:1: DFP_ILOGB0 = -2147483648 // math.h:207:1: DFP_ILOGBNAN = -2147483648 // math.h:212:1: DFP_INFINITE = 1 // math.h:940:1: DFP_NAN = 0 // math.h:937:1: DFP_NORMAL = 4 // math.h:949:1: DFP_SUBNORMAL = 3 // math.h:946:1: DFP_ZERO = 2 // math.h:943:1: DGEOPOINT_H = 0 // latLng.h:21:1: DH3API_H = 0 // h3api.h:24:1: DH3ASSERT_H = 0 // h3Assert.h:42:1: DH3INDEX_H = 0 // h3Index.h:21:1: DH3_BC_OFFSET = 45 // h3Index.h:38:1: DH3_CELL_MODE = 1 // constants.h:81:1: DH3_DIRECTEDEDGE_MODE = 2 // constants.h:82:1: DH3_EDGE_MODE = 3 // constants.h:83:1: DH3_INIT = 35184372088831 // h3Index.h:90:1: DH3_MAX_OFFSET = 63 // h3Index.h:32:1: DH3_MODE_OFFSET = 59 // h3Index.h:35:1: DH3_NULL = 0 // h3api.h:76:1: DH3_NUM_BITS = 64 // h3Index.h:29:1: DH3_PER_DIGIT_OFFSET = 3 // h3Index.h:47:1: DH3_RESERVED_OFFSET = 56 // h3Index.h:44:1: DH3_RES_MASK = 67553994410557440 // h3Index.h:68:1: DH3_RES_MASK_NEGATIVE = 18379190079298994175 // h3Index.h:71:1: DH3_RES_OFFSET = 52 // h3Index.h:41:1: DH3_VERSION_MAJOR = 4 // h3api.h:109:1: DH3_VERSION_MINOR = 1 // h3api.h:110:1: DH3_VERSION_PATCH = 0 // h3api.h:111:1: DH3_VERTEX_MODE = 4 // constants.h:84:1: DIJ = 1 // faceijk.h:54:1: DINT16_MAX = 32767 // stdint.h:122:1: DINT16_MIN = -32768 // stdint.h:117:1: DINT32_MAX = 2147483647 // stdint.h:123:1: DINT32_MIN = -2147483648 // stdint.h:118:1: DINT64_MAX = 9223372036854775807 // stdint.h:124:1: DINT64_MIN = -9223372036854775808 // stdint.h:119:1: DINT8_MAX = 127 // stdint.h:121:1: DINT8_MIN = -128 // stdint.h:116:1: DINTMAX_MAX = 9223372036854775807 // stdint.h:199:1: DINTMAX_MIN = -9223372036854775808 // stdint.h:197:1: DINTPTR_MAX = 9223372036854775807 // stdint.h:187:1: DINTPTR_MIN = -9223372036854775808 // stdint.h:186:1: DINT_FAST16_MAX = 9223372036854775807 // stdint.h:164:1: DINT_FAST16_MIN = -9223372036854775808 // stdint.h:154:1: DINT_FAST32_MAX = 9223372036854775807 // stdint.h:165:1: DINT_FAST32_MIN = -9223372036854775808 // stdint.h:155:1: DINT_FAST64_MAX = 9223372036854775807 // stdint.h:170:1: DINT_FAST64_MIN = -9223372036854775808 // stdint.h:160:1: DINT_FAST8_MAX = 127 // stdint.h:162:1: DINT_FAST8_MIN = -128 // stdint.h:152:1: DINT_LEAST16_MAX = 32767 // stdint.h:140:1: DINT_LEAST16_MIN = -32768 // stdint.h:135:1: DINT_LEAST32_MAX = 2147483647 // stdint.h:141:1: DINT_LEAST32_MIN = -2147483648 // stdint.h:136:1: DINT_LEAST64_MAX = 9223372036854775807 // stdint.h:142:1: DINT_LEAST64_MIN = -9223372036854775808 // stdint.h:137:1: DINT_LEAST8_MAX = 127 // stdint.h:139:1: DINT_LEAST8_MIN = -128 // stdint.h:134:1: DINVALID_BASE_CELL = 127 // baseCells.h:38:1: DINVALID_FACE = -1 // faceijk.h:61:1: DINVALID_ROTATIONS = -1 // baseCells.h:49:1: DJK = 3 // faceijk.h:58:1: DKI = 2 // faceijk.h:56:1: DLDBL_DECIMAL_DIG = 21 // float.h:221:1: DLDBL_DIG = 18 // float.h:55:1: DLDBL_EPSILON = 0 // float.h:115:1: DLDBL_HAS_SUBNORM = 1 // float.h:229:1: DLDBL_MANT_DIG = 64 // float.h:41:1: DLDBL_MAX = 0 // float.h:106:1: DLDBL_MAX_10_EXP = 4932 // float.h:95:1: DLDBL_MAX_EXP = 16384 // float.h:83:1: DLDBL_MIN = 0 // float.h:123:1: DLDBL_MIN_10_EXP = -4931 // float.h:75:1: DLDBL_MIN_EXP = -16381 // float.h:63:1: DLDBL_TRUE_MIN = 0 // float.h:237:1: DLINKED_GEO_H = 0 // linkedGeo.h:21:1: DLITTLE_ENDIAN = 1234 // endian.h:27:1: DL_ctermid = 9 // stdio_lim.h:30:1: DL_tmpnam = 20 // stdio_lim.h:25:1: DMATH_ERREXCEPT = 2 // math.h:1036:1: DMATH_ERRNO = 1 // math.h:1035:1: DMAX_CELL_BNDRY_VERTS = 10 // h3api.h:117:1: DMAX_FACE_COORD = 2 // baseCells.h:46:1: DMAX_H3_RES = 15 // constants.h:67:1: DMAX_ONE_RING_SIZE = 7 // algos.c:45:1: DM_180_PI = 57.29577951308232087679815481410517033240547 // constants.h:39:1: DM_1_PI = 0.31830988618379067154 // math.h:1154:1: DM_2PI = 6.28318530717958647692528676655900576839433 // constants.h:34:1: DM_2_PI = 0.63661977236758134308 // math.h:1155:1: DM_2_SQRTPI = 1.12837916709551257390 // math.h:1156:1: DM_AP7_ROT_RADS = 0.333473172251832115336090755351601070065900389 // constants.h:50:1: DM_COS_AP7_ROT = 0.9449111825230680680167902 // constants.h:56:1: DM_E = 2.7182818284590452354 // math.h:1146:1: DM_LN10 = 2.30258509299404568402 // math.h:1150:1: DM_LN2 = 0.69314718055994530942 // math.h:1149:1: DM_LOG10E = 0.43429448190325182765 // math.h:1148:1: DM_LOG2E = 1.4426950408889634074 // math.h:1147:1: DM_PI = 3.14159265358979323846 // math.h:1151:1: DM_PI_180 = 0.0174532925199432957692369076848861271111 // constants.h:37:1: DM_PI_2 = 1.57079632679489661923 // math.h:1152:1: DM_PI_4 = 0.78539816339744830962 // math.h:1153:1: DM_SIN60 = 0 // constants.h:46:1: DM_SIN_AP7_ROT = 0.3273268353539885718950318 // constants.h:53:1: DM_SQRT1_2 = 0.70710678118654752440 // math.h:1158:1: DM_SQRT2 = 1.41421356237309504880 // math.h:1157:1: DM_SQRT3_2 = 0.8660254037844386467637231707529361834714 // constants.h:44:1: DNUM_BASE_CELLS = 122 // constants.h:72:1: DNUM_HEX_VERTS = 6 // constants.h:74:1: DNUM_ICOSA_FACES = 20 // constants.h:70:1: DNUM_PENTAGONS = 12 // constants.h:78:1: DNUM_PENT_VERTS = 5 // constants.h:76:1: DPDP_ENDIAN = 3412 // endian.h:29:1: DPOLYGON_H = 0 // polygon.h:21:1: DPOLYGON_TO_CELLS_BUFFER = 12 // algos.c:46:1: DPTRDIFF_MAX = 9223372036854775807 // stdint.h:210:1: DPTRDIFF_MIN = -9223372036854775808 // stdint.h:209:1: DP_tmpdir = "/tmp" // stdio.h:120:1: DRAND_MAX = 2147483647 // stdlib.h:87:1: DRES0_U_GNOMONIC = 0.38196601125010500003 // constants.h:64:1: DSEEK_CUR = 1 // stdio.h:110:1: DSEEK_END = 2 // stdio.h:111:1: DSEEK_SET = 0 // stdio.h:109:1: DSIG_ATOMIC_MAX = 2147483647 // stdint.h:223:1: DSIG_ATOMIC_MIN = -2147483648 // stdint.h:222:1: DSIZE_MAX = 18446744073709551615 // stdint.h:227:1: DTMP_MAX = 238328 // stdio_lim.h:26:1: DUINT16_MAX = 65535 // stdint.h:128:1: DUINT32_MAX = 4294967295 // stdint.h:129:1: DUINT64_MAX = 18446744073709551615 // stdint.h:130:1: DUINT8_MAX = 255 // stdint.h:127:1: DUINTMAX_MAX = 18446744073709551615 // stdint.h:202:1: DUINTPTR_MAX = 18446744073709551615 // stdint.h:188:1: DUINT_FAST16_MAX = 18446744073709551615 // stdint.h:175:1: DUINT_FAST32_MAX = 18446744073709551615 // stdint.h:176:1: DUINT_FAST64_MAX = 18446744073709551615 // stdint.h:181:1: DUINT_FAST8_MAX = 255 // stdint.h:173:1: DUINT_LEAST16_MAX = 65535 // stdint.h:146:1: DUINT_LEAST32_MAX = 4294967295 // stdint.h:147:1: DUINT_LEAST64_MAX = 18446744073709551615 // stdint.h:148:1: DUINT_LEAST8_MAX = 255 // stdint.h:145:1: DVEC2D_H = 0 // vec2d.h:21:1: DVERTEX_GRAPH_H = 0 // vertexGraph.h:21:1: DWCHAR_MAX = 2147483647 // stdint.h:240:1: DWCHAR_MIN = -2147483648 // stdint.h:239:1: DWCONTINUED = 8 // waitflags.h:32:1: DWEXITED = 4 // waitflags.h:31:1: DWINT_MAX = 4294967295 // stdint.h:245:1: DWINT_MIN = 0 // stdint.h:244:1: DWNOHANG = 1 // waitflags.h:25:1: DWNOWAIT = 0x01000000 // waitflags.h:33:1: DWSTOPPED = 2 // waitflags.h:30:1: DWUNTRACED = 2 // waitflags.h:26:1: D_ALLOCA_H = 1 // alloca.h:19:1: D_ASSERT_H = 1 // assert.h:34:1: D_ATFILE_SOURCE = 1 // features.h:352:1: D_BITS_ATOMIC_WIDE_COUNTER_H = 0 // atomic_wide_counter.h:20:1: D_BITS_BYTESWAP_H = 1 // byteswap.h:24:1: D_BITS_ENDIANNESS_H = 1 // endianness.h:2:1: D_BITS_ENDIAN_H = 1 // endian.h:20:1: D_BITS_FLOATN_COMMON_H = 0 // floatn-common.h:21:1: D_BITS_FLOATN_H = 0 // floatn.h:20:1: D_BITS_LIBM_SIMD_DECL_STUBS_H = 1 // libm-simd-decl-stubs.h:34:1: D_BITS_PTHREADTYPES_ARCH_H = 1 // pthreadtypes-arch.h:19:1: D_BITS_PTHREADTYPES_COMMON_H = 1 // pthreadtypes.h:20:1: D_BITS_STDINT_INTN_H = 1 // stdint-intn.h:20:1: D_BITS_STDINT_UINTN_H = 1 // stdint-uintn.h:20:1: D_BITS_STDIO_LIM_H = 1 // stdio_lim.h:19:1: D_BITS_TIME64_H = 1 // time64.h:24:1: D_BITS_TYPESIZES_H = 1 // typesizes.h:24:1: D_BITS_TYPES_H = 1 // types.h:24:1: D_BITS_TYPES_LOCALE_T_H = 1 // locale_t.h:20:1: D_BITS_TYPES___LOCALE_T_H = 1 // __locale_t.h:20:1: D_BITS_UINTN_IDENTITY_H = 1 // uintn-identity.h:24:1: D_BITS_WCHAR_H = 1 // wchar.h:20:1: D_BSD_SIZE_T_ = 0 // stddef.h:193:1: D_BSD_SIZE_T_DEFINED_ = 0 // stddef.h:196:1: D_DEFAULT_SOURCE = 1 // features.h:237:1: D_ENDIAN_H = 1 // endian.h:19:1: D_FEATURES_H = 1 // features.h:19:1: D_FILE_OFFSET_BITS = 64 // <builtin>:25:1: D_FLOAT_H___ = 0 // float.h:29:1: D_GCC_SIZE_T = 0 // stddef.h:200:1: D_GCC_WCHAR_T = 0 // stddef.h:280:1: D_GCC_WRAP_STDINT_H = 0 // stdint.h:13:1: D_IOFBF = 0 // stdio.h:93:1: D_IOLBF = 1 // stdio.h:94:1: D_IONBF = 2 // stdio.h:95:1: D_IO_EOF_SEEN = 0x0010 // struct_FILE.h:111:1: D_IO_ERR_SEEN = 0x0020 // struct_FILE.h:114:1: D_IO_USER_LOCK = 0x8000 // struct_FILE.h:117:1: D_LP64 = 1 // <predefined>:313:1: D_MATH_H = 1 // math.h:24:1: D_POSIX_C_SOURCE = 200809 // features.h:291:1: D_POSIX_SOURCE = 1 // features.h:289:1: D_RWLOCK_INTERNAL_H = 0 // struct_rwlock.h:21:1: D_SIZET_ = 0 // stddef.h:201:1: D_SIZE_T = 0 // stddef.h:187:1: D_SIZE_T_ = 0 // stddef.h:192:1: D_SIZE_T_DECLARED = 0 // stddef.h:197:1: D_SIZE_T_DEFINED = 0 // stddef.h:195:1: D_SIZE_T_DEFINED_ = 0 // stddef.h:194:1: D_STDBOOL_H = 0 // stdbool.h:29:1: D_STDC_PREDEF_H = 1 // <predefined>:175:1: D_STDINT_H = 1 // stdint.h:23:1: D_STDIO_H = 1 // stdio.h:24:1: D_STDLIB_H = 1 // stdlib.h:36:1: D_STRINGS_H = 1 // strings.h:19:1: D_STRING_H = 1 // string.h:23:1: D_STRUCT_TIMESPEC = 1 // struct_timespec.h:3:1: D_SYS_CDEFS_H = 1 // cdefs.h:20:1: D_SYS_SELECT_H = 1 // select.h:22:1: D_SYS_SIZE_T_H = 0 // stddef.h:188:1: D_SYS_TYPES_H = 1 // types.h:23:1: D_THREAD_MUTEX_INTERNAL_H = 1 // struct_mutex.h:20:1: D_THREAD_SHARED_TYPES_H = 1 // thread-shared-types.h:20:1: D_T_SIZE = 0 // stddef.h:190:1: D_T_SIZE_ = 0 // stddef.h:189:1: D_T_WCHAR = 0 // stddef.h:271:1: D_T_WCHAR_ = 0 // stddef.h:270:1: D_VA_LIST_DEFINED = 0 // stdio.h:53:1: D_WCHAR_T = 0 // stddef.h:269:1: D_WCHAR_T_ = 0 // stddef.h:273:1: D_WCHAR_T_DECLARED = 0 // stddef.h:281:1: D_WCHAR_T_DEFINED = 0 // stddef.h:276:1: D_WCHAR_T_DEFINED_ = 0 // stddef.h:275:1: D_WCHAR_T_H = 0 // stddef.h:277:1: Dfalse = 0 // stdbool.h:39:1: Dlinux = 1 // <predefined>:256:1: Dmath_errhandling = 3 // math.h:1048:1: Dtrue = 1 // stdbool.h:38:1: Dunix = 1 // <predefined>:192:1: DINT32_MAX_3 = 715827882 // coordijk.c:33:1: DMATHEXTENSIONS_H = 0 // mathExtensions.h:21:1: DH3VERTEX_H = 0 // vertex.h:21:1: DINVALID_VERTEX_NUM = -1 // vertex.h:36:1: DMAX_BASE_CELL_FACES = 5 // vertex.h:39:1: DPRIX16 = "X" // inttypes.h:135:1: DPRIX32 = "X" // inttypes.h:136:1: DPRIX8 = "X" // inttypes.h:134:1: DPRIXFAST8 = "X" // inttypes.h:144:1: DPRIXLEAST16 = "X" // inttypes.h:140:1: DPRIXLEAST32 = "X" // inttypes.h:141:1: DPRIXLEAST8 = "X" // inttypes.h:139:1: DPRId16 = "d" // inttypes.h:55:1: DPRId32 = "d" // inttypes.h:56:1: DPRId8 = "d" // inttypes.h:54:1: DPRIdFAST8 = "d" // inttypes.h:64:1: DPRIdLEAST16 = "d" // inttypes.h:60:1: DPRIdLEAST32 = "d" // inttypes.h:61:1: DPRIdLEAST8 = "d" // inttypes.h:59:1: DPRIi16 = "i" // inttypes.h:71:1: DPRIi32 = "i" // inttypes.h:72:1: DPRIi8 = "i" // inttypes.h:70:1: DPRIiFAST8 = "i" // inttypes.h:80:1: DPRIiLEAST16 = "i" // inttypes.h:76:1: DPRIiLEAST32 = "i" // inttypes.h:77:1: DPRIiLEAST8 = "i" // inttypes.h:75:1: DPRIo16 = "o" // inttypes.h:87:1: DPRIo32 = "o" // inttypes.h:88:1: DPRIo8 = "o" // inttypes.h:86:1: DPRIoFAST8 = "o" // inttypes.h:96:1: DPRIoLEAST16 = "o" // inttypes.h:92:1: DPRIoLEAST32 = "o" // inttypes.h:93:1: DPRIoLEAST8 = "o" // inttypes.h:91:1: DPRIu16 = "u" // inttypes.h:103:1: DPRIu32 = "u" // inttypes.h:104:1: DPRIu8 = "u" // inttypes.h:102:1: DPRIuFAST8 = "u" // inttypes.h:112:1: DPRIuLEAST16 = "u" // inttypes.h:108:1: DPRIuLEAST32 = "u" // inttypes.h:109:1: DPRIuLEAST8 = "u" // inttypes.h:107:1: DPRIx16 = "x" // inttypes.h:119:1: DPRIx32 = "x" // inttypes.h:120:1: DPRIx8 = "x" // inttypes.h:118:1: DPRIxFAST8 = "x" // inttypes.h:128:1: DPRIxLEAST16 = "x" // inttypes.h:124:1: DPRIxLEAST32 = "x" // inttypes.h:125:1: DPRIxLEAST8 = "x" // inttypes.h:123:1: DSCNd16 = "hd" // inttypes.h:172:1: DSCNd32 = "d" // inttypes.h:173:1: DSCNd8 = "hhd" // inttypes.h:171:1: DSCNdFAST8 = "hhd" // inttypes.h:181:1: DSCNdLEAST16 = "hd" // inttypes.h:177:1: DSCNdLEAST32 = "d" // inttypes.h:178:1: DSCNdLEAST8 = "hhd" // inttypes.h:176:1: DSCNi16 = "hi" // inttypes.h:188:1: DSCNi32 = "i" // inttypes.h:189:1: DSCNi8 = "hhi" // inttypes.h:187:1: DSCNiFAST8 = "hhi" // inttypes.h:197:1: DSCNiLEAST16 = "hi" // inttypes.h:193:1: DSCNiLEAST32 = "i" // inttypes.h:194:1: DSCNiLEAST8 = "hhi" // inttypes.h:192:1: DSCNo16 = "ho" // inttypes.h:220:1: DSCNo32 = "o" // inttypes.h:221:1: DSCNo8 = "hho" // inttypes.h:219:1: DSCNoFAST8 = "hho" // inttypes.h:229:1: DSCNoLEAST16 = "ho" // inttypes.h:225:1: DSCNoLEAST32 = "o" // inttypes.h:226:1: DSCNoLEAST8 = "hho" // inttypes.h:224:1: DSCNu16 = "hu" // inttypes.h:204:1: DSCNu32 = "u" // inttypes.h:205:1: DSCNu8 = "hhu" // inttypes.h:203:1: DSCNuFAST8 = "hhu" // inttypes.h:213:1: DSCNuLEAST16 = "hu" // inttypes.h:209:1: DSCNuLEAST32 = "u" // inttypes.h:210:1: DSCNuLEAST8 = "hhu" // inttypes.h:208:1: DSCNx16 = "hx" // inttypes.h:236:1: DSCNx32 = "x" // inttypes.h:237:1: DSCNx8 = "hhx" // inttypes.h:235:1: DSCNxFAST8 = "hhx" // inttypes.h:245:1: DSCNxLEAST16 = "hx" // inttypes.h:241:1: DSCNxLEAST32 = "x" // inttypes.h:242:1: DSCNxLEAST8 = "hhx" // inttypes.h:240:1: D_INTTYPES_H = 1 // inttypes.h:23:1: DM_SQRT7 = 2.6457513110645905905016157536392604257102 // faceijk.c:36:1: DVEC3D_H = 0 // vec3d.h:21:1: DITERATORS_H = 0 // iterators.h:23:1: DDIRECTION_INDEX_OFFSET = 2 // vertex.c:32:1: )
const ( //* H3 digit in center CENTER_DIGIT = 0 //* H3 digit in k-axes direction K_AXES_DIGIT = 1 //* H3 digit in j-axes direction J_AXES_DIGIT = 2 //* H3 digit in j == k direction JK_AXES_DIGIT = 3 // 3 //* H3 digit in i-axes direction I_AXES_DIGIT = 4 //* H3 digit in i == k direction IK_AXES_DIGIT = 5 // 5 //* H3 digit in i == j direction IJ_AXES_DIGIT = 6 // 6 //* H3 digit in the invalid direction INVALID_DIGIT = 7 // * Valid digits will be less than this value. Same value as INVALID_DIGIT. NUM_DIGITS = 7 //* Child digit which is skipped for pentagons PENTAGON_SKIPPED_DIGIT = 1 )
* @brief H3 digit representing ijk+ axes direction. Values will be within the lowest 3 bits of an integer.
const ( //* No overage (on original face) NO_OVERAGE = 0 //* On face edge (only occurs on substrate grids) FACE_EDGE = 1 //* Overage on new face interior NEW_FACE = 2 )
* Digit representing overage type
const ( FP_NAN = 0 FP_INFINITE = 1 FP_ZERO = 2 FP_SUBNORMAL = 3 FP_NORMAL = 4 )
All floating-point numbers can be put in one of these categories.
const ( E_SUCCESS = 0 // Success (no error) E_FAILED = 1 // The operation failed but a more specific error is not available E_DOMAIN = 2 // Argument was outside of acceptable range (when a more // specific error code is not available) E_LATLNG_DOMAIN = 3 // Latitude or longitude arguments were outside of acceptable range E_RES_DOMAIN = 4 // Resolution argument was outside of acceptable range E_CELL_INVALID = 5 // `H3Index` cell argument was not valid E_DIR_EDGE_INVALID = 6 // `H3Index` directed edge argument was not valid E_UNDIR_EDGE_INVALID = 7 // `H3Index` undirected edge argument was not valid E_VERTEX_INVALID = 8 // `H3Index` vertex argument was not valid E_PENTAGON = 9 // Pentagon distortion was encountered which the algorithm // could not handle it E_DUPLICATE_INPUT = 10 // Duplicate input was encountered in the arguments // and the algorithm could not handle it E_NOT_NEIGHBORS = 11 // `H3Index` cell arguments were not neighbors E_RES_MISMATCH = 12 // `H3Index` cell arguments had incompatible resolutions E_MEMORY_ALLOC = 13 // Necessary memory allocation failed E_MEMORY_BOUNDS = 14 // Bounds of provided memory were not large enough E_OPTION_INVALID = 15 )
Variables ¶
var CAPI = map[string]struct{}{}/* 206 elements not displayed */
var XFAILED_DIRECTIONS = [7][7]uint8{ {uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse)}, {uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse)}, {uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dtrue), uint8(Dtrue), uint8(Dfalse)}, {uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dtrue), uint8(Dfalse), uint8(Dtrue)}, {uint8(Dfalse), uint8(Dfalse), uint8(Dtrue), uint8(Dtrue), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse)}, {uint8(Dfalse), uint8(Dfalse), uint8(Dtrue), uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dtrue)}, {uint8(Dfalse), uint8(Dfalse), uint8(Dfalse), uint8(Dtrue), uint8(Dfalse), uint8(Dtrue), uint8(Dfalse)}, } /* localij.c:105:12 */
* Prohibited directions when unfolding a pentagon.
Indexes by two directions, both relative to the pentagon base cell. The first is the direction of the origin index and the second is the direction of the index to unfold. Direction refers to the direction from base cell to base cell if the indexes are on different base cells, or the leading digit if within the pentagon base cell.
This previously included a Class II/Class III check but these were removed due to failure cases. It's possible this could be restricted to a narrower set of a failure cases. Currently, the logic is any unfolding across more than one icosahedron face is not permitted.
var XPENTAGON_ROTATIONS = [7][7]int32{ {0, -1, 0, 0, 0, 0, 0}, {-1, -1, -1, -1, -1, -1, -1}, {0, -1, 0, 0, 0, 1, 0}, {0, -1, 0, 0, 1, 1, 0}, {0, -1, 0, 5, 0, 0, 0}, {0, -1, 5, 5, 0, 0, 0}, {0, -1, 0, 0, 0, 0, 0}, } /* localij.c:39:11 */
* Origin leading digit -> index leading digit -> rotations 60 cw Either being 1 (K axis) is invalid. No good default at 0.
var XPENTAGON_ROTATIONS_REVERSE = [7][7]int32{ {0, 0, 0, 0, 0, 0, 0}, {-1, -1, -1, -1, -1, -1, -1}, {0, 1, 0, 0, 0, 0, 0}, {0, 1, 0, 0, 0, 1, 0}, {0, 5, 0, 0, 0, 0, 0}, {0, 5, 0, 5, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0}, } /* localij.c:53:11 */
* Reverse base cell direction -> leading index digit -> rotations 60 ccw. For reversing the rotation introduced in PENTAGON_ROTATIONS when the origin is on a pentagon (regardless of the base cell of the index.)
var XPENTAGON_ROTATIONS_REVERSE_NONPOLAR = [7][7]int32{ {0, 0, 0, 0, 0, 0, 0}, {-1, -1, -1, -1, -1, -1, -1}, {0, 1, 0, 0, 0, 0, 0}, {0, 1, 0, 0, 0, 1, 0}, {0, 5, 0, 0, 0, 0, 0}, {0, 1, 0, 5, 1, 1, 0}, {0, 0, 0, 0, 0, 0, 0}, } /* localij.c:67:11 */
* Reverse base cell direction -> leading index digit -> rotations 60 ccw. For reversing the rotation introduced in PENTAGON_ROTATIONS when the index is on a pentagon and the origin is not.
var XPENTAGON_ROTATIONS_REVERSE_POLAR = [7][7]int32{ {0, 0, 0, 0, 0, 0, 0}, {-1, -1, -1, -1, -1, -1, -1}, {0, 1, 1, 1, 1, 1, 1}, {0, 1, 0, 0, 0, 1, 0}, {0, 1, 0, 0, 1, 1, 1}, {0, 1, 0, 5, 1, 1, 0}, {0, 1, 1, 0, 1, 1, 1}, } /* localij.c:81:11 */
* Reverse base cell direction -> leading index digit -> rotations 60 ccw. For reversing the rotation introduced in PENTAGON_ROTATIONS when the index is on a polar pentagon and the origin is not.
var XbaseCellData = [122]TBaseCellData{} /* baseCells.c:697:20 *//* 122 elements not displayed */
* @brief Resolution 0 base cell data table.
For each base cell, gives the "home" face and ijk+ coordinates on that face, whether or not the base cell is a pentagon. Additionally, if the base cell is a pentagon, the two cw offset rotation adjacent faces are given (-1 indicates that no cw offset rotation faces exist for this base cell).
var XbaseCellNeighbor60CCWRots = [122][7]int32{} /* baseCells.c:171:11 *//* 122 elements not displayed */
* @brief Neighboring base cell rotations in each IJK direction.
For each base cell, for each direction, the number of 60 degree CCW rotations to the coordinate system of the neighbor is given. -1 indicates there is no neighbor in that direction.
var XbaseCellNeighbors = [122][7]int32{} /* baseCells.c:38:11 *//* 122 elements not displayed */
* @brief Neighboring base cell ID in each IJK direction.
For each base cell, for each direction, the neighboring base cell ID is given. 127 indicates there is no neighbor in that direction.
var XfaceCenterGeo = [20]TLatLng{ {Flat: 0.803582649718989942, Flng: 1.248397419617396099}, {Flat: 1.307747883455638156, Flng: 2.536945009877921159}, {Flat: 1.054751253523952054, Flng: -1.347517358900396623}, {Flat: 0.600191595538186799, Flng: -0.450603909469755746}, {Flat: 0.491715428198773866, Flng: 0.401988202911306943}, {Flat: 0.172745327415618701, Flng: 1.678146885280433686}, {Flat: 0.605929321571350690, Flng: 2.953923329812411617}, {Flat: 0.427370518328979641, Flng: -1.888876200336285401}, {Flat: -0.079066118549212831, Flng: -0.733429513380867741}, {Flat: -0.230961644455383637, Flng: 0.506495587332349035}, {Flat: 0.079066118549212831, Flng: 2.408163140208925497}, {Flat: 0.230961644455383637, Flng: -2.635097066257444203}, {Flat: -0.172745327415618701, Flng: -1.463445768309359553}, {Flat: -0.605929321571350690, Flng: -0.187669323777381622}, {Flat: -0.427370518328979641, Flng: 1.252716453253507838}, {Flat: -0.600191595538186799, Flng: 2.690988744120037492}, {Flat: -0.491715428198773866, Flng: -2.739604450678486295}, {Flat: -0.803582649718989942, Flng: -1.893195233972397139}, {Flat: -1.307747883455638156, Flng: -0.604647643711872080}, {Flat: -1.054751253523952054, Flng: 1.794075294689396615}, } /* faceijk.c:39:14 */
* @brief icosahedron face centers in lat/lng radians
Functions ¶
func X_baseCellIsCwOffset ¶
* @brief Return whether or not the tested face is a cw offset face.
func X_baseCellToCCWrot60 ¶
* @brief Given a base cell and the face it appears on, return
the number of 60' ccw rotations for that base cell's coordinate system.
@returns The number of rotations, or INVALID_ROTATIONS if the base
cell is not found on the given face
func X_baseCellToFaceIjk ¶
* @brief Find the FaceIJK given a base cell.
func X_downAp3 ¶
* Find the normalized ijk coordinates of the hex centered on the indicated hex at the next finer aperture 3 counter-clockwise resolution. Works in place.
@param ijk The ijk coordinates.
func X_downAp3r ¶
* Find the normalized ijk coordinates of the hex centered on the indicated hex at the next finer aperture 3 clockwise resolution. Works in place.
@param ijk The ijk coordinates.
func X_downAp7 ¶
* Find the normalized ijk coordinates of the hex centered on the indicated hex at the next finer aperture 7 counter-clockwise resolution. Works in place.
@param ijk The ijk coordinates.
func X_downAp7r ¶
* Find the normalized ijk coordinates of the hex centered on the indicated hex at the next finer aperture 7 clockwise resolution. Works in place.
@param ijk The ijk coordinates.
func X_faceIjkPentToCellBoundary ¶
func X_faceIjkPentToCellBoundary(tls *libc.TLS, h uintptr, res int32, start int32, length int32, g uintptr)
* Generates the cell boundary in spherical coordinates for a pentagonal cell given by a FaceIJK address at a specified resolution.
@param h The FaceIJK address of the pentagonal cell. @param res The H3 resolution of the cell. @param start The first topological vertex to return. @param length The number of topological vertexes to return. @param g The spherical coordinates of the cell boundary.
func X_faceIjkPentToVerts ¶
* Get the vertices of a pentagon cell as substrate FaceIJK addresses
@param fijk The FaceIJK address of the cell. @param res The H3 resolution of the cell. This may be adjusted if
necessary for the substrate grid resolution.
@param fijkVerts Output array for the vertices
func X_faceIjkToBaseCell ¶
* @brief Find base cell given FaceIJK.
Given the face number and a resolution 0 ijk+ coordinate in that face's face-centered ijk coordinate system, return the base cell located at that coordinate.
Valid ijk+ lookup coordinates are from (0, 0, 0) to (2, 2, 2).
func X_faceIjkToBaseCellCCWrot60 ¶
* @brief Find base cell given FaceIJK.
Given the face number and a resolution 0 ijk+ coordinate in that face's face-centered ijk coordinate system, return the number of 60' ccw rotations to rotate into the coordinate system of the base cell at that coordinates.
Valid ijk+ lookup coordinates are from (0, 0, 0) to (2, 2, 2).
func X_faceIjkToCellBoundary ¶
func X_faceIjkToCellBoundary(tls *libc.TLS, h uintptr, res int32, start int32, length int32, g uintptr)
* Generates the cell boundary in spherical coordinates for a cell given by a FaceIJK address at a specified resolution.
@param h The FaceIJK address of the cell. @param res The H3 resolution of the cell. @param start The first topological vertex to return. @param length The number of topological vertexes to return. @param g The spherical coordinates of the cell boundary.
func X_faceIjkToGeo ¶
* Determines the center point in spherical coordinates of a cell given by a FaceIJK address at a specified resolution.
@param h The FaceIJK address of the cell. @param res The H3 resolution of the cell. @param g The spherical coordinates of the cell center point.
func X_faceIjkToVerts ¶
* Get the vertices of a cell as substrate FaceIJK addresses
@param fijk The FaceIJK address of the cell. @param res The H3 resolution of the cell. This may be adjusted if
necessary for the substrate grid resolution.
@param fijkVerts Output array for the vertices
func X_geoAzDistanceRads ¶
* Computes the point on the sphere a specified azimuth and distance from another point.
@param p1 The first spherical coordinates. @param az The desired azimuth from p1. @param distance The desired distance from p1, must be non-negative. @param p2 The spherical coordinates at the desired azimuth and distance from p1.
func X_geoAzimuthRads ¶
* Determines the azimuth to p2 from p1 in radians.
@param p1 The first spherical coordinates. @param p2 The second spherical coordinates. @return The azimuth in radians from p1 to p2.
func X_geoToClosestFace ¶
* Encodes a coordinate on the sphere to the corresponding icosahedral face and containing the squared euclidean distance to that face center.
@param g The spherical coordinates to encode. @param face The icosahedral face containing the spherical coordinates. @param sqd The squared euclidean distance to its icosahedral face center.
func X_geoToFaceIjk ¶
* Encodes a coordinate on the sphere to the FaceIJK address of the containing cell at the specified resolution.
@param g The spherical coordinates to encode. @param res The desired H3 resolution for the encoding. @param h The FaceIJK address of the containing cell at resolution res.
func X_geoToHex2d ¶
* Encodes a coordinate on the sphere to the corresponding icosahedral face and containing 2D hex coordinates relative to that face center.
@param g The spherical coordinates to encode. @param res The desired H3 resolution for the encoding. @param face The icosahedral face containing the spherical coordinates. @param v The 2D hex coordinates of the cell containing the point.
func X_geoToVec3d ¶
* Calculate the 3D coordinate on unit sphere from the latitude and longitude.
@param geo The latitude and longitude of the point. @param v The 3D coordinate of the point.
func X_getBaseCellNeighbor ¶
func X_getBaseCellNeighbor(tls *libc.TLS, baseCell int32, dir TDirection) int32
* @brief Return the neighboring base cell in the given direction.
func X_h3ToFaceIjkWithInitializedFijk ¶
* Convert an H3Index to the FaceIJK address on a specified icosahedral face. @param h The H3Index. @param fijk The FaceIJK address, initialized with the desired face
and normalized base cell coordinates.
@return Returns 1 if the possibility of overage exists, otherwise 0.
func X_hex2dToCoordIJK ¶
* Determine the containing hex in ijk+ coordinates for a 2D cartesian coordinate vector (from DGGRID).
@param v The 2D cartesian coordinate vector. @param h The ijk+ coordinates of the containing hex.
func X_hex2dToGeo ¶
* Determines the center point in spherical coordinates of a cell given by 2D hex coordinates on a particular icosahedral face.
@param v The 2D hex coordinates of the cell. @param face The icosahedral face upon which the 2D hex coordinate system is
centered.
@param res The H3 resolution of the cell. @param substrate Indicates whether or not this grid is actually a substrate
grid relative to the specified resolution.
@param g The spherical coordinates of the cell center point.
func X_hexRadiusKm ¶
* _hexRadiusKm returns the radius of a given hexagon in Km
@param h3Index the index of the hexagon @return the radius of the hexagon in Km
func X_ijkAdd ¶
* Add two ijk coordinates.
@param h1 The first set of ijk coordinates. @param h2 The second set of ijk coordinates. @param sum The sum of the two sets of ijk coordinates.
func X_ijkMatches ¶
* Returns whether or not two ijk coordinates contain exactly the same component values.
@param c1 The first set of ijk coordinates. @param c2 The second set of ijk coordinates. @return 1 if the two addresses match, 0 if they do not.
func X_ijkNormalize ¶
* Normalizes ijk coordinates by setting the components to the smallest possible values. Works in place.
This function does not protect against signed integer overflow. The caller must ensure that none of (i - j), (i - k), (j - i), (j - k), (k - i), (k - j) will overflow. This function may be changed in the future to make that check itself and return an error code.
@param c The ijk coordinates to normalize.
func X_ijkNormalizeCouldOverflow ¶
* Returns true if _ijkNormalize with the given input could have a signed integer overflow. Assumes k is set to 0.
func X_ijkRotate60ccw ¶
* Rotates ijk coordinates 60 degrees counter-clockwise. Works in place.
@param ijk The ijk coordinates.
func X_ijkRotate60cw ¶
* Rotates ijk coordinates 60 degrees clockwise. Works in place.
@param ijk The ijk coordinates.
func X_ijkScale ¶
* Uniformly scale ijk coordinates by a scalar. Works in place.
@param c The ijk coordinates to scale. @param factor The scaling factor.
func X_ijkSub ¶
* Subtract two ijk coordinates.
@param h1 The first set of ijk coordinates. @param h2 The second set of ijk coordinates. @param diff The difference of the two sets of ijk coordinates (h1 - h2).
func X_ijkToHex2d ¶
* Find the center point in 2D cartesian coordinates of a hex.
@param h The ijk coordinates of the hex. @param v The 2D cartesian coordinates of the hex center point.
func X_initVertexNode ¶
func X_isBaseCellPentagon ¶
* @brief Return whether or not the indicated base cell is a pentagon.
func X_isBaseCellPolarPentagon ¶
* @brief Return whether the indicated base cell is a pentagon where all neighbors are oriented towards it.
func X_neighbor ¶
func X_neighbor(tls *libc.TLS, ijk uintptr, digit TDirection)
* Find the normalized ijk coordinates of the hex in the specified digit direction from the specified ijk coordinates. Works in place.
@param ijk The ijk coordinates. @param digit The digit direction from the original ijk coordinates.
func X_pointSquareDist ¶
* Calculate the square of the distance between two 3D coordinates.
@param v1 The first 3D coordinate. @param v2 The second 3D coordinate. @return The square of the distance between the given points.
func X_posAngleRads ¶
* Normalizes radians to a value between 0.0 and two PI.
@param rads The input radians value. @return The normalized radians value.
func X_setGeoRads ¶
* Set the components of spherical coordinates in radians.
@param p The spherical coordinates. @param latRads The desired latitude in decimal radians. @param lngRads The desired longitude in decimal radians.
func X_setIJK ¶
* Sets an IJK coordinate to the specified component values.
@param ijk The IJK coordinate to set. @param i The desired i component value. @param j The desired j component value. @param k The desired k component value.
func X_square ¶
* Square of a number
@param x The input number. @return The square of the input number.
func X_upAp7 ¶
* Find the normalized ijk coordinates of the indexing parent of a cell in a counter-clockwise aperture 7 grid. Works in place.
@param ijk The ijk coordinates.
func X_upAp7r ¶
* Find the normalized ijk coordinates of the indexing parent of a cell in a clockwise aperture 7 grid. Works in place.
@param ijk The ijk coordinates.
func X_v2dAlmostEquals ¶
* Whether two 2D vectors are almost equal, within some threshold @param v1 First vector to compare @param v2 Second vector to compare @return Whether the vectors are almost equal
func X_v2dIntersect ¶
* Finds the intersection between two lines. Assumes that the lines intersect and that the intersection is not at an endpoint of either line. @param p0 The first endpoint of the first line. @param p1 The second endpoint of the first line. @param p2 The first endpoint of the second line. @param p3 The second endpoint of the second line. @param inter The intersection point.
func X_v2dMag ¶
* Calculates the magnitude of a 2D cartesian vector. @param v The 2D cartesian vector. @return The magnitude of the vector.
func X_vertexGraphToLinkedGeo ¶
* Internal: Create a LinkedGeoPolygon from a vertex graph. It is the responsibility of the caller to call destroyLinkedMultiPolygon on the populated linked geo structure, or the memory for that structure will not be freed. @private @param graph Input graph @param out Output polygon
func XaddLinkedCoord ¶
* Add a new linked coordinate to the current loop @param loop Loop to add coordinate to @param vertex Coordinate to add @return Pointer to the coordinate
func XaddLinkedLoop ¶
* Add an existing linked loop to the current polygon @param polygon Polygon to add loop to @return Pointer to loop
func XaddNewLinkedLoop ¶
* Add a new linked loop to the current polygon @param polygon Polygon to add loop to @return Pointer to loop
func XaddNewLinkedPolygon ¶
* Add a linked polygon to the current polygon @param polygon Polygon to add link to @return Pointer to new polygon
func XaddVertexNode ¶
* Add a edge to the graph @param graph Graph to add node to @param fromVtx Start vertex @param toVtx End vertex @return Pointer to the new node
func XbboxCenter ¶
* Get the center of a bounding box @param bbox Input bounding box @param center Output center coordinate
func XbboxContains ¶
* Whether the bounding box contains a given point @param bbox Bounding box @param point Point to test @return Whether the point is contained
func XbboxEquals ¶
* Whether two bounding boxes are strictly equal @param b1 Bounding box 1 @param b2 Bounding box 2 @return Whether the boxes are equal
func XbboxFromGeoLoop ¶
* Create a bounding box from a simple polygon loop. Known limitations:
- Does not support polygons with two adjacent points > 180 degrees of longitude apart. These will be interpreted as crossing the antimeridian.
- Does not currently support polygons containing a pole.
@param loop Loop of coordinates @param bbox Output bbox
func XbboxFromLinkedGeoLoop ¶
* Create a bounding box from a simple polygon loop. Known limitations:
- Does not support polygons with two adjacent points > 180 degrees of longitude apart. These will be interpreted as crossing the antimeridian.
- Does not currently support polygons containing a pole.
@param loop Loop of coordinates @param bbox Output bbox
func XbboxIsTransmeridian ¶
* Whether the given bounding box crosses the antimeridian @param bbox Bounding box to inspect @return is transmeridian
func XbboxesFromGeoPolygon ¶
* Create a bounding box from a GeoPolygon @param polygon Input GeoPolygon @param bboxes Output bboxes, one for the outer loop and one for each hole
func XconstrainLat ¶
* constrainLat makes sure latitudes are in the proper bounds
@param lat The original lat value @return The corrected lat value
func XconstrainLng ¶
* constrainLng makes sure longitudes are in the proper bounds
@param lng The origin lng value @return The corrected lng value
func XcountLinkedCoords ¶
* Count the number of coordinates in a loop @param loop Loop to count coordinates for @return Count
func XcountLinkedLoops ¶
* Count the number of linked loops in a polygon @param polygon Polygon to count loops for @return Count
func XcountLinkedPolygons ¶
* Count the number of polygons in a linked list @param polygon Starting polygon @return Count
func XcubeToIjk ¶
* Convert cube coordinates to IJK coordinates, in place @param ijk Coordinate to convert
func XdegsToRads ¶
* Convert from decimal degrees to radians.
@param degrees The decimal degrees. @return The corresponding radians.
func XdestroyLinkedGeoLoop ¶
* Free all allocated memory for a linked geo loop. The caller is responsible for freeing memory allocated to input loop struct. @param loop Loop to free
func XdestroyLinkedMultiPolygon ¶
* Free all allocated memory for a linked geo structure. The caller is responsible for freeing memory allocated to input polygon struct. @param polygon Pointer to the first polygon in the structure
func XdestroyVertexGraph ¶
* Destroy a VertexGraph's sub-objects, freeing their memory. The caller is responsible for freeing memory allocated to the VertexGraph struct itself. @param graph Graph to destroy
func XfindNodeForEdge ¶
* Find the Vertex node for a given edge, if it exists @param graph Graph to look in @param fromVtx Start vertex @param toVtx End vertex, or NULL if we don't care @return Pointer to the vertex node, if found
func XfindNodeForVertex ¶
* Find a Vertex node starting at the given vertex @param graph Graph to look in @param fromVtx Start vertex @return Pointer to the vertex node, if found
func XfirstVertexNode ¶
* Get the next vertex node in the graph. @param graph Graph to iterate @return Vertex node, or NULL if at the end
func XgeoAlmostEqual ¶
* Determines if the components of two spherical coordinates are within our standard epsilon distance of each other.
@param p1 The first spherical coordinates. @param p2 The second spherical coordinates. @return Whether or not the two coordinates are within the epsilon distance
of each other.
func XgeoAlmostEqualThreshold ¶
* Determines if the components of two spherical coordinates are within some threshold distance of each other.
@param p1 The first spherical coordinates. @param p2 The second spherical coordinates. @param threshold The threshold distance. @return Whether or not the two coordinates are within the threshold distance
of each other.
func XgetBaseCellNumber ¶
* Returns the H3 base cell "number" of an H3 cell (hexagon or pentagon).
Note: Technically works on H3 edges, but will return base cell of the origin cell.
@param h The H3 cell. @return The base cell "number" of the H3 cell argument.
func XgetResolution ¶
* Returns the H3 resolution of an H3 index. @param h The H3 index. @return The resolution of the H3 index argument.
func XgreatCircleDistanceKm ¶
* The great circle distance in kilometers between two spherical coordinates.
func XgreatCircleDistanceM ¶
* The great circle distance in meters between two spherical coordinates.
func XgreatCircleDistanceRads ¶
* The great circle distance in radians between two spherical coordinates.
This function uses the Haversine formula. For math details, see:
https://en.wikipedia.org/wiki/Haversine_formula https://www.movable-type.co.uk/scripts/latlong.html
@param a the first lat/lng pair (in radians) @param b the second lat/lng pair (in radians)
@return the great circle distance in radians between a and b
func XijkDistance ¶
* Finds the distance between the two coordinates. Returns result.
@param c1 The first set of ijk coordinates. @param c2 The second set of ijk coordinates.
func XijkToCube ¶
* Convert IJK coordinates to cube coordinates, in place @param ijk Coordinate to convert
func XijkToIj ¶
* Transforms coordinates from the IJK+ coordinate system to the IJ coordinate system.
@param ijk The input IJK+ coordinates @param ij The output IJ coordinates
func XinitVertexGraph ¶
* Initialize a new VertexGraph @param graph Graph to initialize @param numBuckets Number of buckets to include in the graph @param res Resolution of the hexagons whose vertices we're storing
func XisClockwiseGeoLoop ¶
* Whether the winding order of a given loop is clockwise. In GeoJSON, clockwise loops are always inner loops (holes). @param loop The loop to check @return Whether the loop is clockwise
func XisClockwiseLinkedGeoLoop ¶
* Whether the winding order of a given loop is clockwise. In GeoJSON, clockwise loops are always inner loops (holes). @param loop The loop to check @return Whether the loop is clockwise
func XisPentagon ¶
* isPentagon takes an H3Index and determines if it is actually a pentagon. @param h The H3Index to check. @return Returns 1 if it is a pentagon, otherwise 0.
func XisResClassIII ¶
* isResClassIII takes a hexagon ID and determines if it is in a Class III resolution (rotated versus the icosahedron and subject to shape distortion adding extra points on icosahedron edges, making them not true hexagons). @param h The H3Index to check. @return Returns 1 if the hexagon is class III, otherwise 0.
func XisResolutionClassIII ¶
* Returns whether or not a resolution is a Class III grid. Note that odd resolutions are Class III and even resolutions are Class II. @param res The H3 resolution. @return 1 if the resolution is a Class III grid, and 0 if the resolution is
a Class II grid.
func XisValidCell ¶
* Returns whether or not an H3 index is a valid cell (hexagon or pentagon). @param h The H3 index to validate. @return 1 if the H3 index if valid, and 0 if it is not.
func XisValidDirectedEdge ¶
* Determines if the provided H3Index is a valid directed edge index @param edge The directed edge H3Index @return 1 if it is a directed edge H3Index, otherwise 0.
func XisValidVertex ¶
* Whether the input is a valid H3 vertex @param vertex H3 index possibly describing a vertex @return Whether the input is valid
func XiterStepChild ¶
* Step a IterCellsChildren to the next child cell. When the iteration is over, IterCellsChildren.h will be H3_NULL. Handles iterating through hexagon and pentagon cells.
func XiterStepRes ¶
func XpentagonCount ¶
* pentagonCount returns the number of pentagons (same at any resolution)
@return int count of pentagon indexes
func XpointInsideGeoLoop ¶
* pointInside is the core loop of the point-in-poly algorithm @param loop The loop to check @param bbox The bbox for the loop being tested @param coord The coordinate to check @return Whether the point is contained
func XpointInsideLinkedGeoLoop ¶
* pointInside is the core loop of the point-in-poly algorithm @param loop The loop to check @param bbox The bbox for the loop being tested @param coord The coordinate to check @return Whether the point is contained
func XpointInsidePolygon ¶
* pointInsidePolygon takes a given GeoPolygon data structure and checks if it contains a given geo coordinate.
@param geoPolygon The geoloop and holes defining the relevant area @param bboxes The bboxes for the main geoloop and each of its holes @param coord The coordinate to check @return Whether the point is contained
func XradsToDegs ¶
* Convert from radians to decimal degrees.
@param radians The radians. @return The corresponding decimal degrees.
func XremoveVertexNode ¶
* Remove a node from the graph. The input node will be freed, and should not be used after removal. @param graph Graph to mutate @param node Node to remove @return 0 on success, 1 on failure (node not found)
func Xres0CellCount ¶
* res0CellCount returns the number of resolution 0 cells
@return int count of resolution 0 cells
func XsetGeoDegs ¶
* Set the components of spherical coordinates in decimal degrees.
@param p The spherical coordinates. @param latDegs The desired latitude in decimal degrees. @param lngDegs The desired longitude in decimal degrees.
func XsetH3Index ¶
* Initializes an H3 index. @param hp The H3 index to initialize. @param res The H3 resolution to initialize the index to. @param baseCell The H3 base cell to initialize the index to. @param initDigit The H3 digit (0-7) to initialize all of the index digits to.
func XtriangleArea ¶
* Compute area in radians^2 of a spherical triangle, given its vertices.
@param a vertex lat/lng in radians @param b vertex lat/lng in radians @param c vertex lat/lng in radians
@return area of triangle on unit sphere, in radians^2
func XtriangleEdgeLengthsToArea ¶
* Surface area in radians^2 of spherical triangle on unit sphere.
For the math, see: https://en.wikipedia.org/wiki/Spherical_trigonometry#Area_and_spherical_excess
@param a length of triangle side A in radians @param b length of triangle side B in radians @param c length of triangle side C in radians
@return area in radians^2 of triangle on unit sphere
func XvertexNumForDirection ¶
func XvertexNumForDirection(tls *libc.TLS, origin TH3Index, direction TDirection) int32
* Get the first vertex number for a given direction. The neighbor in this direction is located between this vertex number and the next number in sequence. @returns The number for the first topological vertex, or INVALID_VERTEX_NUM
if the direction is not valid for this cell
Types ¶
type SLinkedGeoLoop ¶
- @struct LinkedGeoLoop @brief A loop node in a linked geo structure, part of a linked list
type SLinkedGeoPolygon ¶
- @struct LinkedGeoPolygon @brief A polygon node in a linked geo structure, part of a linked list.
type SLinkedLatLng ¶
- @struct LinkedLatLng @brief A coordinate node in a linked geo structure, part of a linked list
type SVertexNode ¶
- @struct VertexNode @brief A single node in a vertex graph, part of a linked list
type S_G_fpos64_t ¶
type S_G_fpos64_t = struct { F__pos T__off64_t F__state T__mbstate_t } /* __fpos64_t.h:10:9 */
The tag name of this struct is _G_fpos64_t to preserve historic
C++ mangled names for functions taking fpos_t and/or fpos64_t arguments. That name should not be used in new code.
type S_G_fpos_t ¶
type S_G_fpos_t = struct { F__pos T__off_t F__state T__mbstate_t } /* __fpos_t.h:10:9 */
The tag name of this struct is _G_fpos_t to preserve historic
C++ mangled names for functions taking fpos_t arguments. That name should not be used in new code.
type S_IO_FILE ¶
type S_IO_FILE = struct { F_flags int32 F__ccgo_pad1 [4]byte F_IO_read_ptr uintptr F_IO_read_end uintptr F_IO_read_base uintptr F_IO_write_base uintptr F_IO_write_ptr uintptr F_IO_write_end uintptr F_IO_buf_base uintptr F_IO_buf_end uintptr F_IO_save_base uintptr F_IO_backup_base uintptr F_IO_save_end uintptr F_markers uintptr F_chain uintptr F_fileno int32 F_flags2 int32 F_old_offset T__off_t F_cur_column uint16 F_vtable_offset int8 F_shortbuf [1]int8 F__ccgo_pad2 [4]byte F_lock uintptr F_offset T__off64_t F_codecvt uintptr F_wide_data uintptr F_freeres_list uintptr F_freeres_buf uintptr F__pad5 Tsize_t F_mode int32 F_unused2 [20]int8 } /* __FILE.h:4:1 */
type S__locale_struct ¶
type S__pthread_cond_s ¶
type S__pthread_cond_s = struct { F__wseq T__atomic_wide_counter F__g1_start T__atomic_wide_counter F__g_refs [2]uint32 F__g_size [2]uint32 F__g1_orig_size uint32 F__wrefs uint32 F__g_signals [2]uint32 } /* thread-shared-types.h:94:1 */
type S__pthread_internal_slist ¶
type S__pthread_internal_slist = struct{ F__next uintptr } /* thread-shared-types.h:57:9 */
type S__pthread_mutex_s ¶
type Sdrand48_data ¶
type Sdrand48_data = struct { F__x [3]uint16 F__old_x [3]uint16 F__c uint16 F__init uint16 F__a uint64 } /* stdlib.h:491:1 */
Data structure for communication with thread safe versions. This
type is to be regarded as opaque. It's only exported because users have to allocate objects of this type.
type Spthread_attr_t ¶
type Srandom_data ¶
type Stimespec ¶
type Stimespec = struct { Ftv_sec T__time_t Ftv_nsec T__syscall_slong_t } /* struct_timespec.h:11:1 */
POSIX.1b structure for a time value. This is like a `struct timeval' but
has nanoseconds instead of microseconds.
type Stimeval ¶
type Stimeval = struct { Ftv_sec T__time_t Ftv_usec T__suseconds_t } /* struct_timeval.h:8:1 */
A time value that is accurate to the nearest
microsecond but also has a range of years.
type TBaseCellData ¶
type TBaseCellData = struct { FhomeFijk TFaceIJK FisPentagon int32 FcwOffsetPent [2]int32 } /* baseCells.h:36:3 */
* @struct BaseCellData @brief information on a single base cell
type TBaseCellRotation ¶
- @struct BaseCellRotation @brief base cell at a given ijk and required rotations into its system
type TCellBoundary ¶
type TCellBoundary = struct { FnumVerts int32 F__ccgo_pad1 [4]byte Fverts [10]TLatLng } /* h3api.h:133:3 */
- @struct CellBoundary @brief cell boundary in latitude/longitude
type TCoordIJ ¶
* @struct CoordIJ @brief IJ hexagon coordinates
Each axis is spaced 120 degrees apart.
type TCoordIJK ¶
* @struct CoordIJK @brief IJK hexagon coordinates
Each axis is spaced 120 degrees apart.
type TDirection ¶
type TDirection = uint32 /* coordijk.h:85:3 */
* @brief H3 digit representing ijk+ axes direction. Values will be within the lowest 3 bits of an integer.
func X_getBaseCellDirection ¶
func X_getBaseCellDirection(tls *libc.TLS, originBaseCell int32, neighboringBaseCell int32) TDirection
* @brief Return the direction from the origin base cell to the neighbor. Returns INVALID_DIGIT if the base cells are not neighbors.
func X_h3LeadingNonZeroDigit ¶
func X_h3LeadingNonZeroDigit(tls *libc.TLS, h TH3Index) TDirection
* Returns the highest resolution non-zero digit in an H3Index. @param h The H3Index. @return The highest resolution non-zero digit in the H3Index.
func X_rotate60ccw ¶
func X_rotate60ccw(tls *libc.TLS, digit TDirection) TDirection
* Rotates indexing digit 60 degrees counter-clockwise. Returns result.
@param digit Indexing digit (between 1 and 6 inclusive)
func X_rotate60cw ¶
func X_rotate60cw(tls *libc.TLS, digit TDirection) TDirection
* Rotates indexing digit 60 degrees clockwise. Returns result.
@param digit Indexing digit (between 1 and 6 inclusive)
func X_unitIjkToDigit ¶
func X_unitIjkToDigit(tls *libc.TLS, ijk uintptr) TDirection
* Determines the H3 digit corresponding to a unit vector or the zero vector in ijk coordinates.
@param ijk The ijk coordinates; must be a unit vector or zero vector. @return The H3 digit (0-6) corresponding to the ijk unit vector, zero vector, or INVALID_DIGIT (7) on failure.
func XdirectionForNeighbor ¶
func XdirectionForNeighbor(tls *libc.TLS, origin TH3Index, destination TH3Index) TDirection
* Get the direction from the origin to a given neighbor. This is effectively the reverse operation for h3NeighborRotations. Returns INVALID_DIGIT if the cells are not neighbors.
TODO: This is currently a brute-force algorithm, but as it's O(6) that's probably acceptable.
func XdirectionForVertexNum ¶
func XdirectionForVertexNum(tls *libc.TLS, origin TH3Index, vertexNum int32) TDirection
* Get the direction for a given vertex number. This returns the direction for the neighbor between the given vertex number and the next number in sequence. @returns The direction for this vertex, or INVALID_DIGIT if the vertex number is invalid.
type TFILE ¶
type TFILE = S_IO_FILE /* FILE.h:7:25 */
The opaque type of streams. This is the definition used elsewhere.
type TFaceIJK ¶
* @struct FaceIJK @brief Face number and ijk coordinates on that face-centered coordinate system
type TFaceOrientIJK ¶
type TFaceOrientIJK = struct { Fface int32 Ftranslate TCoordIJK FccwRot60 int32 } /* faceijk.h:48:3 */
* @struct FaceOrientIJK @brief Information to transform into an adjacent face IJK system
type TGeoMultiPolygon ¶
type TGeoMultiPolygon = struct { FnumPolygons int32 F__ccgo_pad1 [4]byte Fpolygons uintptr } /* h3api.h:158:3 */
- @struct GeoMultiPolygon @brief Simplified core of GeoJSON MultiPolygon coordinates definition
type TGeoPolygon ¶
type TGeoPolygon = struct { Fgeoloop TGeoLoop FnumHoles int32 F__ccgo_pad1 [4]byte Fholes uintptr } /* h3api.h:150:3 */
- @struct GeoPolygon @brief Simplified core of GeoJSON Polygon coordinates definition
type TH3Error ¶
type TH3Error = Tuint32_t /* h3api.h:79:18 */
* @brief Result code (success or specific error) from an H3 operation
func X_getEdgeHexagons ¶
func X_getEdgeHexagons(tls *libc.TLS, geoloop uintptr, numHexagons Tint64_t, res int32, numSearchHexes uintptr, search uintptr, found uintptr) TH3Error
* _getEdgeHexagons takes a given geoloop ring (either the main geoloop or one of the holes) and traces it with hexagons and updates the search and found memory blocks. This is used for determining the initial hexagon set for the polygonToCells algorithm to execute on.
@param geoloop The geoloop (or hole) to be traced @param numHexagons The maximum number of hexagons possible for the geoloop
(also the bounds of the search and found arrays)
@param res The hexagon resolution (0-15) @param numSearchHexes The number of hexagons found so far to be searched @param search The block of memory containing the hexagons to search from @param found The block of memory containing the hexagons found from the search
@return An error code if the hash function cannot insert a found hexagon
into the found array.
func X_gridDiskDistancesInternal ¶
func X_gridDiskDistancesInternal(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr, maxIdx Tint64_t, curK int32) TH3Error
* Internal algorithm for the safe but slow version of gridDiskDistances
Adds the origin cell to the output set (treating it as a hash set) and recurses to its neighbors, if needed.
@param origin Origin cell @param k Maximum distance to move from the origin @param out Array treated as a hash set, elements being either
H3Index or 0.
@param distances Scratch area, with elements paralleling the out array.
Elements indicate ijk distance from the origin cell to the output cell
@param maxIdx Size of out and scratch arrays (must be maxGridDiskSize(k)) @param curK Current distance from the origin
func X_h3ToFaceIjk ¶
* Convert an H3Index to a FaceIJK address. @param h The H3Index. @param fijk The corresponding FaceIJK address.
func X_upAp7Checked ¶
* Returns non-zero if _upAp7 with the given input could have a signed integer overflow.
Assumes ijk is IJK+ coordinates (no negative numbers).
func X_upAp7rChecked ¶
* Returns non-zero if _upAp7r with the given input could have a signed integer overflow.
Assumes ijk is IJK+ coordinates (no negative numbers).
func XareNeighborCells ¶
* Returns whether or not the provided H3Indexes are neighbors. @param origin The origin H3 index. @param destination The destination H3 index. @param out Set to 1 if the indexes are neighbors, 0 otherwise @return Error code if the origin or destination are invalid or incomparable.
func XbboxHexEstimate ¶
* bboxHexEstimate returns an estimated number of hexagons that fit
within the cartesian-projected bounding box
@param bbox the bounding box to estimate the hexagon fill level @param res the resolution of the H3 hexagons to fill the bounding box @param out the estimated number of hexagons to fill the bounding box @return E_SUCCESS (0) on success, or another value otherwise.
func XcellAreaKm2 ¶
* Area of H3 cell in kilometers^2.
func XcellAreaM2 ¶
* Area of H3 cell in meters^2.
func XcellAreaRads2 ¶
* Area of H3 cell in radians^2.
The area is calculated by breaking the cell into spherical triangles and summing up their areas. Note that some H3 cells (hexagons and pentagons) are irregular, and have more than 6 or 5 sides.
todo: optimize the computation by re-using the edges shared between triangles
@param cell H3 cell @param out cell area in radians^2 @return E_SUCCESS on success, or an error code otherwise
func XcellToBoundary ¶
* Determines the cell boundary in spherical coordinates for an H3 index.
@param h3 The H3 index. @param cb The boundary of the H3 cell in spherical coordinates.
func XcellToCenterChild ¶
* cellToCenterChild produces the center child index for a given H3 index at the specified resolution
@param h H3Index to find center child of @param childRes The resolution to switch to @param child H3Index of the center child @return 0 (E_SUCCESS) on success
func XcellToChildPos ¶
* Returns the position of the cell within an ordered list of all children of the cell's parent at the specified resolution
func XcellToChildren ¶
* cellToChildren takes the given hexagon id and generates all of the children at the specified resolution storing them into the provided memory pointer. It's assumed that cellToChildrenSize was used to determine the allocation.
@param h H3Index to find the children of @param childRes int the child level to produce @param children H3Index* the memory to store the resulting addresses in
func XcellToChildrenSize ¶
* cellToChildrenSize returns the exact number of children for a cell at a given child resolution.
@param h H3Index to find the number of children of @param childRes The child resolution you're interested in
@return int Exact number of children (handles hexagons and pentagons
correctly)
func XcellToLatLng ¶
* Determines the spherical coordinates of the center point of an H3 index.
@param h3 The H3 index. @param g The spherical coordinates of the H3 cell center.
func XcellToLocalIj ¶
func XcellToLocalIj(tls *libc.TLS, origin TH3Index, h3 TH3Index, mode Tuint32_t, out uintptr) TH3Error
* Produces ij coordinates for an index anchored by an origin.
The coordinate space used by this function may have deleted regions or warping due to pentagonal distortion.
Coordinates are only comparable if they come from the same origin index.
Failure may occur if the index is too far away from the origin or if the index is on the other side of a pentagon.
This function's output is not guaranteed to be compatible across different versions of H3.
@param origin An anchoring index for the ij coordinate system. @param index Index to find the coordinates of @param mode Mode, must be 0 @param out ij coordinates of the index will be placed here on success @return 0 on success, or another value on failure.
func XcellToLocalIjk ¶
* Produces ijk+ coordinates for an index anchored by an origin.
The coordinate space used by this function may have deleted regions or warping due to pentagonal distortion.
Coordinates are only comparable if they come from the same origin index.
Failure may occur if the index is too far away from the origin or if the index is on the other side of a pentagon.
@param origin An anchoring index for the ijk+ coordinate system. @param index Index to find the coordinates of @param out ijk+ coordinates of the index will be placed here on success @return 0 on success, or another value on failure.
func XcellToParent ¶
* cellToParent produces the parent index for a given H3 index
@param h H3Index to find parent of @param parentRes The resolution to switch to (parent, grandparent, etc)
@return H3Index of the parent, or H3_NULL if you actually asked for a child
func XcellToVertex ¶
* Get a single vertex for a given cell, as an H3 index, or H3_NULL if the vertex is invalid @param cell Cell to get the vertex for @param vertexNum Number (index) of the vertex to calculate
func XcellToVertexes ¶
* Get all vertexes for the given cell @param cell Cell to get the vertexes for @param vertexes Array to hold vertex output. Must have length >= 6.
func XcellsToDirectedEdge ¶
func XcellsToDirectedEdge(tls *libc.TLS, origin TH3Index, destination TH3Index, out uintptr) TH3Error
* Returns a directed edge H3 index based on the provided origin and destination @param origin The origin H3 hexagon index @param destination The destination H3 hexagon index @return The directed edge H3Index, or H3_NULL on failure.
func XcellsToLinkedMultiPolygon ¶
* Create a LinkedGeoPolygon describing the outline(s) of a set of hexagons. Polygon outlines will follow GeoJSON MultiPolygon order: Each polygon will have one outer loop, which is first in the list, followed by any holes.
It is the responsibility of the caller to call destroyLinkedMultiPolygon on the populated linked geo structure, or the memory for that structure will not be freed.
It is expected that all hexagons in the set have the same resolution and that the set contains no duplicates. Behavior is undefined if duplicates or multiple resolutions are present, and the algorithm may produce unexpected or invalid output.
@param h3Set Set of hexagons @param numHexes Number of hexagons in set @param out Output polygon
func XchildPosToCell ¶
func XchildPosToCell(tls *libc.TLS, childPos Tint64_t, parent TH3Index, childRes int32, child uintptr) TH3Error
* Returns the child cell at a given position within an ordered list of all children at the specified resolution
func XcompactCells ¶
* compactCells takes a set of hexagons all at the same resolution and compresses them by pruning full child branches to the parent level. This is also done for all parents recursively to get the minimum number of hex addresses that perfectly cover the defined space. @param h3Set Set of hexagons @param compactedSet The output array of compressed hexagons (preallocated) @param numHexes The size of the input and output arrays (possible that no contiguous regions exist in the set at all and no compression possible) @return an error code on bad input data todo: update internal implementation for int64_t
func XdirectedEdgeToBoundary ¶
* Provides the coordinates defining the directed edge. @param edge The directed edge H3Index @param cb The cellboundary object to store the edge coordinates.
func XdirectedEdgeToCells ¶
* Returns the origin, destination pair of hexagon IDs for the given edge ID @param edge The directed edge H3Index @param originDestination Pointer to memory to store origin and destination IDs
func XedgeLengthKm ¶
* Length of a directed edge in kilometers.
func XedgeLengthM ¶
* Length of a directed edge in meters.
func XedgeLengthRads ¶
* Length of a directed edge in radians.
@param edge H3 directed edge
@return length in radians
func XgetDirectedEdgeDestination ¶
* Returns the destination hexagon from the directed edge H3Index @param edge The edge H3 index @return The destination H3 hexagon index, or H3_NULL on failure
func XgetDirectedEdgeOrigin ¶
* Returns the origin hexagon from the directed edge H3Index @param edge The edge H3 index @return The origin H3 hexagon index, or H3_NULL on failure
func XgetHexagonAreaAvgKm2 ¶
func XgetHexagonAreaAvgM2 ¶
func XgetIcosahedronFaces ¶
* Find all icosahedron faces intersected by a given H3 index, represented as integers from 0-19. The array is sparse; since 0 is a valid value, invalid array values are represented as -1. It is the responsibility of the caller to filter out invalid values.
@param h3 The H3 index @param out Output array. Must be of size maxFaceCount(h3).
func XgetPentagons ¶
* Generates all pentagons at the specified resolution
@param res The resolution to produce pentagons at. @param out Output array. Must be of size pentagonCount().
func XgetRes0Cells ¶
* getRes0Cells generates all base cells storing them into the provided memory pointer. Buffer must be of size NUM_BASE_CELLS * sizeof(H3Index).
@param out H3Index* the memory to store the resulting base cells in @returns E_SUCCESS.
func XgridDisk ¶
* Produce cells within grid distance k of the origin cell.
k-ring 0 is defined as the origin cell, k-ring 1 is defined as k-ring 0 and all neighboring cells, and so on.
Output is placed in the provided array in no particular order. Elements of the output array may be left zero, as can happen when crossing a pentagon.
@param origin origin cell @param k k >= 0 @param out zero-filled array which must be of size maxGridDiskSize(k)
func XgridDiskDistances ¶
func XgridDiskDistances(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr) TH3Error
* Produce cells and their distances from the given origin cell, up to distance k.
k-ring 0 is defined as the origin cell, k-ring 1 is defined as k-ring 0 and all neighboring cells, and so on.
Output is placed in the provided array in no particular order. Elements of the output array may be left zero, as can happen when crossing a pentagon.
@param origin origin cell @param k k >= 0 @param out zero-filled array which must be of size maxGridDiskSize(k) @param distances NULL or a zero-filled array which must be of size
maxGridDiskSize(k)
func XgridDiskDistancesSafe ¶
func XgridDiskDistancesSafe(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr) TH3Error
* Safe but slow version of gridDiskDistances (also called by it when needed).
Adds the origin cell to the output set (treating it as a hash set) and recurses to its neighbors, if needed.
@param origin Origin cell @param k Maximum distance to move from the origin @param out Array treated as a hash set, elements being either
H3Index or 0.
@param distances Scratch area, with elements paralleling the out array.
Elements indicate ijk distance from the origin cell to the output cell
func XgridDiskDistancesUnsafe ¶
func XgridDiskDistancesUnsafe(tls *libc.TLS, origin TH3Index, k int32, out uintptr, distances uintptr) TH3Error
* gridDiskDistancesUnsafe produces indexes within k distance of the origin index. Output behavior is undefined when one of the indexes returned by this function is a pentagon or is in the pentagon distortion area.
k-ring 0 is defined as the origin index, k-ring 1 is defined as k-ring 0 and all neighboring indexes, and so on.
Output is placed in the provided array in order of increasing distance from the origin. The distances in hexagons is placed in the distances array at the same offset.
@param origin Origin location. @param k k >= 0 @param out Array which must be of size maxGridDiskSize(k). @param distances Null or array which must be of size maxGridDiskSize(k). @return 0 if no pentagon or pentagonal distortion area was encountered.
func XgridDiskUnsafe ¶
* gridDiskUnsafe produces indexes within k distance of the origin index. Output behavior is undefined when one of the indexes returned by this function is a pentagon or is in the pentagon distortion area.
k-ring 0 is defined as the origin index, k-ring 1 is defined as k-ring 0 and all neighboring indexes, and so on.
Output is placed in the provided array in order of increasing distance from the origin.
@param origin Origin location. @param k k >= 0 @param out Array which must be of size maxGridDiskSize(k). @return 0 if no pentagon or pentagonal distortion area was encountered.
func XgridDisksUnsafe ¶
* gridDisksUnsafe takes an array of input hex IDs and a max k-ring and returns an array of hexagon IDs sorted first by the original hex IDs and then by the k-ring (0 to max), with no guaranteed sorting within each k-ring group.
@param h3Set A pointer to an array of H3Indexes @param length The total number of H3Indexes in h3Set @param k The number of rings to generate @param out A pointer to the output memory to dump the new set of H3Indexes to
The memory block should be equal to maxGridDiskSize(k) * length
@return 0 if no pentagon is encountered. Cannot trust output otherwise
func XgridDistance ¶
* Produces the grid distance between the two indexes.
This function may fail to find the distance between two indexes, for example if they are very far apart. It may also fail when finding distances for indexes on opposite sides of a pentagon.
@param origin Index to find the distance from. @param index Index to find the distance to. @return The distance, or a negative number if the library could not compute the distance.
func XgridPathCells ¶
* Given two H3 indexes, return the line of indexes between them (inclusive).
This function may fail to find the line between two indexes, for example if they are very far apart. It may also fail when finding distances for indexes on opposite sides of a pentagon.
Notes:
- The specific output of this function should not be considered stable across library versions. The only guarantees the library provides are that the line length will be `gridDistance(start, end) + 1` and that every index in the line will be a neighbor of the preceding index.
- Lines are drawn in grid space, and may not correspond exactly to either Cartesian lines or great arcs.
@param start Start index of the line @param end End index of the line @param out Output array, which must be of size gridPathCellsSize(start, end) @return 0 on success, or another value on failure.
func XgridPathCellsSize ¶
* Number of indexes in a line from the start index to the end index, to be used for allocating memory. Returns a negative number if the line cannot be computed.
@param start Start index of the line @param end End index of the line @param size Size of the line @returns 0 on success, or another value on error
func XgridRingUnsafe ¶
* Returns the "hollow" ring of hexagons at exactly grid distance k from the origin hexagon. In particular, k=0 returns just the origin hexagon.
A nonzero failure code may be returned in some cases, for example, if a pentagon is encountered. Failure cases may be fixed in future versions.
@param origin Origin location. @param k k >= 0 @param out Array which must be of size 6 * k (or 1 if k == 0) @return 0 if successful; nonzero otherwise.
func Xh3NeighborRotations ¶
func Xh3NeighborRotations(tls *libc.TLS, origin TH3Index, dir TDirection, rotations uintptr, out uintptr) TH3Error
* Returns the hexagon index neighboring the origin, in the direction dir.
Implementation note: The only reachable case where this returns 0 is if the origin is a pentagon and the translation is in the k direction. Thus, 0 can only be returned if origin is a pentagon.
@param origin Origin index @param dir Direction to move in @param rotations Number of ccw rotations to perform to reorient the
translation vector. Will be modified to the new number of rotations to perform (such as when crossing a face edge.)
@param out H3Index of the specified neighbor if succesful @return E_SUCCESS on success
func Xh3SetToVertexGraph ¶
* Internal: Create a vertex graph from a set of hexagons. It is the responsibility of the caller to call destroyVertexGraph on the populated graph, otherwise the memory in the graph nodes will not be freed. @private @param h3Set Set of hexagons @param numHexes Number of hexagons in the set @param graph Output graph
func Xh3ToString ¶
* Converts an H3 index into a string representation. @param h The H3 index to convert. @param str The string representation of the H3 index. @param sz Size of the buffer `str`
func XijToIjk ¶
* Transforms coordinates from the IJ coordinate system to the IJK+ coordinate system.
@param ij The input IJ coordinates @param ijk The output IJK+ coordinates @returns E_SUCCESS on success, E_FAILED if signed integer overflow would have occurred.
func XlatLngToCell ¶
* Encodes a coordinate on the sphere to the H3 index of the containing cell at the specified resolution.
Returns 0 on invalid input.
@param g The spherical coordinates to encode. @param res The desired H3 resolution for the encoding. @param out The encoded H3Index. @returns E_SUCCESS (0) on success, another value otherwise
func XlineHexEstimate ¶
func XlineHexEstimate(tls *libc.TLS, origin uintptr, destination uintptr, res int32, out uintptr) TH3Error
* lineHexEstimate returns an estimated number of hexagons that trace
the cartesian-projected line
@param origin the origin coordinates @param destination the destination coordinates @param res the resolution of the H3 hexagons to trace the line @param out Out parameter for the estimated number of hexagons required to trace the line @return E_SUCCESS (0) on success or another value otherwise.
func XlocalIjToCell ¶
func XlocalIjToCell(tls *libc.TLS, origin TH3Index, ij uintptr, mode Tuint32_t, out uintptr) TH3Error
* Produces an index for ij coordinates anchored by an origin.
The coordinate space used by this function may have deleted regions or warping due to pentagonal distortion.
Failure may occur if the index is too far away from the origin or if the index is on the other side of a pentagon.
This function's output is not guaranteed to be compatible across different versions of H3.
@param origin An anchoring index for the ij coordinate system. @param out ij coordinates to index. @param mode Mode, must be 0 @param index Index will be placed here on success. @return 0 on success, or another value on failure.
func XlocalIjkToCell ¶
* Produces an index for ijk+ coordinates anchored by an origin.
The coordinate space used by this function may have deleted regions or warping due to pentagonal distortion.
Failure may occur if the coordinates are too far away from the origin or if the index is on the other side of a pentagon.
@param origin An anchoring index for the ijk+ coordinate system. @param ijk IJK+ Coordinates to find the index of @param out The index will be placed here on success @return 0 on success, or another value on failure.
func XmaxFaceCount ¶
* Returns the max number of possible icosahedron faces an H3 index may intersect.
@return int count of faces
func XmaxGridDiskSize ¶
* Maximum number of cells that result from the gridDisk algorithm with the given k. Formula source and proof: https://oeis.org/A003215
@param k k value, k >= 0. @param out size in indexes
func XmaxPolygonToCellsSize ¶
func XmaxPolygonToCellsSize(tls *libc.TLS, geoPolygon uintptr, res int32, flags Tuint32_t, out uintptr) TH3Error
* maxPolygonToCellsSize returns the number of cells to allocate space for when performing a polygonToCells on the given GeoJSON-like data structure.
The size is the maximum of either the number of points in the geoloop or the number of cells in the bounding box of the geoloop.
@param geoPolygon A GeoJSON-like data structure indicating the poly to fill @param res Hexagon resolution (0-15) @param out number of cells to allocate for @return 0 (E_SUCCESS) on success.
func XnormalizeMultiPolygon ¶
* Normalize a LinkedGeoPolygon in-place into a structure following GeoJSON MultiPolygon rules: Each polygon must have exactly one outer loop, which must be first in the list, followed by any holes. Holes in this algorithm are identified by winding order (holes are clockwise), which is guaranteed by the h3SetToVertexGraph algorithm.
Input to this function is assumed to be a single polygon including all loops to normalize. It's assumed that a valid arrangement is possible.
@param root Root polygon including all loops @return 0 on success, or an error code > 0 for invalid input
func XoriginToDirectedEdges ¶
* Provides all of the directed edges from the current H3Index. @param origin The origin hexagon H3Index to find edges for. @param edges The memory to store all of the edges inside.
func XpolygonToCells ¶
func XpolygonToCells(tls *libc.TLS, geoPolygon uintptr, res int32, flags Tuint32_t, out uintptr) TH3Error
* polygonToCells takes a given GeoJSON-like data structure and preallocated, zeroed memory, and fills it with the hexagons that are contained by the GeoJSON-like data structure.
This implementation traces the GeoJSON geoloop(s) in cartesian space with hexagons, tests them and their neighbors to be contained by the geoloop(s), and then any newly found hexagons are used to test again until no new hexagons are found.
@param geoPolygon The geoloop and holes defining the relevant area @param res The Hexagon resolution (0-15) @param out The slab of zeroed memory to write to. Assumed to be big enough.
func XstringToH3 ¶
* Converts a string representation of an H3 index into an H3 index. @param str The string representation of an H3 index. @return The H3 index corresponding to the string argument, or H3_NULL if invalid.
func XuncompactCells ¶
func XuncompactCells(tls *libc.TLS, compactedSet uintptr, numCompacted Tint64_t, outSet uintptr, numOut Tint64_t, res int32) TH3Error
* uncompactCells takes a compressed set of cells and expands back to the original set of cells.
Skips elements that are H3_NULL (i.e., 0).
@param compactSet Set of compacted cells @param numCompact The number of cells in the input compacted set @param outSet Output array for decompressed cells (preallocated) @param numOut The size of the output array to bound check against @param res The H3 resolution to decompress to @return An error code if output array is too small or any cell
is smaller than the output resolution.
func XuncompactCellsSize ¶
func XuncompactCellsSize(tls *libc.TLS, compactedSet uintptr, numCompacted Tint64_t, res int32, out uintptr) TH3Error
* uncompactCellsSize takes a compacted set of hexagons and provides the exact size of the uncompacted set of hexagons.
@param compactedSet Set of hexagons @param numHexes The number of hexes in the input set @param res The hexagon resolution to decompress to @param out The number of hexagons to allocate memory for @returns E_SUCCESS on success, or another value on error
type TH3ErrorCodes ¶
type TH3ErrorCodes = uint32 /* h3api.h:105:3 */
type TH3Index ¶
type TH3Index = Tuint64_t /* h3api.h:69:18 */
* @brief Identifier for an object (cell, edge, etc) in the H3 system.
The H3Index fits within a 64-bit unsigned integer.
func X_faceIjkToH3 ¶
* Convert an FaceIJK address to the corresponding H3Index. @param fijk The FaceIJK address. @param res The cell resolution. @return The encoded H3Index (or H3_NULL on failure).
func X_h3Rotate60ccw ¶
* Rotate an H3Index 60 degrees counter-clockwise. @param h The H3Index.
func X_h3Rotate60cw ¶
* Rotate an H3Index 60 degrees clockwise. @param h The H3Index.
func X_h3RotatePent60ccw ¶
* Rotate an H3Index 60 degrees counter-clockwise about a pentagonal center. @param h The H3Index.
func X_h3RotatePent60cw ¶
* Rotate an H3Index 60 degrees clockwise about a pentagonal center. @param h The H3Index.
func X_zeroIndexDigits ¶
* Zero out index digits from start to end, inclusive. No-op if start > end.
func XmakeDirectChild ¶
* makeDirectChild takes an index and immediately returns the immediate child index based on the specified cell number. Bit operations only, could generate invalid indexes if not careful (deleted cell under a pentagon).
@param h H3Index to find the direct child of @param cellNumber int id of the direct child (0-6)
@return The new H3Index for the child
type TIterCellsChildren ¶
type TIterCellsChildren = struct { Fh TH3Index F_parentRes int32 F_skipDigit int32 } /* iterators.h:54:3 */
* IterCellsChildren: struct for iterating through the descendants of a given cell.
Constructors:
Initialize with either `iterInitParent` or `iterInitBaseCellNum`. `iterInitParent` sets up an iterator for all the children of a given parent cell at a given resolution.
`iterInitBaseCellNum` sets up an iterator for children cells, given a base cell number (0--121).
Iteration:
Step iterator with `iterStepChild`. During the lifetime of the `IterCellsChildren`, the current iterate is accessed via the `IterCellsChildren.h` member. When the iterator is exhausted or if there was an error in initialization, `IterCellsChildren.h` will be `H3_NULL` even after calling `iterStepChild`.
func XiterInitBaseCellNum ¶
func XiterInitBaseCellNum(tls *libc.TLS, baseCellNum int32, childRes int32) TIterCellsChildren
create iterator for children of base cell at given resolution
func XiterInitParent ¶
func XiterInitParent(tls *libc.TLS, h TH3Index, childRes int32) TIterCellsChildren
* Initialize a IterCellsChildren struct representing the sequence giving the children of cell `h` at resolution `childRes`.
At any point in the iteration, starting once the struct is initialized, IterCellsChildren.h gives the current child.
Also, IterCellsChildren.h == H3_NULL when all the children have been iterated through, or if the input to `iterInitParent` was invalid.
type TIterCellsResolution ¶
type TIterCellsResolution = struct { Fh TH3Index F_baseCellNum int32 F_res int32 F_itC TIterCellsChildren } /* iterators.h:81:3 */
* IterCellsResolution: struct for iterating through all cells at a given resolution
Constructor:
Initialize with `IterCellsResolution`.
Iteration:
Step iterator with `iterStepRes`. During the lifetime of the iterator the current iterate is accessed via the `IterCellsResolution.h` member. When the iterator is exhausted or if there was an error in initialization, `IterCellsResolution.h` will be `H3_NULL` even after calling `iterStepRes`.
func XiterInitRes ¶
func XiterInitRes(tls *libc.TLS, res int32) TIterCellsResolution
create iterator for all cells at given resolution
type TLinkedGeoLoop ¶
type TLinkedGeoLoop = SLinkedGeoLoop /* h3api.h:172:30 */
- @struct LinkedGeoLoop @brief A loop node in a linked geo structure, part of a linked list
type TLinkedGeoPolygon ¶
type TLinkedGeoPolygon = SLinkedGeoPolygon /* h3api.h:182:33 */
- @struct LinkedGeoPolygon @brief A polygon node in a linked geo structure, part of a linked list.
type TLinkedLatLng ¶
type TLinkedLatLng = SLinkedLatLng /* h3api.h:163:29 */
- @struct LinkedLatLng @brief A coordinate node in a linked geo structure, part of a linked list
type TOverage ¶
type TOverage = uint32 /* faceijk.h:71:3 */
* Digit representing overage type
func X_adjustOverageClassII ¶
func X_adjustOverageClassII(tls *libc.TLS, fijk uintptr, res int32, pentLeading4 int32, substrate int32) TOverage
* Adjusts a FaceIJK address in place so that the resulting cell address is relative to the correct icosahedral face.
@param fijk The FaceIJK address of the cell. @param res The H3 resolution of the cell. @param pentLeading4 Whether or not the cell is a pentagon with a leading
digit 4.
@param substrate Whether or not the cell is in a substrate grid. @return 0 if on original face (no overage); 1 if on face edge (only occurs
on substrate grids); 2 if overage on new face interior
func X_adjustPentVertOverage ¶
* Adjusts a FaceIJK address for a pentagon vertex in a substrate grid in place so that the resulting cell address is relative to the correct icosahedral face.
@param fijk The FaceIJK address of the cell. @param res The H3 resolution of the cell.
type TPentagonDirectionFaces ¶
- @struct PentagonDirectionFaces @brief The faces in each axial direction of a given pentagon base cell
type TVertexGraph ¶
type TVertexGraph = struct { Fbuckets uintptr FnumBuckets int32 Fsize int32 Fres int32 F__ccgo_pad1 [4]byte } /* vertexGraph.h:46:3 */
- @struct VertexGraph @brief A data structure to store a graph of vertices
type TVertexNode ¶
type TVertexNode = SVertexNode /* vertexGraph.h:31:27 */
- @struct VertexNode @brief A single node in a vertex graph, part of a linked list
type T__atomic_wide_counter ¶
type T__atomic_wide_counter = struct{ F__value64 uint64 } /* atomic_wide_counter.h:33:3 */
Counter that is monotonically increasing (by less than 2**31 per
increment), with a single writer, and an arbitrary number of readers.
type T__blkcnt64_t ¶
type T__blkcnt64_t = int64 /* types.h:181:30 */
type T__blkcnt_t ¶
type T__blkcnt_t = int64 /* types.h:180:28 */
Type to count number of disk blocks.
type T__builtin_va_list ¶
type T__builtin_va_list = uintptr /* <builtin>:46:14 */
type T__caddr_t ¶
type T__caddr_t = uintptr /* types.h:204:14 */
type T__clock_t ¶
type T__clock_t = int64 /* types.h:156:27 */ // Type of CPU usage counts.
type T__clockid_t ¶
type T__clockid_t = int32 /* types.h:169:29 */
Clock ID used in clock and timer functions.
type T__compar_fn_t ¶
type T__compar_fn_t = uintptr /* stdlib.h:829:13 */
Shorthand for type of comparison functions.
type T__daddr_t ¶
type T__daddr_t = int32 /* types.h:165:27 */ // The type of a disk address.
type T__fd_mask ¶
type T__fd_mask = int64 /* select.h:49:18 */
The fd_set member is required to be an array of longs.
type T__float128 ¶
type T__float128 = float64 /* <builtin>:47:21 */
type T__fpos64_t ¶
type T__fpos64_t = S_G_fpos64_t /* __fpos64_t.h:14:3 */
The tag name of this struct is _G_fpos64_t to preserve historic
C++ mangled names for functions taking fpos_t and/or fpos64_t arguments. That name should not be used in new code.
type T__fpos_t ¶
type T__fpos_t = S_G_fpos_t /* __fpos_t.h:14:3 */
The tag name of this struct is _G_fpos_t to preserve historic
C++ mangled names for functions taking fpos_t arguments. That name should not be used in new code.
type T__fsblkcnt64_t ¶
type T__fsblkcnt64_t = uint64 /* types.h:185:32 */
type T__fsblkcnt_t ¶
type T__fsblkcnt_t = uint64 /* types.h:184:30 */
Type to count file system blocks.
type T__fsfilcnt64_t ¶
type T__fsfilcnt64_t = uint64 /* types.h:189:32 */
type T__fsfilcnt_t ¶
type T__fsfilcnt_t = uint64 /* types.h:188:30 */
Type to count file system nodes.
type T__fsid_t ¶
type T__fsid_t = struct{ F__val [2]int32 } /* types.h:155:26 */ // Type of file system IDs.
type T__fsword_t ¶
type T__fsword_t = int64 /* types.h:192:28 */
Type of miscellaneous file system fields.
type T__gnuc_va_list ¶
type T__gnuc_va_list = T__builtin_va_list /* stdarg.h:40:27 */
type T__gwchar_t ¶
type T__gwchar_t = int32 /* inttypes.h:34:24 */
Get a definition for wchar_t. But we must not define wchar_t itself.
type T__ino64_t ¶
type T__ino64_t = uint64 /* types.h:149:27 */ // Type of file serial numbers (LFS).
type T__int128_t ¶
type T__int16_t ¶
type T__int16_t = int16 /* types.h:39:26 */
type T__int32_t ¶
type T__int32_t = int32 /* types.h:41:20 */
type T__int64_t ¶
type T__int64_t = int64 /* types.h:44:25 */
type T__int8_t ¶
type T__int8_t = int8 /* types.h:37:21 */
Fixed-size types, underlying types depend on word size and compiler.
type T__int_least16_t ¶
type T__int_least16_t = T__int16_t /* types.h:54:19 */
type T__int_least32_t ¶
type T__int_least32_t = T__int32_t /* types.h:56:19 */
type T__int_least64_t ¶
type T__int_least64_t = T__int64_t /* types.h:58:19 */
type T__int_least8_t ¶
type T__int_least8_t = T__int8_t /* types.h:52:18 */
Smallest types with at least a given width.
type T__intptr_t ¶
type T__intptr_t = int64 /* types.h:207:25 */
Duplicates info from stdint.h but this is used in unistd.h.
type T__locale_t ¶
type T__locale_t = uintptr /* __locale_t.h:41:32 */
type T__loff_t ¶
type T__loff_t = T__off64_t /* types.h:203:19 */ // Type of file sizes and offsets (LFS).
These few don't really vary by system, they always correspond
to one of the other defined types.
type T__mbstate_t ¶
type T__mbstate_t = struct { F__count int32 F__value struct{ F__wch uint32 } } /* __mbstate_t.h:21:3 */
Conversion state information.
type T__nlink_t ¶
type T__nlink_t = uint64 /* types.h:151:27 */ // Type of file link counts.
type T__off64_t ¶
type T__off64_t = int64 /* types.h:153:27 */ // Type of file sizes and offsets (LFS).
type T__once_flag ¶
type T__once_flag = struct{ F__data int32 } /* thread-shared-types.h:111:3 */
type T__pthread_list_t ¶
type T__pthread_list_t = S__pthread_internal_list /* thread-shared-types.h:55:3 */
type T__pthread_slist_t ¶
type T__pthread_slist_t = S__pthread_internal_slist /* thread-shared-types.h:60:3 */
type T__rlim64_t ¶
type T__rlim64_t = uint64 /* types.h:158:28 */ // Type for resource measurement (LFS).
type T__sig_atomic_t ¶
type T__sig_atomic_t = int32 /* types.h:215:13 */
C99: An integer type that can be accessed as an atomic entity,
even in the presence of asynchronous interrupts. It is not currently necessary for this to be machine-specific.
type T__sigset_t ¶
type T__sigset_t = struct{ F__val [16]uint64 } /* __sigset_t.h:8:3 */
type T__socklen_t ¶
type T__socklen_t = uint32 /* types.h:210:23 */
Duplicate info from sys/socket.h.
type T__ssize_t ¶
type T__ssize_t = int64 /* types.h:194:27 */ // Type of a byte count, or error.
type T__suseconds64_t ¶
type T__suseconds64_t = int64 /* types.h:163:33 */
type T__suseconds_t ¶
type T__suseconds_t = int64 /* types.h:162:31 */ // Signed count of microseconds.
type T__syscall_slong_t ¶
type T__syscall_slong_t = int64 /* types.h:197:33 */
Signed long type used in system calls.
type T__syscall_ulong_t ¶
type T__syscall_ulong_t = uint64 /* types.h:199:33 */
Unsigned long type used in system calls.
type T__timer_t ¶
type T__timer_t = uintptr /* types.h:172:12 */
Timer ID returned by `timer_create'.
type T__u_quad_t ¶
type T__u_quad_t = uint64 /* types.h:64:27 */
type T__u_short ¶
type T__u_short = uint16 /* types.h:32:28 */
type T__uint128_t ¶
type T__uint16_t ¶
type T__uint16_t = uint16 /* types.h:40:28 */
type T__uint32_t ¶
type T__uint32_t = uint32 /* types.h:42:22 */
type T__uint64_t ¶
type T__uint64_t = uint64 /* types.h:45:27 */
type T__uint8_t ¶
type T__uint8_t = uint8 /* types.h:38:23 */
type T__uint_least16_t ¶
type T__uint_least16_t = T__uint16_t /* types.h:55:20 */
type T__uint_least32_t ¶
type T__uint_least32_t = T__uint32_t /* types.h:57:20 */
type T__uint_least64_t ¶
type T__uint_least64_t = T__uint64_t /* types.h:59:20 */
type T__uint_least8_t ¶
type T__uint_least8_t = T__uint8_t /* types.h:53:19 */
type T__uintmax_t ¶
type T__uintmax_t = uint64 /* types.h:73:27 */
type T__useconds_t ¶
type T__useconds_t = uint32 /* types.h:161:30 */ // Count of microseconds.
type Tblkcnt_t ¶
type Tblkcnt_t = T__blkcnt64_t /* types.h:205:22 */ // Type to count number of disk blocks.
Types from the Large File Support interface.
type Tblksize_t ¶
type Tblksize_t = T__blksize_t /* types.h:185:21 */
type Tcaddr_t ¶
type Tcaddr_t = T__caddr_t /* types.h:115:19 */
type Tclockid_t ¶
type Tclockid_t = T__clockid_t /* clockid_t.h:7:21 */
Clock ID used in clock and timer functions.
type Tdaddr_t ¶
type Tdaddr_t = T__daddr_t /* types.h:114:19 */
type Tfd_mask ¶
type Tfd_mask = T__fd_mask /* select.h:77:19 */
Sometimes the fd_set member is assumed to have this type.
type Tfd_set ¶
type Tfd_set = struct{ F__fds_bits [16]T__fd_mask } /* select.h:70:5 */
fd_set for select and pselect.
type Tfloat_t ¶
type Tfloat_t = float32 /* math.h:163:15 */
Define the following typedefs.
float_t floating-point type at least as wide as `float' used to evaluate `float' expressions double_t floating-point type at least as wide as `double' used to evaluate `double' expressions
type Tfpos_t ¶
type Tfpos_t = T__fpos64_t /* stdio.h:86:20 */
The type of the second argument to `fgetpos' and `fsetpos'.
type Tfsblkcnt_t ¶
type Tfsblkcnt_t = T__fsblkcnt64_t /* types.h:209:24 */ // Type to count file system blocks.
type Tfsfilcnt_t ¶
type Tfsfilcnt_t = T__fsfilcnt64_t /* types.h:213:24 */ // Type to count file system inodes.
type Timaxdiv_t ¶
We have to define the `uintmax_t' type using `ldiv_t'.
type Tino_t ¶
type Tino_t = T__ino64_t /* types.h:49:19 */
type Tint16_t ¶
type Tint16_t = T__int16_t /* stdint-intn.h:25:19 */
type Tint32_t ¶
type Tint32_t = T__int32_t /* stdint-intn.h:26:19 */
type Tint64_t ¶
type Tint64_t = T__int64_t /* stdint-intn.h:27:19 */
type Tint_fast16_t ¶
type Tint_fast16_t = int64 /* stdint.h:60:19 */
type Tint_fast32_t ¶
type Tint_fast32_t = int64 /* stdint.h:61:19 */
type Tint_fast64_t ¶
type Tint_fast64_t = int64 /* stdint.h:62:19 */
type Tint_least16_t ¶
type Tint_least16_t = T__int_least16_t /* stdint.h:44:25 */
type Tint_least32_t ¶
type Tint_least32_t = T__int_least32_t /* stdint.h:45:25 */
type Tint_least64_t ¶
type Tint_least64_t = T__int_least64_t /* stdint.h:46:25 */
type Tlocale_t ¶
type Tlocale_t = T__locale_t /* locale_t.h:24:20 */
type Tnlink_t ¶
type Tnlink_t = T__nlink_t /* types.h:74:19 */
type Toff_t ¶
type Toff_t = T__off64_t /* stdio.h:65:19 */
type Tpthread_attr_t ¶
type Tpthread_attr_t = Spthread_attr_t /* pthreadtypes.h:62:30 */
type Tpthread_barrier_t ¶
type Tpthread_barrier_t = struct { F__ccgo_pad1 [0]uint64 F__size [32]int8 } /* pthreadtypes.h:112:3 */
POSIX barriers data type. The structure of the type is
deliberately not exposed.
type Tpthread_barrierattr_t ¶
type Tpthread_cond_t ¶
type Tpthread_cond_t = struct{ F__data S__pthread_cond_s } /* pthreadtypes.h:80:3 */
type Tpthread_condattr_t ¶
type Tpthread_condattr_t = struct { F__ccgo_pad1 [0]uint32 F__size [4]int8 } /* pthreadtypes.h:45:3 */
Data structure for condition variable handling. The structure of
the attribute type is not exposed on purpose.
type Tpthread_key_t ¶
type Tpthread_key_t = uint32 /* pthreadtypes.h:49:22 */
Keys for thread-specific data
type Tpthread_mutex_t ¶
type Tpthread_mutex_t = struct{ F__data S__pthread_mutex_s } /* pthreadtypes.h:72:3 */
type Tpthread_mutexattr_t ¶
type Tpthread_mutexattr_t = struct { F__ccgo_pad1 [0]uint32 F__size [4]int8 } /* pthreadtypes.h:36:3 */
Data structures for mutex handling. The structure of the attribute
type is not exposed on purpose.
type Tpthread_rwlock_t ¶
type Tpthread_rwlock_t = struct{ F__data S__pthread_rwlock_arch_t } /* pthreadtypes.h:91:3 */
Data structure for reader-writer lock variable handling. The
structure of the attribute type is deliberately not exposed.
type Tpthread_rwlockattr_t ¶
type Tpthread_spinlock_t ¶
type Tpthread_spinlock_t = int32 /* pthreadtypes.h:103:22 */
POSIX spinlock data type.
type Tpthread_t ¶
type Tpthread_t = uint64 /* pthreadtypes.h:27:27 */
Thread identifiers. The structure of the attribute type is not
exposed on purpose.
type Tptrdiff_t ¶
type Tptrdiff_t = int64 /* <builtin>:3:26 */
type Tregister_t ¶
type Tregister_t = int32 /* types.h:164:13 */
type Tsigset_t ¶
type Tsigset_t = T__sigset_t /* sigset_t.h:7:20 */
A set of signals to be blocked, unblocked, or waited for.
type Tssize_t ¶
type Tssize_t = T__ssize_t /* stdio.h:77:19 */
type Tsuseconds_t ¶
type Tsuseconds_t = T__suseconds_t /* select.h:43:23 */
type Ttimer_t ¶
type Ttimer_t = T__timer_t /* timer_t.h:7:19 */
Timer ID returned by `timer_create'.
type Tu_int16_t ¶
type Tu_int16_t = T__uint16_t /* types.h:159:20 */
type Tu_int32_t ¶
type Tu_int32_t = T__uint32_t /* types.h:160:20 */
type Tu_int64_t ¶
type Tu_int64_t = T__uint64_t /* types.h:161:20 */
type Tu_int8_t ¶
type Tu_int8_t = T__uint8_t /* types.h:158:19 */
These were defined by ISO C without the first `_'.
type Tu_quad_t ¶
type Tu_quad_t = T__u_quad_t /* types.h:38:20 */
type Tu_short ¶
type Tu_short = T__u_short /* types.h:34:19 */
type Tuint16_t ¶
type Tuint16_t = T__uint16_t /* stdint-uintn.h:25:20 */
type Tuint32_t ¶
type Tuint32_t = T__uint32_t /* stdint-uintn.h:26:20 */
func X_hashVertex ¶
* Get an integer hash for a lat/lng point, at a precision determined by the current hexagon resolution. TODO: Light testing suggests this might not be sufficient at resolutions finer than 10. Design a better hash function if performance and collisions seem to be an issue here. @param vertex Lat/lng vertex to hash @param res Resolution of the hexagon the vertex belongs to @param numBuckets Number of buckets in the graph @return Integer hash
type Tuint64_t ¶
type Tuint64_t = T__uint64_t /* stdint-uintn.h:27:20 */
type Tuint8_t ¶
type Tuint8_t = T__uint8_t /* stdint-uintn.h:24:19 */
type Tuint_fast16_t ¶
type Tuint_fast16_t = uint64 /* stdint.h:73:27 */
type Tuint_fast32_t ¶
type Tuint_fast32_t = uint64 /* stdint.h:74:27 */
type Tuint_fast64_t ¶
type Tuint_fast64_t = uint64 /* stdint.h:75:27 */
type Tuint_least16_t ¶
type Tuint_least16_t = T__uint_least16_t /* stdint.h:50:26 */
type Tuint_least32_t ¶
type Tuint_least32_t = T__uint_least32_t /* stdint.h:51:26 */
type Tuint_least64_t ¶
type Tuint_least64_t = T__uint_least64_t /* stdint.h:52:26 */
type Tuintmax_t ¶
type Tuintmax_t = T__uintmax_t /* stdint.h:102:22 */
type Tuintptr_t ¶
type Tuintptr_t = uint64 /* stdint.h:90:27 */
type Tva_list ¶
type Tva_list = T__gnuc_va_list /* stdio.h:52:24 */