Weasis shows US image with a blue / magenta tint

70 views
Skip to first unread message

Jon Ander Zuccaro

unread,
Oct 3, 2022, 9:27:31 PM10/3/22
to dcm4che
Hi...
Some US images are shown with a weird blue tint.
This appears to be related to Weasis 4.x since they look fine with Weasis 3.7

Weirdly enough, the jpg generated via WADO looks fine.

The log shows no errors. Please see attachments.

Thanks!
Screenshot from 2022-10-03 21-11-18.png
89014b8b6b30fffdb7b567306397639b.dcm

Nicolas Roduit

unread,
Oct 10, 2022, 4:23:57 PM10/10/22
to dcm4che
Thanks for providing a sample. This image has an RGB value in the attribute Photometric Interpretation but in fact the color model type in the JPEG file is YCbCr. The problem is that in the DICOM standard it is the value in the DICOM metadata that takes precedence over the metadata in the jpeg file. Therefore, this image can be considered as corrupted and not conforming to the standard.

However, in this particular situation of an image in JPEG Baseline lossy syntax with an RGB color model, Weasis will try to detect the value in the JPEG metadata (required a complex algorithm) because JPEG Baseline lossy with an RGB model is not recommended but not forbidden either. I've discovered a bug in version 4 that I will fix in the next release.

This is the short version of this issue. It might be interesting in an example in the output of the ultrasound scanner because this image might have been corrupted by an older version of dcm4chee.

Jon Ander Zuccaro

unread,
Oct 10, 2022, 6:15:02 PM10/10/22
to dcm4che
Hello, thank you for the detailed answer. The images were sent from a wireless US device to an older version of dcm4chee 2.x indeed...

Currently I have no other way to extract any additional images directly without them being sent to the PACS first but thanks to your insights we "solved" the problem by coercing the Photometric Interpretation from RGB to YBR_FULL when receiving the images. They display correctly now.

Not sure if dcm4chee is to blame... I don't trust this particular modality nor any configurations or settings that it currently has... this could be a misconfiguration issue. 

I am glad this led to a discovery of a bug that will improve Weasis.

Nicolas Roduit

unread,
Oct 15, 2022, 2:14:14 PM10/15/22
to dcm4che
For JPEG Baseline, you must use YBR_FULL_422 instead of YBR_FULL because YBR_FULL cannot be used for the lossy type.

A new implementation has been made in Weasis 4.0.3 to detect the true color model in the JPEG Baseline file with an RGB value. It is the color model in the DICOM metadata that should be used but it is quite common to find images where the color model is wrong. These images can be produced by a modality or a workstation. There are also PACS or DICOM tools that change the color model in a way that is not consistent with the image.

Reply all
Reply to author
Forward
0 new messages