#pragma once #include #include #include struct gate { float threshold; bool enable_calibration; unsigned block_size; unsigned hist_idx; unsigned hist_size; float * hist; unsigned cur_block_count; float cur_block_sum; bool is_active; }; void gate_init(); void gate_process( struct gate * gate, size_t frame_size, float const * in, float * out );