Index: /trunk/ArchTOIPipe/Kernel/fitstoirdr.cc
===================================================================
--- /trunk/ArchTOIPipe/Kernel/fitstoirdr.cc	(revision 1786)
+++ /trunk/ArchTOIPipe/Kernel/fitstoirdr.cc	(revision 1787)
@@ -3,5 +3,5 @@
 //                               Christophe Magneville
 //                               Reza Ansari
-// $Id: fitstoirdr.cc,v 1.21 2001-11-16 11:28:45 aubourg Exp $
+// $Id: fitstoirdr.cc,v 1.22 2001-11-26 15:13:48 aubourg Exp $
 
 #include "fitstoirdr.h"
@@ -112,7 +112,13 @@
 
   snBegin = firstSn;
-
+  /*  if (forceMinIn > 0 && forceMinIn > snBegin) {
+    snBegin = forceMinIn;
+  }
+  */
   openFile(allfn.back());
   snEnd = firstSn+nrows-1;
+  /*  if (forceMaxIn > 0 && forceMaxIn < snEnd) {
+    snEnd = forceMaxIn;
+    }*/
   cout << "FITSTOIReader range " << snBegin << " -> " << snEnd << endl;
 }
@@ -252,13 +258,4 @@
    long sn = (long) (samplenum[ip]+.1);
    TOIManager* mgr = TOIManager::getManager();
-#if 0
-   if(sn > mgr->getRequestedEnd()) break;
-   if(sn < mgr->getRequestedBegin()) continue;
-   for(int k=0; k<getNOut(); k++) {
-     if(colval[k]==NULL)  continue;
-     uint_8 flg = (colflg[k]==NULL)? 0: colflg[k][ip];
-     putData(k,sn,colval[k][ip],flg);
-   }
-#else
    if(samplenum[0] > mgr->getRequestedEnd()) break;
    if(samplenum[ifin-ideb] < mgr->getRequestedBegin()) continue;
@@ -276,5 +273,4 @@
      }
    }
-#endif
    totnscount++;
  }
Index: /trunk/ArchTOIPipe/Kernel/toiprocessor.cc
===================================================================
--- /trunk/ArchTOIPipe/Kernel/toiprocessor.cc	(revision 1786)
+++ /trunk/ArchTOIPipe/Kernel/toiprocessor.cc	(revision 1787)
@@ -3,5 +3,5 @@
 //                               Christophe Magneville
 //                               Reza Ansari
-// $Id: toiprocessor.cc,v 1.20 2001-11-16 14:10:42 aubourg Exp $
+// $Id: toiprocessor.cc,v 1.21 2001-11-26 15:13:48 aubourg Exp $
 
 #include "toiprocessor.h"
@@ -39,4 +39,6 @@
   minOut = -1;
   maxOut = -1;
+  forcedMinIn = -1;
+  forcedMaxIn = -1;
   neededHistory = 1000;
   lastAWN = 0;
@@ -72,5 +74,5 @@
 int TOIProcessor::getMinOut() {
   //cout << name << "minout" << endl;
-  if (minOut < 0) minOut = calcMinOut();
+  if (minOut < 0)  minOut = calcMinOut();
   //cout << name << "minout=" << minOut << endl;
   return minOut;
@@ -101,4 +103,5 @@
     if (x > minIn) minIn = x;
   }
+  if (forcedMinIn > 0 && forcedMinIn > minIn) minIn = forcedMinIn;
   return minIn;
 }
@@ -113,4 +116,5 @@
     if (x < maxIn) maxIn = x;
   }
+  if (forcedMaxIn > 0 && forcedMaxIn < maxIn) maxIn = forcedMaxIn;
   return maxIn;
 }
Index: /trunk/ArchTOIPipe/Kernel/toiprocessor.h
===================================================================
--- /trunk/ArchTOIPipe/Kernel/toiprocessor.h	(revision 1786)
+++ /trunk/ArchTOIPipe/Kernel/toiprocessor.h	(revision 1787)
@@ -5,5 +5,5 @@
 //                               Christophe Magneville
 //                               Reza Ansari
-// $Id: toiprocessor.h,v 1.16 2001-11-14 14:12:32 aubourg Exp $
+// $Id: toiprocessor.h,v 1.17 2001-11-26 15:13:48 aubourg Exp $
 
 
@@ -81,17 +81,21 @@
 
   // Gestion des bornes pour les transformations de TOIs...
-  virtual int   calcMinOut();
-  virtual int   calcMaxOut();
+  virtual int   calcMinOut(); // Protected ?
+  virtual int   calcMaxOut(); // Protected ?
 
   virtual int   getMinOut();
   virtual int   getMaxOut();
-  int           minOut;
-  int           maxOut;
+  int           minOut;    // Cache for calcMinOut() value. Protected ?
+  int           maxOut;    // Cache for calcMaxOut() value. Protected ?
 
   virtual int   getMinIn();
   virtual int   getMaxIn();
   // Implementation par defaut
-  int           upExtra;
-  int           lowExtra;
+  int           upExtra;  // MaxIn - MaxOut : extra samples for processing
+  int           lowExtra; // MinOut - MinIn : extra samples for processing
+
+  int           forcedMinIn; // to process a subset of data
+  int           forcedMaxIn; // to process a subset of data
+  void          setSampleSubset(int min, int max);
 
   int           neededHistory;
Index: /trunk/ArchTOIPipe/Kernel/toisegment.h
===================================================================
--- /trunk/ArchTOIPipe/Kernel/toisegment.h	(revision 1786)
+++ /trunk/ArchTOIPipe/Kernel/toisegment.h	(revision 1787)
@@ -5,5 +5,5 @@
 //                               Christophe Magneville
 //                               Reza Ansari
-// $Id: toisegment.h,v 1.16 2001-11-16 14:11:34 aubourg Exp $
+// $Id: toisegment.h,v 1.17 2001-11-26 15:13:48 aubourg Exp $
 
 #ifndef TOISEGMENT_H
@@ -26,7 +26,7 @@
 class TOISegmented : public TOIRegular {
  public:
-  TOISegmented(int bufsz=256, int maxseg=20);
-  TOISegmented(string nm, int bufsz=256, int maxseg=20);
-  TOISegmented(char* cnm, int bufsz=256, int maxseg=20);
+  TOISegmented(int bufsz=1024, int maxseg=20);
+  TOISegmented(string nm, int bufsz=1024, int maxseg=20);
+  TOISegmented(char* cnm, int bufsz=1024, int maxseg=20);
   ~TOISegmented();
 
