Skip to content
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

tests: match tiffdecode test calls to signature #1317

Merged
merged 1 commit into from
Sep 21, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions tests/tiffdecode.cc
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,13 @@ void checkMono(InputImage input_image) {
REQUIRE(heif_image_get_height(image, heif_channel_Y) == 64);
REQUIRE(heif_image_get_bits_per_pixel(image, heif_channel_Y) == 8);
REQUIRE(heif_image_get_bits_per_pixel_range(image, heif_channel_Y) == 8);
REQUIRE(heif_image_has_channel(image, heif_channel_Y) == true);
REQUIRE(heif_image_has_channel(image, heif_channel_R) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_G) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_B) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_interleaved) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Cr) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Cb) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Y) == 1);
REQUIRE(heif_image_has_channel(image, heif_channel_R) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_G) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_B) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_interleaved) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_Cr) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_Cb) == 0);
}

TEST_CASE("mono8") {
Expand Down Expand Up @@ -79,13 +79,13 @@ void checkRGB(InputImage input_image) {
REQUIRE(heif_image_get_height(image, heif_channel_interleaved) == 10);
REQUIRE(heif_image_get_bits_per_pixel(image, heif_channel_interleaved) == 24);
REQUIRE(heif_image_get_bits_per_pixel_range(image, heif_channel_interleaved) == 8);
REQUIRE(heif_image_has_channel(image, heif_channel_Y) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_R) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_G) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_B) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_interleaved) == true);
REQUIRE(heif_image_has_channel(image, heif_channel_Cr) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Cb) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Y) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_R) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_G) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_B) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_interleaved) == 1);
REQUIRE(heif_image_has_channel(image, heif_channel_Cr) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_Cb) == 0);
}

TEST_CASE("rgb") {
Expand Down Expand Up @@ -115,13 +115,13 @@ void checkRGBA(InputImage input_image) {
REQUIRE(heif_image_get_height(image, heif_channel_interleaved) == 10);
REQUIRE(heif_image_get_bits_per_pixel(image, heif_channel_interleaved) == 32);
REQUIRE(heif_image_get_bits_per_pixel_range(image, heif_channel_interleaved) == 8);
REQUIRE(heif_image_has_channel(image, heif_channel_Y) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_R) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_G) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_B) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_interleaved) == true);
REQUIRE(heif_image_has_channel(image, heif_channel_Cr) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Cb) == false);
REQUIRE(heif_image_has_channel(image, heif_channel_Y) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_R) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_G) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_B) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_interleaved) == 1);
REQUIRE(heif_image_has_channel(image, heif_channel_Cr) == 0);
REQUIRE(heif_image_has_channel(image, heif_channel_Cb) == 0);
}

TEST_CASE("rgba") {
Expand Down
Loading