Developer Reference

  • 2021
  • 06/28/2021
  • Public Content
Contents

AddProduct

Adds product of two vectors to the accumulator vector.

Syntax

IppStatus ippsAddProduct_32f(const Ipp32f*
pSrc1
, const Ipp32f*
pSrc2
, Ipp32f*
pSrcDst
, int
len
);
IppStatus ippsAddProduct_64f(const Ipp64f*
pSrc1
, const Ipp64f*
pSrc2
, Ipp64f*
pSrcDst
, int
len
);
IppStatus ippsAddProduct_32fc(const Ipp32fc*
pSrc1
, const Ipp32fc*
pSrc2
, Ipp32fc*
pSrcDst
, int
len
);
IppStatus ippsAddProduct_64fc(const Ipp64fc*
pSrc1
, const Ipp64fc*
pSrc2
, Ipp64fc*
pSrcDst
, int
len
);
IppStatus ippsAddProduct_16s_Sfs(const Ipp16s*
pSrc1
, const Ipp16s*
pSrc2
, Ipp16s*
pSrcDst
, int
len
, int
scaleFactor
);
IppStatus ippsAddProduct_32s_Sfs(const Ipp32s*
pSrc1
, const Ipp32s*
pSrc2
, Ipp32s*
pSrcDst
, int
len
, int
scaleFactor
);
IppStatus ippsAddProduct_16s32s_Sfs(const Ipp16s*
pSrc1
, const Ipp16s*
pSrc2
, Ipp32s*
pSrcDst
, int
len
, int
scaleFactor
);
Include Files
ipps.h
Domain Dependencies
Headers:
ippcore.h
,
ippvm.h
Libraries:
ippcore.lib
,
ippvm.lib
Parameters
pSrc1
,
pSrc2
Pointers to the source vectors.
pSrcDst
Pointer to the destination accumulator vector.
len
The number of elements in the vectors.
scaleFactor
Scale factor, refer to Integer Scaling.
Description
This function multiplies each element of the source vector
pSrc1
by the corresponding element of the vector
pSrc2
, and adds the result to the corresponding element of the accumulator vector
pSrcDst
as given by:
pSrcDst
[n ] =
pSrcDst
[n ] +
pSrc1
[n ] *
pSrc2
[n ]
,
0
n <
len
.
Functions with
Sfs
suffixes perform scaling of the result value in accordance with the
scaleFactor
value. If the output value exceeds the data range, the result becomes saturated.
Return Values
ippStsNoErr
Indicates no error.
ippStsNullPtrErr
Indicates an error when any of the specified pointers is
NULL
.
ippStsSizeErr
Indicates an error when
len
is less than or equal to 0.

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.