]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | <!-- Copyright 2008 Lubomir Bourdev and Hailin Jin |
2 | ||
3 | Distributed under the Boost Software License, Version 1.0. | |
4 | (See accompanying file LICENSE_1_0.txt or copy at | |
5 | http://www.boost.org/LICENSE_1_0.txt) | |
6 | --> | |
7 | ||
8 | <!-- | |
9 | Copyright 2005-2007 Adobe Systems Incorporated | |
10 | Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt | |
11 | or a copy at http://stlab.adobe.com/licenses.html) | |
12 | ||
13 | Some files are held under additional license. | |
14 | Please see "http://stlab.adobe.com/licenses.html" for more information. | |
15 | --> | |
16 | ||
17 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" | |
18 | "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | |
19 | <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> | |
20 | ||
21 | <head> | |
22 | <TITLE>Generic Image Library: static_for_each</TITLE> | |
23 | <META HTTP-EQUIV="content-type" CONTENT="text/html;charset=ISO-8859-1"/> | |
24 | <LINK TYPE="text/css" REL="stylesheet" HREF="adobe_source.css"/> | |
25 | </head> | |
26 | <body> | |
27 | <table border="0" cellspacing="0" cellpadding="0" style='width: 100%; margin: 0; padding: 0'><tr> | |
28 | <td width="100%" valign="top" style='padding-left: 10px; padding-right: 10px; padding-bottom: 10px'> | |
29 | <div class="qindex"><a class="qindex" href="index.html">Modules</a> | |
30 | | <a class="qindex" href="classes.html">Alphabetical List</a> | |
31 | | <a class="qindex" href="annotated.html">Class List</a> | |
32 | | <a class="qindex" href="dirs.html">Directories</a> | |
33 | | <a class="qindex" href="files.html">File List</a> | |
34 | | <a class="qindex" href="../index.html">GIL Home Page</a> | |
35 | </div> | |
36 | <!-- End Header --> | |
37 | <!-- Generated by Doxygen 1.5.6 --> | |
38 | <div class="contents"> | |
39 | <h1>static_for_each<br> | |
40 | <small> | |
41 | [<a class="el" href="g_i_l_0105.html">Algorithms and Utility Functions</a>]</small> | |
42 | </h1><hr><a name="_details"></a><h2>Detailed Description</h2> | |
43 | Equivalent to std::for_each. Pairs the elements semantically. | |
44 | <p> | |
45 | Example: Use static_for_each to increment a planar <a class="el" href="g_i_l_0599.html" title="Represents a pixel value (a container of channels). Models: HomogeneousColorBaseValueConcept...">pixel</a> iterator <div class="fragment"><pre class="fragment"><span class="keyword">struct </span>increment { | |
46 | <span class="keyword">template</span> <<span class="keyword">typename</span> Incrementable> | |
47 | <span class="keywordtype">void</span> operator()(Incrementable& x)<span class="keyword"> const </span>{ ++x; } | |
48 | }; | |
49 | ||
50 | <span class="keyword">template</span> <<span class="keyword">typename</span> ColorBase> | |
51 | <span class="keywordtype">void</span> increment_elements(ColorBase& cb) { | |
52 | static_for_each(cb, increment()); | |
53 | } | |
54 | ||
55 | bits8 red[2], green[2], blue[2]; | |
56 | rgb8c_planar_ptr_t p1(red,green,blue); | |
57 | rgb8c_planar_ptr_t p2=p1; | |
58 | increment_elements(p1); | |
59 | ++p2; | |
60 | assert(p1 == p2); | |
61 | </pre></div> | |
62 | <p> | |
63 | <table border="0" cellpadding="0" cellspacing="0"> | |
64 | <tr><td></td></tr> | |
65 | <tr><td colspan="2"><br><h2>Functions</h2></td></tr> | |
66 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gf2e41c8d53998663da3c834146b01c4e"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gf2e41c8d53998663da3c834146b01c4e" args="(P1 &p1, Op op)" --> | |
67 | template<typename P1, typename Op> </td></tr> | |
68 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, Op op)</td></tr> | |
69 | ||
70 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gbccefaf0f6714246e333707fd4b18c92"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gbccefaf0f6714246e333707fd4b18c92" args="(const P1 &p1, Op op)" --> | |
71 | template<typename P1, typename Op> </td></tr> | |
72 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, Op op)</td></tr> | |
73 | ||
74 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="g7b19d79a9a7af3d127f8bfc12c5414bb"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="g7b19d79a9a7af3d127f8bfc12c5414bb" args="(P1 &p1, P2 &p2, Op op)" --> | |
75 | template<typename P1, typename P2, typename Op> </td></tr> | |
76 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, P2 &p2, Op op)</td></tr> | |
77 | ||
78 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="ga8dc39f3c90000d80a8883cbb3bdec68"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="ga8dc39f3c90000d80a8883cbb3bdec68" args="(P1 &p1, const P2 &p2, Op op)" --> | |
79 | template<typename P1, typename P2, typename Op> </td></tr> | |
80 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, const P2 &p2, Op op)</td></tr> | |
81 | ||
82 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gb3437c620a66023701c72d981a143b8e"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gb3437c620a66023701c72d981a143b8e" args="(const P1 &p1, P2 &p2, Op op)" --> | |
83 | template<typename P1, typename P2, typename Op> </td></tr> | |
84 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, P2 &p2, Op op)</td></tr> | |
85 | ||
86 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gb88ddea7b5aa39a43aea948057a3d5b0"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gb88ddea7b5aa39a43aea948057a3d5b0" args="(const P1 &p1, const P2 &p2, Op op)" --> | |
87 | template<typename P1, typename P2, typename Op> </td></tr> | |
88 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, const P2 &p2, Op op)</td></tr> | |
89 | ||
90 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gf08ac9b7f0ea0c7923743177958b6018"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gf08ac9b7f0ea0c7923743177958b6018" args="(P1 &p1, P2 &p2, P3 &p3, Op op)" --> | |
91 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
92 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, P2 &p2, P3 &p3, Op op)</td></tr> | |
93 | ||
94 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="g0be9bf16d867badd456b2ff5012c7976"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="g0be9bf16d867badd456b2ff5012c7976" args="(P1 &p1, P2 &p2, const P3 &p3, Op op)" --> | |
95 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
96 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, P2 &p2, const P3 &p3, Op op)</td></tr> | |
97 | ||
98 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="g2453bb292d820f2b0b252ab1709b50a3"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="g2453bb292d820f2b0b252ab1709b50a3" args="(P1 &p1, const P2 &p2, P3 &p3, Op op)" --> | |
99 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
100 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, const P2 &p2, P3 &p3, Op op)</td></tr> | |
101 | ||
102 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gd94aed2b7d693ca78195e916b22560f0"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gd94aed2b7d693ca78195e916b22560f0" args="(P1 &p1, const P2 &p2, const P3 &p3, Op op)" --> | |
103 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
104 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (P1 &p1, const P2 &p2, const P3 &p3, Op op)</td></tr> | |
105 | ||
106 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="ge9aa8ea67dbcb72804cf611bdcd7703f"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="ge9aa8ea67dbcb72804cf611bdcd7703f" args="(const P1 &p1, P2 &p2, P3 &p3, Op op)" --> | |
107 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
108 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, P2 &p2, P3 &p3, Op op)</td></tr> | |
109 | ||
110 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="g383bf3f10129814de6df924f8b92cb22"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="g383bf3f10129814de6df924f8b92cb22" args="(const P1 &p1, P2 &p2, const P3 &p3, Op op)" --> | |
111 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
112 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, P2 &p2, const P3 &p3, Op op)</td></tr> | |
113 | ||
114 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="g2c07eb3c9202b2249b3b700545f288ec"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="g2c07eb3c9202b2249b3b700545f288ec" args="(const P1 &p1, const P2 &p2, P3 &p3, Op op)" --> | |
115 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
116 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, const P2 &p2, P3 &p3, Op op)</td></tr> | |
117 | ||
118 | <tr><td class="memTemplParams" nowrap colspan="2"><a class="anchor" name="gf298a75accb069d9ab1384c84b93c2ad"></a><!-- doxytag: member="ColorBaseAlgorithmForEach::static_for_each" ref="gf298a75accb069d9ab1384c84b93c2ad" args="(const P1 &p1, const P2 &p2, const P3 &p3, Op op)" --> | |
119 | template<typename P1, typename P2, typename P3, typename Op> </td></tr> | |
120 | <tr><td class="memTemplItemLeft" nowrap align="right" valign="top">GIL_FORCEINLINE Op </td><td class="memTemplItemRight" valign="bottom"><b>static_for_each</b> (const P1 &p1, const P2 &p2, const P3 &p3, Op op)</td></tr> | |
121 | ||
122 | </table> | |
123 | </div> | |
124 | <hr size="1"><address style="text-align: right;"><small>Generated on Sat May 2 13:50:17 2009 for Generic Image Library by | |
125 | <a href="http://www.doxygen.org/index.html"> | |
126 | <img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address> | |
127 | </body> | |
128 | </html> |