简体   繁体   English

如何检测已录制声音样本的音高

[英]how to detect the pitch of recorded sound sample

I'd like to analyze a piece of a recorded sound sample and find it's properties like pitch and so. 我想分析一段记录的声音样本,并找到其音调等属性。 I have tried to analyze the recorded bytes of the buffer with no success. 我试图分析缓冲区的记录字节,但没有成功。 How it can be done? 怎么做?

Use fast Fourier transform.. Libraries available for most languages. 使用快速傅里叶变换。.适用于大多数语言的库。 Bytes are no good, can be mp3 encoded or wav/pcm.. You need to decide then analyze. 字节不好,可以mp3编码或wav / pcm ..您需要决定然后分析。

DG 危险品

You will have to look into FFM . 您将不得不研究FFM

Then do something like this pseudocode indicates : 然后执行类似此伪代码的指示:

Complex in[1024];
Complex out[1024];
Copy your signal into in
FFT(in, out)
for every member of out compute sqrt(a^2+b^2)
To find frequency with highest power scan for the maximum value in the first 512 points in out

Check also out the original post of the buddy here because it is probably a duplicate. 还可以在此处查看好友的原始帖子,因为它可能是重复的。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM