OpendTect-6_4  6.4
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Protected Attributes | List of all members
TrcKeyZSampling Class Reference

Hor+Vert sampling in 3D surveys. More...

Public Types

enum  Dir { Inl =0, Crl =1, Z =2 }
 

Public Member Functions

 TrcKeyZSampling ()
 
 TrcKeyZSampling (const TrcKeyZSampling &)
 
 TrcKeyZSampling (bool settoSI)
 
bool is2D () const
 
Dir defaultDir () const
 
void getDefaultNormal (Coord3 &) const
 
bool isFlat () const
 is one of directions size 1? More...
 
void init (bool settoSI=true)
 Sets hrg_.init and zrg_ to survey values or zeros. More...
 
void setEmpty ()
 
void set2DDef ()
 Sets to survey zrange and. More...
 
void normalise ()
 Makes sure start<stop and steps are non-zero. More...
 
int lineIdx (Pos::LineID) const
 
int trcIdx (Pos::TraceID) const
 
int zIdx (float z) const
 
int nrLines () const
 
int nrTrcs () const
 
int nrZ () const
 
int64_t totalNr () const
 
int size (Dir d) const
 
float zAtIndex (int idx) const
 
bool isEmpty () const
 
bool isDefined () const
 
bool includes (const TrcKeyZSampling &) const
 
bool getIntersection (const TrcKeyZSampling &, TrcKeyZSampling &) const
 Returns false if intersection is empty. More...
 
void include (const TrcKey &, float z)
 
void include (const TrcKeyZSampling &)
 
void limitTo (const TrcKeyZSampling &, bool ignoresteps=false)
 
void limitToWithUdf (const TrcKeyZSampling &)
 
void expand (int nrlines, int nrtrcs, int nrz)
 
void snapToSurvey ()
 
bool operator== (const TrcKeyZSampling &) const
 
bool operator!= (const TrcKeyZSampling &) const
 
TrcKeyZSamplingoperator= (const TrcKeyZSampling &)
 
bool usePar (const IOPar &)
 
void fillPar (IOPar &) const
 
int inlIdx (int inl) const
 
int crlIdx (int crl) const
 
void include (const BinID &bid, float z)
 
int nrInl () const
 
int nrCrl () const
 
void shrinkTo (const TrcKeyZSampling &innertkzs, float releps=1e-4)
 
void growTo (const TrcKeyZSampling &outertkzs, float releps=1e-4)
 
bool adjustTo (const TrcKeyZSampling &availabletkzs, bool falsereturnsdummy=false)
 
bool makeCompatibleWith (const TrcKeyZSampling &othertkzs)
 
bool isEqual (const TrcKeyZSampling &, float zeps=Values::Undef< float >::val()) const
 

Static Public Member Functions

static const EnumDefImpl< Dir > & DirDef ()
 
static const char ** DirNames ()
 
static bool parseEnumDir (const char *, Dir &)
 
static bool parseEnum (const char *, Dir &)
 
static bool parseEnum (const IOPar &, const char *, Dir &)
 
static Dir parseEnumDir (const char *)
 
static const char * toString (Dir)
 
static uiString toUiString (Dir)
 
static const char * getDirString (Dir)
 
static void removeInfo (IOPar &)
 

Public Attributes

TrcKeySampling hsamp_
 
StepInterval< float > zsamp_
 
TrcKeySamplinghrg
 
StepInterval< float > & zrg
 

Static Protected Attributes

static const char * DirKeys_ []
 
static ConstPtrMan< EnumDefImpl< Dir > > DirDefinition_
 

Detailed Description

Hor+Vert sampling in 3D surveys.

When slices are to be taken from a TrcKeyZSampling, they should be ordered as follows:

Dir Dim1 Dim2
Inl Crl Z
Crl Inl Z
Z Inl Crl

See also the direction() and dimension() free functions.

Member Enumeration Documentation

Enumerator
Inl 
Crl 

Constructor & Destructor Documentation

TrcKeyZSampling::TrcKeyZSampling ( )
TrcKeyZSampling::TrcKeyZSampling ( const TrcKeyZSampling )
TrcKeyZSampling::TrcKeyZSampling ( bool  settoSI)

Member Function Documentation

bool TrcKeyZSampling::adjustTo ( const TrcKeyZSampling availabletkzs,
bool  falsereturnsdummy = false 
)

adjusts the non-flat dimensions of the desired "this" tkzs to the availabletkzs for optimal texture data display.

int TrcKeyZSampling::crlIdx ( int  crl) const
inline
Dir TrcKeyZSampling::defaultDir ( ) const

'flattest' direction, i.e. direction with smallest size. If equal, prefer Inl then Crl then Z

static const EnumDefImpl< Dir >& TrcKeyZSampling::DirDef ( )
static
static const char** TrcKeyZSampling::DirNames ( )
static
void TrcKeyZSampling::expand ( int  nrlines,
int  nrtrcs,
int  nrz 
)
void TrcKeyZSampling::fillPar ( IOPar ) const
void TrcKeyZSampling::getDefaultNormal ( Coord3 ) const
static const char* TrcKeyZSampling::getDirString ( Dir  )
static
bool TrcKeyZSampling::getIntersection ( const TrcKeyZSampling ,
TrcKeyZSampling  
) const

Returns false if intersection is empty.

void TrcKeyZSampling::growTo ( const TrcKeyZSampling outertkzs,
float  releps = 1e-4 
)

grows "this" tkzs up to but not across outertkzs boundaries. Counterpart of shrinkTo(.) function.

void TrcKeyZSampling::include ( const TrcKey ,
float  z 
)
void TrcKeyZSampling::include ( const TrcKeyZSampling )
void TrcKeyZSampling::include ( const BinID bid,
float  z 
)
bool TrcKeyZSampling::includes ( const TrcKeyZSampling ) const
void TrcKeyZSampling::init ( bool  settoSI = true)

Sets hrg_.init and zrg_ to survey values or zeros.

int TrcKeyZSampling::inlIdx ( int  inl) const
inline
bool TrcKeyZSampling::is2D ( ) const
inline
bool TrcKeyZSampling::isDefined ( ) const
bool TrcKeyZSampling::isEmpty ( ) const
bool TrcKeyZSampling::isEqual ( const TrcKeyZSampling ,
float  zeps = Values::Undef< float >::val() 
) const
bool TrcKeyZSampling::isFlat ( ) const

is one of directions size 1?

void TrcKeyZSampling::limitTo ( const TrcKeyZSampling ,
bool  ignoresteps = false 
)
void TrcKeyZSampling::limitToWithUdf ( const TrcKeyZSampling )

handles undef values + returns reference cube nearest limit if the 2 cubes do not intersect

int TrcKeyZSampling::lineIdx ( Pos::LineID  ) const
bool TrcKeyZSampling::makeCompatibleWith ( const TrcKeyZSampling othertkzs)

makes "this" tkzs compatible to othertkzs. Only keeps locations lying on the grid of othertkzs.

void TrcKeyZSampling::normalise ( )

Makes sure start<stop and steps are non-zero.

int TrcKeyZSampling::nrCrl ( ) const
inline
int TrcKeyZSampling::nrInl ( ) const
inline
int TrcKeyZSampling::nrLines ( ) const
int TrcKeyZSampling::nrTrcs ( ) const
int TrcKeyZSampling::nrZ ( ) const
bool TrcKeyZSampling::operator!= ( const TrcKeyZSampling ) const
TrcKeyZSampling& TrcKeyZSampling::operator= ( const TrcKeyZSampling )
bool TrcKeyZSampling::operator== ( const TrcKeyZSampling ) const
static bool TrcKeyZSampling::parseEnum ( const IOPar ,
const char *  ,
Dir  
)
static
static bool TrcKeyZSampling::parseEnum ( const char *  ,
Dir  
)
static
static Dir TrcKeyZSampling::parseEnumDir ( const char *  )
static
static bool TrcKeyZSampling::parseEnumDir ( const char *  ,
Dir  
)
static
static void TrcKeyZSampling::removeInfo ( IOPar )
static
void TrcKeyZSampling::set2DDef ( )

Sets to survey zrange and.

void TrcKeyZSampling::setEmpty ( )
inline
void TrcKeyZSampling::shrinkTo ( const TrcKeyZSampling innertkzs,
float  releps = 1e-4 
)

shrinks "this" tkzs up to but not across innertkzs boundaries. Result will be one step larger than limitTo(.) in case of non-matching steps.

int TrcKeyZSampling::size ( Dir  d) const
void TrcKeyZSampling::snapToSurvey ( )

Checks if it is on valid bids and sample positions. If not, it will expand until it is

static const char* TrcKeyZSampling::toString ( Dir  )
static
int64_t TrcKeyZSampling::totalNr ( ) const
static uiString TrcKeyZSampling::toUiString ( Dir  )
static
int TrcKeyZSampling::trcIdx ( Pos::TraceID  ) const
bool TrcKeyZSampling::usePar ( const IOPar )
float TrcKeyZSampling::zAtIndex ( int  idx) const
int TrcKeyZSampling::zIdx ( float  z) const

Member Data Documentation

ConstPtrMan<EnumDefImpl< Dir > > TrcKeyZSampling::DirDefinition_
staticprotected
const char* TrcKeyZSampling::DirKeys_[]
staticprotected
TrcKeySampling& TrcKeyZSampling::hrg
TrcKeySampling TrcKeyZSampling::hsamp_
StepInterval<float>& TrcKeyZSampling::zrg
StepInterval<float> TrcKeyZSampling::zsamp_

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