Commit 23eb895b authored by Wei Chen's avatar Wei Chen
Browse files

support multi-channel gray slide



add two functions:

```
void openslide_read_region_gray8(openslide_t *osr, uint8_t *dest,
                                 int64_t x, int64_t y, int32_t level,
                                 int64_t w, int64_t h);

void openslide_read_region_gray16(openslide_t *osr, uint8_t *dest,
                                  int64_t x, int64_t y, int32_t level,
                                  int64_t w, int64_t h);
```

They accept similar set of parameters as openslide_read_region(). The
only difference is the `level` parameter. Since `level` is the index
into `osr->levels` array, and `osr->levels` now stores `struct
_openslide_level` for all levels of all channels, caller needs calculate
`level` as:

    num_of_channels * num_of_level_in_one_channel + level_in_channel

Signed-off-by: default avatarWei Chen <chenw1@uthscsa.edu>
parent 5e6ceeb9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment