diff options
| author | Carl Hetherington <cth@carlh.net> | 2021-09-15 23:36:21 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2021-09-27 13:41:46 +0200 |
| commit | 3799e91d126d243d41c44dcb0ca1bfa66b53a57e (patch) | |
| tree | 74348b18d5ac0ef81bbebb27fe32862b22baa0b2 /test/video_level_test.cc | |
| parent | 9bfa07293928c371d59db2091ba2b7e715ce5994 (diff) | |
Replace aligned bool with enum Alignment.
Diffstat (limited to 'test/video_level_test.cc')
| -rw-r--r-- | test/video_level_test.cc | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/test/video_level_test.cc b/test/video_level_test.cc index 8d82e9d76..54513464c 100644 --- a/test/video_level_test.cc +++ b/test/video_level_test.cc @@ -54,7 +54,6 @@ using std::min; -using std::make_pair; using std::max; using std::pair; using std::string; @@ -71,7 +70,7 @@ static shared_ptr<Image> grey_image (dcp::Size size, uint8_t pixel) { - auto grey = make_shared<Image>(AV_PIX_FMT_RGB24, size, true); + auto grey = make_shared<Image>(AV_PIX_FMT_RGB24, size, Image::Alignment::PADDED); for (int y = 0; y < size.height; ++y) { uint8_t* p = grey->data()[0] + y * grey->stride()[0]; for (int x = 0; x < size.width; ++x) { @@ -94,7 +93,7 @@ BOOST_AUTO_TEST_CASE (ffmpeg_image_full_range_not_changed) write_image (grey_image(size, grey_pixel), file); FFmpegImageProxy proxy (file); - ImageProxy::Result result = proxy.image (false); + ImageProxy::Result result = proxy.image (Image::Alignment::COMPACT); BOOST_REQUIRE (!result.error); for (int y = 0; y < size.height; ++y) { @@ -128,7 +127,7 @@ BOOST_AUTO_TEST_CASE (ffmpeg_image_video_range_expanded) BOOST_REQUIRE (!player->pass()); } - auto image = player_video->image ([](AVPixelFormat f) { return f; }, VideoRange::FULL, true, false); + auto image = player_video->image ([](AVPixelFormat f) { return f; }, VideoRange::FULL, Image::Alignment::PADDED, false); for (int y = 0; y < size.height; ++y) { uint8_t* p = image->data()[0] + y * image->stride()[0]; @@ -214,7 +213,7 @@ pixel_range (shared_ptr<const Film> film, shared_ptr<const Content> content) BOOST_REQUIRE (!decoder->pass()); } - return pixel_range (content_video->image->image(false).image); + return pixel_range (content_video->image->image(Image::Alignment::COMPACT).image); } |
