MusicKit  0.0.0
vDSP.h
00001 /*
00002   $Id$
00003 
00004   Description: 
00005     Replacement DSP functions emulating the behaviour of Apple's vDSP library on Intel
00006     SSE2 architecture. Should be compiled with -msse2.
00007 
00008   Original Author: Leigh M. Smith
00009 
00010   Copyright (c) 2010 The MusicKit Project. All Rights Reserved.
00011 */
00012 
00013 #ifndef _VDSP_H_
00014 #define _VDSP_H_
00015 
00016 #ifdef __cplusplus
00017 extern "C" {
00018 #endif 
00019 
00027 void vDSP_vadd(const float input1[], unsigned int stride1,
00028                       const float input2[], unsigned int stride2,
00029                       float result[], unsigned int strideResult,
00030                       unsigned int size);
00031 
00039 void vDSP_vsub(const float input1[], unsigned int stride1,
00040                       const float input2[], unsigned int stride2,
00041                       float result[], unsigned int strideResult,
00042                       unsigned int size);
00043 
00051 void vDSP_vdiv(const float input1[], unsigned int input1Stride, 
00052                       const float input2[], unsigned int input2Stride,
00053                       float result[], unsigned int resultStride,
00054                       unsigned int size);
00055 
00065 void vDSP_vrsum(const float *input, unsigned int inputStride,
00066                 const float *scalingValue,
00067                 float *result, unsigned int resultStride,
00068                 unsigned int size);
00069 
00086 void vDSP_vramp(float *initialValue,
00087                 float *increment,
00088                 float *result,
00089                 unsigned int resultStride,
00090                 unsigned int vectorLength);
00091 
00100 void vDSP_vsadd(float *input,
00101                 unsigned int inputStride,
00102                 float *scalarOperand,
00103                 float *result,
00104                 unsigned int resultStride,
00105                 unsigned int vectorLength);
00106 
00111 void vDSP_dotpr(const float input1[],
00112                 unsigned int inputStride1,
00113                 const float input2[],
00114                 unsigned int inputStride2,
00115                 float *result,
00116                 unsigned int size);
00117 
00118 #ifdef __cplusplus
00119 }
00120 #endif
00121 
00122 #endif