summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Blossom <eb@comsec.com>2010-10-18 20:14:26 -0700
committerEric Blossom <eb@comsec.com>2010-11-10 12:10:45 -0800
commit3d55841ec05f1a09eb2de304f9ad30b9ed068986 (patch)
treec0887336267fdc743a5f9d1e8b613a5a8db25865
parent3e5e68383e0b1283ad1a40216ef11e777c245824 (diff)
Make fft window parameter a const vector ref to ease swigging.
-rw-r--r--gnuradio-core/src/lib/general/gr_fft_vcc.i4
-rw-r--r--gnuradio-core/src/lib/general/gr_fft_vfc.cc6
-rw-r--r--gnuradio-core/src/lib/general/gr_fft_vfc.h10
-rw-r--r--gnuradio-core/src/lib/general/gr_fft_vfc.i8
4 files changed, 14 insertions, 14 deletions
diff --git a/gnuradio-core/src/lib/general/gr_fft_vcc.i b/gnuradio-core/src/lib/general/gr_fft_vcc.i
index 2475713740..f35316e703 100644
--- a/gnuradio-core/src/lib/general/gr_fft_vcc.i
+++ b/gnuradio-core/src/lib/general/gr_fft_vcc.i
@@ -1,6 +1,6 @@
/* -*- c++ -*- */
/*
- * Copyright 2004,2007,2008 Free Software Foundation, Inc.
+ * Copyright 2004,2007,2008,2010 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
@@ -23,7 +23,7 @@
GR_SWIG_BLOCK_MAGIC(gr, fft_vcc)
gr_fft_vcc_sptr
-gr_make_fft_vcc (int fft_size, bool forward, const std::vector<float> window, bool shift=false);
+gr_make_fft_vcc (int fft_size, bool forward, const std::vector<float> &window, bool shift=false);
class gr_fft_vcc : public gr_sync_block
{
diff --git a/gnuradio-core/src/lib/general/gr_fft_vfc.cc b/gnuradio-core/src/lib/general/gr_fft_vfc.cc
index 608161efed..561c637407 100644
--- a/gnuradio-core/src/lib/general/gr_fft_vfc.cc
+++ b/gnuradio-core/src/lib/general/gr_fft_vfc.cc
@@ -40,12 +40,12 @@
gr_fft_vfc_sptr
-gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> window)
+gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> &window)
{
return gnuradio::get_initial_sptr(new gr_fft_vfc (fft_size, forward, window));
}
-gr_fft_vfc::gr_fft_vfc (int fft_size, bool forward, const std::vector<float> window)
+gr_fft_vfc::gr_fft_vfc (int fft_size, bool forward, const std::vector<float> &window)
: gr_sync_block ("fft_vfc",
gr_make_io_signature (1, 1, fft_size * sizeof (float)),
gr_make_io_signature (1, 1, fft_size * sizeof (gr_complex))),
@@ -107,7 +107,7 @@ gr_fft_vfc::work (int noutput_items,
}
bool
-gr_fft_vfc::set_window(const std::vector<float> window)
+gr_fft_vfc::set_window(const std::vector<float> &window)
{
if(window.size()==0 || window.size()==d_fft_size) {
d_window=window;
diff --git a/gnuradio-core/src/lib/general/gr_fft_vfc.h b/gnuradio-core/src/lib/general/gr_fft_vfc.h
index 054a383ef3..0745744770 100644
--- a/gnuradio-core/src/lib/general/gr_fft_vfc.h
+++ b/gnuradio-core/src/lib/general/gr_fft_vfc.h
@@ -1,6 +1,6 @@
/* -*- c++ -*- */
/*
- * Copyright 2004 Free Software Foundation, Inc.
+ * Copyright 2004,2010 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
@@ -31,7 +31,7 @@ class gr_fft_vfc;
typedef boost::shared_ptr<gr_fft_vfc> gr_fft_vfc_sptr;
gr_fft_vfc_sptr
-gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float>);
+gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> &window);
/*!
* \brief Compute forward FFT. float vector in / complex vector out.
@@ -41,13 +41,13 @@ gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float>);
class gr_fft_vfc : public gr_sync_block
{
friend gr_fft_vfc_sptr
- gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> window);
+ gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> &window);
unsigned int d_fft_size;
std::vector<float> d_window;
gri_fft_complex *d_fft;
- gr_fft_vfc (int fft_size, bool forward, const std::vector<float> window);
+ gr_fft_vfc (int fft_size, bool forward, const std::vector<float> &window);
public:
~gr_fft_vfc ();
@@ -55,7 +55,7 @@ class gr_fft_vfc : public gr_sync_block
int work (int noutput_items,
gr_vector_const_void_star &input_items,
gr_vector_void_star &output_items);
- bool set_window(const std::vector<float> window);
+ bool set_window(const std::vector<float> &window);
};
diff --git a/gnuradio-core/src/lib/general/gr_fft_vfc.i b/gnuradio-core/src/lib/general/gr_fft_vfc.i
index 90c368fe62..f680c40223 100644
--- a/gnuradio-core/src/lib/general/gr_fft_vfc.i
+++ b/gnuradio-core/src/lib/general/gr_fft_vfc.i
@@ -1,6 +1,6 @@
/* -*- c++ -*- */
/*
- * Copyright 2004 Free Software Foundation, Inc.
+ * Copyright 2004,2010 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
@@ -23,13 +23,13 @@
GR_SWIG_BLOCK_MAGIC(gr, fft_vfc)
gr_fft_vfc_sptr
-gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> window);
+gr_make_fft_vfc (int fft_size, bool forward, const std::vector<float> &window);
class gr_fft_vfc : public gr_sync_block
{
protected:
- gr_fft_vfc (int fft_size, bool forward, const std::vector<float> window);
+ gr_fft_vfc (int fft_size, bool forward, const std::vector<float> &window);
public:
- bool set_window(const std::vector<float> window);
+ bool set_window(const std::vector<float> &window);
};