HDFGroup / HDFGroup/hdf5

[Feature Request] expose `ndims` in `H5Dchunk_iter` callback

Open
#2,437 1 comment 0 reactions 1 assignee Claimed by @jhendersonHDF View on GitHub
Component - C Library
Dominant language
C
Stars
988
Forks
355
Avg merge
4d 2h
Merged PRs (30d)
12

Description

**Is your feature request related to a problem? Please describe.**
It's hard to work with the `offset` array in `H5Dchunk_iter` callback because we don't know the size of the array. It would be too expensive to call `H5Sget_simple_extent_ndims` each time.

**Describe the solution you'd like**
I propose that we should pass `ndims` to the callback. I.e.

`typedef int (*H5D_chunk_iter_op_t)(const hsize_t *offset, unsigned ndims, unsigned filter_mask, haddr_t addr, hsize_t size,
void *op_data);`

**Describe alternatives you've considered**
Call `H5Sget_simple_extent_ndims` in the callback.

**Additional context**
I'm working on implementing Java binding for `H5Dchunk_iter`. I don't see there's an easy workaround. I can upload my patch if needed.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.