gil icon indicating copy to clipboard operation
gil copied to clipboard

Add test suite for color_convert and default_color_converter

Open mloskot opened this issue 5 years ago • 3 comments

We need to start a detailed test cases coverage for color conversion algorithms:

  • Add test/core/pixel/color_convert.cpp
  • Use Boost.Test to define test cases using BOOST_AUTO_TEST_CASE or BOOST_AUTO_TEST_CASE_TEMPLATE
  • Add test cases for each pre-defined specialisations of converters
  • Covert byte-based as well as bit-aligned and packed pixel types

It's a good idea to exercise the color_convert and default_color_converter using available interfaces, for example

gil::rgb8_pixel_t red(255, 0, 0);
... red2;

// three equivalent conversions
gil::color_convert(red1, red2);
gil::default_color_converter()(red1, red2);
red2 = gil::color_convert_deref_fn<gil::rgb8_ref_t, ...>()(red1);

mloskot avatar Feb 15 '20 20:02 mloskot

Hi, I would like to work on this issue.

pankaj-2407 avatar Feb 06 '21 12:02 pankaj-2407

Feel free to take on this. No need for permission. :D

lpranam avatar Feb 06 '21 12:02 lpranam

Thankyou @lpranam

pankaj-2407 avatar Feb 06 '21 12:02 pankaj-2407