Boost GIL


cmyk.hpp
Go to the documentation of this file.
1 /*
2  Copyright 2005-2007 Adobe Systems Incorporated
3 
4  Use, modification and distribution are subject to the Boost Software License,
5  Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
6  http://www.boost.org/LICENSE_1_0.txt).
7 
8  See http://opensource.adobe.com/gil for most recent version including documentation.
9 */
10 
11 /*************************************************************************************************/
12 
13 #ifndef GIL_CMYK_H
14 #define GIL_CMYK_H
15 
23 
24 #include <cstddef>
25 
26 #include <boost/config.hpp>
27 #include <boost/mpl/range_c.hpp>
28 #include <boost/mpl/vector_c.hpp>
29 
30 #include "gil_config.hpp"
31 #include "metafunctions.hpp"
32 
33 namespace boost { namespace gil {
34 
37 
39 struct cyan_t {};
40 
42 struct magenta_t {};
43 
45 struct yellow_t {};
46 
48 struct black_t {};
50 
52 typedef mpl::vector4<cyan_t,magenta_t,yellow_t,black_t> cmyk_t;
53 
56 
59 template <typename IC>
61 planar_cmyk_view(std::size_t width, std::size_t height, IC c, IC m, IC y, IC k, std::ptrdiff_t rowsize_in_bytes) {
62  typedef typename type_from_x_iterator<planar_pixel_iterator<IC,cmyk_t> >::view_t RView;
63  return RView(width, height, typename RView::locator(planar_pixel_iterator<IC,cmyk_t>(c,m,y,k), rowsize_in_bytes));
64 }
65 
66 } } // namespace gil
67 
68 #endif
Magenta.
Definition: cmyk.hpp:42
Yellow.
Definition: cmyk.hpp:45
metafunctions that construct types or return type properties
An iterator over planar pixels. Models HomogeneousColorBaseConcept, PixelIteratorConcept, HomogeneousPixelBasedConcept, MemoryBasedIteratorConcept, HasDynamicXStepTypeConcept.
Definition: algorithm.hpp:53
Given a pixel iterator defining access to pixels along a row, returns the types of the corresponding ...
Definition: metafunctions.hpp:252
Represents a color space and ordering of channels in memory.
Definition: utilities.hpp:317
Black.
Definition: cmyk.hpp:48
GIL configuration file.
Cyan.
Definition: cmyk.hpp:39
type_from_x_iterator< planar_pixel_iterator< IC, cmyk_t > >::view_t planar_cmyk_view(std::size_t width, std::size_t height, IC c, IC m, IC y, IC k, std::ptrdiff_t rowsize_in_bytes)
from raw CMYK planar data
Definition: cmyk.hpp:61