constantinpape / pybdv

python tools for BigDataViewer

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Proper support and check for unsigned types

constantinpape opened this issue · comments

Bigdataviewer implements it's own types for unsigned char and unsigned short, because
java does not support unsigned types natively.
As far as I understand it maps like this for uint8 (and similarly for uint16):

0->0, 1->1, ...., 127->127, 128->-1, .... 255->-128

I am currently not taking care of this, which causes ugly errors when opening a converted file with an id > 32767 (int16 max id).

This conversion should be done automatically (if necessary) and if the datarange can not be mapped,
pybdv should throw an error.