Imported Upstream version 1.72.0
[platform/upstream/boost.git] / libs / geometry / doc / html / geometry / reference / algorithms / make / make_3_3_coordinate_values.html
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
4 <title>make (3 coordinate values)</title>
5 <link rel="stylesheet" href="../../../../../../../../doc/src/boostbook.css" type="text/css">
6 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
7 <link rel="home" href="../../../../index.html" title="Chapter&#160;1.&#160;Geometry">
8 <link rel="up" href="../make.html" title="make">
9 <link rel="prev" href="make_2_2_coordinate_values.html" title="make (2 coordinate values)">
10 <link rel="next" href="make_inverse.html" title="make_inverse">
11 </head>
12 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13 <table cellpadding="2" width="100%"><tr>
14 <td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../../boost.png"></td>
15 <td align="center"><a href="../../../../../../../../index.html">Home</a></td>
16 <td align="center"><a href="../../../../../../../../libs/libraries.htm">Libraries</a></td>
17 <td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
18 <td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
19 <td align="center"><a href="../../../../../../../../more/index.htm">More</a></td>
20 </tr></table>
21 <hr>
22 <div class="spirit-nav">
23 <a accesskey="p" href="make_2_2_coordinate_values.html"><img src="../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../make.html"><img src="../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="make_inverse.html"><img src="../../../../../../../../doc/src/images/next.png" alt="Next"></a>
24 </div>
25 <div class="section">
26 <div class="titlepage"><div><div><h5 class="title">
27 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values"></a><a class="link" href="make_3_3_coordinate_values.html" title="make (3 coordinate values)">make
28           (3 coordinate values)</a>
29 </h5></div></div></div>
30 <p>
31             <a class="indexterm" name="idm46186994293792"></a>
32 Construct a geometry.
33           </p>
34 <h6>
35 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.h0"></a>
36             <span class="phrase"><a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.synopsis"></a></span><a class="link" href="make_3_3_coordinate_values.html#geometry.reference.algorithms.make.make_3_3_coordinate_values.synopsis">Synopsis</a>
37           </h6>
38 <p>
39 </p>
40 <pre class="programlisting"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> <span class="identifier">Geometry</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Type</span><span class="special">&gt;</span>
41 <span class="identifier">Geometry</span> <span class="identifier">make</span><span class="special">(</span><span class="identifier">Type</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">c1</span><span class="special">,</span> <span class="identifier">Type</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">c2</span><span class="special">,</span> <span class="identifier">Type</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">c3</span><span class="special">)</span></pre>
42 <p>
43           </p>
44 <h6>
45 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.h1"></a>
46             <span class="phrase"><a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.parameters"></a></span><a class="link" href="make_3_3_coordinate_values.html#geometry.reference.algorithms.make.make_3_3_coordinate_values.parameters">Parameters</a>
47           </h6>
48 <div class="informaltable"><table class="table">
49 <colgroup>
50 <col>
51 <col>
52 <col>
53 <col>
54 </colgroup>
55 <thead><tr>
56 <th>
57                     <p>
58                       Type
59                     </p>
60                   </th>
61 <th>
62                     <p>
63                       Concept
64                     </p>
65                   </th>
66 <th>
67                     <p>
68                       Name
69                     </p>
70                   </th>
71 <th>
72                     <p>
73                       Description
74                     </p>
75                   </th>
76 </tr></thead>
77 <tbody>
78 <tr>
79 <td>
80                     <p>
81                       Geometry
82                     </p>
83                   </td>
84 <td>
85                     <p>
86                       Any type fulfilling a Geometry Concept
87                     </p>
88                   </td>
89 <td>
90                     <p>
91                       -
92                     </p>
93                   </td>
94 <td>
95                     <p>
96                       Must be specified
97                     </p>
98                   </td>
99 </tr>
100 <tr>
101 <td>
102                     <p>
103                       Type const &amp;
104                     </p>
105                   </td>
106 <td>
107                     <p>
108                       numerical type (int, double, ttmath, ...) to specify the coordinates
109                     </p>
110                   </td>
111 <td>
112                     <p>
113                       c1
114                     </p>
115                   </td>
116 <td>
117                     <p>
118                       First coordinate (usually x-coordinate)
119                     </p>
120                   </td>
121 </tr>
122 <tr>
123 <td>
124                     <p>
125                       Type const &amp;
126                     </p>
127                   </td>
128 <td>
129                     <p>
130                       numerical type (int, double, ttmath, ...) to specify the coordinates
131                     </p>
132                   </td>
133 <td>
134                     <p>
135                       c2
136                     </p>
137                   </td>
138 <td>
139                     <p>
140                       Second coordinate (usually y-coordinate)
141                     </p>
142                   </td>
143 </tr>
144 <tr>
145 <td>
146                     <p>
147                       Type const &amp;
148                     </p>
149                   </td>
150 <td>
151                     <p>
152                       numerical type (int, double, ttmath, ...) to specify the coordinates
153                     </p>
154                   </td>
155 <td>
156                     <p>
157                       c3
158                     </p>
159                   </td>
160 <td>
161                     <p>
162                       Third coordinate (usually z-coordinate)
163                     </p>
164                   </td>
165 </tr>
166 </tbody>
167 </table></div>
168 <h6>
169 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.h2"></a>
170             <span class="phrase"><a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.returns"></a></span><a class="link" href="make_3_3_coordinate_values.html#geometry.reference.algorithms.make.make_3_3_coordinate_values.returns">Returns</a>
171           </h6>
172 <p>
173             The constructed geometry, here: a 3D point
174           </p>
175 <h6>
176 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.h3"></a>
177             <span class="phrase"><a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.header"></a></span><a class="link" href="make_3_3_coordinate_values.html#geometry.reference.algorithms.make.make_3_3_coordinate_values.header">Header</a>
178           </h6>
179 <p>
180             Either
181           </p>
182 <p>
183             <code class="computeroutput"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">geometry</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span></code>
184           </p>
185 <p>
186             Or
187           </p>
188 <p>
189             <code class="computeroutput"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">geometry</span><span class="special">/</span><span class="identifier">algorithms</span><span class="special">/</span><span class="identifier">make</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span></code>
190           </p>
191 <h6>
192 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.h4"></a>
193             <span class="phrase"><a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.example"></a></span><a class="link" href="make_3_3_coordinate_values.html#geometry.reference.algorithms.make.make_3_3_coordinate_values.example">Example</a>
194           </h6>
195 <p>
196             Using make to construct a three dimensional point
197           </p>
198 <p>
199 </p>
200 <pre class="programlisting"><span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">iostream</span><span class="special">&gt;</span>
201
202 <span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">geometry</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
203 <span class="preprocessor">#include</span> <span class="special">&lt;</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">geometry</span><span class="special">/</span><span class="identifier">geometries</span><span class="special">/</span><span class="identifier">point</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span>
204
205 <span class="keyword">int</span> <span class="identifier">main</span><span class="special">()</span>
206 <span class="special">{</span>
207     <span class="keyword">typedef</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">geometry</span><span class="special">::</span><span class="identifier">model</span><span class="special">::</span><span class="identifier">point</span><span class="special">&lt;</span><span class="keyword">double</span><span class="special">,</span> <span class="number">3</span><span class="special">,</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">geometry</span><span class="special">::</span><span class="identifier">cs</span><span class="special">::</span><span class="identifier">cartesian</span><span class="special">&gt;</span> <span class="identifier">point_type</span><span class="special">;</span>
208     <span class="identifier">point_type</span> <span class="identifier">p</span> <span class="special">=</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">geometry</span><span class="special">::</span><span class="identifier">make</span><span class="special">&lt;</span><span class="identifier">point_type</span><span class="special">&gt;(</span><span class="number">1</span><span class="special">,</span> <span class="number">2</span><span class="special">,</span> <span class="number">3</span><span class="special">);</span>
209     <span class="identifier">std</span><span class="special">::</span><span class="identifier">cout</span> <span class="special">&lt;&lt;</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">geometry</span><span class="special">::</span><span class="identifier">dsv</span><span class="special">(</span><span class="identifier">p</span><span class="special">)</span> <span class="special">&lt;&lt;</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">endl</span><span class="special">;</span>
210     <span class="keyword">return</span> <span class="number">0</span><span class="special">;</span>
211 <span class="special">}</span>
212 </pre>
213 <p>
214           </p>
215 <p>
216             Output:
217           </p>
218 <pre class="programlisting">(1, 2, 3)
219 </pre>
220 <h6>
221 <a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.h5"></a>
222             <span class="phrase"><a name="geometry.reference.algorithms.make.make_3_3_coordinate_values.see_also"></a></span><a class="link" href="make_3_3_coordinate_values.html#geometry.reference.algorithms.make.make_3_3_coordinate_values.see_also">See
223             also</a>
224           </h6>
225 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
226                 <a class="link" href="../assign/assign_values_4_3_coordinate_values.html" title="assign_values (3 coordinate values)">assign</a>
227               </li></ul></div>
228 </div>
229 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
230 <td align="left"></td>
231 <td align="right"><div class="copyright-footer">Copyright &#169; 2009-2019 Barend Gehrels, Bruno Lalande, Mateusz Loskot, Adam
232       Wulkiewicz, Oracle and/or its affiliates<p>
233         Distributed under the Boost Software License, Version 1.0. (See accompanying
234         file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
235       </p>
236 </div></td>
237 </tr></table>
238 <hr>
239 <div class="spirit-nav">
240 <a accesskey="p" href="make_2_2_coordinate_values.html"><img src="../../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../make.html"><img src="../../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../../index.html"><img src="../../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="make_inverse.html"><img src="../../../../../../../../doc/src/images/next.png" alt="Next"></a>
241 </div>
242 </body>
243 </html>