diff options
author | Tom Rondeau <trondeau@vt.edu> | 2013-02-26 12:21:02 -0500 |
---|---|---|
committer | Tom Rondeau <trondeau@vt.edu> | 2013-02-26 12:21:02 -0500 |
commit | d0d1348a08db382e1497e4a929f2ec22b35b8f0a (patch) | |
tree | 0f6f529cfd42446b20f68b6a6dd940ddb897563c /gr-analog/lib | |
parent | 38d82bad2cfbcbb9575af54bf29e96476dee4117 (diff) | |
parent | d8e73d63c0af6ba6810319d866cab07b332d0e42 (diff) |
Merge branch 'master' into next
Diffstat (limited to 'gr-analog/lib')
-rw-r--r-- | gr-analog/lib/noise_source_X_impl.cc.t | 16 | ||||
-rw-r--r-- | gr-analog/lib/noise_source_X_impl.h.t | 4 |
2 files changed, 18 insertions, 2 deletions
diff --git a/gr-analog/lib/noise_source_X_impl.cc.t b/gr-analog/lib/noise_source_X_impl.cc.t index 35dda9c5d4..40e2517d2e 100644 --- a/gr-analog/lib/noise_source_X_impl.cc.t +++ b/gr-analog/lib/noise_source_X_impl.cc.t @@ -54,11 +54,27 @@ namespace gr { { } + void + @IMPL_NAME@::set_type(noise_type_t type) + { + gruel::scoped_lock l(d_setlock); + d_type = type; + } + + void + @IMPL_NAME@::set_amplitude(float ampl) + { + gruel::scoped_lock l(d_setlock); + d_ampl = ampl; + } + int @IMPL_NAME@::work(int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items) { + gruel::scoped_lock l(d_setlock); + @TYPE@ *out = (@TYPE@*)output_items[0]; switch(d_type) { diff --git a/gr-analog/lib/noise_source_X_impl.h.t b/gr-analog/lib/noise_source_X_impl.h.t index 8bcc1dfde3..3a0e8d6d7c 100644 --- a/gr-analog/lib/noise_source_X_impl.h.t +++ b/gr-analog/lib/noise_source_X_impl.h.t @@ -41,8 +41,8 @@ namespace gr { @IMPL_NAME@(noise_type_t type, float ampl, long seed = 0); ~@IMPL_NAME@(); - void set_type(noise_type_t type) { d_type = type; } - void set_amplitude(float ampl) { d_ampl = ampl; } + void set_type(noise_type_t type); + void set_amplitude(float ampl); noise_type_t type() const { return d_type; } float amplitude() const { return d_ampl; } |