vxu.h 61 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946
  1. /*
  2. * Copyright (c) 2012-2017 The Khronos Group Inc.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. */
  16. #ifndef _OPENVX_UTILITY_H_
  17. #define _OPENVX_UTILITY_H_
  18. /*!
  19. * \file
  20. * \brief The OpenVX Utility Library.
  21. */
  22. #ifdef __cplusplus
  23. extern "C" {
  24. #endif
  25. /*! \brief [Immediate] Invokes an immediate Color Conversion.
  26. * \param [in] context The reference to the overall context.
  27. * \param [in] input The input image.
  28. * \param [out] output The output image.
  29. * \ingroup group_vision_function_colorconvert
  30. * \return A <tt>\ref vx_status_e</tt> enumeration.
  31. * \retval VX_SUCCESS Success
  32. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  33. */
  34. VX_API_ENTRY vx_status VX_API_CALL vxuColorConvert(vx_context context, vx_image input, vx_image output);
  35. /*! \brief [Immediate] Invokes an immediate Channel Extract.
  36. * \param [in] context The reference to the overall context.
  37. * \param [in] input The input image. Must be one of the defined <tt>\ref vx_df_image_e</tt> multi-channel formats.
  38. * \param [in] channel The <tt>\ref vx_channel_e</tt> enumeration to extract.
  39. * \param [out] output The output image. Must be <tt>\ref VX_DF_IMAGE_U8</tt>.
  40. * \ingroup group_vision_function_channelextract
  41. * \return A <tt>\ref vx_status_e</tt> enumeration.
  42. * \retval VX_SUCCESS Success
  43. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  44. */
  45. VX_API_ENTRY vx_status VX_API_CALL vxuChannelExtract(vx_context context, vx_image input, vx_enum channel, vx_image output);
  46. /*! \brief [Immediate] Invokes an immediate Channel Combine.
  47. * \param [in] context The reference to the overall context.
  48. * \param [in] plane0 The plane that forms channel 0. Must be <tt>\ref VX_DF_IMAGE_U8</tt>.
  49. * \param [in] plane1 The plane that forms channel 1. Must be <tt>\ref VX_DF_IMAGE_U8</tt>.
  50. * \param [in] plane2 [optional] The plane that forms channel 2. Must be <tt>\ref VX_DF_IMAGE_U8</tt>.
  51. * \param [in] plane3 [optional] The plane that forms channel 3. Must be <tt>\ref VX_DF_IMAGE_U8</tt>.
  52. * \param [out] output The output image.
  53. * \ingroup group_vision_function_channelcombine
  54. * \return A <tt>\ref vx_status_e</tt> enumeration.
  55. * \retval VX_SUCCESS Success
  56. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  57. */
  58. VX_API_ENTRY vx_status VX_API_CALL vxuChannelCombine(vx_context context, vx_image plane0, vx_image plane1, vx_image plane2, vx_image plane3, vx_image output);
  59. /*! \brief [Immediate] Invokes an immediate Sobel 3x3.
  60. * \param [in] context The reference to the overall context.
  61. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  62. * \param [out] output_x [optional] The output gradient in the x direction in <tt>\ref VX_DF_IMAGE_S16</tt>.
  63. * \param [out] output_y [optional] The output gradient in the y direction in <tt>\ref VX_DF_IMAGE_S16</tt>.
  64. * \ingroup group_vision_function_sobel3x3
  65. * \return A <tt>\ref vx_status_e</tt> enumeration.
  66. * \retval VX_SUCCESS Success
  67. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  68. */
  69. VX_API_ENTRY vx_status VX_API_CALL vxuSobel3x3(vx_context context, vx_image input, vx_image output_x, vx_image output_y);
  70. /*! \brief [Immediate] Invokes an immediate Magnitude.
  71. * \param [in] context The reference to the overall context.
  72. * \param [in] grad_x The input x image. This must be in <tt>\ref VX_DF_IMAGE_S16</tt> format.
  73. * \param [in] grad_y The input y image. This must be in <tt>\ref VX_DF_IMAGE_S16</tt> format.
  74. * \param [out] mag The magnitude image. This will be in <tt>\ref VX_DF_IMAGE_S16</tt> format.
  75. * \ingroup group_vision_function_magnitude
  76. * \return A <tt>\ref vx_status_e</tt> enumeration.
  77. * \retval VX_SUCCESS Success
  78. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  79. */
  80. VX_API_ENTRY vx_status VX_API_CALL vxuMagnitude(vx_context context, vx_image grad_x, vx_image grad_y, vx_image mag);
  81. /*! \brief [Immediate] Invokes an immediate Phase.
  82. * \param [in] context The reference to the overall context.
  83. * \param [in] grad_x The input x image. This must be in <tt>\ref VX_DF_IMAGE_S16</tt> format.
  84. * \param [in] grad_y The input y image. This must be in <tt>\ref VX_DF_IMAGE_S16</tt> format.
  85. * \param [out] orientation The phase image. This will be in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  86. * \ingroup group_vision_function_phase
  87. * \return A <tt>\ref vx_status_e</tt> enumeration.
  88. * \retval VX_SUCCESS Success
  89. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  90. */
  91. VX_API_ENTRY vx_status VX_API_CALL vxuPhase(vx_context context, vx_image grad_x, vx_image grad_y, vx_image orientation);
  92. /*! \brief [Immediate] Scales an input image to an output image.
  93. * \param [in] context The reference to the overall context.
  94. * \param [in] src The source image of type <tt>\ref VX_DF_IMAGE_U8</tt>.
  95. * \param [out] dst The destintation image of type <tt>\ref VX_DF_IMAGE_U8</tt>.
  96. * \param [in] type The interpolation type. \see vx_interpolation_type_e.
  97. * \ingroup group_vision_function_scale_image
  98. * \return A <tt>\ref vx_status_e</tt> enumeration.
  99. * \retval VX_SUCCESS Success
  100. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  101. */
  102. VX_API_ENTRY vx_status VX_API_CALL vxuScaleImage(vx_context context, vx_image src, vx_image dst, vx_enum type);
  103. /*! \brief [Immediate] Processes the image through the LUT.
  104. * \param [in] context The reference to the overall context.
  105. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt>.
  106. * \param [in] lut The LUT which is of type <tt>\ref VX_TYPE_UINT8</tt> if input image is <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_TYPE_INT16</tt> if input image is <tt>\ref VX_DF_IMAGE_S16</tt>.
  107. * \param [out] output The output image of the same type as the input image.
  108. * \ingroup group_vision_function_lut
  109. * \return A <tt>\ref vx_status_e</tt> enumeration.
  110. * \retval VX_SUCCESS Success
  111. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  112. */
  113. VX_API_ENTRY vx_status VX_API_CALL vxuTableLookup(vx_context context, vx_image input, vx_lut lut, vx_image output);
  114. /*! \brief [Immediate] Generates a distribution from an image.
  115. * \param [in] context The reference to the overall context.
  116. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt>
  117. * \param [out] distribution The output distribution.
  118. * \ingroup group_vision_function_histogram
  119. * \return A <tt>\ref vx_status_e</tt> enumeration.
  120. * \retval VX_SUCCESS Success
  121. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  122. */
  123. VX_API_ENTRY vx_status VX_API_CALL vxuHistogram(vx_context context, vx_image input, vx_distribution distribution);
  124. /*! \brief [Immediate] Equalizes the Histogram of a grayscale image.
  125. * \param [in] context The reference to the overall context.
  126. * \param [in] input The grayscale input image in <tt>\ref VX_DF_IMAGE_U8</tt>
  127. * \param [out] output The grayscale output image of type <tt>\ref VX_DF_IMAGE_U8</tt> with equalized brightness and contrast.
  128. * \ingroup group_vision_function_equalize_hist
  129. * \return A <tt>\ref vx_status_e</tt> enumeration.
  130. * \retval VX_SUCCESS Success
  131. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  132. */
  133. VX_API_ENTRY vx_status VX_API_CALL vxuEqualizeHist(vx_context context, vx_image input, vx_image output);
  134. /*! \brief [Immediate] Computes the absolute difference between two images.
  135. * \param [in] context The reference to the overall context.
  136. * \param [in] in1 An input image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  137. * \param [in] in2 An input image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  138. * \param [out] out The output image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  139. * \ingroup group_vision_function_absdiff
  140. * \return A <tt>\ref vx_status_e</tt> enumeration.
  141. * \retval VX_SUCCESS Success
  142. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  143. */
  144. VX_API_ENTRY vx_status VX_API_CALL vxuAbsDiff(vx_context context, vx_image in1, vx_image in2, vx_image out);
  145. /*! \brief [Immediate] Computes the mean value and optionally the standard deviation.
  146. * \param [in] context The reference to the overall context.
  147. * \param [in] input The input image. <tt>\ref VX_DF_IMAGE_U8</tt> is supported.
  148. * \param [out] mean The average pixel value.
  149. * \param [out] stddev [optional] The standard deviation of the pixel values.
  150. * \ingroup group_vision_function_meanstddev
  151. * \return A <tt>\ref vx_status_e</tt> enumeration.
  152. * \retval VX_SUCCESS Success
  153. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  154. */
  155. VX_API_ENTRY vx_status VX_API_CALL vxuMeanStdDev(vx_context context, vx_image input, vx_float32 *mean, vx_float32 *stddev);
  156. /*! \brief [Immediate] Threshold's an input image and produces a <tt>\ref VX_DF_IMAGE_U8</tt> boolean image.
  157. * \param [in] context The reference to the overall context.
  158. * \param [in] input The input image. Only images with format <tt>\ref VX_DF_IMAGE_U8</tt>
  159. * and <tt>\ref VX_DF_IMAGE_S16</tt> are supported.
  160. * \param [in] thresh The thresholding object that defines the parameters of
  161. * the operation. The <tt>\ref VX_THRESHOLD_INPUT_FORMAT</tt> must be the same as the input image format and
  162. * the <tt>\ref VX_THRESHOLD_OUTPUT_FORMAT</tt> must be the same as the output image format.
  163. * \param [out] output The output image, that will contain as pixel value
  164. * true and false values defined by \p thresh. Only images with format
  165. * <tt>\ref VX_DF_IMAGE_U8</tt> are supported.
  166. * \ingroup group_vision_function_threshold
  167. * \return A <tt>\ref vx_status_e</tt> enumeration.
  168. * \retval VX_SUCCESS Success
  169. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  170. */
  171. VX_API_ENTRY vx_status VX_API_CALL vxuThreshold(vx_context context, vx_image input, vx_threshold thresh, vx_image output);
  172. /*! \brief [Immediate] Performs Non-Maxima Suppression on an image, producing an image of the same type.
  173. * \param [in] context The reference to the overall context.
  174. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  175. * \param [in] mask [optional] Constrict suppression to a ROI. The mask image is of type <tt>\ref VX_DF_IMAGE_U8</tt> and must be the same dimensions as the input image.
  176. * \param [in] win_size The size of window over which to perform the localized non-maxima suppression. Must be odd, and less than or equal to the smallest dimension of the input image.
  177. * \param [out] output The output image, of the same type as the input, that has been non-maxima suppressed.
  178. * \ingroup group_vision_function_nms
  179. * \return A <tt>\ref vx_status_e</tt> enumeration.
  180. * \retval VX_SUCCESS Success
  181. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  182. */
  183. VX_API_ENTRY vx_status VX_API_CALL vxuNonMaxSuppression(vx_context context, vx_image input, vx_image mask, vx_int32 win_size, vx_image output);
  184. /*! \brief [Immediate] Computes the integral image of the input.
  185. * \param [in] context The reference to the overall context.
  186. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  187. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U32</tt> format.
  188. * \ingroup group_vision_function_integral_image
  189. * \return A <tt>\ref vx_status_e</tt> enumeration.
  190. * \retval VX_SUCCESS Success
  191. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  192. */
  193. VX_API_ENTRY vx_status VX_API_CALL vxuIntegralImage(vx_context context, vx_image input, vx_image output);
  194. /*! \brief [Immediate] Erodes an image by a 3x3 window.
  195. * \param [in] context The reference to the overall context.
  196. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  197. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  198. * \ingroup group_vision_function_erode_image
  199. * \return A <tt>\ref vx_status_e</tt> enumeration.
  200. * \retval VX_SUCCESS Success
  201. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  202. */
  203. VX_API_ENTRY vx_status VX_API_CALL vxuErode3x3(vx_context context, vx_image input, vx_image output);
  204. /*! \brief [Immediate] Dilates an image by a 3x3 window.
  205. * \param [in] context The reference to the overall context.
  206. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  207. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  208. * \ingroup group_vision_function_dilate_image
  209. * \return A <tt>\ref vx_status_e</tt> enumeration.
  210. * \retval VX_SUCCESS Success
  211. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  212. */
  213. VX_API_ENTRY vx_status VX_API_CALL vxuDilate3x3(vx_context context, vx_image input, vx_image output);
  214. /*! \brief [Immediate] Computes a median filter on the image by a 3x3 window.
  215. * \param [in] context The reference to the overall context.
  216. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  217. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  218. * \ingroup group_vision_function_median_image
  219. * \return A <tt>\ref vx_status_e</tt> enumeration.
  220. * \retval VX_SUCCESS Success
  221. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  222. */
  223. VX_API_ENTRY vx_status VX_API_CALL vxuMedian3x3(vx_context context, vx_image input, vx_image output);
  224. /*! \brief [Immediate] Computes a box filter on the image by a 3x3 window.
  225. * \param [in] context The reference to the overall context.
  226. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  227. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  228. * \ingroup group_vision_function_box_image
  229. * \return A <tt>\ref vx_status_e</tt> enumeration.
  230. * \retval VX_SUCCESS Success
  231. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  232. */
  233. VX_API_ENTRY vx_status VX_API_CALL vxuBox3x3(vx_context context, vx_image input, vx_image output);
  234. /*! \brief [Immediate] Computes a gaussian filter on the image by a 3x3 window.
  235. * \param [in] context The reference to the overall context.
  236. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  237. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  238. * \ingroup group_vision_function_gaussian_image
  239. * \return A <tt>\ref vx_status_e</tt> enumeration.
  240. * \retval VX_SUCCESS Success
  241. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  242. */
  243. VX_API_ENTRY vx_status VX_API_CALL vxuGaussian3x3(vx_context context, vx_image input, vx_image output);
  244. /*! \brief [Immediate] Performs Non-linear Filtering.
  245. * \param [in] context The reference to the overall context.
  246. * \param [in] function The non-linear filter function. See <tt>\ref vx_non_linear_filter_e</tt>.
  247. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  248. * \param [in] mask The mask to be applied to the Non-linear function. <tt>\ref VX_MATRIX_ORIGIN</tt> attribute is used
  249. * to place the mask appropriately when computing the resulting image. See <tt>\ref vxCreateMatrixFromPattern</tt> and <tt>\ref vxCreateMatrixFromPatternAndOrigin</tt>.
  250. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  251. * \return A <tt>\ref vx_status_e</tt> enumeration.
  252. * \retval VX_SUCCESS Success
  253. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  254. * \ingroup group_vision_function_nonlinear_filter
  255. */
  256. VX_API_ENTRY vx_status VX_API_CALL vxuNonLinearFilter(vx_context context, vx_enum function, vx_image input, vx_matrix mask, vx_image output);
  257. /*! \brief [Immediate] Computes a convolution on the input image with the supplied
  258. * matrix.
  259. * \param [in] context The reference to the overall context.
  260. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> format.
  261. * \param [in] conv The <tt>\ref vx_int16</tt> convolution matrix.
  262. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  263. * \ingroup group_vision_function_custom_convolution
  264. * \return A <tt>\ref vx_status_e</tt> enumeration.
  265. * \retval VX_SUCCESS Success
  266. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  267. */
  268. VX_API_ENTRY vx_status VX_API_CALL vxuConvolve(vx_context context, vx_image input, vx_convolution conv, vx_image output);
  269. /*! \brief [Immediate] Computes a Gaussian pyramid from an input image.
  270. * \param [in] context The reference to the overall context.
  271. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt>
  272. * \param [out] gaussian The Gaussian pyramid with <tt>\ref VX_DF_IMAGE_U8</tt> to construct.
  273. * \ingroup group_vision_function_gaussian_pyramid
  274. * \return A <tt>\ref vx_status_e</tt> enumeration.
  275. * \retval VX_SUCCESS Success
  276. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  277. */
  278. VX_API_ENTRY vx_status VX_API_CALL vxuGaussianPyramid(vx_context context, vx_image input, vx_pyramid gaussian);
  279. /*! \brief [Immediate] Computes a Laplacian pyramid from an input image.
  280. * \param [in] context The reference to the overall context.
  281. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  282. * \param [out] laplacian The Laplacian pyramid with <tt>\ref VX_DF_IMAGE_S16</tt> to construct.
  283. * \param [out] output The lowest resolution image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format necessary to reconstruct the input image from the pyramid. The output image format should be same as input image format.
  284. * \ingroup group_vision_function_laplacian_pyramid
  285. * \see group_pyramid
  286. * \return A <tt>\ref vx_status</tt> enumeration.
  287. * \retval VX_SUCCESS Success.
  288. * \retval * An error occured. See <tt>\ref vx_status_e</tt>
  289. */
  290. VX_API_ENTRY vx_status VX_API_CALL vxuLaplacianPyramid(vx_context context, vx_image input, vx_pyramid laplacian, vx_image output);
  291. /*! \brief [Immediate] Reconstructs an image from a Laplacian Image pyramid.
  292. * \param [in] context The reference to the overall context.
  293. * \param [in] laplacian The Laplacian pyramid with <tt>\ref VX_DF_IMAGE_S16</tt> format.
  294. * \param [in] input The lowest resolution image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format for the Laplacian pyramid.
  295. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format with the highest possible resolution reconstructed from the Laplacian pyramid. The output image format should be same as input image format.
  296. * \ingroup group_vision_function_laplacian_reconstruct
  297. * \see group_pyramid
  298. * \return A <tt>\ref vx_status</tt> enumeration.
  299. * \retval VX_SUCCESS Success.
  300. * \retval * An error occured. See <tt>\ref vx_status_e</tt>
  301. */
  302. VX_API_ENTRY vx_status VX_API_CALL vxuLaplacianReconstruct(vx_context context, vx_pyramid laplacian, vx_image input,
  303. vx_image output);
  304. /*! \brief [Immediate] Computes an accumulation.
  305. * \param [in] context The reference to the overall context.
  306. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  307. * \param [in,out] accum The accumulation image in <tt>\ref VX_DF_IMAGE_S16</tt>
  308. * \ingroup group_vision_function_accumulate
  309. * \return A <tt>\ref vx_status_e</tt> enumeration.
  310. * \retval VX_SUCCESS Success
  311. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  312. */
  313. VX_API_ENTRY vx_status VX_API_CALL vxuAccumulateImage(vx_context context, vx_image input, vx_image accum);
  314. /*! \brief [Immediate] Computes a weighted accumulation.
  315. * \param [in] context The reference to the overall context.
  316. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  317. * \param [in] alpha A <tt>\ref VX_TYPE_FLOAT32</tt> type, the input value with the range \f$ 0.0 \le \alpha \le 1.0 \f$.
  318. * \param [in,out] accum The <tt>\ref VX_DF_IMAGE_U8</tt> accumulation image.
  319. * \ingroup group_vision_function_accumulate_weighted
  320. * \return A <tt>\ref vx_status_e</tt> enumeration.
  321. * \retval VX_SUCCESS Success
  322. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  323. */
  324. VX_API_ENTRY vx_status VX_API_CALL vxuAccumulateWeightedImage(vx_context context, vx_image input, vx_scalar alpha, vx_image accum);
  325. /*! \brief [Immediate] Computes a squared accumulation.
  326. * \param [in] context The reference to the overall context.
  327. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  328. * \param [in] shift A <tt>\ref VX_TYPE_UINT32</tt> type, the input value with the range \f$ 0 \le shift \le 15 \f$.
  329. * \param [in,out] accum The accumulation image in <tt>\ref VX_DF_IMAGE_S16</tt>
  330. * \ingroup group_vision_function_accumulate_square
  331. * \return A <tt>\ref vx_status_e</tt> enumeration.
  332. * \retval VX_SUCCESS Success
  333. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  334. */
  335. VX_API_ENTRY vx_status VX_API_CALL vxuAccumulateSquareImage(vx_context context, vx_image input, vx_scalar shift, vx_image accum);
  336. /*! \brief [Immediate] Computes the minimum and maximum values of the image.
  337. * \param [in] context The reference to the overall context.
  338. * \param [in] input The input image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  339. * \param [out] minVal The minimum value in the image, which corresponds to the type of the input.
  340. * \param [out] maxVal The maximum value in the image, which corresponds to the type of the input.
  341. * \param [out] minLoc [optional] The minimum <tt>\ref VX_TYPE_COORDINATES2D</tt> locations. If the input image has several minimums, the kernel will return up to the capacity of the array.
  342. * \param [out] maxLoc [optional] The maximum <tt>\ref VX_TYPE_COORDINATES2D</tt> locations. If the input image has several maximums, the kernel will return up to the capacity of the array.
  343. * \param [out] minCount [optional] The total number of detected minimums in image. Use a <tt>\ref VX_TYPE_SIZE</tt> scalar.
  344. * \param [out] maxCount [optional] The total number of detected maximums in image. Use a <tt>\ref VX_TYPE_SIZE</tt> scalar.
  345. * \ingroup group_vision_function_minmaxloc
  346. * \return A <tt>\ref vx_status_e</tt> enumeration.
  347. * \retval VX_SUCCESS Success
  348. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  349. */
  350. VX_API_ENTRY vx_status VX_API_CALL vxuMinMaxLoc(vx_context context, vx_image input,
  351. vx_scalar minVal, vx_scalar maxVal,
  352. vx_array minLoc, vx_array maxLoc,
  353. vx_scalar minCount, vx_scalar maxCount);
  354. /*! \brief [Immediate] Computes pixel-wise minimum values between two images.
  355. * \param [in] context The reference to the overall context.
  356. * \param [in] in1 The first input image. Must be of type <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt>.
  357. * \param [in] in2 The second input image. Must be of type <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt>.
  358. * \param [out] out The output image which will hold the result of min.
  359. * \ingroup group_vision_function_min
  360. * \return A <tt>\ref vx_status_e</tt> enumeration.
  361. * \retval VX_SUCCESS Success
  362. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  363. */
  364. VX_API_ENTRY vx_status VX_API_CALL vxuMin(vx_context context, vx_image in1, vx_image in2, vx_image out);
  365. /*! \brief [Immediate] Computes pixel-wise maximum values between two images.
  366. * \param [in] context The reference to the overall context.
  367. * \param [in] in1 The first input image. Must be of type <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt>.
  368. * \param [in] in2 The second input image. Must be of type <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt>.
  369. * \param [out] out The output image which will hold the result of max.
  370. * \ingroup group_vision_function_max
  371. * \return A <tt>\ref vx_status_e</tt> enumeration.
  372. * \retval VX_SUCCESS Success
  373. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  374. */
  375. VX_API_ENTRY vx_status VX_API_CALL vxuMax(vx_context context, vx_image in1, vx_image in2, vx_image out);
  376. /*! \brief [Immediate] Converts the input images bit-depth into the output image.
  377. * \param [in] context The reference to the overall context.
  378. * \param [in] input The input image.
  379. * \param [out] output The output image.
  380. * \param [in] policy A <tt>\ref VX_TYPE_ENUM</tt> of the <tt>\ref vx_convert_policy_e</tt> enumeration.
  381. * \param [in] shift A scalar containing a <tt>\ref VX_TYPE_INT32</tt> of the shift value.
  382. * \ingroup group_vision_function_convertdepth
  383. * \return A <tt>\ref vx_status_e</tt> enumeration.
  384. * \retval VX_SUCCESS Success
  385. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>..
  386. */
  387. VX_API_ENTRY vx_status VX_API_CALL vxuConvertDepth(vx_context context, vx_image input, vx_image output, vx_enum policy, vx_int32 shift);
  388. /*! \brief [Immediate] Computes Canny Edges on the input image into the output image.
  389. * \param [in] context The reference to the overall context.
  390. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  391. * \param [in] hyst The double threshold for hysteresis. The <tt>\ref VX_THRESHOLD_INPUT_FORMAT</tt> shall be either
  392. * <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt>. The <tt>\ref VX_THRESHOLD_OUTPUT_FORMAT</tt> is ignored.
  393. * \param [in] gradient_size The size of the Sobel filter window, must support at least 3, 5 and 7.
  394. * \param [in] norm_type A flag indicating the norm used to compute the gradient, <tt>\ref VX_NORM_L1</tt> or <tt>\ref VX_NORM_L2</tt>.
  395. * \param [out] output The output image in <tt>\ref VX_DF_IMAGE_U8</tt> format with values either 0 or 255.
  396. * \ingroup group_vision_function_canny
  397. * \return A <tt>\ref vx_status_e</tt> enumeration.
  398. * \retval VX_SUCCESS Success
  399. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  400. */
  401. VX_API_ENTRY vx_status VX_API_CALL vxuCannyEdgeDetector(vx_context context, vx_image input, vx_threshold hyst,
  402. vx_int32 gradient_size, vx_enum norm_type,
  403. vx_image output);
  404. /*! \brief [Immediate] Performs a Gaussian Blur on an image then half-scales it. The interpolation mode used is nearest-neighbor.
  405. * \param [in] context The reference to the overall context.
  406. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  407. * \param [out] output The output <tt>\ref VX_DF_IMAGE_U8</tt> image.
  408. * \param [in] kernel_size The input size of the Gaussian filter. Supported values are 1, 3 and 5.
  409. * \ingroup group_vision_function_scale_image
  410. * \return A <tt>\ref vx_status_e</tt> enumeration.
  411. * \retval VX_SUCCESS Success
  412. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  413. */
  414. VX_API_ENTRY vx_status VX_API_CALL vxuHalfScaleGaussian(vx_context context, vx_image input, vx_image output, vx_int32 kernel_size);
  415. /*! \brief [Immediate] Computes the bitwise and between two images.
  416. * \param [in] context The reference to the overall context.
  417. * \param [in] in1 A <tt>\ref VX_DF_IMAGE_U8</tt> input image
  418. * \param [in] in2 A <tt>\ref VX_DF_IMAGE_U8</tt> input image
  419. * \param [out] out The <tt>\ref VX_DF_IMAGE_U8</tt> output image.
  420. * \ingroup group_vision_function_and
  421. * \return A <tt>\ref vx_status_e</tt> enumeration.
  422. * \retval VX_SUCCESS Success
  423. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  424. */
  425. VX_API_ENTRY vx_status VX_API_CALL vxuAnd(vx_context context, vx_image in1, vx_image in2, vx_image out);
  426. /*! \brief [Immediate] Computes the bitwise inclusive-or between two images.
  427. * \param [in] context The reference to the overall context.
  428. * \param [in] in1 A <tt>\ref VX_DF_IMAGE_U8</tt> input image
  429. * \param [in] in2 A <tt>\ref VX_DF_IMAGE_U8</tt> input image
  430. * \param [out] out The <tt>\ref VX_DF_IMAGE_U8</tt> output image.
  431. * \ingroup group_vision_function_or
  432. * \return A <tt>\ref vx_status_e</tt> enumeration.
  433. * \retval VX_SUCCESS Success
  434. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  435. */
  436. VX_API_ENTRY vx_status VX_API_CALL vxuOr(vx_context context, vx_image in1, vx_image in2, vx_image out);
  437. /*! \brief [Immediate] Computes the bitwise exclusive-or between two images.
  438. * \param [in] context The reference to the overall context.
  439. * \param [in] in1 A <tt>\ref VX_DF_IMAGE_U8</tt> input image
  440. * \param [in] in2 A <tt>\ref VX_DF_IMAGE_U8</tt> input image
  441. * \param [out] out The <tt>\ref VX_DF_IMAGE_U8</tt> output image.
  442. * \ingroup group_vision_function_xor
  443. * \return A <tt>\ref vx_status_e</tt> enumeration.
  444. * \retval VX_SUCCESS Success
  445. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  446. */
  447. VX_API_ENTRY vx_status VX_API_CALL vxuXor(vx_context context, vx_image in1, vx_image in2, vx_image out);
  448. /*! \brief [Immediate] Computes the bitwise not of an image.
  449. * \param [in] context The reference to the overall context.
  450. * \param [in] input The <tt>\ref VX_DF_IMAGE_U8</tt> input image
  451. * \param [out] output The <tt>\ref VX_DF_IMAGE_U8</tt> output image.
  452. * \ingroup group_vision_function_not
  453. * \return A <tt>\ref vx_status_e</tt> enumeration.
  454. * \retval VX_SUCCESS Success
  455. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  456. */
  457. VX_API_ENTRY vx_status VX_API_CALL vxuNot(vx_context context, vx_image input, vx_image output);
  458. /*! \brief [Immediate] Performs elementwise multiplications on pixel values in the input images and a scale.
  459. * \param [in] context The reference to the overall context.
  460. * \param [in] in1 A <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> input image.
  461. * \param [in] in2 A <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> input image.
  462. * \param [in] scale A non-negative <tt>\ref VX_TYPE_FLOAT32</tt> multiplied to each product before overflow handling.
  463. * \param [in] overflow_policy A <tt>\ref vx_convert_policy_e</tt> enumeration.
  464. * \param [in] rounding_policy A <tt>\ref vx_round_policy_e</tt> enumeration.
  465. * \param [out] out The output image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  466. * \ingroup group_vision_function_mult
  467. * \return A <tt>\ref vx_status_e</tt> enumeration.
  468. * \retval VX_SUCCESS Success
  469. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  470. */
  471. VX_API_ENTRY vx_status VX_API_CALL vxuMultiply(vx_context context, vx_image in1, vx_image in2, vx_float32 scale, vx_enum overflow_policy, vx_enum rounding_policy, vx_image out);
  472. /*! \brief [Immediate] Performs arithmetic addition on pixel values in the input images.
  473. * \param [in] context The reference to the overall context.
  474. * \param [in] in1 A <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> input image.
  475. * \param [in] in2 A <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> input image.
  476. * \param [in] policy A \ref vx_convert_policy_e enumeration.
  477. * \param [out] out The output image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  478. * \ingroup group_vision_function_add
  479. * \return A <tt>\ref vx_status_e</tt> enumeration.
  480. * \retval VX_SUCCESS Success
  481. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  482. */
  483. VX_API_ENTRY vx_status VX_API_CALL vxuAdd(vx_context context, vx_image in1, vx_image in2, vx_enum policy, vx_image out);
  484. /*! \brief [Immediate] Performs arithmetic subtraction on pixel values in the input images.
  485. * \param [in] context The reference to the overall context.
  486. * \param [in] in1 A <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> input image, the minuend.
  487. * \param [in] in2 A <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> input image, the subtrahend.
  488. * \param [in] policy A \ref vx_convert_policy_e enumeration.
  489. * \param [out] out The output image in <tt>\ref VX_DF_IMAGE_U8</tt> or <tt>\ref VX_DF_IMAGE_S16</tt> format.
  490. * \ingroup group_vision_function_sub
  491. * \return A <tt>\ref vx_status_e</tt> enumeration.
  492. * \retval VX_SUCCESS Success
  493. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  494. */
  495. VX_API_ENTRY vx_status VX_API_CALL vxuSubtract(vx_context context, vx_image in1, vx_image in2, vx_enum policy, vx_image out);
  496. /*! \brief [Immediate] Performs an Affine warp on an image.
  497. * \param [in] context The reference to the overall context.
  498. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  499. * \param [in] matrix The affine matrix. Must be 2x3 of type \ref VX_TYPE_FLOAT32.
  500. * \param [in] type The interpolation type from \ref vx_interpolation_type_e.
  501. * \ref VX_INTERPOLATION_AREA is not supported.
  502. * \param [out] output The output <tt>\ref VX_DF_IMAGE_U8</tt> image.
  503. * \ingroup group_vision_function_warp_affine
  504. * \return A <tt>\ref vx_status_e</tt> enumeration.
  505. * \retval VX_SUCCESS Success
  506. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  507. */
  508. VX_API_ENTRY vx_status VX_API_CALL vxuWarpAffine(vx_context context, vx_image input, vx_matrix matrix, vx_enum type, vx_image output);
  509. /*! \brief [Immediate] Performs an Perspective warp on an image.
  510. * \param [in] context The reference to the overall context.
  511. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  512. * \param [in] matrix The perspective matrix. Must be 3x3 of type \ref VX_TYPE_FLOAT32.
  513. * \param [in] type The interpolation type from \ref vx_interpolation_type_e.
  514. * \ref VX_INTERPOLATION_AREA is not supported.
  515. * \param [out] output The output <tt>\ref VX_DF_IMAGE_U8</tt> image.
  516. * \ingroup group_vision_function_warp_perspective
  517. * \return A <tt>\ref vx_status_e</tt> enumeration.
  518. * \retval VX_SUCCESS Success
  519. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  520. */
  521. VX_API_ENTRY vx_status VX_API_CALL vxuWarpPerspective(vx_context context, vx_image input, vx_matrix matrix, vx_enum type, vx_image output);
  522. /*! \brief [Immediate] Computes the Harris Corners over an image and produces the array of scored points.
  523. * \param [in] context The reference to the overall context.
  524. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  525. * \param [in] strength_thresh The <tt>\ref VX_TYPE_FLOAT32</tt> minimum threshold which to eliminate Harris Corner scores (computed using the normalized Sobel kernel).
  526. * \param [in] min_distance The <tt>\ref VX_TYPE_FLOAT32</tt> radial Euclidean distance for non-maximum suppression.
  527. * \param [in] sensitivity The <tt>\ref VX_TYPE_FLOAT32</tt> scalar sensitivity threshold \f$ k \f$ from the Harris-Stephens equation.
  528. * \param [in] gradient_size The gradient window size to use on the input. The
  529. * implementation must support at least 3, 5, and 7.
  530. * \param [in] block_size The block window size used to compute the harris corner score.
  531. * The implementation must support at least 3, 5, and 7.
  532. * \param [out] corners The array of <tt>\ref VX_TYPE_KEYPOINT</tt> structs. The order of the keypoints in this array is implementation dependent.
  533. * \param [out] num_corners [optional] The total number of detected corners in image. Use a \ref VX_TYPE_SIZE scalar
  534. * \ingroup group_vision_function_harris
  535. * \return A <tt>\ref vx_status_e</tt> enumeration.
  536. * \retval VX_SUCCESS Success
  537. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  538. */
  539. VX_API_ENTRY vx_status VX_API_CALL vxuHarrisCorners(vx_context context,
  540. vx_image input,
  541. vx_scalar strength_thresh,
  542. vx_scalar min_distance,
  543. vx_scalar sensitivity,
  544. vx_int32 gradient_size,
  545. vx_int32 block_size,
  546. vx_array corners,
  547. vx_scalar num_corners);
  548. /*! \brief [Immediate] Computes corners on an image using FAST algorithm and produces the array of feature points.
  549. * \param [in] context The reference to the overall context.
  550. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  551. * \param [in] strength_thresh Threshold on difference between intensity of the central pixel and pixels on Bresenham's circle
  552. * of radius 3 (<tt>\ref VX_TYPE_FLOAT32</tt> scalar), with a value in the range of 0.0 \f$\le\f$ strength_thresh < 256.0.
  553. * Any fractional value will be truncated to an integer.
  554. * \param [in] nonmax_suppression If true, non-maximum suppression is applied to
  555. * detected corners before being places in the <tt>\ref vx_array</tt> of <tt>\ref VX_TYPE_KEYPOINT</tt> structs.
  556. * \param [out] corners Output corner <tt>\ref vx_array</tt> of <tt>\ref VX_TYPE_KEYPOINT</tt>. The order of the keypoints in this array is implementation dependent.
  557. * \param [out] num_corners [optional] The total number of detected corners in image. Use a \ref VX_TYPE_SIZE scalar.
  558. * \ingroup group_vision_function_fast
  559. * \return A <tt>\ref vx_status_e</tt> enumeration.
  560. * \retval VX_SUCCESS Success
  561. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  562. */
  563. VX_API_ENTRY vx_status VX_API_CALL vxuFastCorners(vx_context context, vx_image input, vx_scalar strength_thresh, vx_bool nonmax_suppression, vx_array corners, vx_scalar num_corners);
  564. /*! \brief [Immediate] Computes an optical flow on two images.
  565. * \param [in] context The reference to the overall context.
  566. * \param [in] old_images Input of first (old) image pyramid in <tt>\ref VX_DF_IMAGE_U8</tt>.
  567. * \param [in] new_images Input of destination (new) image pyramid in <tt>\ref VX_DF_IMAGE_U8</tt>
  568. * \param [in] old_points an array of key points in a vx_array of <tt>\ref VX_TYPE_KEYPOINT</tt> those key points are defined at
  569. * the old_images high resolution pyramid
  570. * \param [in] new_points_estimates an array of estimation on what is the output key points in a <tt>\ref vx_array</tt> of
  571. * <tt>\ref VX_TYPE_KEYPOINT</tt> those keypoints are defined at the new_images high resolution pyramid
  572. * \param [out] new_points an output array of key points in a <tt>\ref vx_array</tt> of <tt>\ref VX_TYPE_KEYPOINT</tt> those key points are
  573. * defined at the new_images high resolution pyramid
  574. * \param [in] termination termination can be <tt>\ref VX_TERM_CRITERIA_ITERATIONS</tt> or <tt>\ref VX_TERM_CRITERIA_EPSILON</tt> or
  575. * <tt>\ref VX_TERM_CRITERIA_BOTH</tt>
  576. * \param [in] epsilon is the <tt>\ref vx_float32</tt> error for terminating the algorithm
  577. * \param [in] num_iterations is the number of iterations. Use a <tt>\ref VX_TYPE_UINT32</tt> scalar.
  578. * \param [in] use_initial_estimate Can be set to either <tt>\ref vx_false_e</tt> or <tt>\ref vx_true_e</tt>.
  579. * \param [in] window_dimension The size of the window on which to perform the algorithm. See
  580. * <tt>\ref VX_CONTEXT_OPTICAL_FLOW_MAX_WINDOW_DIMENSION</tt>
  581. *
  582. * \ingroup group_vision_function_opticalflowpyrlk
  583. * \return A <tt>\ref vx_status_e</tt> enumeration.
  584. * \retval VX_SUCCESS Success
  585. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  586. */
  587. VX_API_ENTRY vx_status VX_API_CALL vxuOpticalFlowPyrLK(vx_context context,
  588. vx_pyramid old_images,
  589. vx_pyramid new_images,
  590. vx_array old_points,
  591. vx_array new_points_estimates,
  592. vx_array new_points,
  593. vx_enum termination,
  594. vx_scalar epsilon,
  595. vx_scalar num_iterations,
  596. vx_scalar use_initial_estimate,
  597. vx_size window_dimension);
  598. /*! \brief [Immediate] The function compares an image template against overlapped image regions.
  599. * \details The detailed equation to the matching can be found in <tt>\ref vx_comp_metric_e</tt>.
  600. * The output of the template matching node is a comparison map as described in <tt>\ref vx_comp_metric_e</tt>.
  601. * The Node have a limitation on the template image size (width*height). It should not be larger then 65535.
  602. * If the valid region of the template image is smaller than the entire template image, the result in the destination image is implementation-dependent.
  603. * \param [in] context The reference to the overall context.
  604. * \param [in] src The input image of type <tt>\ref VX_DF_IMAGE_U8</tt>.
  605. * \param [in] templateImage Searched template of type <tt>\ref VX_DF_IMAGE_U8</tt>.
  606. * \param [in] matchingMethod attribute specifying the comparison method <tt>\ref vx_comp_metric_e</tt>. This function support only <tt>\ref VX_COMPARE_CCORR_NORM</tt> and <tt>\ref VX_COMPARE_L2</tt>.
  607. * \param [out] output Map of comparison results. The output is an image of type <tt>\ref VX_DF_IMAGE_S16</tt>
  608. * \return A <tt>\ref vx_status_e</tt> enumeration.
  609. * \retval VX_SUCCESS Success
  610. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  611. * \ingroup group_vision_function_match_template
  612. */
  613. VX_API_ENTRY vx_status VX_API_CALL vxuMatchTemplate(vx_context context, vx_image src, vx_image templateImage, vx_enum matchingMethod, vx_image output);
  614. /*! \brief [Immediate] The function extracts LBP image from an input image
  615. * \param [in] context The reference to the overall context.
  616. * \param [in] in An input image in <tt>vx_image</tt>. Or \f$ SrcImg\f$ in the equations. the image is of type <tt>\ref VX_DF_IMAGE_U8</tt>
  617. * \param [in] format A variation of LBP like original LBP and mLBP. see <tt> \ref vx_lbp_format_e </tt>
  618. * \param [in] kernel_size Kernel size. Only size of 3 and 5 are supported
  619. * \param [out] out An output image in <tt>vx_image</tt>.Or \f$ DstImg\f$ in the equations. the image is of type <tt>\ref VX_DF_IMAGE_U8</tt>
  620. * \return A <tt>\ref vx_status_e</tt> enumeration.
  621. * \retval VX_SUCCESS Success
  622. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  623. * \ingroup group_vision_function_lbp
  624. */
  625. VX_API_ENTRY vx_status VX_API_CALL vxuLBP(vx_context context,
  626. vx_image in, vx_enum format, vx_int8 kernel_size, vx_image out);
  627. /*! \brief [Immediate] Performs cell calculations for the average gradient magnitude and gradient orientation histograms.
  628. * \details Firstly, the gradient magnitude and gradient orientation are computed for each pixel in the input image.
  629. * Two 1-D centred, point discrete derivative masks are applied to the input image in the horizontal and vertical directions.
  630. * \f[ M_h = [-1, 0, 1] \f] and \f[ M_v = [-1, 0, 1]^T \f]
  631. * \f$G_v\f$ is the result of applying mask \f$M_v\f$ to the input image, and \f$G_h\f$ is the result of applying mask \f$M_h\f$ to the input image.
  632. * The border mode used for the gradient calculation is implementation dependent. Its behavior should be similar to <tt>\ref VX_BORDER_UNDEFINED</tt>.
  633. * The gradient magnitudes and gradient orientations for each pixel are then calculated in the following manner.
  634. * \f[ G(x,y) = \sqrt{G_v(x,y)^2 + G_h(x,y)^2} \f]
  635. * \f[ \theta(x,y) = arctan(G_v(x,y), G_h(x,y)) \f]
  636. * where \f$arctan(v, h)\f$
  637. * is \f$ tan^{-1}(v/h)\f$ when \f$h!=0\f$,
  638. *
  639. * \f$ -pi/2 \f$ if \f$v<0\f$ and \f$h==0\f$,
  640. *
  641. * \f$ pi/2 \f$ if \f$v>0\f$ and \f$h==0\f$
  642. *
  643. * and \f$ 0 \f$ if \f$v==0\f$ and \f$h==0\f$
  644. *
  645. * Secondly, the gradient magnitudes and orientations are used to compute the bins output tensor and optional magnitudes output tensor.
  646. * These tensors are computed on a cell level where the cells are rectangular in shape.
  647. * The magnitudes tensor contains the average gradient magnitude for each cell.
  648. * \f[magnitudes(c) = \frac{1}{(cell\_width * cell\_height)}\sum\limits_{w=0}^{cell\_width} \sum\limits_{h=0}^{cell\_height} G_c(w,h)\f]
  649. * where \f$G_c\f$ is the gradient magnitudes related to cell \f$c\f$.
  650. * The bins tensor contains histograms of gradient orientations for each cell.
  651. * The gradient orientations at each pixel range from 0 to 360 degrees. These are quantised into a set of histogram bins based on the num_bins parameter.
  652. * Each pixel votes for a specific cell histogram bin based on its gradient orientation. The vote itself is the pixel's gradient magnitude.
  653. * \f[bins(c, n) = \sum\limits_{w=0}^{cell\_width} \sum\limits_{h=0}^{cell\_height} G_c(w,h) * 1[B_c(w, h, num\_bins) == n]\f]
  654. * where \f$B_c\f$ produces the histogram bin number based on the gradient orientation of the pixel at location (\f$w\f$, \f$h\f$) in cell \f$c\f$ based on
  655. * the \f$num\_bins\f$ and \f[1[B_c(w, h, num\_bins) == n]\f] is a delta-function with value 1 when \f$B_c(w, h, num\_bins) == n\f$ or 0 otherwise.
  656. * \param [in] context The reference to the overall context.
  657. * \param [in] input The input image of type <tt>\ref VX_DF_IMAGE_U8</tt>.
  658. * \param [in] cell_width The histogram cell width of type <tt>\ref VX_TYPE_INT32</tt>.
  659. * \param [in] cell_height The histogram cell height of type <tt>\ref VX_TYPE_INT32</tt>.
  660. * \param [in] num_bins The histogram size of type <tt>\ref VX_TYPE_INT32</tt>.
  661. * \param [out] magnitudes The output average gradient magnitudes per cell of <tt>\ref vx_tensor</tt> of type <tt>\ref VX_TYPE_INT16</tt> of size \f$ [floor(image_{width}/cell_{width}) ,floor(image_{height}/cell_{height}) ] \f$.
  662. * \param [out] bins The output gradient orientation histograms per cell of <tt>\ref vx_tensor</tt> of type <tt>\ref VX_TYPE_INT16</tt> of size \f$ [floor(image_{width}/cell_{width}) ,floor(image_{height}/cell_{height}), num_{bins}] \f$.
  663. *
  664. * \ingroup group_vision_function_hog
  665. * \return A <tt>\ref vx_status_e</tt> enumeration.
  666. * \retval VX_SUCCESS Success
  667. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  668. */
  669. VX_API_ENTRY vx_status VX_API_CALL vxuHOGCells(vx_context context, vx_image input, vx_int32 cell_width, vx_int32 cell_height, vx_int32 num_bins, vx_tensor magnitudes, vx_tensor bins);
  670. /*! \brief [Immediate] Computes Histogram of Oriented Gradients features for the W1xW2 window in a sliding window fashion over the whole input image.
  671. * \details Firstly if a magnitudes tensor is provided the cell histograms in the bins tensor are normalised by the average cell gradient magnitudes.
  672. \f[bins(c,n) = \frac{bins(c,n)}{magnitudes(c)}\f]
  673. * To account for changes in illumination and contrast the cell histograms must be locally normalized which requires grouping the cell histograms together into larger spatially connected blocks.
  674. * Blocks are rectangular grids represented by three parameters: the number of cells per block, the number of pixels per cell, and the number of bins per cell histogram.
  675. * These blocks typically overlap, meaning that each cell histogram contributes more than once to the final descriptor.
  676. * To normalize a block its cell histograms \f$h\f$ are grouped together to form a vector \f$v = [h_1, h_2, h_3, ... , h_n]\f$.
  677. * This vector is normalised using L2-Hys which means performing L2-norm on this vector; clipping the result (by limiting the maximum values of v to be threshold) and renormalizing again. If the threshold is equal to zero then L2-Hys normalization is not performed.
  678. * \f[L2norm(v) = \frac{v}{\sqrt{\|v\|_2^2 + \epsilon^2}}\f]
  679. * where \f$ \|v\|_k \f$ be its k-norm for k=1, 2, and \f$ \epsilon \f$ be a small constant.
  680. * For a specific window its HOG descriptor is then the concatenated vector of the components of the normalized cell histograms from all of the block regions contained in the window.
  681. * The W1xW2 window starting position is at coordinates 0x0.
  682. * If the input image has dimensions that are not an integer multiple of W1xW2 blocks with the specified stride, then the last positions that contain only a partial W1xW2 window
  683. * will be calculated with the remaining part of the W1xW2 window padded with zeroes.
  684. * The Window W1xW2 must also have a size so that it contains an integer number of cells, otherwise the node is not well-defined.
  685. * The final output tensor will contain HOG descriptors equal to the number of windows in the input image.
  686. * The output features tensor has 3 dimensions, given by:\n
  687. * \f[[ (floor((image_{width}-window_{width})/window_{stride}) + 1),\f]
  688. * \f[ (floor((image_{height}-window_{height})/window_{stride}) + 1),\f]
  689. * \f[ floor((window_{width} - block_{width})/block_{stride} + 1) * floor((window_{height} - block_{height})/block_{stride} + 1) *\f]
  690. * \f[ (((block_{width} * block_{height}) / (cell_{width} * cell_{height})) * num_{bins})] \f]
  691. * See <tt>\ref vxCreateTensor</tt> and <tt>\ref vxCreateVirtualTensor</tt>.
  692. * The output tensor from this function may be very large. For this reason, is it not recommended that this "immediate mode" version of the function be used.
  693. * The preferred method to perform this function is as graph node with a virtual tensor as the output.
  694. * \param [in] context The reference to the overall context.
  695. * \param [in] input The input image of type <tt>\ref VX_DF_IMAGE_U8</tt>.
  696. * \param [in] magnitudes The averge gradient magnitudes per cell of <tt>\ref vx_tensor</tt> of type <tt>\ref VX_TYPE_INT16</tt>. It is the output of <tt>\ref vxuHOGCells</tt>.
  697. * \param [in] bins The gradient orientation histogram per cell of <tt>\ref vx_tensor</tt> of type <tt>\ref VX_TYPE_INT16</tt>. It is the output of <tt>\ref vxuHOGCells</tt>.
  698. * \param [in] params The parameters of type <tt>\ref vx_hog_t</tt>.
  699. * \param [in] hog_param_size Size of <tt>\ref vx_hog_t</tt> in bytes.
  700. * \param [out] features The output HOG features of <tt>\ref vx_tensor</tt> of type <tt>\ref VX_TYPE_INT16</tt>.
  701. *
  702. * \ingroup group_vision_function_hog
  703. * \return A <tt>\ref vx_status_e</tt> enumeration.
  704. * \retval VX_SUCCESS Success
  705. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  706. */
  707. VX_API_ENTRY vx_status VX_API_CALL vxuHOGFeatures(vx_context context, vx_image input, vx_tensor magnitudes, vx_tensor bins, const vx_hog_t *params, vx_size hog_param_size, vx_tensor features);
  708. /*! \brief [Immediate] Finds the Probabilistic Hough Lines detected in the input binary image, each line is stored in the output array as a set of points (x1, y1, x2, y2) .
  709. * \details Some implementations of the algorithm may have a random or non-deterministic element. If the target application is in a safety-critical environment this
  710. * should be borne in mind and steps taken in the implementation, the application or both to achieve the level of determinism required by the system design.
  711. * \param [in] context The reference to the overall context.
  712. * \param [in] input 8 bit, single channel binary source image
  713. * \param [in] params parameters of the struct <tt>\ref vx_hough_lines_p_t</tt>
  714. * \param [out] lines_array lines_array contains array of lines, see <tt>\ref vx_line2d_t</tt> The order of lines in implementation dependent
  715. * \param [out] num_lines [optional] The total number of detected lines in image. Use a VX_TYPE_SIZE scalar
  716. * \return A <tt>\ref vx_status_e</tt> enumeration.
  717. * \retval VX_SUCCESS Success
  718. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  719. * \ingroup group_vision_function_hough_lines_p
  720. */
  721. VX_API_ENTRY vx_status VX_API_CALL vxuHoughLinesP(vx_context context, vx_image input, const vx_hough_lines_p_t *params, vx_array lines_array, vx_scalar num_lines);
  722. /*! \brief [Immediate] Remaps an output image from an input image.
  723. * \param [in] context The reference to the overall context.
  724. * \param [in] input The input <tt>\ref VX_DF_IMAGE_U8</tt> image.
  725. * \param [in] table The remap table object.
  726. * \param [in] policy The interpolation policy from \ref vx_interpolation_type_e.
  727. * \ref VX_INTERPOLATION_AREA is not supported.
  728. * \param [out] output The output <tt>\ref VX_DF_IMAGE_U8</tt> image.
  729. * \return A <tt>\ref vx_status_e</tt> enumeration.
  730. * \ingroup group_vision_function_remap
  731. */
  732. VX_API_ENTRY vx_status VX_API_CALL vxuRemap(vx_context context,
  733. vx_image input,
  734. vx_remap table,
  735. vx_enum policy,
  736. vx_image output);
  737. /*! \brief [Immediate] The function applies bilateral filtering to the input tensor.
  738. * \param [in] context The reference to the overall context.
  739. * \param [in] src The input data a <tt>\ref vx_tensor</tt>. maximum 3 dimension and minimum 2. The tensor is of type <tt>\ref VX_TYPE_UINT8</tt> or <tt>\ref VX_TYPE_INT16</tt>.
  740. * dimensions are [radiometric ,width,height] or [width,height]
  741. * \param [in] diameter of each pixel neighbourhood that is used during filtering. Values of diameter must be odd. Bigger then 3 and smaller then 10.
  742. * \param [in] sigmaValues Filter sigma in the radiometric space. Supported values are bigger then 0 and smaller or equal 20.
  743. * \param [in] sigmaSpace Filter sigma in the spatial space. Supported values are bigger then 0 and smaller or equal 20.
  744. * \param [out] dst The output data a <tt>\ref vx_tensor</tt>,Of type <tt>\ref VX_TYPE_UINT8</tt> or <tt>\ref VX_TYPE_INT16</tt>. And must be the same type and size of the input.
  745. * \note The border modes
  746. * <tt>\ref VX_NODE_BORDER</tt> value
  747. * <tt>\ref VX_BORDER_REPLICATE</tt> and <tt>\ref VX_BORDER_CONSTANT</tt> are supported.
  748. * \return A <tt>\ref vx_status_e</tt> enumeration.
  749. * \retval VX_SUCCESS Success
  750. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  751. * \ingroup group_vision_function_bilateral_filter
  752. */
  753. VX_API_ENTRY vx_status VX_API_CALL vxuBilateralFilter(vx_context context, vx_tensor src, vx_int32 diameter, vx_float32 sigmaSpace, vx_float32 sigmaValues, vx_tensor dst);
  754. /*! \brief [Immediate] Performs element wise multiplications on element values in the input tensor data with a scale.
  755. * \param [in] context The reference to the overall context.
  756. * \param [in] input1 Input tensor data. Implementations must support input tensor data type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_position 8,
  757. * and tensor data types <tt>\ref VX_TYPE_UINT8</tt> and <tt>\ref VX_TYPE_INT8</tt>, with fixed_point_position 0.
  758. * \param [in] input2 Input tensor data. The dimensions and sizes of input2 match those of input1, unless the vx_tensor of one or more dimensions in input2 is 1.
  759. * In this case, those dimensions are treated as if this tensor was expanded to match the size of the corresponding dimension of input1,
  760. * and data was duplicated on all terms in that dimension. After this expansion, the dimensions will be equal.
  761. * The data type must match the data type of Input1.
  762. * \param [in] scale A non-negative <tt>\ref VX_TYPE_FLOAT32</tt> multiplied to each product before overflow handling.
  763. * \param [in] overflow_policy A <tt>\ref vx_convert_policy_e</tt> enumeration.
  764. * \param [in] rounding_policy A <tt>\ref vx_round_policy_e</tt> enumeration.
  765. * \param [out] output The output tensor data with the same dimensions as the input tensor data.
  766. * \ingroup group_vision_function_tensor_multiply
  767. * \return A <tt>\ref vx_status_e</tt> enumeration.
  768. * \retval VX_SUCCESS Success
  769. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  770. */
  771. VX_API_ENTRY vx_status VX_API_CALL vxuTensorMultiply(vx_context context, vx_tensor input1, vx_tensor input2, vx_scalar scale, vx_enum overflow_policy,
  772. vx_enum rounding_policy, vx_tensor output);
  773. /*! \brief [Immediate] Performs arithmetic addition on element values in the input tensor data.
  774. * \param [in] context The reference to the overall context.
  775. * \param [in] input1 Input tensor data. Implementations must support input tensor data type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_position 8,
  776. * and tensor data types <tt>\ref VX_TYPE_UINT8</tt> and <tt>\ref VX_TYPE_INT8</tt>, with fixed_point_position 0.
  777. * \param [in] input2 Input tensor data. The dimensions and sizes of input2 match those of input1, unless the vx_tensor of one or more dimensions in input2 is 1.
  778. * In this case, those dimensions are treated as if this tensor was expanded to match the size of the corresponding dimension of input1,
  779. * and data was duplicated on all terms in that dimension. After this expansion, the dimensions will be equal.
  780. * The data type must match the data type of Input1.
  781. * \param [in] policy A <tt>\ref vx_convert_policy_e</tt> enumeration.
  782. * \param [out] output The output tensor data with the same dimensions as the input tensor data.
  783. * \ingroup group_vision_function_tensor_add
  784. * \return A <tt>\ref vx_status_e</tt> enumeration.
  785. * \retval VX_SUCCESS Success
  786. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  787. */
  788. VX_API_ENTRY vx_status VX_API_CALL vxuTensorAdd(vx_context context, vx_tensor input1, vx_tensor input2, vx_enum policy, vx_tensor output);
  789. /*! \brief [Immediate] Performs arithmetic subtraction on element values in the input tensor data.
  790. * \param [in] context The reference to the overall context.
  791. * \param [in] input1 Input tensor data. Implementations must support input tensor data type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_position 8,
  792. * and tensor data types <tt>\ref VX_TYPE_UINT8</tt> and <tt>\ref VX_TYPE_INT8</tt>, with fixed_point_position 0.
  793. * \param [in] input2 Input tensor data. The dimensions and sizes of input2 match those of input1, unless the vx_tensor of one or more dimensions in input2 is 1.
  794. * In this case, those dimensions are treated as if this tensor was expanded to match the size of the corresponding dimension of input1,
  795. * and data was duplicated on all terms in that dimension. After this expansion, the dimensions will be equal.
  796. * The data type must match the data type of Input1.
  797. * \param [in] policy A <tt>\ref vx_convert_policy_e</tt> enumeration.
  798. * \param [out] output The output tensor data with the same dimensions as the input tensor data.
  799. * \ingroup group_vision_function_tensor_subtract
  800. * \return A <tt>\ref vx_status_e</tt> enumeration.
  801. * \retval VX_SUCCESS Success
  802. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  803. */
  804. VX_API_ENTRY vx_status VX_API_CALL vxuTensorSubtract(vx_context context, vx_tensor input1, vx_tensor input2, vx_enum policy, vx_tensor output);
  805. /*! \brief [Immediate] Performs LUT on element values in the input tensor data.
  806. * \param [in] context The reference to the overall context.
  807. * \param [in] input1 Input tensor data. Implementations must support input tensor data type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_position 8,
  808. * and tensor data types <tt>\ref VX_TYPE_UINT8</tt>, with fixed_point_position 0.
  809. * \param [in] lut The look-up table to use, of type <tt>\ref vx_lut</tt>.
  810. * The elements of input1 are treated as unsigned integers to determine an index into the look-up table.
  811. * The data type of the items in the look-up table must match that of the output tensor.
  812. * \param [out] output The output tensor data with the same dimensions as the input tensor data.
  813. * \ingroup group_vision_function_tensor_tablelookup
  814. * \return A <tt>\ref vx_status_e</tt> enumeration.
  815. * \retval VX_SUCCESS Success
  816. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  817. */
  818. VX_API_ENTRY vx_status VX_API_CALL vxuTensorTableLookup(vx_context context, vx_tensor input1, vx_lut lut, vx_tensor output);
  819. /*! \brief [Immediate] Performs transpose on the input tensor.
  820. * The tensor is transposed according to a specified 2 indexes in the tensor (0-based indexing)
  821. * \param [in] context The reference to the overall context.
  822. * \param [in] input Input tensor data, Implementations must support input tensor data type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_position 8,
  823. * and tensor data types <tt>\ref VX_TYPE_UINT8</tt> and <tt>\ref VX_TYPE_INT8</tt>, with fixed_point_position 0.
  824. * \param [out] output output tensor data,
  825. * \param [in] dimension1 Dimension index that is transposed with dim 2.
  826. * \param [in] dimension2 Dimension index that is transposed with dim 1.
  827. * \ingroup group_vision_function_tensor_transpose
  828. * \return A <tt>\ref vx_status_e</tt> enumeration.
  829. * \retval VX_SUCCESS Success
  830. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  831. */
  832. VX_API_ENTRY vx_status VX_API_CALL vxuTensorTranspose(vx_context context, vx_tensor input, vx_tensor output, vx_size dimension1, vx_size dimension2);
  833. /*! \brief [Immediate] Performs a bit-depth conversion.
  834. * \param [in] context The reference to the overall context.
  835. * \param [in] input The input tensor. Implementations must support input tensor data type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_position 8,
  836. * and tensor data types <tt>\ref VX_TYPE_UINT8</tt> and <tt>\ref VX_TYPE_INT8</tt>, with fixed_point_position 0.
  837. * \param [in] policy A <tt>\ref VX_TYPE_ENUM</tt> of the <tt>\ref vx_convert_policy_e</tt> enumeration.
  838. * \param [in] norm A scalar containing a <tt>\ref VX_TYPE_FLOAT32</tt> of the normalization value.
  839. * \param [in] offset A scalar containing a <tt>\ref VX_TYPE_FLOAT32</tt> of the offset value subtracted before normalization.
  840. * \param [out] output The output tensor. Implementations must support input tensor data type <tt>VX_TYPE_INT16</tt>. with fixed_point_position 8.
  841. * And <tt>VX_TYPE_UINT8</tt> with fixed_point_position 0.
  842. * \ingroup group_vision_function_tensor_convert_depth
  843. * \return A <tt>\ref vx_status_e</tt> enumeration.
  844. * \retval VX_SUCCESS Success
  845. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  846. */
  847. VX_API_ENTRY vx_status VX_API_CALL vxuTensorConvertDepth(vx_context context, vx_tensor input, vx_enum policy, vx_scalar norm, vx_scalar offset, vx_tensor output);
  848. /*! \brief [Immediate] Performs a generalized matrix multiplication.
  849. * \param [in] context The reference to the overall context.
  850. * \param [in] input1 The first input 2D tensor of type <tt>\ref VX_TYPE_INT16</tt> with fixed_point_pos 8, or tensor data types <tt>\ref VX_TYPE_UINT8</tt> or <tt>\ref VX_TYPE_INT8</tt>, with fixed_point_pos 0.
  851. * \param [in] input2 The second 2D tensor. Must be in the same data type as input1.
  852. * \param [in] input3 The third 2D tensor. Must be in the same data type as input1. [optional].
  853. * \param [in] matrix_multiply_params Matrix multiply parameters, see <tt>\ref vx_tensor_matrix_multiply_params_t </tt>.
  854. * \param [out] output The output 2D tensor. Must be in the same data type as input1. Output dimension must agree the formula in the description.
  855. * \ingroup group_vision_function_tensor_matrix_multiply
  856. * \return A <tt>\ref vx_status_e</tt> enumeration.
  857. * \retval VX_SUCCESS Success
  858. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  859. */
  860. VX_API_ENTRY vx_status VX_API_CALL vxuTensorMatrixMultiply(vx_context context, vx_tensor input1, vx_tensor input2, vx_tensor input3,
  861. const vx_tensor_matrix_multiply_params_t *matrix_multiply_params, vx_tensor output);
  862. /*! \brief [Immediate] Copy data from one object to another.
  863. * \param [in] context The reference to the overall context.
  864. * \param [in] input The input data object.
  865. * \param [out] output The output data object.
  866. * \return A <tt>\ref vx_status_e</tt> enumeration.
  867. * \retval VX_SUCCESS Success
  868. * \retval * An error occurred. See <tt>\ref vx_status_e</tt>.
  869. * \ingroup group_vision_function_copy
  870. */
  871. VX_API_ENTRY vx_status VX_API_CALL vxuCopy(vx_context context, vx_reference input, vx_reference output);
  872. #ifdef __cplusplus
  873. }
  874. #endif
  875. #endif