public byte[] convolve(byte[] samples, double[] kernel)
	{
		int len = kernel.length;
		byte[] result = new byte[samples.length + len - 1];
		for(int n = 0; n < result.length; n++)
		{
			double sum = 0;
			for(int i = 0; i < len; i++)
			{
				if(i < samples.length + len - 1 - n && i >= len - n - 1)
				{
					sum += samples[i + n - len + 1] * kernel[len - i - 1];
				}
			}
			result[n] = (byte)sum;
		}
		return result;
	}