📄 nsegy.h
字号:
1 = local 2 = GMT 3 = other */ short trwf; /* trace weighting factor, defined as 1/2^N volts for the least sigificant bit */ short grnors; /* geophone group number of roll switch position one */ short grnofr; /* geophone group number of trace one within original field record */ short grnlof; /* geophone group number of last trace within original field record */ short gaps; /* gap size (total number of groups dropped) */ short otrav; /* overtravel taper code: 1 = down (or behind) 2 = up (or ahead) */ /* local assignments */ float d1; /* sample spacing for non-seismic data */ float f1; /* first sample location for non-seismic data */ float d2; /* sample spacing between traces */ float f2; /* first trace location */ float ungpow; /* negative of power used for dynamic range compression */ float unscale; /* reciprocal of scaling factor to normalize range */ int ntr; /* number of traces */ short mark; /* mark selected traces */ short mutb; /* mute time at bottom (start time) */ /* bottom mute ends at last sample */ float dz; /* depth sampling interval in (m or ft) */ /* if =0.0, input are time samples */ float fz; /* depth of first sample in (m or ft) */ short n2; /* number of traces per cdp or per shot */ short shortpad; /* alignment padding */ short unass[10]; float data[SU_NFLTS];} segy;typedef struct { /* bhed - binary header */ int jobid; /* job identification number */ int lino; /* line number (only one line per reel) */ int reno; /* reel number */ short ntrpr; /* number of data traces per record */ short nart; /* number of auxiliary traces per record */ unsigned short hdt; /* sample interval in micro secs for this reel */ unsigned short dto; /* same for original field recording */ unsigned short hns; /* number of samples per trace for this reel */ unsigned short nso; /* same for original field recording */ short format; /* data sample format code: 1 = floating point (4 bytes) 2 = fixed point (4 bytes) 3 = fixed point (2 bytes) 4 = fixed point w/gain code (4 bytes) */ short fold; /* CDP fold expected per CDP ensemble */ short tsort; /* trace sorting code: 1 = as recorded (no sorting) 2 = CDP ensemble 3 = single fold continuous profile 4 = horizontally stacked */ short vscode; /* vertical sum code: 1 = no sum 2 = two sum ... N = N sum (N = 32,767) */ short hsfs; /* sweep frequency at start */ short hsfe; /* sweep frequency at end */ short hslen; /* sweep length (ms) */ short hstyp; /* sweep type code: 1 = linear 2 = parabolic 3 = exponential 4 = other */ short schn; /* trace number of sweep channel */ short hstas; /* sweep trace taper length at start if tapered (the taper starts at zero time and is effective for this length) */ short hstae; /* sweep trace taper length at end (the ending taper starts at sweep length minus the taper length at end) */ short htatyp; /* sweep trace taper type code: 1 = linear 2 = cos-squared 3 = other */ short hcorr; /* correlated data traces code: 1 = no 2 = yes */ short bgrcv; /* binary gain recovered code: 1 = yes 2 = no */ short rcvm; /* amplitude recovery method code: 1 = none 2 = spherical divergence 3 = AGC 4 = other */ short mfeet; /* measurement system code: 1 = meters 2 = feet */ short polyt; /* impulse signal polarity code: 1 = increase in pressure or upward geophone case movement gives negative number on tape 2 = increase in pressure or upward geophone case movement gives positive number on tape */ short vpol; /* vibratory polarity code: code seismic signal lags pilot by 1 337.5 to 22.5 degrees 2 22.5 to 67.5 degrees 3 67.5 to 112.5 degrees 4 112.5 to 157.5 degrees 5 157.5 to 202.5 degrees 6 202.5 to 247.5 degrees 7 247.5 to 292.5 degrees 8 293.5 to 337.5 degrees */ short hunass[170]; /* unassigned */} bhed;/* DEFINES */#define gettr(x) fgettr(stdin, (x))#define vgettr(x) fvgettr(stdin, (x))#define puttr(x) fputtr(stdout, (x))#define vputtr(x) fvputtr(stdout, (x))#define gettra(x, y) fgettra(stdin, (x), (y))/* The following refer to the trid field in segy.h *//* CHARPACK represents byte packed seismic data from supack1 */#define CHARPACK 101/* SHORTPACK represents 2 byte packed seismic data from supack2 */#define SHORTPACK 102/* TREAL represents real time traces */#define TREAL 1/* TDEAD represents dead time traces */#define TDEAD 2/* TDUMMY represents dummy time traces */#define TDUMMY 3/* TBREAK represents time break traces */#define TBREAK 4/* UPHOLE represents uphole traces */#define UPHOLE 5/* SWEEP represents sweep traces */#define SWEEP 6/* TIMING represents timing traces */#define TIMING 7/* WBREAK represents timing traces */#define WBREAK 8/* TCMPLX represents complex time traces */#define TCMPLX 13/* TAMPH represents time domain data in amplitude/phase form */#define TAMPH 15/* FPACK represents packed frequency domain data */#define FPACK 12/* FUNPACKNYQ represents complex frequency domain data */#define FUNPACKNYQ 11/* FCMPLX represents complex frequency domain data */#define FCMPLX 10/* FAMPH represents freq domain data in amplitude/phase form */#define FAMPH 14/* REALPART represents the real part of a trace to Nyquist */#define REALPART 16/* IMAGPART represents the real part of a trace to Nyquist */#define IMAGPART 17/* AMPLITUDE represents the amplitude of a trace to Nyquist */#define AMPLITUDE 18/* PHASE represents the phase of a trace to Nyquist */#define PHASE 19/* KT represents wavenumber-time domain data */#define KT 21/* KOMEGA represents wavenumber-frequency domain data */#define KOMEGA 22/* ENVELOPE represents the envelope of the complex time trace */#define ENVELOPE 23/* INSTPHASE represents the phase of the complex time trace */#define INSTPHASE 24/* INSTFREQ represents the frequency of the complex time trace */#define INSTFREQ 25/* DEPTH represents traces in depth-range (z-x) */#define TRID_DEPTH 30/* 3C data... v,h1,h2=(11,12,13)+32 so a bitmask will convert *//* between conventions *//* TVERT represents the vertical component */#define TVERT 43/* TVHOZ1 represents the horizontal-1 component */#define THORZ1 44/* TVHOZ2 represents the horizontal-2 component */#define THORZ2 45/* TRADIAL represents the radial component */#define TRADIAL 46/* TTRANS represents the transverse component */#define TTRANS 47/* #define ISSEISMIC(id) (( (id)==0 || (id)==TREAL || (id)==TDEAD || (id)==TDUMMY ) ? cwp_true : cwp_false ) */#define ISSEISMIC(id) (( (id)==0 || (id)==TREAL || (id)==TDEAD || (id)==TDUMMY || \ (id)==TVERT || (id)==THORZ1 || (id)==THORZ2 || \ (id)==TRADIAL || (id)==TTRANS ) ? cwp_true : cwp_false ) /* FUNCTION PROTOTYPES */#ifdef __cplusplus /* if C++, specify external linkage to C functions */extern "C" {#endifint fgettr(FILE *fp, segy *tp);int fvgettr(FILE *fp, segy *tp);void fputtr(FILE *fp, segy *tp);void fvputtr(FILE *fp, segy *tp);int fgettra(FILE *fp, segy *tp, int itr);/* hdrpkge */void gethval(const segy *tp, int index, Value *valp);void puthval(segy *tp, int index, Value *valp);void getbhval(const bhed *bhp, int index, Value *valp);void putbhval(bhed *bhp, int index, Value *valp);void gethdval(const segy *tp, char *key, Value *valp);void puthdval(segy *tp, char *key, Value *valp);char *hdtype(const char *key);char *getkey(const int index);int getindex(const char *key);void swaphval(segy *tp, int index);void swapbhval(bhed *bhp, int index);void printheader(const segy *tp);void tabplot(segy *tp, int itmin, int itmax);#ifdef __cplusplus /* if C++, end external linkage specification */}#endif#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -