fix sinewave when input from audioprefrence dialog