⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ipps.hpp

📁 经典的嵌入式教程C和C++的内容中的源代码
💻 HPP
📖 第 1 页 / 共 5 页
字号:
*/


 inline IppStatus ippsTriangle_Direct( Ipp64f* pDst, int len, double magn, double
                             rFreq, double asym, double* pPhase) {
     return ippsTriangle_Direct_64f( pDst, len, magn, rFreq, asym, pPhase );
     }
 inline IppStatus ippsTriangle_Direct( Ipp64fc* pDst, int len, double magn, double
                             rFreq, double asym, double* pPhase) {
     return ippsTriangle_Direct_64fc( pDst, len, magn, rFreq, asym, pPhase );
     }
 inline IppStatus ippsTriangle_Direct( Ipp32f* pDst, int len, float magn, float rFreq,
                             float asym, float* pPhase) {
     return ippsTriangle_Direct_32f( pDst, len, magn, rFreq, asym, pPhase );
     }
 inline IppStatus ippsTriangle_Direct( Ipp32fc* pDst, int len, float magn, float rFreq,
                             float asym, float* pPhase) {
     return ippsTriangle_Direct_32fc( pDst, len, magn, rFreq, asym, pPhase );
     }
 inline IppStatus ippsTriangle_Direct( Ipp16s* pDst, int len, Ipp16s magn, float rFreq,
                             float asym, float* pPhase) {
     return ippsTriangle_Direct_16s( pDst, len, magn, rFreq, asym, pPhase );
     }
 inline IppStatus ippsTriangle_Direct( Ipp16sc* pDst, int len, Ipp16s magn, float
                             rFreq, float asym, float* pPhase) {
     return ippsTriangle_Direct_16sc( pDst, len, magn, rFreq, asym, pPhase );
     }

//-- #if !defined ( _OWN_BLDPCS )
/* IPP Context triangle identification */
//-- struct TriangleState_16s;
//-- typedef struct TriangleState_16s IppTriangleState_16s;
//-- #endif

/*
//  Name:                ippsTriangleInitAllocQ15_16s
//  Purpose:             Allocates memory for the structure IppTriangleState_16s,
//                       initializes it with a set of wave parameters (magnitude,
//                       frequency, phase, asymmetry).
//  Context:
//  Returns:             IppStatus
//    ippStsNoErr        Ok
//    ippStsNullPtrErr   Double pointer to pTriangleState is NULL
//    ippStsTriangleMagnErr  The magn value is less than or equal to zero
//    ippStsTriangleFreqErr  The freqQ15 value is less than 0 or greater than 16383
//    ippStsTriangleAsymErr  The phaseQ15 value is less tahn 0 or greater than 205886
//    ippStsTrianglePhaseErr The asymQ15 value is less than -102943 or greater than 102943
//  Parameters:
//    **pTriangleState   Double pointer to the structure IppTriangleState_16s.
//    magn               Magnitude of the Triangle; that is, the maximum value
//                       attained by the wave.
//    rFreqQ15           Frequency of the Triangle relative to the sampling
//                       frequency. It must be between 0 and 16383
//    phaseQ15           Phase of the Triangle relative to a wave. It must
//                       be between 0 and 205886.
//    asymQ15            Asymmetry of the Triangle relative to a wave. It must
//                       be between -102943 and 102943.
//  Notes:
*/
 inline IppStatus ippsTriangleInitAlloc( IppTriangleState_16s** pTriangleState, Ipp16s
                             magn, Ipp16s rFreqQ15, Ipp32s phaseQ15, Ipp32s asymQ15) {
     return ippsTriangleInitAllocQ15_16s( pTriangleState, magn, rFreqQ15, phaseQ15,
                             asymQ15 );
     }



/*
//  Name:                ippsTriangleFree_16s
//  Purpose:             Frees memory, which was allocated
//                       for the structure IppTriangleState_16s.
//  Context:
//  Returns:             IppStatus
//    ippStsNoErr        Ok
//    ippStsNullPtrErr   Pointer to pTriangleState is NULL
//  Parameters:
//    *pTriangleState    Pointer to the structure IppTriangleState_16s.
//  Notes:
*/
//-- IPPAPI(IppStatus, ippsTriangleFree, (IppTriangleState_16s* pTriangleState))



/*
//  Name:                ippsTriangleGetStateSizeQ15_16s
//  Purpose:             Computes the size, in bytes, of the structure IppTriangleState_16s
//  Context:
//  Returns:             IppStatus
//    ippStsNoErr        Ok
//    ippStsNullPtrErr   Pointer to pTriangleState size is NULL
//  Parameters:
//    *pTriangleStateSize Pointer to the computed value of the size
//                        of the structure IppTriangleState_16s.
//  Notes:
*/
 inline IppStatus ippsTriangleGetStateSize( int* pTriangleStateSize) {
     return ippsTriangleGetStateSizeQ15_16s( pTriangleStateSize );
     }

/*
//  Name:                ippsTriangleInitQ15_16s
//  Purpose:             Initializes the structure IppTriangleState_16s
//                       with a given set of cosinewave parameters (magnitude,
//                       frequency, phase)
//  Context:
//  Returns:               IppStatus
//    ippStsNoErr          Ok
//    ippStsNullPtrErr     The pointer to pTriangleState is NULL
//    ippStsTrngleMagnErr  The magn value is less than or equal to zero
//    ippStsTrngleFreqErr  The freqQ15 value is less than 0 or greater than 16383
//    ippStsTrnglePhaseErr The phaseQ15 value is less than 0 or greater than 205886
//    ippStsTrngleAsymErr  The asymQ15 value is less than -102943 or greater than 102943
//  Parameters:
//    *pTriangleState    Pointer to the structure IppTriangleState_16s.
//    magn               Magnitude of the Triangle; that is, the maximum value
//                       attained by the wave.
//    rFreqQ15           Frequency of the Triangle relative to the sampling
//                       frequency. It must be between 0 and 16383
//    phaseQ15           Phase of the Triangle relative to a wave. It must
//                       be between 0 and 205886.
//    asymQ15            Asymmetry of the Triangle relative to a wave. It must
//                       be between -102943 and 102943.

//  Notes:
*/
 inline IppStatus ippsTriangleInit( IppTriangleState_16s* pTriangleState, Ipp16s magn,
                             Ipp16s rFreqQ15, Ipp32s phaseQ15, Ipp32s asymQ15) {
     return ippsTriangleInitQ15_16s( pTriangleState, magn, rFreqQ15, phaseQ15, asymQ15
                             );
     }


/*
//  Name:                ippsTriangleQ15_16s
//  Purpose:             generates a Triangle
//  Context:
//  Returns:             IppStatus
//    ippStsNoErr        Ok
//  Parameters:
//    pDst               The pointer to destination vector.
//    len                The length of vector
//    *pTriangleState    Pointer to the structure IppTriangleState_16s.
//  Notes:
*/
 inline IppStatus ippsTriangle( Ipp16s* pDst, int len, IppTriangleState_16s*
                             pTriangleState) {
     return ippsTriangleQ15_16s( pDst, len, pTriangleState );
     }

/* /////////////////////////////////////////////////////////////////////////////
//  Name:           ippsToneQ15_Direct_16s
//  Purpose:        generates a tone
//  Context:
//  Returns:             IppStatus
//    ippStsNoErr        Ok
//    ippStsNullPtrErr   The pointer to the destination vector is NULL
//    ippStsSizeErr      The length of the vector is less than or equal to zero
//    ippStsToneMagnErr  The magn value is less than or equal to zero
//    ippStsToneFreqErr  The rFreqQ15 value is less than 0 or greater than 16383
//    ippStsTonePhaseErr The phaseQ15 value is less than 0 or greater than 205886

//  Parameters:
//    pDst          Pointer to the destination vector.
//    len           Length of the vector
//    magn          Magnitude of the tone; that is, the maximum value
//                  attained by the wave.It must be between 0 and 32767
//    rFreqQ15      Frequency of the tone relative to the sampling
//                  frequency. It must be between 0 and 16383
//    phaseQ15      Phase of the tone relative to a cosinewave. It must
//                  be between 0 and 205886.
*/
 inline IppStatus ippsTone_Direct( Ipp16s* pDst, int len, Ipp16s magn, Ipp16s rFreqQ15,
                             Ipp32s phaseQ15) {
     return ippsToneQ15_Direct_16s( pDst, len, magn, rFreqQ15, phaseQ15 );
     }


/* /////////////////////////////////////////////////////////////////////////////
//  Name:           ippsTriangleQ15_Direct_16s
//  Purpose:        generates a Triangle
//  Context:
//  Returns:                 IppStatus
//    ippStsNoErr            Ok
//    ippStsNullPtrErr       The pointer to the destination vectro is NULL
//    ippStsSizeErr          The length of the vector is less than or equal to zero
//    ippStsTriangleMagnErr  The magn value is less than or equal to zero
//    ippStsTriangleFreqErr  The rFfreqQ15 value is less than 0 or greater than 16383
//    ippStsTriangleAsymErr  The asymQ15 value is less than 0 or greater than 205886
//    ippStsTrianglePhaseErr The phaseQ15 value is less than -102943 or greater tahn 102943
//  Parameters:
//    pDst          Pointer to the destination vector.
//    len           Length of the vector
//    mag           Magnitude of the Triangle; that is, the maximum value
//                  attained by the wave. It must be between 0 and 32767.
//    rFreqQ15      Frequency of the Triangle relative to the sampling
//                  frequency. It must be between 0 and 16383
//    phaseQ15      The phase of the Triangle relative to a wave. It must
//                  be between 0 and 205886.
//    asymQ15       The asymmmetry of the Triangle relative to a wave. It must
//                  be between -102943 and 102943.
//  Notes:
*/
 inline IppStatus ippsTriangle_Direct( Ipp16s* pDst, int len, Ipp16s magn, Ipp16s
                             rFreqQ15, Ipp32s phaseQ15, Ipp32s asymQ15) {
     return ippsTriangleQ15_Direct_16s( pDst, len, magn, rFreqQ15, phaseQ15, asymQ15 );
     }



/* /////////////////////////////////////////////////////////////////////////
//  Name:               ippsVectorRamp_8u,  ippsVectorRamp_8s,
//                      ippsVectorRamp_16u, ippsVectorRamp_16s,
//                      ippsVectorRamp_32u, ippsVectorRamp_32s,
//                      ippsVectorRamp_32f, ippsVectorRamp_64f
//  Purpose:            Creates ramp vector
//
//  Parameters:
//    pDst              A pointer to the destination vector
//    len               Vector's length
//    offset            Offset value
//    slope             Slope coefficient
//
//  Return:
//    ippStsNoErr       No error
//    ippStsNullPtrErr  pDst pointer is NULL
//    ippStsBadSizeErr  Vector's length is less or equal zero
//    ippStsNoErr       No error
//
//  Notes:              Dst[n] = offset + slope * n
//
*/
 inline IppStatus ippsVectorRamp( Ipp8u* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_8u( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp8s* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_8s( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp16u* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_16u( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp16s* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_16s( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp32u* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_32u( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp32s* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_32s( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp32f* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_32f( pDst, len, offset, slope );
     }
 inline IppStatus ippsVectorRamp( Ipp64f* pDst, int len, float offset, float slope) {
     return ippsVectorRamp_64f( pDst, len, offset, slope );
     }



/* /////////////////////////////////////////////////////////////////////////////
//                   Convert functions
///////////////////////////////////////////////////////////////////////////// */
/* /////////////////////////////////////////////////////////////////////////////
//  Name:       ippsReal
//  Purpose:    form vector with real part of the input complex vector
//  Parameters:
//    pSrc       pointer to the input complex vector
//    pDstRe     pointer to the output vector to store the real part
//    len        length of the vectors, number of items
//  Return:
//    ippStsNullPtrErr       pointer(s) to the data is NULL
//    ippStsSizeErr          length of the vectors is less or equal zero
//    ippStsNoErr            otherwise
*/

 inline IppStatus ippsReal( const Ipp64fc* pSrc, Ipp64f* pDstRe, int len) {
     return ippsReal_64fc( pSrc, pDstRe, len );
     }
 inline IppStatus ippsReal( const Ipp32fc* pSrc, Ipp32f* pDstRe, int len) {
     return ippsReal_32fc( pSrc, pDstRe, len );
     }
 inline IppStatus ippsReal( const Ipp16sc* pSrc, Ipp16s* pDstRe, int len) {
     return ippsReal_16sc( pSrc, pDstRe, len );
     }

/* /////////////////////////////////////////////////////////////////////////////
//  Name:       ippsImag
//  Purpose:    form vector with imaginary part of the input complex vector
//  Parameters:
//    pSrc       pointer to the input complex vector
//    pDstRe     pointer to the output vector to store the real part
//    len        length of the vectors, number of items
//  Return:
//    ippStsNullPtrErr       pointer(s) to the data is NULL
//    ippStsSizeErr          length of the vectors is less or equal zero
//    ippStsNoErr            otherwise
*/

 inline IppStatus ippsImag( const Ipp64fc* pSrc, Ipp64f* pDstIm, int len) {
     return ippsImag_64fc( pSrc, pDstIm, len );
     }
 inline IppStatus ippsImag( const Ipp32fc* pSrc, Ipp32f* pDstIm, int len) {

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -