• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<html>
2<head>
3<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
4<title>strategy::distance::projected_point</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 1. Geometry">
8<link rel="up" href="../strategies.html" title="Strategies">
9<link rel="prev" href="strategy_distance_haversine.html" title="strategy::distance::haversine">
10<link rel="next" href="strategy_distance_cross_track.html" title="strategy::distance::cross_track">
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="strategy_distance_haversine.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../strategies.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="strategy_distance_cross_track.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a>
24</div>
25<div class="section">
26<div class="titlepage"><div><div><h4 class="title">
27<a name="geometry.reference.strategies.strategy_distance_projected_point"></a><a class="link" href="strategy_distance_projected_point.html" title="strategy::distance::projected_point">strategy::distance::projected_point</a>
28</h4></div></div></div>
29<p>
30          <a class="indexterm" name="idm45635668910032"></a><a class="indexterm" name="idm45635668909344"></a><a class="indexterm" name="idm45635668908656"></a>
31Strategy for distance point to segment.
32        </p>
33<h6>
34<a name="geometry.reference.strategies.strategy_distance_projected_point.h0"></a>
35          <span class="phrase"><a name="geometry.reference.strategies.strategy_distance_projected_point.description"></a></span><a class="link" href="strategy_distance_projected_point.html#geometry.reference.strategies.strategy_distance_projected_point.description">Description</a>
36        </h6>
37<p>
38          Calculates distance using projected-point method, and (optionally) Pythagoras
39        </p>
40<h6>
41<a name="geometry.reference.strategies.strategy_distance_projected_point.h1"></a>
42          <span class="phrase"><a name="geometry.reference.strategies.strategy_distance_projected_point.synopsis"></a></span><a class="link" href="strategy_distance_projected_point.html#geometry.reference.strategies.strategy_distance_projected_point.synopsis">Synopsis</a>
43        </h6>
44<p>
45</p>
46<pre class="programlisting"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> <span class="identifier">CalculationType</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">Strategy</span><span class="special">&gt;</span>
47<span class="keyword">class</span> <span class="identifier">strategy</span><span class="special">::</span><span class="identifier">distance</span><span class="special">::</span><span class="identifier">projected_point</span>
48<span class="special">{</span>
49  <span class="comment">// ...</span>
50<span class="special">};</span>
51</pre>
52<p>
53        </p>
54<h6>
55<a name="geometry.reference.strategies.strategy_distance_projected_point.h2"></a>
56          <span class="phrase"><a name="geometry.reference.strategies.strategy_distance_projected_point.template_parameter_s_"></a></span><a class="link" href="strategy_distance_projected_point.html#geometry.reference.strategies.strategy_distance_projected_point.template_parameter_s_">Template
57          parameter(s)</a>
58        </h6>
59<div class="informaltable"><table class="table">
60<colgroup>
61<col>
62<col>
63<col>
64</colgroup>
65<thead><tr>
66<th>
67                  <p>
68                    Parameter
69                  </p>
70                </th>
71<th>
72                  <p>
73                    Default
74                  </p>
75                </th>
76<th>
77                  <p>
78                    Description
79                  </p>
80                </th>
81</tr></thead>
82<tbody>
83<tr>
84<td>
85                  <p>
86                    typename CalculationType
87                  </p>
88                </td>
89<td>
90                  <p>
91                    void
92                  </p>
93                </td>
94<td>
95                  <p>
96                    numeric type for calculation (e.g. high precision); if <span class="bold"><strong>void</strong></span> then it is extracted automatically
97                    from the coordinate type and (if necessary) promoted to floating
98                    point
99                  </p>
100                </td>
101</tr>
102<tr>
103<td>
104                  <p>
105                    typename Strategy
106                  </p>
107                </td>
108<td>
109                  <p>
110                    pythagoras&lt;CalculationType&gt;
111                  </p>
112                </td>
113<td>
114                  <p>
115                    underlying point-point distance strategy
116                  </p>
117                </td>
118</tr>
119</tbody>
120</table></div>
121<h6>
122<a name="geometry.reference.strategies.strategy_distance_projected_point.h3"></a>
123          <span class="phrase"><a name="geometry.reference.strategies.strategy_distance_projected_point.member_function_s_"></a></span><a class="link" href="strategy_distance_projected_point.html#geometry.reference.strategies.strategy_distance_projected_point.member_function_s_">Member
124          Function(s)</a>
125        </h6>
126<div class="informaltable"><table class="table">
127<colgroup>
128<col>
129<col>
130<col>
131<col>
132</colgroup>
133<thead><tr>
134<th>
135                  <p>
136                    Function
137                  </p>
138                </th>
139<th>
140                  <p>
141                    Description
142                  </p>
143                </th>
144<th>
145                  <p>
146                    Parameters
147                  </p>
148                </th>
149<th>
150                  <p>
151                    Returns
152                  </p>
153                </th>
154</tr></thead>
155<tbody>
156<tr>
157<td>
158                  <p>
159</p>
160<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">relate_segment_segment_strategy_type</span> <span class="identifier">get_relate_segment_segment_strategy</span><span class="special">()</span></pre>
161<p>
162                  </p>
163                </td>
164<td>
165                </td>
166<td>
167                </td>
168<td>
169                </td>
170</tr>
171<tr>
172<td>
173                  <p>
174</p>
175<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="identifier">point_in_geometry_strategy_type</span> <span class="identifier">get_point_in_geometry_strategy</span><span class="special">()</span></pre>
176<p>
177                  </p>
178                </td>
179<td>
180                </td>
181<td>
182                </td>
183<td>
184                </td>
185</tr>
186<tr>
187<td>
188                  <p>
189</p>
190<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> <span class="identifier">Point</span><span class="special">,</span> <span class="keyword">typename</span> <span class="identifier">PointOfSegment</span><span class="special">&gt;</span>
191<span class="identifier">calculation_type</span><span class="special">&lt;</span> <span class="identifier">Point</span><span class="special">,</span> <span class="identifier">PointOfSegment</span> <span class="special">&gt;::</span><span class="identifier">type</span> <span class="identifier">apply</span><span class="special">(</span><span class="identifier">Point</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">p</span><span class="special">,</span> <span class="identifier">PointOfSegment</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">p1</span><span class="special">,</span> <span class="identifier">PointOfSegment</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">p2</span><span class="special">)</span></pre>
192<p>
193                  </p>
194                </td>
195<td>
196                </td>
197<td>
198                  <p>
199                    <span class="bold"><strong>Point const &amp;</strong></span>: <span class="emphasis"><em>p</em></span>:
200                  </p>
201                  <p>
202                    <span class="bold"><strong>PointOfSegment const &amp;</strong></span>:
203                    <span class="emphasis"><em>p1</em></span>:
204                  </p>
205                  <p>
206                    <span class="bold"><strong>PointOfSegment const &amp;</strong></span>:
207                    <span class="emphasis"><em>p2</em></span>:
208                  </p>
209                </td>
210<td>
211                </td>
212</tr>
213<tr>
214<td>
215                  <p>
216</p>
217<pre xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="table-programlisting"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> <span class="identifier">CT</span><span class="special">&gt;</span>
218<span class="identifier">CT</span> <span class="identifier">vertical_or_meridian</span><span class="special">(</span><span class="identifier">CT</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">lat1</span><span class="special">,</span> <span class="identifier">CT</span> <span class="keyword">const</span> <span class="special">&amp;</span> <span class="identifier">lat2</span><span class="special">)</span></pre>
219<p>
220                  </p>
221                </td>
222<td>
223                </td>
224<td>
225                  <p>
226                    <span class="bold"><strong>CT const &amp;</strong></span>: <span class="emphasis"><em>lat1</em></span>:
227                  </p>
228                  <p>
229                    <span class="bold"><strong>CT const &amp;</strong></span>: <span class="emphasis"><em>lat2</em></span>:
230                  </p>
231                </td>
232<td>
233                </td>
234</tr>
235</tbody>
236</table></div>
237<h6>
238<a name="geometry.reference.strategies.strategy_distance_projected_point.h4"></a>
239          <span class="phrase"><a name="geometry.reference.strategies.strategy_distance_projected_point.header"></a></span><a class="link" href="strategy_distance_projected_point.html#geometry.reference.strategies.strategy_distance_projected_point.header">Header</a>
240        </h6>
241<p>
242          <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">strategies</span><span class="special">/</span><span class="identifier">cartesian</span><span class="special">/</span><span class="identifier">distance_projected_point</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">&gt;</span></code>
243        </p>
244<h6>
245<a name="geometry.reference.strategies.strategy_distance_projected_point.h5"></a>
246          <span class="phrase"><a name="geometry.reference.strategies.strategy_distance_projected_point.see_also"></a></span><a class="link" href="strategy_distance_projected_point.html#geometry.reference.strategies.strategy_distance_projected_point.see_also">See
247          also</a>
248        </h6>
249<p>
250          <a class="link" href="../algorithms/distance/distance_3_with_strategy.html" title="distance (with strategy)">distance
251          (with strategy)</a>
252        </p>
253</div>
254<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
255<td align="left"></td>
256<td align="right"><div class="copyright-footer">Copyright © 2009-2019 Barend Gehrels, Bruno Lalande, Mateusz Loskot, Adam
257      Wulkiewicz, Oracle and/or its affiliates<p>
258        Distributed under the Boost Software License, Version 1.0. (See accompanying
259        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>)
260      </p>
261</div></td>
262</tr></table>
263<hr>
264<div class="spirit-nav">
265<a accesskey="p" href="strategy_distance_haversine.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../strategies.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="strategy_distance_cross_track.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a>
266</div>
267</body>
268</html>
269