@@ -89,8 +89,7 @@ int H3_EXPORT(getBaseCellNumber)(H3Index h) { return H3_GET_BASE_CELL(h); }
89
89
/**
90
90
* Converts a string representation of an H3 index into an H3 index.
91
91
* @param str The string representation of an H3 index.
92
- * @return The H3 index corresponding to the string argument, or H3_NULL if
93
- * invalid.
92
+ * @param out Output: The H3 index corresponding to the string argument
94
93
*/
95
94
H3Error H3_EXPORT (stringToH3 )(const char * str , H3Index * out ) {
96
95
H3Index h = H3_NULL ;
@@ -187,8 +186,7 @@ void setH3Index(H3Index *hp, int res, int baseCell, Direction initDigit) {
187
186
*
188
187
* @param h H3Index to find parent of
189
188
* @param parentRes The resolution to switch to (parent, grandparent, etc)
190
- *
191
- * @return H3Index of the parent, or H3_NULL if you actually asked for a child
189
+ * @param out Output: H3Index of the parent
192
190
*/
193
191
H3Error H3_EXPORT (cellToParent )(H3Index h , int parentRes , H3Index * out ) {
194
192
int childRes = H3_GET_RESOLUTION (h );
@@ -231,9 +229,8 @@ static bool _hasChildAtRes(H3Index h, int childRes) {
231
229
*
232
230
* @param h H3Index to find the number of children of
233
231
* @param childRes The child resolution you're interested in
234
- *
235
- * @return int Exact number of children (handles hexagons and pentagons
236
- * correctly)
232
+ * @param out Output: exact number of children (handles hexagons and
233
+ * pentagons correctly)
237
234
*/
238
235
H3Error H3_EXPORT (cellToChildrenSize )(H3Index h , int childRes , int64_t * out ) {
239
236
if (!_hasChildAtRes (h , childRes )) return E_RES_DOMAIN ;
@@ -547,8 +544,8 @@ H3Error H3_EXPORT(compactCells)(const H3Index *h3Set, H3Index *compactedSet,
547
544
*
548
545
* Skips elements that are H3_NULL (i.e., 0).
549
546
*
550
- * @param compactSet Set of compacted cells
551
- * @param numCompact The number of cells in the input compacted set
547
+ * @param compactedSet Set of compacted cells
548
+ * @param numCompacted The number of cells in the input compacted set
552
549
* @param outSet Output array for decompressed cells (preallocated)
553
550
* @param numOut The size of the output array to bound check against
554
551
* @param res The H3 resolution to decompress to
@@ -577,7 +574,7 @@ H3Error H3_EXPORT(uncompactCells)(const H3Index *compactedSet,
577
574
* the exact size of the uncompacted set of hexagons.
578
575
*
579
576
* @param compactedSet Set of hexagons
580
- * @param numHexes The number of hexes in the input set
577
+ * @param numCompacted The number of hexes in the input set
581
578
* @param res The hexagon resolution to decompress to
582
579
* @param out The number of hexagons to allocate memory for
583
580
* @returns E_SUCCESS on success, or another value on error
@@ -1114,6 +1111,10 @@ static H3Error validateChildPos(int64_t childPos, H3Index parent,
1114
1111
/**
1115
1112
* Returns the position of the cell within an ordered list of all children of
1116
1113
* the cell's parent at the specified resolution
1114
+ * @param child Child cell index
1115
+ * @param parentRes Resolution of the parent cell to find the position within
1116
+ * @param out Output: The position of the child cell within its parents cell
1117
+ * list of children
1117
1118
*/
1118
1119
H3Error H3_EXPORT (cellToChildPos )(H3Index child , int parentRes , int64_t * out ) {
1119
1120
int childRes = H3_GET_RESOLUTION (child );
@@ -1189,7 +1190,12 @@ H3Error H3_EXPORT(cellToChildPos)(H3Index child, int parentRes, int64_t *out) {
1189
1190
1190
1191
/**
1191
1192
* Returns the child cell at a given position within an ordered list of all
1192
- * children at the specified resolution */
1193
+ * children at the specified resolution
1194
+ * @param childPos Position within the ordered list
1195
+ * @param parent Parent cell of the cell index to find
1196
+ * @param childRes Resolution of the child cell index
1197
+ * @param child Output: child cell index
1198
+ */
1193
1199
H3Error H3_EXPORT (childPosToCell )(int64_t childPos , H3Index parent ,
1194
1200
int childRes , H3Index * child ) {
1195
1201
// Validate resolution
0 commit comments