29 : binid_(bid), offset_(offs) {}
31 : binid_(
mUdf(int),trcnr), offset_(offs) {}
34 inline bool is2D()
const {
return mIsUdf(binid_.inl()); }
42 inline int trcNr()
const {
return binid_.crl(); }
43 inline int inLine()
const {
return binid_.inl(); }
44 inline int xLine()
const {
return binid_.crl(); }
45 inline float offset()
const {
return offset_; }
46 inline bool hasOffset(
float)
const;
48 inline void setTrcNr(
int trcnr ) { binid_.crl() = trcnr; }
50 inline void setInline(
int inl ) { binid_.inl() = inl; }
51 inline void setXine(
int crl ) { binid_.crl() = crl; }
52 inline void setOffset(
float offs ) { offset_ = offs; }
53 inline void set(
const BinID& bid,
float offs )
54 { binid_ = bid; offset_ = offs; }
55 inline void set(
int trcnr,
float offs )
56 { binid_.inl() =
mUdf(
int); binid_.crl() = trcnr;
58 inline void set(
int trcnr,
const BinID&,float);
61 inline int&
trcNr() {
return binid_.crl(); }
62 inline BinID&
binID() {
return binid_; }
63 inline float&
offset() {
return offset_; }
64 inline int&
inLine() {
return binid_.inl(); }
65 inline int&
xLine() {
return binid_.crl(); }
67 static PosKey
undef() {
return PosKey(
mUdf(
int) ); }
87 const float diff = offs -
offset_;
const BinID & binID() const
Definition: seisposkey.h:41
#define mExpClass(module)
Definition: commondefs.h:160
#define mIsUdf(val)
Use mIsUdf to check for undefinedness of simple types.
Definition: undefval.h:287
Summary for a Seismic object.
Definition: segydirectdef.h:23
int trcNr() const
Definition: seisposkey.h:42
float & offset()
Definition: seisposkey.h:63
bool operator==(const ArrayNDInfo &a1, const ArrayNDInfo &a2)
Definition: arrayndinfo.h:53
#define mSetUdf(val)
Use this macro to set simple types to undefined.
Definition: undefval.h:274
#define mIsZero(x, eps)
Definition: commondefs.h:53
bool is2D(GeomType gt)
Definition: seistype.h:34
PosKey(int trcnr, float offs=mUdf(float))
Definition: seisposkey.h:30
IdxType & inl()
Definition: posidxpair.h:43
int & xLine()
Definition: seisposkey.h:65
void setXine(int crl)
Definition: seisposkey.h:51
int inLine() const
Definition: seisposkey.h:43
void setInline(int inl)
Definition: seisposkey.h:50
BinID binid_
Definition: seisposkey.h:71
Definition: seisposkey.h:23
#define mIsEqual(x, y, eps)
Definition: commondefs.h:54
GeomType
Definition: seistype.h:33
bool isPS(GeomType gt)
Definition: seistype.h:38
int & inLine()
Definition: seisposkey.h:64
#define mUdf(type)
Use this macro to get the undefined for simple types.
Definition: undefval.h:272
bool is2D() const
Definition: seisposkey.h:34
bool operator==(const PosKey &) const
Definition: seisposkey.h:105
PosKey(Seis::GeomType gt=Seis::Vol)
Definition: seisposkey.h:77
void setOffset(float offs)
Definition: seisposkey.h:52
Seis::GeomType geomType() const
Definition: seisposkey.h:36
void setTrcNr(int trcnr)
Definition: seisposkey.h:48
float offset() const
Definition: seisposkey.h:45
Positioning in a seismic survey: inline/crossline or lineNr/trcNr.
Definition: binid.h:30
bool isUndef() const
Definition: seisposkey.h:38
BinID & binID()
Definition: seisposkey.h:62
Definition: seistype.h:33
static PosKey undef()
Definition: seisposkey.h:67
float offset_
Definition: seisposkey.h:72
GeomType geomTypeOf(const char *)
bool hasOffset(float) const
Definition: seisposkey.h:85
void set(const BinID &bid, float offs)
Definition: seisposkey.h:53
int xLine() const
Definition: seisposkey.h:44
int & trcNr()
Definition: seisposkey.h:61
void setUndef()
Definition: seisposkey.h:39
bool isPS() const
Definition: seisposkey.h:35
void setBinID(const BinID &bid)
Definition: seisposkey.h:49
PosKey(const BinID &bid, float offs=mUdf(float))
Definition: seisposkey.h:28