r166: *** empty log message ***
[ctsim.git] / libctsim / filter.cpp
index 544afecbb8074ec5de18466d2490b99d5219d167..84d2e7b4e080f877d9d162973d548e70131be084 100644 (file)
@@ -9,7 +9,7 @@
 **  This is part of the CTSim program
 **  Copyright (C) 1983-2000 Kevin Rosenberg
 **
-**  $Id: filter.cpp,v 1.22 2000/07/23 01:49:03 kevin Exp $
+**  $Id: filter.cpp,v 1.23 2000/07/31 14:48:35 kevin Exp $
 **
 **  This program is free software; you can redistribute it and/or modify
 **  it under the terms of the GNU General Public License (version 2) as
@@ -317,11 +317,16 @@ SignalFilter::init (const int filterID, const int filterMethodID, double bw, dou
     } else if (m_idDomain == DOMAIN_SPATIAL) {
       double x;
       int i;
-      for (x = m_filterMin, i = 0; i < m_nFilterPoints; x += m_filterInc, i++)
+      for (x = m_filterMin, i = 0; i < m_nFilterPoints; x += m_filterInc, i++) {
        if (haveAnalyticSpatial(m_idFilter))
          m_vecFilter[i] = spatialResponseAnalytic (x, m_filterParam);
        else
          m_vecFilter[i] = spatialResponseCalc (x, m_filterParam);
+#if LIMIT_BANDWIDTH_TRIAL
+       if (i < m_nFilterPoints / 4 || i > (m_nFilterPoints * 3) / 4)
+         m_vecFilter[i] = 0;
+#endif
+      }
     } else {
       m_failMessage = "Illegal domain name ";
       m_failMessage += m_idDomain;