#include <TFElement.h>
Inheritance diagram for TFElement:
see below for a double indirection element (so they can change types and you can track changes to them) TFEltSP
For Collaboration with TFGeneric
See also: TFEltView, TFElementBox, TFParams.h, TFViewWidget, TFSurfaceWidget
Definition at line 49 of file TFElement.h.
Views, 2D projections | |
virtual TFEltView * | getView (const gutz::vec2i &axes)=0 |
get view, returns View interface, each concrete TFElement should have an associated view object than handles the collaboration between 2D manipulations and the full ND representation of the Element. | |
Evaluate | |
virtual ValType | eval (const PosType &tfpos) const=0 |
evaluate at generic position | |
Zero Val | |
The "Zero Val" is the value for "unclassified regions" this may or may not actually be zero, so you may need to change what that value is.
The zero value defaults to tfRangeType_default | |
ValType | getZeroVal () const |
void | setZeroVal (const ValType &zv) |
evaluator strategies Depricated? | |
TFEvalSP | getEvaluator () const |
void | setEvaluator (TFEvalSP e) |
Domain/Position | |
all of the "nodes" associated with this element, ie, verticies of polytope in tf domain | |
PosVecType & | getPosVec () |
PosVecType | getPosVec () const |
void | setPosVec (PosVecType &pv) |
PosType & | getPos (int i) |
PosType | getPos (int i) const |
void | setPos (int i, PosType p) |
domain bounding box | |
you can override these for speed!! should we recompute on every call?? very slow! maybe you can cache this in a subclass. | |
virtual PosType | getMinBox () const |
virtual PosType | getMaxBox () const |
Range/Value | |
all of the values associated with each node, if vec::size() == 1 then the element has a global definition of range. | |
ValVecType & | getValVec () |
ValVecType | getValVec () const |
Text object-name | |
from SimBase | |
std::string | getObjName () |
std::string | getName () |
void | setName (std::string name) |
void | setName (const char *name) |
Debug prints | |
from SimBase: These print the object name with the error, mostly for convenience, but they are compiled to inline-no-op if you build in release mode | |
void | derr (const char *when, const char *where=0) const |
template<class T> void | derr (const char *when, const char *where, const T stuff) const |
Modification, AKA "changed" | |
from SimBase: id based, you can capture the current id for comparison later, if the id's don't match the class has been changed | |
virtual int | getChangeID () |
virtual int | getChangeID () const |
virtual void | setChanged () |
Serialization: | |
from SimBase You MUST override these pure virtual functions, they "should" do something usefull. It is also nice if you declare a static std::istream &create(std::istream &is) const; function, to create a class from a stream. This is done on a per-concrete class basis.
These aren't pure virutal yet, but will be soon! | |
virtual std::ostream & | saveSelf (std::ostream &os) |
serialize | |
virtual std::istream & | readSelf (std::istream &is) |
unserialize | |
Public Types | |
typedef STF::tfSType | SType |
typedef STF::tfDomainType | PosType |
scalar type | |
typedef STF::tfDomainVec | PosVecType |
typedef STF::tfRangeType | ValType |
typedef STF::tfRangeVec | ValVecType |
typedef STF::tfVec2 | tfVec2 |
typedef STF::tfRangeVec4 | tfVec4 |
Public Member Functions | |
virtual | ~TFElement () |
bool | needRemove () const |
check to see if this element needs to be removed/deleted | |
virtual void | rasterize2D (NrroSP n, const gutz::vec2i &posIdx, const int kind=STF::TF_RGBA)=0 |
rasterize this element into an image. | |
Protected Member Functions | |
TFElement () | |
a generic rasterization algorithm the index vector allows you to rearrange and select which values from the domain are rasterized into the 2D image map (ni). | |
virtual void | _incCount () |
gutz::Counted interface, increment reference count by one. | |
virtual void | _decCount () |
gutz::Counted interface, decrement reference count by one. | |
virtual int | _getCount () const |
gutz::Counted interface, get the current reference count. | |
Protected Attributes | |
PosVecType | _posVec |
ValVecType | _valVec |
ValType | _zeroVal |
TFEvalSP | _eval |
bool | _remove |
TFBlend _blend;. | |
std::string | _name_ |
a text name for the object, SimBase | |
int | _changed |
change id, incremented whenever setChanged is called, SimBase | |
Friends | |
class | SmartPtr |
class | SmartPtrRef |
|
scalar type
Reimplemented in TFElementBox. Definition at line 57 of file TFElement.h. |
|
Definition at line 58 of file TFElement.h. Referenced by getPosVec(). |
|
Definition at line 56 of file TFElement.h. Referenced by TFElementBox::myEval(), and TFElementBox::rasterize2D(). |
|
Definition at line 61 of file TFElement.h. Referenced by TFView::TFView(). |
|
Definition at line 62 of file TFElement.h. |
|
Reimplemented in TFElementBox. Definition at line 59 of file TFElement.h. |
|
Definition at line 60 of file TFElement.h. Referenced by getValVec(). |
|
Definition at line 54 of file TFElement.h. |
|
a generic rasterization algorithm the index vector allows you to rearrange and select which values from the domain are rasterized into the 2D image map (ni). defined in "TFRasterize.cpp", see for more details. Definition at line 201 of file TFElement.h. |
|
gutz::Counted interface, decrement reference count by one. Not generaly used by subclasses, mostly for collaboration with gutz::SmartPtr. Sometimes you need to call this though, see the documentation for gutz::SmartPtr Definition at line 54 of file smartptr.h. Referenced by TFImage::clear(), NrroImage::fBlendOverRGBA(), and Nrro::updateMinMax(). |
|
gutz::Counted interface, get the current reference count. Not generaly used by subclasses, mostly for collaboration with gutz::SmartPtr. Definition at line 58 of file smartptr.h. |
|
gutz::Counted interface, increment reference count by one. Not generaly used by subclasses, mostly for collaboration with gutz::SmartPtr. Sometimes you need to call this though, see the documentation for gutz::SmartPtr Definition at line 48 of file smartptr.h. Referenced by TFImage::clear(), NrroImage::fBlendOverRGBA(), and Nrro::updateMinMax(). |
|
only prints in debug mode, -D_DEBUG Definition at line 130 of file simBase.h. References SimBase::_name_. |
|
|
evaluate at generic position
Implemented in TFElementBox. |
|
Definition at line 73 of file simBase.h. References SimBase::_changed. |
|
Reimplemented in TFGeneric, TFBaseSP, and TFEltSP. Definition at line 72 of file simBase.h. References SimBase::_changed. Referenced by TFEltSP::getChangeID(), TFBaseSP::getChangeID(), and TFGeneric::getChangeID(). |
|
Definition at line 121 of file TFElement.h. References _eval. |
|
Definition at line 158 of file TFElement.h. References _posVec, and gutz::vs_max(). |
|
Definition at line 151 of file TFElement.h. References _posVec, and gutz::vs_min(). |
|
Definition at line 45 of file simBase.h. References SimBase::_name_. Referenced by MetaProg::operator<<(). |
|
Definition at line 44 of file simBase.h. References string. |
|
Definition at line 142 of file TFElement.h. References _posVec. |
|
Definition at line 141 of file TFElement.h. References _posVec. Referenced by TFItem::getTFPosCA(), and TFItem::setTFPosCA(). |
|
Definition at line 139 of file TFElement.h. References _posVec, and PosVecType. |
|
Definition at line 138 of file TFElement.h. References _posVec, and PosVecType. Referenced by TFItem::getTFPosCA(), and TFItem::setTFPosCA(). |
|
Definition at line 174 of file TFElement.h. References _valVec, and ValVecType. |
|
Definition at line 173 of file TFElement.h. References _valVec, and ValVecType. |
|
get view, returns View interface, each concrete TFElement should have an associated view object than handles the collaboration between 2D manipulations and the full ND representation of the Element. see TFEltView for the interface spec. Implemented in TFElementBox. |
|
Definition at line 114 of file TFElement.h. References _zeroVal. |
|
check to see if this element needs to be removed/deleted
Definition at line 179 of file TFElement.h. References _remove. |
|
rasterize this element into an image. For now, the image must have 4 channels Implemented in TFElementBox. |
|
unserialize
Reimplemented in SimCore, and VolRenBase. |
|
serialize
Reimplemented in SimCore, and VolRenBase. |
|
Definition at line 74 of file simBase.h. References SimBase::_changed. Referenced by TFEltSP::getChangeID(), TFBaseSP::getChangeID(), TFBaseSP::operator=(), and TFGeneric::update(). |
|
Definition at line 122 of file TFElement.h. References _eval. |
|
Definition at line 47 of file simBase.h. References SimBase::_name_, and name. |
|
Reimplemented in Key. Definition at line 46 of file simBase.h. References SimBase::_name_, and name. Referenced by EventData::EventData(), and GenDataObj_base< Nrro, gutz::SmartPtr< Nrro > >::GenDataObj_base(). |
|
Definition at line 143 of file TFElement.h. References _posVec. Referenced by TFItem::setTFPosCA(). |
|
Definition at line 140 of file TFElement.h. References _posVec. |
|
Definition at line 115 of file TFElement.h. References _zeroVal. |
|
Definition at line 40 of file smartptr.h. Referenced by Nrro::NrroIter< T >::NrroIter(). |
|
Definition at line 41 of file smartptr.h. |
|
change id, incremented whenever setChanged is called, SimBase
Definition at line 103 of file simBase.h. Referenced by SimBase::getChangeID(), SimBase::setChanged(), and SimBase::SimBase(). |
|
Definition at line 208 of file TFElement.h. Referenced by getEvaluator(), setEvaluator(), and TFElement(). |
|
a text name for the object, SimBase
Definition at line 101 of file simBase.h. Referenced by SimBase::derr(), SimBase::getName(), SimBase::setName(), and SimBase::SimBase(). |
|
|
TFBlend _blend;.
Definition at line 211 of file TFElement.h. Referenced by needRemove(), and TFElement(). |
|
Definition at line 204 of file TFElement.h. Referenced by TFElementBox::eval(), getValVec(), and TFElementBox::TFElementBox(). |
|
Definition at line 206 of file TFElement.h. Referenced by getZeroVal(), and setZeroVal(). |