###

#

pixel_based.hpp
//
// Copyright 2005-2007 Adobe Systems Incorporated
//
// Distributed under the Boost Software License, Version 1.0
// See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt
//
#ifndef BOOST_GIL_CONCEPTS_PIXEL_BASED_HPP
#define BOOST_GIL_CONCEPTS_PIXEL_BASED_HPP
#include <boost/gil/concepts/basic.hpp>
#include <boost/gil/concepts/channel.hpp>
#include <boost/gil/concepts/color.hpp>
#include <boost/gil/concepts/concept_check.hpp>
#include <boost/gil/concepts/fwd.hpp>
#include <cstddef>
#if defined(BOOST_CLANG)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wunknown-pragmas"
#pragma clang diagnostic ignored "-Wunused-local-typedefs"
#endif
#if defined(BOOST_GCC) && (BOOST_GCC >= 40900)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-local-typedefs"
#endif
namespace boost { namespace gil {
template <typename P>
struct PixelBasedConcept
{
void constraints()
{
using color_space_t = typename color_space_type<P>::type;
gil_function_requires<ColorSpaceConcept<color_space_t>>();
using channel_mapping_t = typename channel_mapping_type<P>::type ;
gil_function_requires<ChannelMappingConcept<channel_mapping_t>>();
static const bool planar = is_planar<P>::value;
ignore_unused_variable_warning(planar);
// This is not part of the concept, but should still work
static const std::size_t nc = num_channels<P>::value;
ignore_unused_variable_warning(nc);
}
};
template <typename P>
struct HomogeneousPixelBasedConcept
{
void constraints()
{
gil_function_requires<PixelBasedConcept<P>>();
using channel_t = typename channel_type<P>::type;
gil_function_requires<ChannelConcept<channel_t>>();
}
};
}} // namespace boost::gil
#if defined(BOOST_CLANG)
#pragma clang diagnostic pop
#endif
#if defined(BOOST_GCC) && (BOOST_GCC >= 40900)
#pragma GCC diagnostic pop
#endif
#endif
boost
defined(BOOST_NO_CXX17_HDR_MEMORY_RESOURCE)
Definition: algorithm.hpp:36
boost::gil::HomogeneousPixelBasedConcept
Concept for homogeneous pixel-based GIL constructs.
Definition: pixel_based.hpp:83
boost::gil::PixelBasedConcept
Concept for all pixel-based GIL constructs.
Definition: pixel_based.hpp:53
boost::gil::channel_type
Definition: color_convert.hpp:31
boost::gil::num_channels
Returns the number of channels of a pixel-based GIL construct.
Definition: locator.hpp:38