conv/many suite: convert (m)any seismic data format(s)

◆ writeheader()

void writeheader ( std::ostream &  os,
const Header header 
)

Definition at line 85 of file any2ascii.cc.

References ANY2ASCII_VERSION, Header::filefree, Header::filename, Header::hasfilefree, Header::hasinfo, Header::hassrce, Header::hastracefree, Header::info, Header::itrace, Header::srce, Header::tracefree, and Header::wid2.

Referenced by main().

86 {
87  os << ANY2ASCII_VERSION << endl;
88  os << "input file: " << header.filename << endl;
89  os << "input trace: " << header.itrace << endl << endl;
90  os << "file header: " << endl;
91  os << "============ " << endl;
92  if (header.hassrce) { sff::verbose(os, header.srce); }
93  else { os << "file header contains no SRCE line" << endl; }
94  if (header.hasfilefree) { sff::verbose(os, header.filefree); }
95  else { os << "file header contains no FREE block" << endl; }
96  os << endl;
97  os << "trace header: " << endl;
98  os << "============= " << endl;
99  sff::verbose(os, header.wid2);
100  if (header.hasinfo) { sff::verbose(os, header.info); }
101  else { os << "trace header contains no INFO line" << endl; }
102  if (header.hastracefree) { sff::verbose(os, header.tracefree); }
103  else { os << "trace header contains no FREE block" << endl; }
104  os << endl;
105 }
sff::WID2 wid2
Definition: any2ascii.cc:76
sff::FREE tracefree
Definition: any2ascii.cc:75
sff::FREE filefree
Definition: any2ascii.cc:75
bool hasinfo
Definition: any2ascii.cc:74
bool hassrce
Definition: any2ascii.cc:74
#define ANY2ASCII_VERSION
Definition: any2ascii.cc:45
sff::INFO info
Definition: any2ascii.cc:77
sff::SRCE srce
Definition: any2ascii.cc:78
bool hasfilefree
Definition: any2ascii.cc:74
std::string filename
Definition: any2ascii.cc:80
bool hastracefree
Definition: any2ascii.cc:74
int itrace
Definition: any2ascii.cc:79
Here is the caller graph for this function: