Commit ad0699b4 authored by thomas.forbriger's avatar thomas.forbriger Committed by thomas.forbriger
Browse files

proceeding

This is a legacy commit from before 2015-03-01.
It may be incomplete as well as inconsistent.
See COPYING.legacy and README.history for details.


SVN Path:     http://gpitrsvn.gpi.uni-karlsruhe.de/repos/TFSoftware/trunk
SVN Revision: 2302
SVN UUID:     67feda4a-a26e-11df-9d6e-31afc202ad0c
parent 145c0f5c
......@@ -3,7 +3,7 @@
*
* ----------------------------------------------------------------------------
*
* $Id: readany.cc,v 1.12 2006-04-03 15:24:32 tforb Exp $
* $Id: readany.cc,v 1.13 2007-06-12 15:14:32 tforb Exp $
* \author Thomas Forbriger
* \date 06/04/2004
*
......@@ -37,7 +37,7 @@
#define DATREAD_READANY_CC_VERSION \
"DATREAD_READANY_CC V1.2 "
#define DATREAD_READANY_CC_CVSID \
"$Id: readany.cc,v 1.12 2006-04-03 15:24:32 tforb Exp $"
"$Id: readany.cc,v 1.13 2007-06-12 15:14:32 tforb Exp $"
#include <datreadxx/readany.h>
#include<datreadxx/sff.h>
......@@ -55,7 +55,7 @@ namespace datread {
{
if (Mformat==Fbonjer) { Mis=new ibonjerstream(is); }
else if (Mformat==Fpdas) { Mis=new ipdasstream(is); }
else if (Mformat==Fsff) { Mis=new isffstream(is); }
else if (Mformat==Fsff) { Mis=new isffstream(is, debug); }
else if (Mformat==Fhpmo) { Mis=new ihpmostream(is); }
else if (Mformat==Fmseed) { Mis=new imseedstream(is, debug); }
else
......
......@@ -3,7 +3,7 @@
*
* ----------------------------------------------------------------------------
*
* $Id: sff.h,v 1.8 2006-03-28 16:07:43 tforb Exp $
* $Id: sff.h,v 1.9 2007-06-12 15:14:32 tforb Exp $
* \author Thomas Forbriger
* \date 30/03/2004
*
......@@ -29,6 +29,7 @@
*
* REVISIONS and CHANGES
* - 30/03/2004 V1.0 Thomas Forbriger
* - 12/06/2007 V1.1 added DEBUG member data
*
* ============================================================================
*/
......@@ -37,9 +38,9 @@
#ifndef DATREAD_SFF_H_VERSION
#define DATREAD_SFF_H_VERSION \
"DATREAD_SFF_H V1.0 "
"DATREAD_SFF_H V1.1 "
#define DATREAD_SFF_H_CVSID \
"$Id: sff.h,v 1.8 2006-03-28 16:07:43 tforb Exp $"
"$Id: sff.h,v 1.9 2007-06-12 15:14:32 tforb Exp $"
#include<datreadxx/datread.h>
......@@ -67,6 +68,7 @@ namespace datread {
{ Tbase::help(os, "isffstream"); }
private:
void settraceheader(const sff::TraceHeader& header);
bool Mdebug;
}; // class isffstream
} // namespace datread
......
......@@ -3,7 +3,7 @@
*
* ----------------------------------------------------------------------------
*
* $Id: sff.cc,v 1.6 2006-03-28 16:07:48 tforb Exp $
* $Id: sff.cc,v 1.7 2007-06-12 15:14:32 tforb Exp $
* \author Thomas Forbriger
* \date 30/03/2004
*
......@@ -29,13 +29,14 @@
*
* REVISIONS and CHANGES
* - 30/03/2004 V1.0 Thomas Forbriger
* - 12/06/2004 V1.1 provides DEBUG output
*
* ============================================================================
*/
#define DATREAD_SFF_CC_VERSION \
"DATREAD_SFF_CC V1.0 "
"DATREAD_SFF_CC V1.1 "
#define DATREAD_SFF_CC_CVSID \
"$Id: sff.cc,v 1.6 2006-03-28 16:07:48 tforb Exp $"
"$Id: sff.cc,v 1.7 2007-06-12 15:14:32 tforb Exp $"
#include <datreadxx/sff.h>
#include <sffxx.h>
......@@ -43,7 +44,7 @@
namespace datread {
isffstream::isffstream(std::istream& is, const bool& debug):
Tbase(is, true, true, true)
Tbase(is, true, true, true), Mdebug(debug)
{
sff::FileHeader fileheader(Mis, debug);
if (fileheader.hasfree()) { this->setfilefree(fileheader.free()); }
......@@ -55,8 +56,16 @@ namespace datread {
Tdseries isffstream::dseries()
{
this->newtrace();
if (Mdebug)
{
std::cerr
<< "DEBUG (isffstream::dseries): read waveform"
<< std::endl;
}
sff::InputWaveform<Tdseries> waveform(Mis);
this->settraceheader(waveform.header());
if (Mdebug)
{ std::cerr << "DEBUG (isffstream::dseries): done" << std::endl; }
return(waveform.series());
}
......@@ -65,8 +74,16 @@ namespace datread {
Tfseries isffstream::fseries()
{
this->newtrace();
if (Mdebug)
{
std::cerr
<< "DEBUG (isffstream::fseries): read waveform"
<< std::endl;
}
sff::InputWaveform<Tfseries> waveform(Mis);
this->settraceheader(waveform.header());
if (Mdebug)
{ std::cerr << "DEBUG (isffstream::fseries): done" << std::endl; }
return(waveform.series());
}
......@@ -75,8 +92,16 @@ namespace datread {
Tiseries isffstream::iseries()
{
this->newtrace();
if (Mdebug)
{
std::cerr
<< "DEBUG (isffstream::iseries): read waveform"
<< std::endl;
}
sff::InputWaveform<Tiseries> waveform(Mis);
this->settraceheader(waveform.header());
if (Mdebug)
{ std::cerr << "DEBUG (isffstream::iseries): done" << std::endl; }
return(waveform.series());
}
......@@ -85,7 +110,15 @@ namespace datread {
void isffstream::skipseries()
{
this->newtrace();
if (Mdebug)
{
std::cerr
<< "DEBUG (isffstream::skipseries): skipped waveform"
<< std::endl;
}
sff::SkipWaveform skip(Mis);
if (Mdebug)
{ std::cerr << "DEBUG (isffstream::skipseries): done" << std::endl; }
this->settraceheader(skip.header());
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment