blob: 6c1fcbcabed15c76d56f92c19c502fbd71674091 [file] [log] [blame]
Jenkins514be652019-02-28 12:25:18 +00001<!-- HTML header for doxygen 1.8.15-->
2<!-- Remember to use version doxygen 1.8.15 +-->
Jenkinsb9abeae2018-11-22 11:58:08 +00003<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
4<html xmlns="http://www.w3.org/1999/xhtml">
5<head>
6<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
7<meta http-equiv="X-UA-Compatible" content="IE=9"/>
Jenkins514be652019-02-28 12:25:18 +00008<meta name="generator" content="Doxygen 1.8.15"/>
Jenkinsb9abeae2018-11-22 11:58:08 +00009<meta name="robots" content="NOINDEX, NOFOLLOW" /> <!-- Prevent indexing by search engines -->
10<title>Compute Library: src/core/CL/cl_kernels/warp_helpers_quantized.h File Reference</title>
11<link href="tabs.css" rel="stylesheet" type="text/css"/>
12<script type="text/javascript" src="jquery.js"></script>
13<script type="text/javascript" src="dynsections.js"></script>
14<link href="navtree.css" rel="stylesheet" type="text/css"/>
15<script type="text/javascript" src="resize.js"></script>
16<script type="text/javascript" src="navtreedata.js"></script>
17<script type="text/javascript" src="navtree.js"></script>
18<script type="text/javascript">
Jenkins514be652019-02-28 12:25:18 +000019/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
Jenkinsb9abeae2018-11-22 11:58:08 +000020 $(document).ready(initResizable);
Jenkins514be652019-02-28 12:25:18 +000021/* @license-end */</script>
Jenkinsb9abeae2018-11-22 11:58:08 +000022<link href="search/search.css" rel="stylesheet" type="text/css"/>
23<script type="text/javascript" src="search/searchdata.js"></script>
24<script type="text/javascript" src="search/search.js"></script>
25<script type="text/x-mathjax-config">
26 MathJax.Hub.Config({
27 extensions: ["tex2jax.js"],
28 jax: ["input/TeX","output/HTML-CSS"],
29});
Jenkins514be652019-02-28 12:25:18 +000030</script><script type="text/javascript" async="async" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
Jenkinsb9abeae2018-11-22 11:58:08 +000031<link href="doxygen.css" rel="stylesheet" type="text/css" />
Jenkins514be652019-02-28 12:25:18 +000032<link href="stylesheet.css" rel="stylesheet" type="text/css"/>
Jenkinsb9abeae2018-11-22 11:58:08 +000033</head>
34<body>
35<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
36<div id="titlearea">
37<table cellspacing="0" cellpadding="0">
38 <tbody>
39 <tr style="height: 56px;">
Jenkins514be652019-02-28 12:25:18 +000040 <img alt="Compute Library" src="https://raw.githubusercontent.com/ARM-software/ComputeLibrary/gh-pages/ACL_logo.png" style="max-width: 100%;margin-top: 15px;margin-left: 10px"/>
Jenkinsb9abeae2018-11-22 11:58:08 +000041 <td style="padding-left: 0.5em;">
Jenkins514be652019-02-28 12:25:18 +000042 <div id="projectname">
43 &#160;<span id="projectnumber">19.02</span>
Jenkinsb9abeae2018-11-22 11:58:08 +000044 </div>
45 </td>
46 </tr>
47 </tbody>
48</table>
49</div>
50<!-- end header part -->
Jenkins514be652019-02-28 12:25:18 +000051<!-- Generated by Doxygen 1.8.15 -->
Jenkinsb9abeae2018-11-22 11:58:08 +000052<script type="text/javascript">
Jenkins514be652019-02-28 12:25:18 +000053/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
Jenkinsb9abeae2018-11-22 11:58:08 +000054var searchBox = new SearchBox("searchBox", "search",false,'Search');
Jenkins514be652019-02-28 12:25:18 +000055/* @license-end */
Jenkinsb9abeae2018-11-22 11:58:08 +000056</script>
57<script type="text/javascript" src="menudata.js"></script>
58<script type="text/javascript" src="menu.js"></script>
59<script type="text/javascript">
Jenkins514be652019-02-28 12:25:18 +000060/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
Jenkinsb9abeae2018-11-22 11:58:08 +000061$(function() {
62 initMenu('',true,false,'search.php','Search');
63 $(document).ready(function() { init_search(); });
64});
Jenkins514be652019-02-28 12:25:18 +000065/* @license-end */</script>
Jenkinsb9abeae2018-11-22 11:58:08 +000066<div id="main-nav"></div>
67</div><!-- top -->
68<div id="side-nav" class="ui-resizable side-nav-resizable">
69 <div id="nav-tree">
70 <div id="nav-tree-contents">
71 <div id="nav-sync" class="sync"></div>
72 </div>
73 </div>
74 <div id="splitbar" style="-moz-user-select:none;"
75 class="ui-resizable-handle">
76 </div>
77</div>
78<script type="text/javascript">
Jenkins514be652019-02-28 12:25:18 +000079/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
Jenkinsb9abeae2018-11-22 11:58:08 +000080$(document).ready(function(){initNavTree('warp__helpers__quantized_8h.xhtml','');});
Jenkins514be652019-02-28 12:25:18 +000081/* @license-end */
Jenkinsb9abeae2018-11-22 11:58:08 +000082</script>
83<div id="doc-content">
84<!-- window showing the filter options -->
85<div id="MSearchSelectWindow"
86 onmouseover="return searchBox.OnSearchSelectShow()"
87 onmouseout="return searchBox.OnSearchSelectHide()"
88 onkeydown="return searchBox.OnSearchSelectKey(event)">
89</div>
90
91<!-- iframe showing the search results (closed by default) -->
92<div id="MSearchResultsWindow">
93<iframe src="javascript:void(0)" frameborder="0"
94 name="MSearchResults" id="MSearchResults">
95</iframe>
96</div>
97
98<div class="header">
99 <div class="summary">
100<a href="#func-members">Functions</a> </div>
101 <div class="headertitle">
102<div class="title">warp_helpers_quantized.h File Reference</div> </div>
103</div><!--header-->
104<div class="contents">
105<div class="textblock"><code>#include &quot;<a class="el" href="helpers__asymm_8h_source.xhtml">helpers_asymm.h</a>&quot;</code><br />
106</div>
107<p><a href="warp__helpers__quantized_8h_source.xhtml">Go to the source code of this file.</a></p>
108<table class="memberdecls">
109<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
110Functions</h2></td></tr>
111<tr class="memitem:aafa351a2c35f5f121921cee080c223d6"><td class="memItemLeft" align="right" valign="top">const float8&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a> (float8 coords, const float width, const float height, const float border_size)</td></tr>
112<tr class="memdesc:aafa351a2c35f5f121921cee080c223d6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clamps the given coordinates to the borders according to the border size. <a href="#aafa351a2c35f5f121921cee080c223d6">More...</a><br /></td></tr>
113<tr class="separator:aafa351a2c35f5f121921cee080c223d6"><td class="memSeparator" colspan="2">&#160;</td></tr>
114<tr class="memitem:a33c81135c18bd3881c3f5f36c25fe499"><td class="memItemLeft" align="right" valign="top">const float8&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="warp__helpers__quantized_8h.xhtml#a33c81135c18bd3881c3f5f36c25fe499">clamp_to_border_quantized</a> (float8 coords, const float width, const float height)</td></tr>
115<tr class="memdesc:a33c81135c18bd3881c3f5f36c25fe499"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clamps the given coordinates to the borders. <a href="#a33c81135c18bd3881c3f5f36c25fe499">More...</a><br /></td></tr>
116<tr class="separator:a33c81135c18bd3881c3f5f36c25fe499"><td class="memSeparator" colspan="2">&#160;</td></tr>
117<tr class="memitem:ac05d99f194a7cf429a7ecbadd1ffb018"><td class="memItemLeft" align="right" valign="top">const float8&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="warp__helpers__quantized_8h.xhtml#ac05d99f194a7cf429a7ecbadd1ffb018">get_neighbour_coords_quantized</a> (const float2 coord)</td></tr>
118<tr class="memdesc:ac05d99f194a7cf429a7ecbadd1ffb018"><td class="mdescLeft">&#160;</td><td class="mdescRight">Given a texel coordinates this function will return the following array of coordinates: [ P, right neighbour, below neighbour, below right neighbour ]. <a href="#ac05d99f194a7cf429a7ecbadd1ffb018">More...</a><br /></td></tr>
119<tr class="separator:ac05d99f194a7cf429a7ecbadd1ffb018"><td class="memSeparator" colspan="2">&#160;</td></tr>
120<tr class="memitem:aa13de3eff8afd51e8bf4c1904a9b7415"><td class="memItemLeft" align="right" valign="top">const float2&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="warp__helpers__quantized_8h.xhtml#aa13de3eff8afd51e8bf4c1904a9b7415">get_current_coords_quantized</a> ()</td></tr>
121<tr class="memdesc:aa13de3eff8afd51e8bf4c1904a9b7415"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the current thread coordinates. <a href="#aa13de3eff8afd51e8bf4c1904a9b7415">More...</a><br /></td></tr>
122<tr class="separator:aa13de3eff8afd51e8bf4c1904a9b7415"><td class="memSeparator" colspan="2">&#160;</td></tr>
123<tr class="memitem:ae8a3d61874f95580e8110f4f206c3b8b"><td class="memItemLeft" align="right" valign="top">const DATA_TYPE4&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="warp__helpers__quantized_8h.xhtml#ae8a3d61874f95580e8110f4f206c3b8b">bilinear_interpolate_with_border_quantized</a> (const <a class="el" href="struct_image.xhtml">Image</a> *in, const float8 coords, const float width, const float height, const float border_size, const float scale, const int offset_qasymm)</td></tr>
124<tr class="memdesc:ae8a3d61874f95580e8110f4f206c3b8b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Computes the bilinear interpolation for each set of coordinates in the vector coords and returns the values. <a href="#ae8a3d61874f95580e8110f4f206c3b8b">More...</a><br /></td></tr>
125<tr class="separator:ae8a3d61874f95580e8110f4f206c3b8b"><td class="memSeparator" colspan="2">&#160;</td></tr>
126<tr class="memitem:ac2c57ad5c97b24360457a028a8e7e58c"><td class="memItemLeft" align="right" valign="top">const DATA_TYPE4&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="warp__helpers__quantized_8h.xhtml#ac2c57ad5c97b24360457a028a8e7e58c">bilinear_interpolate_quantized</a> (const <a class="el" href="struct_image.xhtml">Image</a> *in, const float8 coords, const float width, const float height, const float scale, const int offset_qasymm)</td></tr>
127<tr class="memdesc:ac2c57ad5c97b24360457a028a8e7e58c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Computes the bilinear interpolation for each set of coordinates in the vector coords and returns the values. <a href="#ac2c57ad5c97b24360457a028a8e7e58c">More...</a><br /></td></tr>
128<tr class="separator:ac2c57ad5c97b24360457a028a8e7e58c"><td class="memSeparator" colspan="2">&#160;</td></tr>
129</table>
130<h2 class="groupheader">Function Documentation</h2>
131<a id="ac2c57ad5c97b24360457a028a8e7e58c"></a>
132<h2 class="memtitle"><span class="permalink"><a href="#ac2c57ad5c97b24360457a028a8e7e58c">&#9670;&nbsp;</a></span>bilinear_interpolate_quantized()</h2>
133
134<div class="memitem">
135<div class="memproto">
136<table class="mlabels">
137 <tr>
138 <td class="mlabels-left">
139 <table class="memname">
140 <tr>
141 <td class="memname">const DATA_TYPE4 bilinear_interpolate_quantized </td>
142 <td>(</td>
143 <td class="paramtype">const <a class="el" href="struct_image.xhtml">Image</a> *&#160;</td>
144 <td class="paramname"><em>in</em>, </td>
145 </tr>
146 <tr>
147 <td class="paramkey"></td>
148 <td></td>
149 <td class="paramtype">const float8&#160;</td>
150 <td class="paramname"><em>coords</em>, </td>
151 </tr>
152 <tr>
153 <td class="paramkey"></td>
154 <td></td>
155 <td class="paramtype">const float&#160;</td>
156 <td class="paramname"><em>width</em>, </td>
157 </tr>
158 <tr>
159 <td class="paramkey"></td>
160 <td></td>
161 <td class="paramtype">const float&#160;</td>
162 <td class="paramname"><em>height</em>, </td>
163 </tr>
164 <tr>
165 <td class="paramkey"></td>
166 <td></td>
167 <td class="paramtype">const float&#160;</td>
168 <td class="paramname"><em>scale</em>, </td>
169 </tr>
170 <tr>
171 <td class="paramkey"></td>
172 <td></td>
173 <td class="paramtype">const int&#160;</td>
174 <td class="paramname"><em>offset_qasymm</em>&#160;</td>
175 </tr>
176 <tr>
177 <td></td>
178 <td>)</td>
179 <td></td><td></td>
180 </tr>
181 </table>
182 </td>
183 <td class="mlabels-right">
184<span class="mlabels"><span class="mlabel">inline</span></span> </td>
185 </tr>
186</table>
187</div><div class="memdoc">
188
189<p>Computes the bilinear interpolation for each set of coordinates in the vector coords and returns the values. </p>
190<dl class="params"><dt>Parameters</dt><dd>
191 <table class="params">
192 <tr><td class="paramdir">[in]</td><td class="paramname">in</td><td>Pointer to the source image. </td></tr>
Jenkins514be652019-02-28 12:25:18 +0000193 <tr><td class="paramdir">[in]</td><td class="paramname">coords</td><td><a class="el" href="struct_vector.xhtml" title="Structure to hold Vector information.">Vector</a> of four 2D coordinates. Even pos is x and odd y. </td></tr>
Jenkinsb9abeae2018-11-22 11:58:08 +0000194 <tr><td class="paramdir">[in]</td><td class="paramname">width</td><td>Width of the image </td></tr>
195 <tr><td class="paramdir">[in]</td><td class="paramname">height</td><td>Height of the image </td></tr>
196 <tr><td class="paramdir">[in]</td><td class="paramname">scale</td><td>Scale value </td></tr>
197 <tr><td class="paramdir">[in]</td><td class="paramname">offset_qasymm</td><td>Offset value </td></tr>
198 </table>
199 </dd>
200</dl>
201
202<p class="definition">Definition at line <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00135">135</a> of file <a class="el" href="warp__helpers__quantized_8h_source.xhtml">warp_helpers_quantized.h</a>.</p>
Jenkinsb9abeae2018-11-22 11:58:08 +0000203<div class="fragment"><div class="line"><a name="l00136"></a><span class="lineno"> 136</span>&#160;{</div><div class="line"><a name="l00137"></a><span class="lineno"> 137</span>&#160; <span class="keywordflow">return</span> <a class="code" href="warp__helpers__quantized_8h.xhtml#ae8a3d61874f95580e8110f4f206c3b8b">bilinear_interpolate_with_border_quantized</a>(in, coords, width, height, 1, <a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#acec6d8ad52a28972fa74e071c1a63b6a">scale</a>, offset_qasymm);</div><div class="line"><a name="l00138"></a><span class="lineno"> 138</span>&#160;}</div><div class="ttc" id="warp__helpers__quantized_8h_xhtml_ae8a3d61874f95580e8110f4f206c3b8b"><div class="ttname"><a href="warp__helpers__quantized_8h.xhtml#ae8a3d61874f95580e8110f4f206c3b8b">bilinear_interpolate_with_border_quantized</a></div><div class="ttdeci">const DATA_TYPE4 bilinear_interpolate_with_border_quantized(const Image *in, const float8 coords, const float width, const float height, const float border_size, const float scale, const int offset_qasymm)</div><div class="ttdoc">Computes the bilinear interpolation for each set of coordinates in the vector coords and returns the ...</div><div class="ttdef"><b>Definition:</b> <a href="warp__helpers__quantized_8h_source.xhtml#l00084">warp_helpers_quantized.h:84</a></div></div>
204<div class="ttc" id="namespacearm__compute_1_1test_1_1validation_xhtml_acec6d8ad52a28972fa74e071c1a63b6a"><div class="ttname"><a href="namespacearm__compute_1_1test_1_1validation.xhtml#acec6d8ad52a28972fa74e071c1a63b6a">arm_compute::test::validation::scale</a></div><div class="ttdeci">scale</div><div class="ttdef"><b>Definition:</b> <a href="_n_e_o_n_2_pixel_wise_multiplication_8cpp_source.xhtml#l00168">PixelWiseMultiplication.cpp:168</a></div></div>
205</div><!-- fragment -->
Jenkins514be652019-02-28 12:25:18 +0000206<p class="reference">References <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00084">bilinear_interpolate_with_border_quantized()</a>, and <a class="el" href="_n_e_o_n_2_pixel_wise_multiplication_8cpp_source.xhtml#l00168">arm_compute::test::validation::scale</a>.</p>
207
Jenkinsb9abeae2018-11-22 11:58:08 +0000208</div>
209</div>
210<a id="ae8a3d61874f95580e8110f4f206c3b8b"></a>
211<h2 class="memtitle"><span class="permalink"><a href="#ae8a3d61874f95580e8110f4f206c3b8b">&#9670;&nbsp;</a></span>bilinear_interpolate_with_border_quantized()</h2>
212
213<div class="memitem">
214<div class="memproto">
215<table class="mlabels">
216 <tr>
217 <td class="mlabels-left">
218 <table class="memname">
219 <tr>
220 <td class="memname">const DATA_TYPE4 bilinear_interpolate_with_border_quantized </td>
221 <td>(</td>
222 <td class="paramtype">const <a class="el" href="struct_image.xhtml">Image</a> *&#160;</td>
223 <td class="paramname"><em>in</em>, </td>
224 </tr>
225 <tr>
226 <td class="paramkey"></td>
227 <td></td>
228 <td class="paramtype">const float8&#160;</td>
229 <td class="paramname"><em>coords</em>, </td>
230 </tr>
231 <tr>
232 <td class="paramkey"></td>
233 <td></td>
234 <td class="paramtype">const float&#160;</td>
235 <td class="paramname"><em>width</em>, </td>
236 </tr>
237 <tr>
238 <td class="paramkey"></td>
239 <td></td>
240 <td class="paramtype">const float&#160;</td>
241 <td class="paramname"><em>height</em>, </td>
242 </tr>
243 <tr>
244 <td class="paramkey"></td>
245 <td></td>
246 <td class="paramtype">const float&#160;</td>
247 <td class="paramname"><em>border_size</em>, </td>
248 </tr>
249 <tr>
250 <td class="paramkey"></td>
251 <td></td>
252 <td class="paramtype">const float&#160;</td>
253 <td class="paramname"><em>scale</em>, </td>
254 </tr>
255 <tr>
256 <td class="paramkey"></td>
257 <td></td>
258 <td class="paramtype">const int&#160;</td>
259 <td class="paramname"><em>offset_qasymm</em>&#160;</td>
260 </tr>
261 <tr>
262 <td></td>
263 <td>)</td>
264 <td></td><td></td>
265 </tr>
266 </table>
267 </td>
268 <td class="mlabels-right">
269<span class="mlabels"><span class="mlabel">inline</span></span> </td>
270 </tr>
271</table>
272</div><div class="memdoc">
273
274<p>Computes the bilinear interpolation for each set of coordinates in the vector coords and returns the values. </p>
275<dl class="params"><dt>Parameters</dt><dd>
276 <table class="params">
277 <tr><td class="paramdir">[in]</td><td class="paramname">in</td><td>Pointer to the source image. </td></tr>
Jenkins514be652019-02-28 12:25:18 +0000278 <tr><td class="paramdir">[in]</td><td class="paramname">coords</td><td><a class="el" href="struct_vector.xhtml" title="Structure to hold Vector information.">Vector</a> of four 2D coordinates. Even pos is x and odd y. </td></tr>
Jenkinsb9abeae2018-11-22 11:58:08 +0000279 <tr><td class="paramdir">[in]</td><td class="paramname">width</td><td>Width of the image </td></tr>
280 <tr><td class="paramdir">[in]</td><td class="paramname">height</td><td>Height of the image </td></tr>
281 <tr><td class="paramdir">[in]</td><td class="paramname">border_size</td><td>Border size </td></tr>
282 <tr><td class="paramdir">[in]</td><td class="paramname">scale</td><td>Scale value </td></tr>
283 <tr><td class="paramdir">[in]</td><td class="paramname">offset_qasymm</td><td>Offset value </td></tr>
284 </table>
285 </dd>
286</dl>
287
288<p class="definition">Definition at line <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00084">84</a> of file <a class="el" href="warp__helpers__quantized_8h_source.xhtml">warp_helpers_quantized.h</a>.</p>
Jenkins514be652019-02-28 12:25:18 +0000289<div class="fragment"><div class="line"><a name="l00086"></a><span class="lineno"> 86</span>&#160;{</div><div class="line"><a name="l00087"></a><span class="lineno"> 87</span>&#160; <span class="comment">// If any of the 4 texels is out of the image&#39;s boundaries we use the border value (REPLICATE or CONSTANT) for any texel out of the image.</span></div><div class="line"><a name="l00088"></a><span class="lineno"> 88</span>&#160;</div><div class="line"><a name="l00089"></a><span class="lineno"> 89</span>&#160; <span class="comment">// Sets the 4x4 coordinates for each of the four input texels</span></div><div class="line"><a name="l00090"></a><span class="lineno"> 90</span>&#160; <span class="keyword">const</span> float8 fc = floor(coords);</div><div class="line"><a name="l00091"></a><span class="lineno"> 91</span>&#160; <span class="keyword">const</span> float16 c1 = (float16)(</div><div class="line"><a name="l00092"></a><span class="lineno"> 92</span>&#160; <a class="code" href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a>(<a class="code" href="warp__helpers__quantized_8h.xhtml#ac05d99f194a7cf429a7ecbadd1ffb018">get_neighbour_coords_quantized</a>((float2)(fc.s0, fc.s1)), width, height, border_size),</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>&#160; <a class="code" href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a>(<a class="code" href="warp__helpers__quantized_8h.xhtml#ac05d99f194a7cf429a7ecbadd1ffb018">get_neighbour_coords_quantized</a>((float2)(fc.s2, fc.s3)), width, height, border_size));</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span>&#160; <span class="keyword">const</span> float16 c2 = (float16)(</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span>&#160; <a class="code" href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a>(<a class="code" href="warp__helpers__quantized_8h.xhtml#ac05d99f194a7cf429a7ecbadd1ffb018">get_neighbour_coords_quantized</a>((float2)(fc.s4, fc.s5)), width, height, border_size),</div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span>&#160; <a class="code" href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a>(<a class="code" href="warp__helpers__quantized_8h.xhtml#ac05d99f194a7cf429a7ecbadd1ffb018">get_neighbour_coords_quantized</a>((float2)(fc.s6, fc.s7)), width, height, border_size));</div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span>&#160;</div><div class="line"><a name="l00098"></a><span class="lineno"> 98</span>&#160; <span class="comment">// Loads the values from the input image</span></div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span>&#160; <span class="keyword">const</span> int16 t = (int16)(</div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>&#160; <span class="comment">/* tl, tr, bl, br */</span></div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span>&#160; * ((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.s0, c1.s1)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.s2, c1.s3)),</div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.s4, c1.s5)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.s6, c1.s7)),</div><div class="line"><a name="l00103"></a><span class="lineno"> 103</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.s8, c1.s9)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.sa, c1.sb)),</div><div class="line"><a name="l00104"></a><span class="lineno"> 104</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.sc, c1.sd)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c1.se, c1.sf)),</div><div class="line"><a name="l00105"></a><span class="lineno"> 105</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.s0, c2.s1)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.s2, c2.s3)),</div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.s4, c2.s5)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.s6, c2.s7)),</div><div class="line"><a name="l00107"></a><span class="lineno"> 107</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.s8, c2.s9)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.sa, c2.sb)),</div><div class="line"><a name="l00108"></a><span class="lineno"> 108</span>&#160; *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.sc, c2.sd)), *((__global <a class="code" href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a> *)<a class="code" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a>(in, c2.se, c2.sf)));</div><div class="line"><a name="l00109"></a><span class="lineno"> 109</span>&#160;</div><div class="line"><a name="l00110"></a><span class="lineno"> 110</span>&#160; <span class="keyword">const</span> float16 inf32 = convert_float16(t - (int16)offset_qasymm) * (float16)<a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#acec6d8ad52a28972fa74e071c1a63b6a">scale</a>;</div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span>&#160;</div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span>&#160; <span class="keyword">const</span> float8 a = coords - fc;</div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span>&#160; <span class="keyword">const</span> float8 b = ((float8)(1.f)) - a;</div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span>&#160; <span class="keyword">const</span> float4 fr = (float4)(</div><div class="line"><a name="l00115"></a><span class="lineno"> 115</span>&#160; ((inf32.s0 * b.s0 * b.s1) + (inf32.s1 * a.s0 * b.s1) + (inf32.s2 * b.s0 * a.s1) + (inf32.s3 * a.s0 * a.s1)),</div><div class="line"><a name="l00116"></a><span class="lineno"> 116</span>&#160; ((inf32.s4 * b.s2 * b.s3) + (inf32.s5 * a.s2 * b.s3) + (inf32.s6 * b.s2 * a.s3) + (inf32.s7 * a.s2 * a.s3)),</div><div class="line"><a name="l00117"></a><span class="lineno"> 117</span>&#160; ((inf32.s8 * b.s4 * b.s5) + (inf32.s9 * a.s4 * b.s5) + (inf32.sa * b.s4 * a.s5) + (inf32.sb * a.s4 * a.s5)),</div><div class="line"><a name="l00118"></a><span class="lineno"> 118</span>&#160; ((inf32.sc * b.s6 * b.s7) + (inf32.sd * a.s6 * b.s7) + (inf32.se * b.s6 * a.s7) + (inf32.sf * a.s6 * a.s7)));</div><div class="line"><a name="l00119"></a><span class="lineno"> 119</span>&#160;</div><div class="line"><a name="l00120"></a><span class="lineno"> 120</span>&#160; <span class="keyword">const</span> uchar4 res = convert_uchar4_sat(convert_int4_sat_rtp(fr / <a class="code" href="namespacearm__compute_1_1test_1_1validation.xhtml#acec6d8ad52a28972fa74e071c1a63b6a">scale</a>) + offset_qasymm);</div><div class="line"><a name="l00121"></a><span class="lineno"> 121</span>&#160;</div><div class="line"><a name="l00122"></a><span class="lineno"> 122</span>&#160; <span class="keywordflow">return</span> res;</div><div class="line"><a name="l00123"></a><span class="lineno"> 123</span>&#160;}</div><div class="ttc" id="src_2core_2_c_l_2cl__kernels_2_helpers_8h_xhtml_a009469e4d9b8fce3b6d5e97d2077827d"><div class="ttname"><a href="src_2core_2_c_l_2cl__kernels_2_helpers_8h.xhtml#a009469e4d9b8fce3b6d5e97d2077827d">offset</a></div><div class="ttdeci">__global uchar * offset(const Image *img, int x, int y)</div><div class="ttdoc">Get the pointer position of a Image.</div><div class="ttdef"><b>Definition:</b> <a href="src_2core_2_c_l_2cl__kernels_2_helpers_8h_source.xhtml#l00312">helpers.h:312</a></div></div>
290<div class="ttc" id="convolution3x3_8cl_xhtml_afb8c72ce35c4a1f4a2588d6573e54aa1"><div class="ttname"><a href="convolution3x3_8cl.xhtml#afb8c72ce35c4a1f4a2588d6573e54aa1">DATA_TYPE</a></div><div class="ttdeci">#define DATA_TYPE</div><div class="ttdef"><b>Definition:</b> <a href="convolution3x3_8cl_source.xhtml#l00027">convolution3x3.cl:27</a></div></div>
291<div class="ttc" id="warp__helpers__quantized_8h_xhtml_aafa351a2c35f5f121921cee080c223d6"><div class="ttname"><a href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a></div><div class="ttdeci">const float8 clamp_to_border_with_size_quantized(float8 coords, const float width, const float height, const float border_size)</div><div class="ttdoc">Clamps the given coordinates to the borders according to the border size.</div><div class="ttdef"><b>Definition:</b> <a href="warp__helpers__quantized_8h_source.xhtml#l00034">warp_helpers_quantized.h:34</a></div></div>
292<div class="ttc" id="namespacearm__compute_1_1test_1_1validation_xhtml_acec6d8ad52a28972fa74e071c1a63b6a"><div class="ttname"><a href="namespacearm__compute_1_1test_1_1validation.xhtml#acec6d8ad52a28972fa74e071c1a63b6a">arm_compute::test::validation::scale</a></div><div class="ttdeci">scale</div><div class="ttdef"><b>Definition:</b> <a href="_n_e_o_n_2_pixel_wise_multiplication_8cpp_source.xhtml#l00168">PixelWiseMultiplication.cpp:168</a></div></div>
293<div class="ttc" id="warp__helpers__quantized_8h_xhtml_ac05d99f194a7cf429a7ecbadd1ffb018"><div class="ttname"><a href="warp__helpers__quantized_8h.xhtml#ac05d99f194a7cf429a7ecbadd1ffb018">get_neighbour_coords_quantized</a></div><div class="ttdeci">const float8 get_neighbour_coords_quantized(const float2 coord)</div><div class="ttdoc">Given a texel coordinates this function will return the following array of coordinates: [ P,...</div><div class="ttdef"><b>Definition:</b> <a href="warp__helpers__quantized_8h_source.xhtml#l00063">warp_helpers_quantized.h:63</a></div></div>
294</div><!-- fragment -->
295<p class="reference">References <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00034">clamp_to_border_with_size_quantized()</a>, <a class="el" href="convolution3x3_8cl_source.xhtml#l00027">DATA_TYPE</a>, <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00063">get_neighbour_coords_quantized()</a>, <a class="el" href="src_2core_2_c_l_2cl__kernels_2_helpers_8h_source.xhtml#l00312">offset()</a>, and <a class="el" href="_n_e_o_n_2_pixel_wise_multiplication_8cpp_source.xhtml#l00168">arm_compute::test::validation::scale</a>.</p>
Jenkinsb9abeae2018-11-22 11:58:08 +0000296
297<p class="reference">Referenced by <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00135">bilinear_interpolate_quantized()</a>, and <a class="el" href="scale__quantized_8cl_source.xhtml#l00073">scale_bilinear_quantized_nchw()</a>.</p>
Jenkins514be652019-02-28 12:25:18 +0000298
Jenkinsb9abeae2018-11-22 11:58:08 +0000299</div>
300</div>
301<a id="a33c81135c18bd3881c3f5f36c25fe499"></a>
302<h2 class="memtitle"><span class="permalink"><a href="#a33c81135c18bd3881c3f5f36c25fe499">&#9670;&nbsp;</a></span>clamp_to_border_quantized()</h2>
303
304<div class="memitem">
305<div class="memproto">
306<table class="mlabels">
307 <tr>
308 <td class="mlabels-left">
309 <table class="memname">
310 <tr>
311 <td class="memname">const float8 clamp_to_border_quantized </td>
312 <td>(</td>
313 <td class="paramtype">float8&#160;</td>
314 <td class="paramname"><em>coords</em>, </td>
315 </tr>
316 <tr>
317 <td class="paramkey"></td>
318 <td></td>
319 <td class="paramtype">const float&#160;</td>
320 <td class="paramname"><em>width</em>, </td>
321 </tr>
322 <tr>
323 <td class="paramkey"></td>
324 <td></td>
325 <td class="paramtype">const float&#160;</td>
326 <td class="paramname"><em>height</em>&#160;</td>
327 </tr>
328 <tr>
329 <td></td>
330 <td>)</td>
331 <td></td><td></td>
332 </tr>
333 </table>
334 </td>
335 <td class="mlabels-right">
336<span class="mlabels"><span class="mlabel">inline</span></span> </td>
337 </tr>
338</table>
339</div><div class="memdoc">
340
341<p>Clamps the given coordinates to the borders. </p>
342<dl class="params"><dt>Parameters</dt><dd>
343 <table class="params">
Jenkins514be652019-02-28 12:25:18 +0000344 <tr><td class="paramdir">[in]</td><td class="paramname">coords</td><td><a class="el" href="struct_vector.xhtml" title="Structure to hold Vector information.">Vector</a> of 2D coordinates to clamp. Even positions are X coords, odd positions are Y coords. </td></tr>
Jenkinsb9abeae2018-11-22 11:58:08 +0000345 <tr><td class="paramdir">[in]</td><td class="paramname">width</td><td>Width of the image </td></tr>
346 <tr><td class="paramdir">[in]</td><td class="paramname">height</td><td>Height of the image </td></tr>
347 </table>
348 </dd>
349</dl>
350
351<p class="definition">Definition at line <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00049">49</a> of file <a class="el" href="warp__helpers__quantized_8h_source.xhtml">warp_helpers_quantized.h</a>.</p>
Jenkins514be652019-02-28 12:25:18 +0000352<div class="fragment"><div class="line"><a name="l00050"></a><span class="lineno"> 50</span>&#160;{</div><div class="line"><a name="l00051"></a><span class="lineno"> 51</span>&#160; <span class="keywordflow">return</span> <a class="code" href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a>(coords, width, height, 1);</div><div class="line"><a name="l00052"></a><span class="lineno"> 52</span>&#160;}</div><div class="ttc" id="warp__helpers__quantized_8h_xhtml_aafa351a2c35f5f121921cee080c223d6"><div class="ttname"><a href="warp__helpers__quantized_8h.xhtml#aafa351a2c35f5f121921cee080c223d6">clamp_to_border_with_size_quantized</a></div><div class="ttdeci">const float8 clamp_to_border_with_size_quantized(float8 coords, const float width, const float height, const float border_size)</div><div class="ttdoc">Clamps the given coordinates to the borders according to the border size.</div><div class="ttdef"><b>Definition:</b> <a href="warp__helpers__quantized_8h_source.xhtml#l00034">warp_helpers_quantized.h:34</a></div></div>
Jenkinsb9abeae2018-11-22 11:58:08 +0000353</div><!-- fragment -->
Jenkins514be652019-02-28 12:25:18 +0000354<p class="reference">References <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00034">clamp_to_border_with_size_quantized()</a>.</p>
355
Jenkinsb9abeae2018-11-22 11:58:08 +0000356</div>
357</div>
358<a id="aafa351a2c35f5f121921cee080c223d6"></a>
359<h2 class="memtitle"><span class="permalink"><a href="#aafa351a2c35f5f121921cee080c223d6">&#9670;&nbsp;</a></span>clamp_to_border_with_size_quantized()</h2>
360
361<div class="memitem">
362<div class="memproto">
363<table class="mlabels">
364 <tr>
365 <td class="mlabels-left">
366 <table class="memname">
367 <tr>
368 <td class="memname">const float8 clamp_to_border_with_size_quantized </td>
369 <td>(</td>
370 <td class="paramtype">float8&#160;</td>
371 <td class="paramname"><em>coords</em>, </td>
372 </tr>
373 <tr>
374 <td class="paramkey"></td>
375 <td></td>
376 <td class="paramtype">const float&#160;</td>
377 <td class="paramname"><em>width</em>, </td>
378 </tr>
379 <tr>
380 <td class="paramkey"></td>
381 <td></td>
382 <td class="paramtype">const float&#160;</td>
383 <td class="paramname"><em>height</em>, </td>
384 </tr>
385 <tr>
386 <td class="paramkey"></td>
387 <td></td>
388 <td class="paramtype">const float&#160;</td>
389 <td class="paramname"><em>border_size</em>&#160;</td>
390 </tr>
391 <tr>
392 <td></td>
393 <td>)</td>
394 <td></td><td></td>
395 </tr>
396 </table>
397 </td>
398 <td class="mlabels-right">
399<span class="mlabels"><span class="mlabel">inline</span></span> </td>
400 </tr>
401</table>
402</div><div class="memdoc">
403
404<p>Clamps the given coordinates to the borders according to the border size. </p>
405<dl class="params"><dt>Parameters</dt><dd>
406 <table class="params">
Jenkins514be652019-02-28 12:25:18 +0000407 <tr><td class="paramdir">[in]</td><td class="paramname">coords</td><td><a class="el" href="struct_vector.xhtml" title="Structure to hold Vector information.">Vector</a> of 2D coordinates to clamp. Even positions are X coords, odd positions are Y coords. </td></tr>
Jenkinsb9abeae2018-11-22 11:58:08 +0000408 <tr><td class="paramdir">[in]</td><td class="paramname">width</td><td>Width of the image </td></tr>
409 <tr><td class="paramdir">[in]</td><td class="paramname">height</td><td>Height of the image </td></tr>
410 <tr><td class="paramdir">[in]</td><td class="paramname">border_size</td><td>Border size of the image </td></tr>
411 </table>
412 </dd>
413</dl>
414
415<p class="definition">Definition at line <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00034">34</a> of file <a class="el" href="warp__helpers__quantized_8h_source.xhtml">warp_helpers_quantized.h</a>.</p>
Jenkins514be652019-02-28 12:25:18 +0000416<div class="fragment"><div class="line"><a name="l00035"></a><span class="lineno"> 35</span>&#160;{</div><div class="line"><a name="l00036"></a><span class="lineno"> 36</span>&#160; <span class="keyword">const</span> float4 clamped_x = <a class="code" href="namespacearm__compute_1_1utility.xhtml#a96efecf997f13a914609ddf1eb67f624">clamp</a>(coords.even, 0.0f - border_size, width - 1 + border_size);</div><div class="line"><a name="l00037"></a><span class="lineno"> 37</span>&#160; <span class="keyword">const</span> float4 clamped_y = <a class="code" href="namespacearm__compute_1_1utility.xhtml#a96efecf997f13a914609ddf1eb67f624">clamp</a>(coords.odd, 0.0f - border_size, height - 1 + border_size);</div><div class="line"><a name="l00038"></a><span class="lineno"> 38</span>&#160; <span class="keywordflow">return</span> (float8)(clamped_x.s0, clamped_y.s0, clamped_x.s1, clamped_y.s1, clamped_x.s2, clamped_y.s2, clamped_x.s3, clamped_y.s3);</div><div class="line"><a name="l00039"></a><span class="lineno"> 39</span>&#160;}</div><div class="ttc" id="namespacearm__compute_1_1utility_xhtml_a96efecf997f13a914609ddf1eb67f624"><div class="ttname"><a href="namespacearm__compute_1_1utility.xhtml#a96efecf997f13a914609ddf1eb67f624">arm_compute::utility::clamp</a></div><div class="ttdeci">DataType clamp(const DataType &amp;n, const DataType &amp;lower=std::numeric_limits&lt; RangeType &gt;::lowest(), const DataType &amp;upper=std::numeric_limits&lt; RangeType &gt;::max())</div><div class="ttdoc">Performs clamping among a lower and upper value.</div><div class="ttdef"><b>Definition:</b> <a href="_utility_8h_source.xhtml#l00084">Utility.h:84</a></div></div>
417</div><!-- fragment -->
Jenkinsb9abeae2018-11-22 11:58:08 +0000418<p class="reference">References <a class="el" href="_utility_8h_source.xhtml#l00084">arm_compute::utility::clamp()</a>.</p>
419
420<p class="reference">Referenced by <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00084">bilinear_interpolate_with_border_quantized()</a>, and <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00049">clamp_to_border_quantized()</a>.</p>
Jenkins514be652019-02-28 12:25:18 +0000421
Jenkinsb9abeae2018-11-22 11:58:08 +0000422</div>
423</div>
424<a id="aa13de3eff8afd51e8bf4c1904a9b7415"></a>
425<h2 class="memtitle"><span class="permalink"><a href="#aa13de3eff8afd51e8bf4c1904a9b7415">&#9670;&nbsp;</a></span>get_current_coords_quantized()</h2>
426
427<div class="memitem">
428<div class="memproto">
429<table class="mlabels">
430 <tr>
431 <td class="mlabels-left">
432 <table class="memname">
433 <tr>
434 <td class="memname">const float2 get_current_coords_quantized </td>
435 <td>(</td>
436 <td class="paramname"></td><td>)</td>
437 <td></td>
438 </tr>
439 </table>
440 </td>
441 <td class="mlabels-right">
442<span class="mlabels"><span class="mlabel">inline</span></span> </td>
443 </tr>
444</table>
445</div><div class="memdoc">
446
447<p>Returns the current thread coordinates. </p>
448
449<p class="definition">Definition at line <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00069">69</a> of file <a class="el" href="warp__helpers__quantized_8h_source.xhtml">warp_helpers_quantized.h</a>.</p>
Jenkinsb9abeae2018-11-22 11:58:08 +0000450<div class="fragment"><div class="line"><a name="l00070"></a><span class="lineno"> 70</span>&#160;{</div><div class="line"><a name="l00071"></a><span class="lineno"> 71</span>&#160; <span class="keywordflow">return</span> (float2)(get_global_id(0) * 4, get_global_id(1));</div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>&#160;}</div></div><!-- fragment -->
Jenkins514be652019-02-28 12:25:18 +0000451<p class="reference">Referenced by <a class="el" href="scale__quantized_8cl_source.xhtml#l00073">scale_bilinear_quantized_nchw()</a>.</p>
452
Jenkinsb9abeae2018-11-22 11:58:08 +0000453</div>
454</div>
455<a id="ac05d99f194a7cf429a7ecbadd1ffb018"></a>
456<h2 class="memtitle"><span class="permalink"><a href="#ac05d99f194a7cf429a7ecbadd1ffb018">&#9670;&nbsp;</a></span>get_neighbour_coords_quantized()</h2>
457
458<div class="memitem">
459<div class="memproto">
460<table class="mlabels">
461 <tr>
462 <td class="mlabels-left">
463 <table class="memname">
464 <tr>
465 <td class="memname">const float8 get_neighbour_coords_quantized </td>
466 <td>(</td>
467 <td class="paramtype">const float2&#160;</td>
468 <td class="paramname"><em>coord</em></td><td>)</td>
469 <td></td>
470 </tr>
471 </table>
472 </td>
473 <td class="mlabels-right">
474<span class="mlabels"><span class="mlabel">inline</span></span> </td>
475 </tr>
476</table>
477</div><div class="memdoc">
478
479<p>Given a texel coordinates this function will return the following array of coordinates: [ P, right neighbour, below neighbour, below right neighbour ]. </p>
480<dl class="section note"><dt>Note</dt><dd>No checks to see if the coordinates are out of the image are done here.</dd></dl>
481<dl class="params"><dt>Parameters</dt><dd>
482 <table class="params">
483 <tr><td class="paramdir">[in]</td><td class="paramname">coord</td><td>Input coordinates</td></tr>
484 </table>
485 </dd>
486</dl>
487<dl class="section return"><dt>Returns</dt><dd>vector of 8 floats with the coordinates, even positions are x and odd y. </dd></dl>
488
489<p class="definition">Definition at line <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00063">63</a> of file <a class="el" href="warp__helpers__quantized_8h_source.xhtml">warp_helpers_quantized.h</a>.</p>
Jenkinsb9abeae2018-11-22 11:58:08 +0000490<div class="fragment"><div class="line"><a name="l00064"></a><span class="lineno"> 64</span>&#160;{</div><div class="line"><a name="l00065"></a><span class="lineno"> 65</span>&#160; <span class="keywordflow">return</span> (float8)(<span class="comment">/*tl*/</span> coord.s0, coord.s1, <span class="comment">/*tr*/</span> coord.s0 + 1, coord.s1, <span class="comment">/*bl*/</span> coord.s0, coord.s1 + 1, <span class="comment">/*br*/</span> coord.s0 + 1, coord.s1 + 1);</div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span>&#160;}</div></div><!-- fragment -->
Jenkins514be652019-02-28 12:25:18 +0000491<p class="reference">Referenced by <a class="el" href="warp__helpers__quantized_8h_source.xhtml#l00084">bilinear_interpolate_with_border_quantized()</a>.</p>
492
Jenkinsb9abeae2018-11-22 11:58:08 +0000493</div>
494</div>
495</div><!-- contents -->
496</div><!-- doc-content -->
497<!-- start footer part -->
498<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
499 <ul>
500 <li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.xhtml">src</a></li><li class="navelem"><a class="el" href="dir_aebb8dcc11953d78e620bbef0b9e2183.xhtml">core</a></li><li class="navelem"><a class="el" href="dir_8c278f79c760e5c5fbd911f9870614c1.xhtml">CL</a></li><li class="navelem"><a class="el" href="dir_25885286e9dad4fa105b7b25a8031bbf.xhtml">cl_kernels</a></li><li class="navelem"><a class="el" href="warp__helpers__quantized_8h.xhtml">warp_helpers_quantized.h</a></li>
Jenkins514be652019-02-28 12:25:18 +0000501 <li class="footer">Generated on Thu Feb 28 2019 12:24:56 for Compute Library by
Jenkinsb9abeae2018-11-22 11:58:08 +0000502 <a href="http://www.doxygen.org/index.html">
Jenkins514be652019-02-28 12:25:18 +0000503 <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.15 </li>
Jenkinsb9abeae2018-11-22 11:58:08 +0000504 </ul>
505</div>
506</body>
507</html>