OpendTect
6.6
|
Set of data points with group selection. More...
Classes | |
class | DataRow |
Data point with group. Group 0 means 'inactive', it can never be selected. More... | |
class | Pos |
Real Coord3D-position storable in BinIDValueSet + trc nr. More... | |
Public Types | |
typedef int | ColID |
typedef int | RowID |
Public Types inherited from DataPack | |
typedef MultiID | FullID |
typedef int | ID |
Public Types inherited from ObjectWithName | |
typedef OD::String | name_type |
Public Member Functions | |
DataPointSet (bool is2d, bool minimal=false) | |
DataPointSet (const DataPointSet &) | |
DataPointSet (const DataPointSet &, const ::Pos::Filter &) | |
DataPointSet (const PosVecDataSet &, bool is2d, bool minimal=false) | |
DataPointSet (const TypeSet< DataRow > &, const BufferStringSet &valnms, bool is2d, bool minimal=false) | |
DataPointSet (const TypeSet< DataRow > &, const ObjectSet< DataColDef > &, bool is2d, bool minimal=false) | |
virtual | ~DataPointSet () |
void | addCol (const char *nm, const char *ref=0, const UnitOfMeasure *un=0) |
or use dataSet() to add columns More... | |
void | addRow (const DataRow &) |
When finished, you have to call dataChanged() More... | |
BinID | binID (RowID) const |
BinIDValueSet & | bivSet () |
const BinIDValueSet & | bivSet () const |
int | bivSetIdx (ColID idx) const |
BinIDValueSet::SPos | bvsPos (RowID rid) const |
void | clearData () |
Keeps structure. More... | |
DataColDef & | colDef (ColID i) |
const DataColDef & | colDef (ColID i) const |
const char * | colName (ColID) const |
Coord | coord (RowID) const |
void | dataChanged () |
DataRow | dataRow (RowID) const |
PosVecDataSet & | dataSet () |
const PosVecDataSet & | dataSet () const |
void | dumpInfo (IOPar &) const |
bool | extractPositions (::Pos::Provider &, const ObjectSet< DataColDef > &, const ::Pos::Filter *f=0, TaskRunner *tr=0, bool filterAccept=true) |
RowID | find (const Pos &) const |
RowID | find (const Pos &, float horradius, float deltaz) const |
RowID | findFirst (const BinID &) const |
RowID | findFirst (const Coord &) const |
bool | getRange (TrcKeyZSampling &) const |
RowID | getRowID (BinIDValueSet::SPos) const |
DataPointSet * | getSubselected (int maxsz, const TypeSet< int > *selected_cols=0, bool allow_udf_values=true, const ObjectSet< Interval< float > > *value_ranges=0) const |
float * | getValues (RowID) |
const float * | getValues (RowID) const |
unsigned short | group (RowID) const |
ColID | indexOf (const char *) const |
bool | is2D () const |
bool | isEmpty () const |
bool | isInactive (RowID rid) const |
bool | isMinimal () const |
bool | isSelected (RowID) const |
int | nrActive () const |
int | nrCols () const |
int | nrFixedCols () const |
float | nrKBytes () const |
DataPointSet & | operator= (const DataPointSet &) |
Pos | pos (RowID) const |
void | purgeInactive () |
void | purgeSelected (bool selected_rows=true) |
void | randomSubselect (int maxsz) |
int | selGroup (RowID) const |
void | setEmpty () |
void | setGroup (RowID, unsigned short) |
void | setInactive (RowID, bool) |
bool | setRow (const DataRow &) |
void | setSelected (RowID, int selgrp) |
bool | setValue (ColID, RowID, float) |
bool | simpleCoords () const |
If true, coords are always SI().tranform(b) More... | |
int | size () const |
int | trcNr (RowID) const |
const UnitOfMeasure * | unit (ColID) const |
bool | validColID (ColID) const |
float | value (ColID, RowID) const |
float | z (RowID) const |
Public Member Functions inherited from PointDataPack | |
virtual bool | isOrdered () const |
If yes, one can draw a line between the pts. More... | |
Public Member Functions inherited from DataPack | |
DataPack (const char *categry) | |
DataPack (const DataPack &) | |
virtual | ~DataPack () |
virtual const char * | category () const |
FullID | fullID (int mgrid) const |
ID | id () const |
virtual bool | isOK () const |
DataPack * | obtain () |
void | release () |
Threads::Lock & | updateLock () const |
Public Member Functions inherited from NamedCallBacker | |
NamedCallBacker (const char *nm=0) | |
NamedCallBacker (const NamedCallBacker &) | |
virtual Notifier< NamedCallBacker > & | objectToBeDeleted () const |
bool | operator== (const NamedCallBacker &oth) const |
bool | operator== (const NamedObject &oth) const |
Public Member Functions inherited from CallBacker | |
CallBacker () | |
CallBacker (const CallBacker &) | |
virtual | ~CallBacker () |
bool | attachCB (const NotifierAccess &, const CallBack &, bool onlyifnew=false) const |
bool | attachCB (const NotifierAccess *notif, const CallBack &cb, bool onlyifnew=false) const |
void | detachAllNotifiers () const |
Call from the destructor of your inherited object. More... | |
void | detachCB (const NotifierAccess &, const CallBack &) const |
void | detachCB (const NotifierAccess *notif, const CallBack &cb) const |
virtual bool | isCapsule () const |
bool | isNotifierAttached (const NotifierAccess *) const |
Only for debugging purposes, don't use. More... | |
void | stopReceivingNotifications () const |
Public Member Functions inherited from NamedObject | |
NamedObject (const char *nm=nullptr) | |
NamedObject (const NamedObject &oth) | |
virtual | ~NamedObject () |
virtual BufferString | getName () const |
bool | getNameFromPar (const IOPar &) |
virtual const name_type & | name () const |
NamedObject & | operator= (const NamedObject &) |
bool | operator== (const NamedObject &oth) const |
virtual void | setName (const char *nm) |
Public Member Functions inherited from ObjectWithName | |
virtual | ~ObjectWithName () |
bool | hasName (const char *nm) const |
bool | hasName (const name_type &nm) const |
void | putNameInPar (IOPar &) const |
Protected Member Functions | |
void | calcIdxs () |
DataColDef & | gtColDef (ColID) const |
void | init (const TypeSet< DataRow > &, const ObjectSet< DataColDef > &) |
void | initPVDS () |
Protected Member Functions inherited from PointDataPack | |
PointDataPack (const char *categry) | |
Protected Member Functions inherited from DataPack | |
void | setCategory (const char *c) |
void | setManager (const DataPackMgr *) |
Protected Member Functions inherited from NamedCallBacker | |
void | sendDelNotif () const |
Protected Attributes | |
TypeSet< BinIDValueSet::SPos > | bvsidxs_ |
PosVecDataSet & | data_ |
bool | is2d_ |
bool | minimal_ |
const int | nrfixedcols_ |
Protected Attributes inherited from DataPack | |
const BufferString | category_ |
const ID | id_ |
const DataPackMgr * | manager_ |
int | nrusers_ |
Threads::Lock | nruserslock_ |
Threads::Lock | updatelock_ |
Protected Attributes inherited from NamedCallBacker | |
Threads::Atomic< bool > | delalreadytriggered_ |
Notifier< NamedCallBacker > | delnotif_ |
Protected Attributes inherited from NamedObject | |
BufferString | name_ |
Static Protected Attributes | |
static const int | groupcol_ |
Additional Inherited Members | |
Static Public Member Functions inherited from DataPack | |
static ID | cNoID () |
static ID | cUdfID () |
static ID | getID (const FullID &fid) |
static Notifier< DataPack > & | instanceCreated () |
static const char * | sKeyCategory () |
Static Public Member Functions inherited from CallBacker | |
static void | createReceiverForCurrentThread () |
static void | removeReceiverForCurrentThread () |
Static Protected Member Functions inherited from DataPack | |
static ID | getNewID () |
ensures a global data pack ID More... | |
static float | sKb2MbFac () |
1 / 1024 More... | |
Set of data points with group selection.
The idea is to generate a set of data points, which are then put in different groups. The data is transferred into a BinIDValueSet for performance, but a fixed int addressing becomes available.
The design is based on the model that you extract data in some way which should then be quickly accessible. The data set is not meant to be manipulated other than via setSelected() and setGroup().
For data associated with 2D seismics, you can specify that the DataPointSet needs to be 2D; then also 'trcNr() can be used.
For large sets, you may not be interested in precise X and Y, and grouping/selection. Then specify the 'minimal' flag on construction.
<>
typedef int DataPointSet::ColID |
typedef int DataPointSet::RowID |
DataPointSet::DataPointSet | ( | const TypeSet< DataRow > & | , |
const ObjectSet< DataColDef > & | , | ||
bool | is2d, | ||
bool | minimal = false |
||
) |
DataPointSet::DataPointSet | ( | const TypeSet< DataRow > & | , |
const BufferStringSet & | valnms, | ||
bool | is2d, | ||
bool | minimal = false |
||
) |
DataPointSet::DataPointSet | ( | const PosVecDataSet & | , |
bool | is2d, | ||
bool | minimal = false |
||
) |
DataPointSet::DataPointSet | ( | const DataPointSet & | , |
const ::Pos::Filter & | |||
) |
DataPointSet::DataPointSet | ( | const DataPointSet & | ) |
|
virtual |
DataPointSet::DataPointSet | ( | bool | is2d, |
bool | minimal = false |
||
) |
void DataPointSet::addCol | ( | const char * | nm, |
const char * | ref = 0 , |
||
const UnitOfMeasure * | un = 0 |
||
) |
or use dataSet() to add columns
void DataPointSet::addRow | ( | const DataRow & | ) |
When finished, you have to call dataChanged()
Implements PointDataPack.
BinIDValueSet& DataPointSet::bivSet | ( | ) |
The idea is to manage vectors with the selection mechanism. But if you really must remove vectors, this may be your access point
|
inline |
|
inline |
|
inline |
|
protected |
void DataPointSet::clearData | ( | ) |
Keeps structure.
|
inline |
|
inline |
const char* DataPointSet::colName | ( | ColID | ) | const |
Reimplemented from PointDataPack.
|
inline |
When data modified, you want to call this. all RowIDs may change In case you want to change the definition of a col
|
inline |
To add/remove columns. Never remove the position columns!
|
inline |
bool DataPointSet::extractPositions | ( | ::Pos::Provider & | , |
const ObjectSet< DataColDef > & | , | ||
const ::Pos::Filter * | f = 0 , |
||
TaskRunner * | tr = 0 , |
||
bool | filterAccept = true |
||
) |
bool DataPointSet::getRange | ( | TrcKeyZSampling & | ) | const |
RowID DataPointSet::getRowID | ( | BinIDValueSet::SPos | ) | const |
DataPointSet* DataPointSet::getSubselected | ( | int | maxsz, |
const TypeSet< int > * | selected_cols = 0 , |
||
bool | allow_udf_values = true , |
||
const ObjectSet< Interval< float > > * | value_ranges = 0 |
||
) | const |
float* DataPointSet::getValues | ( | RowID | ) |
const float* DataPointSet::getValues | ( | RowID | ) | const |
unsigned short DataPointSet::group | ( | RowID | ) | const |
|
protected |
ColID DataPointSet::indexOf | ( | const char * | ) | const |
|
protected |
|
protected |
|
inline |
|
inline |
|
inline |
|
inline |
bool DataPointSet::isSelected | ( | RowID | ) | const |
int DataPointSet::nrActive | ( | ) | const |
int DataPointSet::nrCols | ( | ) | const |
|
inline |
|
virtual |
Implements DataPack.
DataPointSet& DataPointSet::operator= | ( | const DataPointSet & | ) |
void DataPointSet::purgeInactive | ( | ) |
void DataPointSet::purgeSelected | ( | bool | selected_rows = true | ) |
void DataPointSet::randomSubselect | ( | int | maxsz | ) |
int DataPointSet::selGroup | ( | RowID | ) | const |
void DataPointSet::setEmpty | ( | ) |
void DataPointSet::setGroup | ( | RowID | , |
unsigned short | |||
) |
void DataPointSet::setInactive | ( | RowID | , |
bool | |||
) |
bool DataPointSet::setRow | ( | const DataRow & | ) |
Can be add or change Returns whether it's an add (see addRow)
void DataPointSet::setSelected | ( | RowID | , |
int | selgrp | ||
) |
|
inlinevirtual |
If true, coords are always SI().tranform(b)
Reimplemented from PointDataPack.
|
inlinevirtual |
Implements PointDataPack.
|
virtual |
Reimplemented from PointDataPack.
const UnitOfMeasure* DataPointSet::unit | ( | ColID | ) | const |
bool DataPointSet::validColID | ( | ColID | ) | const |
|
virtual |
Implements PointDataPack.
|
protected |
|
protected |
|
staticprotected |
|
protected |
|
protected |
|
protected |
Generated at for the OpendTect seismic interpretation project. Copyright (C): dGB Beheer B.V. 1995-2022