3 * Copyright 2003,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_fir_util.py.
27 * Any changes made to this file will be overwritten.
30 #ifndef INCLUDED_GR_FIR_UTIL_H
31 #define INCLUDED_GR_FIR_UTIL_H
34 * \brief routines to create gr_fir_XXX's
36 * This class handles selecting the fastest version of the finite
37 * implulse response filter available for your platform. This
38 * interface should be used by the rest of the system for creating
41 * The trailing suffix has the form _IOT where I codes the input type,
42 * O codes the output type, and T codes the tap type.
43 * I,O,T are elements of the set 's' (short), 'f' (float), 'c' (gr_complex),
56 // structures returned by get_gr_fir_XXX_info methods
59 struct gr_fir_ccf_info {
60 const char *name; // implementation name, e.g., "generic", "SSE", "3DNow!"
61 gr_fir_ccf *(*create)(const std::vector<float> &taps);
64 struct gr_fir_fcc_info {
65 const char *name; // implementation name, e.g., "generic", "SSE", "3DNow!"
66 gr_fir_fcc *(*create)(const std::vector<gr_complex> &taps);
69 struct gr_fir_ccc_info {
70 const char *name; // implementation name, e.g., "generic", "SSE", "3DNow!"
71 gr_fir_ccc *(*create)(const std::vector<gr_complex> &taps);
74 struct gr_fir_fff_info {
75 const char *name; // implementation name, e.g., "generic", "SSE", "3DNow!"
76 gr_fir_fff *(*create)(const std::vector<float> &taps);
79 struct gr_fir_scc_info {
80 const char *name; // implementation name, e.g., "generic", "SSE", "3DNow!"
81 gr_fir_scc *(*create)(const std::vector<gr_complex> &taps);
84 struct gr_fir_fsf_info {
85 const char *name; // implementation name, e.g., "generic", "SSE", "3DNow!"
86 gr_fir_fsf *(*create)(const std::vector<float> &taps);
91 // create a fast version of gr_fir_XXX.
93 static gr_fir_ccf *create_gr_fir_ccf (const std::vector<float> &taps);
94 static gr_fir_fcc *create_gr_fir_fcc (const std::vector<gr_complex> &taps);
95 static gr_fir_ccc *create_gr_fir_ccc (const std::vector<gr_complex> &taps);
96 static gr_fir_fff *create_gr_fir_fff (const std::vector<float> &taps);
97 static gr_fir_scc *create_gr_fir_scc (const std::vector<gr_complex> &taps);
98 static gr_fir_fsf *create_gr_fir_fsf (const std::vector<float> &taps);
100 // Get information about all gr_fir_XXX implementations.
101 // This is useful for benchmarking, testing, etc without having to
102 // know a priori what's linked into this image
104 // The caller must pass in a valid pointer to a vector.
105 // The vector will be filled with structs describing the
106 // available implementations.
108 static void get_gr_fir_ccf_info (std::vector<gr_fir_ccf_info> *info);
109 static void get_gr_fir_fcc_info (std::vector<gr_fir_fcc_info> *info);
110 static void get_gr_fir_ccc_info (std::vector<gr_fir_ccc_info> *info);
111 static void get_gr_fir_fff_info (std::vector<gr_fir_fff_info> *info);
112 static void get_gr_fir_scc_info (std::vector<gr_fir_scc_info> *info);
113 static void get_gr_fir_fsf_info (std::vector<gr_fir_fsf_info> *info);
117 #endif /* INCLUDED_GR_FIR_UTIL_H */