OpendTect-6_4  6.4
seisinfo.h
Go to the documentation of this file.
1 #ifndef seisinfo_h
2 #define seisinfo_h
3 
4 /*+
5 ________________________________________________________________________
6 
7  (C) dGB Beheer B.V.; (LICENSE) http://opendtect.org/OpendTect_license.txt
8  Author: A.H. Bril
9  Date: 25-10-1996
10  RCS: $Id$
11 ________________________________________________________________________
12 
13 -*/
14 
15 #include "seismod.h"
16 #include "seisposkey.h"
17 #include "samplingdata.h"
18 #include "position.h"
19 #include "ranges.h"
20 #include "enums.h"
21 class SeisTrc;
22 class PosAuxInfo;
23 
24 
28 {
29 public:
30 
32 
34  : sampling(0,defaultSampleInterval()), nr(0)
35  , refnr(mUdf(float)), pick(mUdf(float))
36  , offset(0), azimuth(0), zref(0), new_packet(false)
37  {}
38 
40  int nr;
41  BinID binid; /* mDeprecated */
43  float offset;
44  float azimuth;
45  float refnr;
46  float pick;
47 
48  // New functions that will be used more and more.
49  // Try to avoid using binid directly!
50  inline const BinID& binID() const { return binid; }
51  inline IdxType inl() const { return binid.inl(); }
52  inline IdxType crl() const { return binid.crl(); }
53  inline SeisTrcInfo& setBinID( const BinID& bid )
54  { binid = bid; return *this; }
55  inline SeisTrcInfo& setInl( IdxType inr )
56  { binid.inl() = inr; return *this; }
57  inline SeisTrcInfo& setCrl( IdxType inr )
58  { binid.crl() = inr; return *this; }
59 
60  int nearestSample(float pos) const;
61  float samplePos( int idx ) const
62  { return sampling.atIndex( idx ); }
63  SampleGate sampleGate(const Interval<float>&) const;
64  bool dataPresent(float pos,int trcsize) const;
65 
66  enum Fld { TrcNr=0, Pick, RefNr,
67  CoordX, CoordY, BinIDInl, BinIDCrl,
70  double getValue(Fld) const;
71  static void getAxisCandidates(Seis::GeomType,TypeSet<Fld>&);
72  int getDefaultAxisFld(Seis::GeomType,
73  const SeisTrcInfo* next) const;
74  void getInterestingFlds(Seis::GeomType,IOPar&) const;
75  void setPSFlds(const Coord& rcvpos,const Coord& srcpos,
76  bool setpos=false);
77 
78  static const char* sSamplingInfo;
79  static const char* sNrSamples;
80  static float defaultSampleInterval(bool forcetime=false);
81 
82  Seis::PosKey posKey(Seis::GeomType) const;
83  void setPosKey(const Seis::PosKey&);
84  void putTo(PosAuxInfo&) const;
85  void getFrom(const PosAuxInfo&);
86  void fillPar(IOPar&) const;
87  void usePar(const IOPar&);
88 
89  float zref; // not stored
90  bool new_packet; // not stored
91 
92 };
93 
94 
95 #endif
#define mExpClass(module)
Definition: commondefs.h:160
Summary for a Seismic object.
Definition: segydirectdef.h:23
IdxType crl() const
Definition: seisinfo.h:52
SeisTrcInfo()
Definition: seisinfo.h:33
BinID binid
Definition: posauxinfo.h:35
Definition: seisinfo.h:68
void usePar(const IOPar &iop, ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:188
float azimuth
Definition: seisinfo.h:44
IdxType & inl()
Definition: posidxpair.h:43
BinID binid
Definition: seisinfo.h:41
SeisTrcInfo & setInl(IdxType inr)
Definition: seisinfo.h:55
int nr
Definition: seisinfo.h:40
float offset
Definition: posauxinfo.h:38
A cartesian coordinate in 2D space.
Definition: coord.h:25
od_int32 Index_Type
Definition: commontypes.h:33
float offset
Definition: seisinfo.h:43
float samplePos(int idx) const
Definition: seisinfo.h:61
#define mDeclareEnumUtils(enm)
Some utilities surrounding the often needed enum <-> string table.
Definition: enums.h:258
SeisTrcInfo & setBinID(const BinID &bid)
Definition: seisinfo.h:53
T atIndex(IT) const
Definition: samplingdata.h:158
GeomType
Definition: seistype.h:33
Set of (small) copyable elements.
Definition: commontypes.h:30
Generalized set of parameters of the keyword-value type.
Definition: iopar.h:47
Fld
Definition: seisinfo.h:66
#define mUdf(type)
Use this macro to get the undefined for simple types.
Definition: undefval.h:272
SeisTrcInfo & setCrl(IdxType inr)
Definition: seisinfo.h:57
Information for a seismic trace, AKA trace header info.
Definition: seisinfo.h:27
void fillPar(IOPar &iop, const ODPolygon< T > &poly, const char *inpkey)
Definition: polygon.h:175
SamplingData< float > sampling
Definition: seisinfo.h:39
IdxType & crl()
Definition: posidxpair.h:48
float pick
Definition: seisinfo.h:46
Positioning in a seismic survey: inline/crossline or lineNr/trcNr.
Definition: binid.h:30
Auxiliray data possibly needed at location. Mostly a seismic thing.
Definition: posauxinfo.h:22
Seismic trace.
Definition: seistrc.h:34
Coord coord
Definition: seisinfo.h:42
Definition: picklocation.h:21
float azimuth
Definition: posauxinfo.h:39
float pick
Definition: posauxinfo.h:40
Definition: seisinfo.h:67
float refnr
Definition: posauxinfo.h:41
const BinID & binID() const
Definition: seisinfo.h:50
float refnr
Definition: seisinfo.h:45
Definition: seistype.h:55
IdxType inl() const
Definition: seisinfo.h:51
Index_Type IdxType
Definition: seisinfo.h:31

Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B. V. 2019