-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
uint16 RGB numpy array to Qimage in 48bits #16
Comments
qimage2ndarray only provides a thin, efficient conversion between numpy arrays and QImage. QImage does not support more than 8 bits per channel (I just checked again, but please correct me if I'm wrong). One may specify min/max values during conversion, enabling to work with 48 bit data, for instance using QImage for display purposes (limited to 8bit per channel, of course). |
actualy on pyqt5.4 he have rgb30 (10-10-10) format and in 5.12 have 2 new format : rgbx64 and rgba64. In pyqt5.13 ( actually in dev branch of pyqt5) you have grayscale8 (pyqt 5.5) and grayscale16 (new). |
actually for grayscale 8bit nparray what is the format ? ( grayscale8 ?) |
Thanks for the information! Indeed, then qimage2ndarray needs updating. Should be a rather local change. |
see issue #16: - collect list of all formats, handle them more consistently - let core view method support 16 and 64 bit formats as well
On July 5th, Pypi has released the new version of pyqt 5! (5.13). The current version is now compatible with RGBA / RGBX and grayscale 16 bit! |
Thanks for the info. Let me dump my brain here, while I am not able to work on this quickly enough myself:
|
Hello
|
no news ? |
W.r.t. news, you may have noticed that I worked quite a bit on this in the master branch. However, it is much more work than I thought. As indicated above, one needs to first work on the opposite direction. Since qimage2ndarray should not depend on PyQt 5.13+ (in fact, it must not even depend on PyQt), it needs to dynamically detect the availability of higher bit depths. Furthermore, the test suite must run fine with different versions of PyQt, PySide, PythonQt, Qt and Python itself, so we want conditional tests. Any help is appreciated, potentially also with CI (issue #20). |
Hello.
I use your lib in my code : https://github.com/gehelem/als (alpha branch).
But i use this lib for astronomic picture. For this, i need visualization in 16bit x3 ( for RGB picture).
currently I do not know if your library manages conversion to qimage 48bits.
In my code i convert in qimage and after i convert qimage to qpixmap.
before i used Opencv for create 48bit tiff picture and i use qpixmap for read this image (but it's slow).
Thanks for help
The text was updated successfully, but these errors were encountered: