u_format: Define tests for r3g3b2 formats and fix BE swizzles for them.
These tests passed for LE, and the BE channel ordering specified obviously didn't fit the pattern of the other BE formats (channels are listed right-to-left in the BE columns for historical reasons). Note that we can't write pure-integer format tests in u_format_tests.c currently. Acked-by: Adam Jackson <ajax@redhat.com> Acked-by: Ilia Mirkin <imirkin@alum.mit.edu> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10505>
This commit is contained in:
@@ -1048,7 +1048,13 @@ util_format_test_cases[] =
|
||||
/*
|
||||
* Special formats that not fit anywhere else
|
||||
*/
|
||||
{PIPE_FORMAT_R3G3B2_UNORM, PACKED_1x8(0xff), PACKED_1x8(0x07), UNPACKED_1x1(1.0, 0.0, 0.0, 1.0)},
|
||||
{PIPE_FORMAT_R3G3B2_UNORM, PACKED_1x8(0xff), PACKED_1x8(0x38), UNPACKED_1x1(0.0, 1.0, 0.0, 1.0)},
|
||||
{PIPE_FORMAT_R3G3B2_UNORM, PACKED_1x8(0xff), PACKED_1x8(0xc0), UNPACKED_1x1(0.0, 0.0, 1.0, 1.0)},
|
||||
|
||||
{PIPE_FORMAT_B2G3R3_UNORM, PACKED_1x8(0xff), PACKED_1x8(0x03), UNPACKED_1x1(0.0, 0.0, 1.0, 1.0)},
|
||||
{PIPE_FORMAT_B2G3R3_UNORM, PACKED_1x8(0xff), PACKED_1x8(0x1c), UNPACKED_1x1(0.0, 1.0, 0.0, 1.0)},
|
||||
{PIPE_FORMAT_B2G3R3_UNORM, PACKED_1x8(0xff), PACKED_1x8(0xe0), UNPACKED_1x1(1.0, 0.0, 0.0, 1.0)},
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user