Jump to content
Xtreme .Net Talk

Recommended Posts

Posted (edited)

#include "FFT.h"

 

#define TWO_PI 6.283185

 

void CopyAudioData(PBYTE pbAudioBuffer, PFLOAT pfRealBuffer,PFLOAT pfImagBuffer, int iNumBytes)

{

int i,n;

short sAudioSample;

for (i=0,n=0; i< iNumBytes; i+=2,n++)

{

// we need to align the data, because it has the wrong byte order

sAudioSample = ((pbAudioBuffer[i+1] << 8) & 0xFF00)|

(pbAudioBuffer & 0x00FF);

pfImagBuffer[n] = 0;

pfRealBuffer[n] = sAudioSample; // this is the correct 16bit SampleValue

}

}

 

what would this look like converted?Using framework 2.0

At least get me pointed in the right direction :rolleyes:

 

Example...,what the void,,,does that stand for sub?

what are the variables PBYTE,PFLOAT, in vb.net?=Byte and Single?

Edited by cheewacheewa

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...