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

finished implementation of file format selection

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/branches/su1
SVN Revision: 3652
SVN UUID:     67feda4a-a26e-11df-9d6e-31afc202ad0c
parent 930af883
......@@ -27,7 +27,7 @@ c 22/02/2001 V1.0 Thomas Forbriger
c 02/08/2001 V1.1 allow trace order rather than offset order
c 09/09/2004 V1.2 set lower limit of time window
c 13/06/2006 V1.3 provide Hanning taper
c 22.12.2010 V1.4 implement file format selection
c 30.12.2010 V1.4 implemented file format selection
c
c==============================================================================
c
......@@ -40,10 +40,10 @@ c
& '$Id$')
c
c input dataset
character*80 filename
character*80 filename, informat
integer maxtraces, totmaxsamples
parameter(maxtraces=40, totmaxsamples=4000000)
integer lu
integer lu, ierr
parameter(lu=12)
real fdata(totmaxsamples)
integer idata(totmaxsamples)
......@@ -89,15 +89,15 @@ c commandline
integer maxopt, lastarg, iargc
character*80 argument
parameter(maxopt=12)
character*2 optid(maxopt)
character*3 optid(maxopt)
character*40 optarg(maxopt)
logical optset(maxopt), opthasarg(maxopt)
c here are the keys to our commandline options
data optid/2h-d, 2h-v, '-f', '-n', '-o', '-t', '-T', '-w', '-S',
& 2h-m, '-h', '-ty'/
data optid/'-d', '-v', '-f', '-n', '-o', '-t', '-T', '-w', '-S',
& '-m', '-h', '-ty'/
data opthasarg/2*.FALSE.,2*.TRUE.,.FALSE.,5*.TRUE.,.false.,
& .true./
data optarg/2*1h-,'100.','100','-','1.','1','1.','1','0.','-',
data optarg/2*'-','100.','100','-','1.','1','1.','1','0.','-',
& 'sff'/
c
c------------------------------------------------------------------------------
......@@ -166,6 +166,7 @@ c
if (optset(9)) read(optarg(9), *) nptraces
read(optarg(10), *) tmin
hanning=optset(11)
informat=optarg(12)
overwrite=optset(5)
......@@ -175,6 +176,8 @@ c
call getarg(2, outbase)
c------------------------------------------------------------------------------
c go
call sff_select_input_format(informat, ierr)
if (ierr.ne.0) stop 'ERROR: selecting input file format'
call sffu_simpleread(lu, filename, maxtraces, totmaxsamples,
& fdata, idata, toffset, tracedt, roffset, innsamples,
& firstsample, ntraces, verbose)
......
Markdown is supported
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