3 * Copyright 2002,2004 Free Software Foundation, Inc.
5 * This file is part of GNU Radio
7 * GNU Radio is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 3, or (at your option)
12 * GNU Radio is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with GNU Radio; see the file COPYING. If not, write to
19 * the Free Software Foundation, Inc., 51 Franklin Street,
20 * Boston, MA 02110-1301, USA.
24 * WARNING: This file is automatically generated by
25 * generate_gr_freq_xlating_fir_filter_XXX.py Any changes made to this file
26 * will be overwritten.
29 #ifndef INCLUDED_GR_FREQ_XLATING_FIR_FILTER_FCC_H
30 #define INCLUDED_GR_FREQ_XLATING_FIR_FILTER_FCC_H
32 #include <gr_sync_decimator.h>
33 #include <gr_rotator.h>
35 class gr_freq_xlating_fir_filter_fcc;
36 typedef boost::shared_ptr<gr_freq_xlating_fir_filter_fcc> gr_freq_xlating_fir_filter_fcc_sptr;
39 * Construct a FIR filter with the given taps and a composite frequency
40 * translation that shifts center_freq down to zero Hz. The frequency
41 * translation logically comes before the filtering operation.
43 gr_freq_xlating_fir_filter_fcc_sptr
44 gr_make_freq_xlating_fir_filter_fcc (int decimation, const std::vector<gr_complex> &taps,
45 double center_freq, double sampling_freq);
51 * \brief FIR filter combined with frequency translation with float input, gr_complex output and gr_complex taps
54 * This class efficiently combines a frequency translation
55 * (typically "down conversion") with a FIR filter (typically low-pass)
56 * and decimation. It is ideally suited for a "channel selection filter"
57 * and can be efficiently used to select and decimate a narrow band signal
58 * out of wide bandwidth input.
60 * Uses a single input array to produce a single output array.
61 * Additional inputs and/or outputs are ignored.
63 class gr_freq_xlating_fir_filter_fcc : public gr_sync_decimator
66 virtual ~gr_freq_xlating_fir_filter_fcc ();
68 void set_center_freq (double center_freq);
69 void set_taps (const std::vector<gr_complex> &taps);
71 int work (int noutput_items,
72 gr_vector_const_void_star &input_items,
73 gr_vector_void_star &output_items);
76 friend gr_freq_xlating_fir_filter_fcc_sptr
77 gr_make_freq_xlating_fir_filter_fcc (int decimation, const std::vector<gr_complex> &taps,
78 double center_freq, double sampling_freq);
81 std::vector<gr_complex> d_proto_taps;
82 gr_fir_fcc *d_composite_fir;
85 double d_sampling_freq;
88 virtual void build_composite_fir ();
91 * Construct a FIR filter with the given taps and a composite frequency
92 * translation that shifts center_freq down to zero Hz. The frequency
93 * translation logically comes before the filtering operation.
95 gr_freq_xlating_fir_filter_fcc (int decimation,
96 const std::vector<gr_complex> &taps,
97 double center_freq, double sampling_freq);
100 #endif /* _gr_freq_xlating_fir_filter_fcc_H_ */