Skip to content

UBSan: Fix incorrect conversion in TestYIQToRGB

David Gobbi requested to merge dgobbi/vtk:fix-test-yiq-to-rgb into master

The test performed the conversions using unsigned char, which is incorrect because the IQ components of YIQ are signed values. The conversion should be perfomed, ideally, with a floating-point type.

The problem was identified with UBSan, which detected the attempt to store signed values in an unsigned integer.

Merge request reports