1793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler/*M///////////////////////////////////////////////////////////////////////////////////////
2793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
3793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//  IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.
4793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
5793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//  By downloading, copying, installing or using the software you agree to this license.
6793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//  If you do not agree to this license, do not download, install,
7793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//  copy or use the software.
8793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
9793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
10793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//                          License Agreement
11793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//                For Open Source Computer Vision Library
12793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
13793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// Copyright (C) 2000-2008, Intel Corporation, all rights reserved.
14793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// Copyright (C) 2009, Willow Garage Inc., all rights reserved.
15793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// Copyright (C) 2013, OpenCV Foundation, all rights reserved.
16793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// Copyright (C) 2015, Itseez Inc., all rights reserved.
17793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// Third party copyrights are property of their respective owners.
18793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
19793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// Redistribution and use in source and binary forms, with or without modification,
20793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// are permitted provided that the following conditions are met:
21793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
22793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//   * Redistribution's of source code must retain the above copyright notice,
23793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//     this list of conditions and the following disclaimer.
24793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
25793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//   * Redistribution's in binary form must reproduce the above copyright notice,
26793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//     this list of conditions and the following disclaimer in the documentation
27793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//     and/or other materials provided with the distribution.
28793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
29793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//   * The name of the copyright holders may not be used to endorse or promote products
30793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//     derived from this software without specific prior written permission.
31793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
32793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// This software is provided by the copyright holders and contributors "as is" and
33793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// any express or implied warranties, including, but not limited to, the implied
34793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// warranties of merchantability and fitness for a particular purpose are disclaimed.
35793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// In no event shall the Intel Corporation or contributors be liable for any direct,
36793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// indirect, incidental, special, exemplary, or consequential damages
37793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// (including, but not limited to, procurement of substitute goods or services;
38793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// loss of use, data, or profits; or business interruption) however caused
39793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// and on any theory of liability, whether in contract, strict liability,
40793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// or tort (including negligence or otherwise) arising in any way out of
41793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler// the use of this software, even if advised of the possibility of such damage.
42793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//
43793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//M*/
44793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
45793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler#ifndef __OPENCV_HAL_HPP__
46793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler#define __OPENCV_HAL_HPP__
47793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
48793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler#include "opencv2/hal/defs.h"
49793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
50793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler/**
51793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler  @defgroup hal Hardware Acceleration Layer
52793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler*/
53793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
54793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslernamespace cv { namespace hal {
55793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
56793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslernamespace Error {
57793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
58793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerenum
59793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler{
60793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler    Ok = 0,
61793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler    Unknown = -1
62793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler};
63793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
64793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler}
65793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
66793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint normHamming(const uchar* a, int n);
67793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint normHamming(const uchar* a, const uchar* b, int n);
68793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
69793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint normHamming(const uchar* a, int n, int cellSize);
70793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint normHamming(const uchar* a, const uchar* b, int n, int cellSize);
71793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
72793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler//////////////////////////////// low-level functions ////////////////////////////////
73793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
74793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint LU(float* A, size_t astep, int m, float* b, size_t bstep, int n);
75793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint LU(double* A, size_t astep, int m, double* b, size_t bstep, int n);
76793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerbool Cholesky(float* A, size_t astep, int m, float* b, size_t bstep, int n);
77793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerbool Cholesky(double* A, size_t astep, int m, double* b, size_t bstep, int n);
78793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
79793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerint normL1_(const uchar* a, const uchar* b, int n);
80793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerfloat normL1_(const float* a, const float* b, int n);
81793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslerfloat normL2Sqr_(const float* a, const float* b, int n);
82793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
83793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid exp(const float* src, float* dst, int n);
84793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid exp(const double* src, double* dst, int n);
85793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid log(const float* src, float* dst, int n);
86793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid log(const double* src, double* dst, int n);
87793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
88793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid fastAtan2(const float* y, const float* x, float* dst, int n, bool angleInDegrees);
89793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid magnitude(const float* x, const float* y, float* dst, int n);
90793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid magnitude(const double* x, const double* y, double* dst, int n);
91793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid sqrt(const float* src, float* dst, int len);
92793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid sqrt(const double* src, double* dst, int len);
93793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid invSqrt(const float* src, float* dst, int len);
94793ee12c6df9cad3806238d32528c49a3ff9331dNoah Preslervoid invSqrt(const double* src, double* dst, int len);
95793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
96793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler}} //cv::hal
97793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler
98793ee12c6df9cad3806238d32528c49a3ff9331dNoah Presler#endif //__OPENCV_HAL_HPP__
99