[med-svn] [aghermann] 07/60: whitespace, comments

andrei zavada hmmr-guest at alioth.debian.org
Mon Nov 4 23:49:51 UTC 2013


This is an automated email from the git hooks/post-receive script.

hmmr-guest pushed a commit to branch WIP
in repository aghermann.

commit 0e4b35585c17ec8a67ae7c3a6cfc9576110bb20c
Author: Andrei Zavada <johnhommer at gmail.com>
Date:   Tue Oct 8 02:17:29 2013 +0300

    whitespace, comments
---
 upstream/src/aghermann/ui/sf/channel.cc |    7 ++-----
 upstream/src/aghermann/ui/sf/montage.cc |    4 ++--
 upstream/src/libsigfile/channel.hh      |   18 ++++++++++++------
 upstream/src/libsigfile/edf.cc          |   27 +++++++++++++--------------
 upstream/src/libsigproc/sigproc.hh      |    2 +-
 5 files changed, 30 insertions(+), 28 deletions(-)

diff --git a/upstream/src/aghermann/ui/sf/channel.cc b/upstream/src/aghermann/ui/sf/channel.cc
index 7fc8d2e..70b1007 100644
--- a/upstream/src/aghermann/ui/sf/channel.cc
+++ b/upstream/src/aghermann/ui/sf/channel.cc
@@ -106,9 +106,6 @@ SChannel (agh::CRecording& r,
         get_signal_original();
         get_signal_filtered();
 
-      // irrespective (grown out of EMG, eventually for universal use)
-        // get_raw_profile(); // too heavy; make it on-demand
-
       // psd power and spectrum, mc
         if ( schannel().is_fftable() ) {
               // power in a single bin
@@ -230,7 +227,7 @@ get_psd_in_bands()
                 for ( size_t i = 0; i < xi.size(); ++i )
                         xi[i] = i;
                 for ( size_t b = 0; b <= psd.uppermost_band; ++b ) {
-                        auto        _from = _p._p.ED->freq_bands[b][0],
+                        auto    _from = _p._p.ED->freq_bands[b][0],
                                 _upto = _p._p.ED->freq_bands[b][1];
                         auto tmp = crecording.psd_profile.course( _from, _upto);
                         psd.course_in_bands[b] =
@@ -241,7 +238,7 @@ get_psd_in_bands()
                 }
         } else
                 for ( size_t b = 0; b <= psd.uppermost_band; ++b ) {
-                        auto        _from = _p._p.ED->freq_bands[b][0],
+                        auto    _from = _p._p.ED->freq_bands[b][0],
                                 _upto = _p._p.ED->freq_bands[b][1];
                         psd.course_in_bands[b] =
                                 crecording.psd_profile.course( _from, _upto);
diff --git a/upstream/src/aghermann/ui/sf/montage.cc b/upstream/src/aghermann/ui/sf/montage.cc
index 8eff24e..81f5708 100644
--- a/upstream/src/aghermann/ui/sf/montage.cc
+++ b/upstream/src/aghermann/ui/sf/montage.cc
@@ -331,7 +331,7 @@ draw_page( cairo_t *cr,
                                                         pattern_params.dzcdf_step,
                                                         pattern_params.dzcdf_sigma,
                                                         pattern_params.dzcdf_smooth);
-                                        float        dzcdf_display_scale = (pbot-ptop)/2. / dzcdf.max();
+                                        float   dzcdf_display_scale = (pbot-ptop)/2. / dzcdf.max();
 
                                         cairo_set_source_rgba( cr, 0.3, 0.3, 0.99, .8);
                                         cairo_set_line_width( cr, 1.);
@@ -384,7 +384,7 @@ draw_page( cairo_t *cr,
         }
 
       // waveform: signal_filtered
-        bool        need_filtered = (have_low_pass() or have_high_pass() or have_notch_filter()) or (not artifacts().empty()),
+        bool    need_filtered = (have_low_pass() or have_high_pass() or have_notch_filter()) or (not artifacts().empty()),
                 one_signal_drawn = false;
         if ( draw_filtered_signal and need_filtered ) {
                 cairo_set_line_width( cr, fine_line());
diff --git a/upstream/src/libsigfile/channel.hh b/upstream/src/libsigfile/channel.hh
index b5a81ff..5ab0137 100644
--- a/upstream/src/libsigfile/channel.hh
+++ b/upstream/src/libsigfile/channel.hh
@@ -133,12 +133,15 @@ struct SChannel {
                 {}
         SChannel () = default;
 
-        TType type() const
+        TType
+        type() const
                 { return _type; }
-        const char* type_s() const
+        const char*
+        type_s() const
                 { return type_s(_type); }
 
-        const char* name() const
+        const char*
+        name() const
                 {
                         if ( _custom_name.empty() )
                                 switch ( _type ) {
@@ -152,12 +155,15 @@ struct SChannel {
                         else
                                 return _custom_name.c_str();
                 }
-        const char* c_str() const
+        const char*
+        c_str() const
                 { return name(); }
-        int idx() const
+        int
+        idx() const
                 { return _idx; }
 
-        bool is_fftable() const
+        bool
+        is_fftable() const
                 { return is_fftable( _type); }
     private:
         TType   _type;
diff --git a/upstream/src/libsigfile/edf.cc b/upstream/src/libsigfile/edf.cc
index a198596..83d356d 100644
--- a/upstream/src/libsigfile/edf.cc
+++ b/upstream/src/libsigfile/edf.cc
@@ -394,14 +394,14 @@ void
 CEDFFile::
 _lay_out_header()
 {
-        header.version_number          = (char*)_mmapping;               //[ 8],
-        header.patient_id              = header.version_number   +  8;   //[80],
-        header.recording_id            = header.patient_id       + 80;   //[80],
-        header.recording_date          = header.recording_id     + 80;   //[ 8],
-        header.recording_time          = header.recording_date   +  8;   //[ 8],
-        header.header_length           = header.recording_time   +  8;   //[ 8],
-        header.reserved                = header.header_length    +  8;   //[44],
-        header.n_data_records          = header.reserved         + 44;   //[ 8],
+        header.version_number    = (char*)_mmapping;               //[ 8],
+        header.patient_id        = header.version_number   +  8;   //[80],
+        header.recording_id      = header.patient_id       + 80;   //[80],
+        header.recording_date    = header.recording_id     + 80;   //[ 8],
+        header.recording_time    = header.recording_date   +  8;   //[ 8],
+        header.header_length     = header.recording_time   +  8;   //[ 8],
+        header.reserved          = header.header_length    +  8;   //[44],
+        header.n_data_records    = header.reserved         + 44;   //[ 8],
         header.data_record_size  = header.n_data_records   +  8;   //[ 8],
         header.n_channels        = header.data_record_size +  8;   //[ 4];
 
@@ -689,9 +689,9 @@ _extract_embedded_annotations()
                 if ( (this_a[0] == '+'   || this_a[0] == '-') &&
                      (isdigit(this_a[1]) || this_a[1] == '.') ) {
 
-                        string        abuf (this_a, alen); // NULL-terminated, possibly at pos <alen
+                        string  abuf (this_a, alen); // NULL-terminated, possibly at pos <alen
 
-                        float        offset,
+                        float   offset,
                                 duration;
                         const char
                                 *offset_p = abuf.c_str(),
@@ -751,8 +751,8 @@ details( const int which) const
         if ( _status & bad_header )
                 recv << "Bad header, or no file\n";
         else {
-                size_t        n_dicontinuities = 0;
-                double        prev_offset = NAN, cur_offset;
+                size_t  n_dicontinuities = 0;
+                double  prev_offset = NAN, cur_offset;
                 for ( size_t r = 1; r < _record_offsets.size(); ++r ) {
                         cur_offset = _record_offsets[r] - _record_offsets[r-1];
                         if ( isfinite(prev_offset) and cur_offset != prev_offset )
@@ -862,7 +862,6 @@ int
 agh::SSubjectId::
 parse_recording_id_edf_style( const string& s)
 {
-        using namespace agh::str;
         int_least32_t status = 0;
         auto subfields = tokens( s, " ");
         if ( subfields.size() < 4 ) {
@@ -885,7 +884,7 @@ parse_recording_id_edf_style( const string& s)
 
 // Local Variables:
 // Mode: c++
-// indent-tabs-mode: 8
+// indent-tabs-mode: nil
 // tab-width: 8
 // c-basic-offset: 8
 // End:
diff --git a/upstream/src/libsigproc/sigproc.hh b/upstream/src/libsigproc/sigproc.hh
index 4e7e1d6..8ccf90a 100644
--- a/upstream/src/libsigproc/sigproc.hh
+++ b/upstream/src/libsigproc/sigproc.hh
@@ -228,7 +228,7 @@ struct SCachedDzcdf
                         data.resize(0);
                 }
     private:
-        double        step,
+        double  step,
                 sigma;
         unsigned
                 smooth;

-- 
Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/aghermann.git



More information about the debian-med-commit mailing list