pitch

Android Pitch and Roll Issue

♀尐吖头ヾ 提交于 2019-11-30 16:06:13
问题 I am working on a tilt app for Android. I am having an issue with Portrait & landscape mode. When the pitch = 90 degrees (phone on end) and even slightly before the roll value goes crazy when there has been no physical change in roll. I have not been able to find a solution to this problem. If anyone can point me in the right direction, it would be appreciated. Here’s a short code dump, so you know it is not an accelerometer error. final SensorEventListener mEventListener = new

Android Pitch and Roll Issue

被刻印的时光 ゝ 提交于 2019-11-30 15:45:09
I am working on a tilt app for Android. I am having an issue with Portrait & landscape mode. When the pitch = 90 degrees (phone on end) and even slightly before the roll value goes crazy when there has been no physical change in roll. I have not been able to find a solution to this problem. If anyone can point me in the right direction, it would be appreciated. Here’s a short code dump, so you know it is not an accelerometer error. final SensorEventListener mEventListener = new SensorEventListener(){ public void onAccuracyChanged(Sensor sensor, int accuracy) {} public void onSensorChanged

WAV File Synthesis From Scratch - C

对着背影说爱祢 提交于 2019-11-30 09:16:39
Recently I saw a video lecture in my CS 101 class that inspired me to start playing with the WAV File Format in C. My project today has been creating sounds using a simple mathematical sine function. Despite a couple obstacles, my program can now accept several inputs(frequencies of waves, amplitudes of waves, sampling rate, etc.) and create a wav file containing the specified pitches. However, when playing these tones on my computer speakers, there is a strange, rhythmic popping sound, which varies with the sampling rate. At higher sampling rates, the frequency of the popping sound increases

C/C++/Obj-C Real-time algorithm to ascertain Note (not Pitch) from Vocal Input

浪尽此生 提交于 2019-11-30 06:17:38
问题 I want to detect not the pitch, but the pitch class of a sung note. So, whether it is C4 or C5 is not important: they must both be detected as C. Imagine the 12 semitones arranged on a clock face, with the needle pointing to the pitch class. That's what I'm after! ideally I would like to be able to tell whether the sung note is spot-on or slightly off. This is not a duplicate of previously asked questions, as it introduces the constraints that: the sound source is a single human voice ,

FFT Pitch Detection - Melody Extraction [closed]

房东的猫 提交于 2019-11-30 02:31:14
I am creating a pitch detection program that extracts the fundamental frequency from the power spectrum obtained from the FFT of a frame. This is what I have so far: divide input audio signal into frames. multiply frame with a Hamming window compute the FFT and magnitude of the frame sqrt(real^2 + img^2) find the fundamental frequency (peak) by harmonic product spectrum convert the frequency of the peak (bin frequency) to note (e. g. ~440 Hz is A4) Now the program produces an integer with value from 0 to 87 for each frame. Each integer corresponds to a piano note according to a formula I found

How to detect sound frequency / pitch on an iPhone? [closed]

眉间皱痕 提交于 2019-11-29 19:02:46
问题 I'm trying to find a way to detect sound frequency being recorded by iPhone's Microphone. I'd like to detect whether the sound frequency is going up or down. 回答1: you can try to use SCListener. It's a small open-source class and very easy to use EDIT: The formatter does not like the _ in the name. Here is the link. http://github.com/stephencelis/sc_listener 回答2: To detect frequency you should check out the fast Fourier transform (FFT) algorithm. 回答3: Note that the SC_listener does not work on

Algorithm to determine fundamental frequency from potential harmonics

自古美人都是妖i 提交于 2019-11-29 03:21:42
I am attempting to extract a fundamental frequency from a sound source. maybe someone is singing A3 into the microphone, so I want to be detecting ~ 110Hz my approach is: FFT 1024 floats use the phase of each bin to accurately determine its precise frequency determine peaks (typically 50 or so) order them with the loudest first (Peak[0].power=1063.343750, .freq=2032.715088 (Peak[1].power=1047.764893, .freq=3070.605225 (Peak[2].power=1014.986877, .freq=5925.878418 (Peak[3].power=1011.707825, .freq=6963.769043 (Peak[4].power=1009.152954, .freq=4022.363037 (Peak[5].power=995.199585, .freq=4974

How to set pitch of an audio file or recorded audio file in iphone sdk?

白昼怎懂夜的黑 提交于 2019-11-29 00:43:25
I am recoding a file or I have audio file I want to change the pitch and play the audio file. How can I set the pitch in a iphone program that is using objective-c. Please help me out of this. Thank you, Madan Mohan. The naive approach is to play it using a different sampling rate as compared to the sampling rate used to record the file. For example, if the file was recorded with Fs=44100Hz, then playing it with Fs=22050Hz, will give you half the original pitch. Of course this naive approach involves changing the duration of the file, and other sound-related artifacts. If you need something

FFT Pitch Detection - Melody Extraction [closed]

梦想与她 提交于 2019-11-28 23:26:59
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 11 months ago . I am creating a pitch detection program that extracts the fundamental frequency from the power spectrum obtained from the FFT of a frame. This is what I have so far: divide input audio signal into frames. multiply frame with a Hamming window compute the FFT and magnitude of the

C/C++/Obj-C Real-time algorithm to ascertain Note (not Pitch) from Vocal Input

点点圈 提交于 2019-11-28 16:55:28
I want to detect not the pitch, but the pitch class of a sung note. So, whether it is C4 or C5 is not important: they must both be detected as C. Imagine the 12 semitones arranged on a clock face, with the needle pointing to the pitch class. That's what I'm after! ideally I would like to be able to tell whether the sung note is spot-on or slightly off. This is not a duplicate of previously asked questions, as it introduces the constraints that: the sound source is a single human voice , hopefully with negligible background interference (although I may need to deal with this) the octave is not