]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/gil/test/extension/dynamic_image/any_image.cpp
2 // Copyright 2020 Samuel Debionne
4 // Distributed under the Boost Software License, Version 1.0
5 // See accompanying file LICENSE_1_0.txt or copy at
6 // http://www.boost.org/LICENSE_1_0.txt
8 #include <boost/gil.hpp>
9 #include <boost/gil/extension/dynamic_image/any_image.hpp>
11 #include <boost/core/lightweight_test.hpp>
13 #include "test_fixture.hpp"
14 #include "core/image/test_fixture.hpp"
16 namespace gil
= boost::gil
;
17 namespace fixture
= boost::gil::test::fixture
;
19 struct test_any_image_move_ctor
21 template <typename Image
>
22 void operator()(Image
const&)
24 using image_t
= Image
;
25 fixture::dynamic_image
i0(fixture::create_image
<image_t
>(4, 4, 128));
26 BOOST_TEST_EQ(i0
.dimensions().x
, 4);
27 BOOST_TEST_EQ(i0
.dimensions().y
, 4);
29 fixture::dynamic_image i1
= fixture::create_image
<image_t
>(4, 4, 128);
30 BOOST_TEST_EQ(i1
.dimensions().x
, 4);
31 BOOST_TEST_EQ(i1
.dimensions().y
, 4);
35 boost::mp11::mp_for_each
<fixture::image_types
>(test_any_image_move_ctor
{});
42 test_any_image_move_ctor::run();
44 return ::boost::report_errors();