Intel® Integrated Performance Primitives (Intel® IPP) Developer Guide and Reference

ID 790148
Date 3/22/2024
Public
Document Table of Contents

Min

Returns the minimum value of a vector.

Syntax

IppStatus ippsMin_16s(const Ipp16s* pSrc, int len, Ipp16s* pMin);

IppStatus ippsMin_32s(const Ipp32s* pSrc, int len, Ipp32s* pMin);

IppStatus ippsMin_32f(const Ipp32f* pSrc, int len, Ipp32f* pMin);

IppStatus ippsMin_64f(const Ipp64f* pSrc, int len, Ipp64f* pMin);

Include Files

ipps.h

Domain Dependencies

Headers: ippcore.h, ippvm.h

Libraries: ippcore.lib, ippvm.lib

Parameters

pSrc

Pointer to the source vector.

pMin

Pointer to the output result.

len

Number of elements in the vector.

Description

This function returns the minimum value of the input vector pSrc, and stores the result in pMin.

Return Values

ippStsNoErr

Indicates no error.

ippStsNullPtrErr

Indicates an error when the pMin or pSrc pointer is NULL.

ippStsSizeErr

Indicates an error when len is less than or equal to 0.

Example

The example below shows how to use the function ippsMin.

Ipp16s src = { 1, -2, 3, 8, -6}; 
Ipp16s min; 
int len = 5;
ippsMin_16s (src, len, &min );

Result:

 min = -6