diff options
author | Josh Morman <jmorman@perspectalabs.com> | 2020-12-16 14:44:46 -0500 |
---|---|---|
committer | Marcus Müller <marcus@hostalia.de> | 2020-12-18 22:36:14 +0100 |
commit | 96a15f6b0d52f116ee9546be63dce90c4b90238f (patch) | |
tree | 60d01e0773a9becbb189eea782095efe5b4fab73 /gr-filter/python | |
parent | af408c76d0e4993e71a91051ed09c923749c6383 (diff) |
filter: remove deprecated win_type duplicate in firdes
The win_type defined in firdes is marked as deprecated to be removed in
3.8, so let's go ahead and remove it and fix all the references
Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
Diffstat (limited to 'gr-filter/python')
-rw-r--r-- | gr-filter/python/filter/bindings/firdes_python.cc | 44 | ||||
-rw-r--r-- | gr-filter/python/filter/bindings/hilbert_fc_python.cc | 4 |
2 files changed, 16 insertions, 32 deletions
diff --git a/gr-filter/python/filter/bindings/firdes_python.cc b/gr-filter/python/filter/bindings/firdes_python.cc index 3e697a1213..fc7cf78866 100644 --- a/gr-filter/python/filter/bindings/firdes_python.cc +++ b/gr-filter/python/filter/bindings/firdes_python.cc @@ -14,7 +14,7 @@ /* BINDTOOL_GEN_AUTOMATIC(0) */ /* BINDTOOL_USE_PYGCCXML(0) */ /* BINDTOOL_HEADER_FILE(firdes.h) */ -/* BINDTOOL_HEADER_FILE_HASH(0b2837cc3e5dcdc4435575d7ce1950df) */ +/* BINDTOOL_HEADER_FILE_HASH(afeccb5d25e3c88b1dcfc23d3542ec0b) */ /***********************************************************************************/ #include <pybind11/complex.h> @@ -33,21 +33,6 @@ void bind_firdes(py::module& m) py::class_<firdes, std::shared_ptr<firdes>> firdes_class(m, "firdes", D(firdes)); - py::enum_<gr::filter::firdes::win_type>(firdes_class, "win_type") - .value("WIN_NONE", gr::filter::firdes::WIN_NONE) // -1 - .value("WIN_HAMMING", gr::filter::firdes::WIN_HAMMING) // 0 - .value("WIN_HANN", gr::filter::firdes::WIN_HANN) // 1 - .value("WIN_BLACKMAN", gr::filter::firdes::WIN_BLACKMAN) // 2 - .value("WIN_RECTANGULAR", gr::filter::firdes::WIN_RECTANGULAR) // 3 - .value("WIN_KAISER", gr::filter::firdes::WIN_KAISER) // 4 - .value("WIN_BLACKMAN_hARRIS", gr::filter::firdes::WIN_BLACKMAN_hARRIS) // 5 - .value("WIN_BLACKMAN_HARRIS", gr::filter::firdes::WIN_BLACKMAN_HARRIS) // 5 - .value("WIN_BARTLETT", gr::filter::firdes::WIN_BARTLETT) // 6 - .value("WIN_FLATTOP", gr::filter::firdes::WIN_FLATTOP) // 7 - .export_values(); - - py::implicitly_convertible<int, gr::filter::firdes::win_type>(); - firdes_class .def_static("window", &firdes::window, @@ -63,7 +48,7 @@ void bind_firdes(py::module& m) py::arg("sampling_freq"), py::arg("cutoff_freq"), py::arg("transition_width"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, low_pass)) @@ -75,7 +60,7 @@ void bind_firdes(py::module& m) py::arg("cutoff_freq"), py::arg("transition_width"), py::arg("attenuation_dB"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, low_pass_2)) @@ -86,7 +71,7 @@ void bind_firdes(py::module& m) py::arg("sampling_freq"), py::arg("cutoff_freq"), py::arg("transition_width"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, high_pass)) @@ -98,7 +83,7 @@ void bind_firdes(py::module& m) py::arg("cutoff_freq"), py::arg("transition_width"), py::arg("attenuation_dB"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, high_pass_2)) @@ -110,7 +95,7 @@ void bind_firdes(py::module& m) py::arg("low_cutoff_freq"), py::arg("high_cutoff_freq"), py::arg("transition_width"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, band_pass)) @@ -123,7 +108,7 @@ void bind_firdes(py::module& m) py::arg("high_cutoff_freq"), py::arg("transition_width"), py::arg("attenuation_dB"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, band_pass_2)) @@ -135,7 +120,7 @@ void bind_firdes(py::module& m) py::arg("low_cutoff_freq"), py::arg("high_cutoff_freq"), py::arg("transition_width"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, complex_band_pass)) @@ -148,7 +133,7 @@ void bind_firdes(py::module& m) py::arg("high_cutoff_freq"), py::arg("transition_width"), py::arg("attenuation_dB"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, complex_band_pass_2)) @@ -160,7 +145,7 @@ void bind_firdes(py::module& m) py::arg("low_cutoff_freq"), py::arg("high_cutoff_freq"), py::arg("transition_width"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, band_reject)) @@ -173,7 +158,7 @@ void bind_firdes(py::module& m) py::arg("high_cutoff_freq"), py::arg("transition_width"), py::arg("attenuation_dB"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, band_reject_2)) @@ -185,7 +170,7 @@ void bind_firdes(py::module& m) py::arg("low_cutoff_freq"), py::arg("high_cutoff_freq"), py::arg("transition_width"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, complex_band_reject)) @@ -198,7 +183,7 @@ void bind_firdes(py::module& m) py::arg("high_cutoff_freq"), py::arg("transition_width"), py::arg("attenuation_dB"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(firdes, complex_band_reject_2)) @@ -206,8 +191,7 @@ void bind_firdes(py::module& m) .def_static("hilbert", &firdes::hilbert, py::arg("ntaps") = 19, - py::arg("windowtype") = - ::gr::filter::firdes::win_type::WIN_RECTANGULAR, + py::arg("windowtype") = ::gr::fft::window::win_type::WIN_RECTANGULAR, py::arg("beta") = 6.7599999999999998, D(firdes, hilbert)) diff --git a/gr-filter/python/filter/bindings/hilbert_fc_python.cc b/gr-filter/python/filter/bindings/hilbert_fc_python.cc index 35cbe68753..ceb660471b 100644 --- a/gr-filter/python/filter/bindings/hilbert_fc_python.cc +++ b/gr-filter/python/filter/bindings/hilbert_fc_python.cc @@ -14,7 +14,7 @@ /* BINDTOOL_GEN_AUTOMATIC(0) */ /* BINDTOOL_USE_PYGCCXML(0) */ /* BINDTOOL_HEADER_FILE(hilbert_fc.h) */ -/* BINDTOOL_HEADER_FILE_HASH(e204e5877a924c21b62513d8e83e952d) */ +/* BINDTOOL_HEADER_FILE_HASH(3f5ee100c05bf0b167c39a017a65b9eb) */ /***********************************************************************************/ #include <pybind11/complex.h> @@ -40,7 +40,7 @@ void bind_hilbert_fc(py::module& m) .def(py::init(&hilbert_fc::make), py::arg("ntaps"), - py::arg("window") = ::gr::filter::firdes::win_type::WIN_HAMMING, + py::arg("window") = ::gr::fft::window::win_type::WIN_HAMMING, py::arg("beta") = 6.7599999999999998, D(hilbert_fc, make)); } |