Displat Depth image in PyQT4
-
@Lucien said in Displat Depth image in PyQT4:
May I know what alternative can I do to display this type of Image?
You could search for a library which can convert this format into something Qt supports (like PNG or JPEG).
-
@Lucien said in Displat Depth image in PyQT4:
what I want to do is to display a 2D depth map on PyQT
You can show pictures in a QLabel:
Or you can paint the picture on a widget in its https://doc.qt.io/qt-5/qwidget.html#paintEvent
-
Hi thanks for the input again,
I understand QT can display color images. But what i really want is to display a depth map. The depth map is obtain in ROS by my depth camera (theres no RGB component in it).
P.S. I have extracted this from a source in google.I saw most of the QPixmap and QImage.format requires some colors in it (RGB/Mono/Grayscale) which does not fit in.
-
@Lucien said in Displat Depth image in PyQT4:
requires some colors in it (RGB/Mono/Grayscale) which does not fit in
Mono and greyscale do not have colors, so don't know what the problem is...
"QImage::Format_Mono 1 The image is stored using 1-bit per pixel. Bytes are packed with the most significant bit (MSB) first.".
"QImage::Format_Grayscale8 24 The image is stored using an 8-bit grayscale format. (added in Qt 5.5)
QImage::Format_Grayscale16 28 The image is stored using an 16-bit grayscale format. (added in Qt 5.13)"