private void standardize() {
		if (frameRate == STANDARD_FRAME_RATE) return;
		double sf = STANDARD_FRAME_RATE / frameRate;
		int newFrameCount = (int) (frameCount * sf);
		byte[] newData = new byte[nChannels * newFrameCount * BYTES_PER_SAMPLE];
		int ix = 0;
		for (int i = 0; i < newFrameCount; i++) {
			// Add averaging at some point in the future
			for (int channel = 0; channel < nChannels; channel++) {
				int sx = (int) (i / sf) * BYTES_PER_SAMPLE * nChannels + BYTES_PER_SAMPLE * channel;
				int sample = (data[sx] << 8) | (data[sx + 1] & 0xFF);
				newData[ix++] = (byte) (sample >> 8);
				newData[ix++] = (byte) (sample & 0xFF);
			}
		}
		data = newData;
		frameCount = newFrameCount;
		format = new AudioFormat(frameRate, 16, nChannels, true, true);
	}