/// <summary> /// Makes sure echo gets canceled from the frame. /// </summary> /// <param name="data"></param> /// <param name="samples">the amount of samples per frame</param> /// <returns></returns> public bool PassAudioOutput(short[] data, int samples) { if (_disposed) { throw new ObjectDisposedException(GetType().FullName); } return(FilterAudioFunctions.PassAudioOutput(_filterAudio, data, (uint)samples) == 0); }
/// <summary> /// Initialises a new instance of filter_audio. /// </summary> /// <param name="sampleRate"></param> public FilterAudio(int sampleRate) { _sampleRate = sampleRate; _filterAudio = FilterAudioFunctions.NewFilterAudio((uint)sampleRate); }
protected override bool ReleaseHandle() { FilterAudioFunctions.KillFilterAudio(handle); return(true); }