FFTPitch.java (1320B)
1 /* 2 * _______ _____ _____ _____ 3 * |__ __| | __ \ / ____| __ \ 4 * | | __ _ _ __ ___ ___ ___| | | | (___ | |__) | 5 * | |/ _` | '__/ __|/ _ \/ __| | | |\___ \| ___/ 6 * | | (_| | | \__ \ (_) \__ \ |__| |____) | | 7 * |_|\__,_|_| |___/\___/|___/_____/|_____/|_| 8 * 9 * ------------------------------------------------------------- 10 * 11 * TarsosDSP is developed by Joren Six at IPEM, University Ghent 12 * 13 * ------------------------------------------------------------- 14 * 15 * Info: http://0110.be/tag/TarsosDSP 16 * Github: https://github.com/JorenSix/TarsosDSP 17 * Releases: http://0110.be/releases/TarsosDSP/ 18 * 19 * TarsosDSP includes modified source code by various authors, 20 * for credits and info, see README. 21 * 22 */ 23 24 package be.tarsos.dsp.pitch; 25 26 27 /** 28 * Implements a pitch tracker by simply locating the most 29 * salient frequency component in a signal. 30 * 31 * @author Joren Six 32 */ 33 public class FFTPitch implements PitchDetector { 34 35 private final PitchDetectionResult result; 36 public FFTPitch(int sampleRate,int bufferSize){ 37 result = new PitchDetectionResult(); 38 } 39 40 @Override 41 public PitchDetectionResult getPitch(float[] audioBuffer) { 42 43 44 return result; 45 } 46 47 48 }