< Table Of Contents

RandUniformInitAlloc

Allocates memory and initializes a noise generator with uniform distribution.

Syntax

IppStatus ippsRandUniformInitAlloc_8u(IppsRandUniState_8u** pRandUniState, Ipp8u low, Ipp8u high, unsigned int seed);

IppStatus ippsRandUniformInitAlloc_16s(IppsRandUniState_16s** pRandUniState, Ipp16s low, Ipp16s high, unsigned int seed);

IppStatus ippsRandUniformInitAlloc_32f(IppsRandUniState_32f** pRandUniState, Ipp32f low, Ipp32f high, unsigned int seed);

Parameters

pRandUniState

Pointer to the structure containing parameters for the generator of noise.

low

Lower bound of the uniform distribution range.

high

Upper bound of the uniform distribution range.

seed

Seed value used by the pseudo-random number generation algorithm.

Description

The function ippsRandUniformInitAlloc is declared in the ipps.h file. This function allocates memory and initializes the pseudo-random generator state pRandUniState. The uniform distribution range is specified by the lower and upper bounds low and high, respectively.

Code example demonstrates how to use the function ippsRandUniformInitAlloc.

Return Values

ippStsNoErr

Indicates no error.

ippStsNullPtrErr

Indicates an error when the pRandUniState pointer is NULL.

ippStsMemAllocErr

Indicates an error when there is not enough memory for the operation.

Submit feedback on this help topic

Copyright © 2000 - 2011, Intel Corporation. All rights reserved.