#include <TFElementSTD.h>
Inheritance diagram for TFElementBox:
Definition at line 29 of file TFElementSTD.h.
Element Kinds | |
enum | BOX_KIND { RADIAL, SEPARABLE } |
int | getKind () const |
void | setKind (const int kind) |
Position, Size, BBox | |
enum | BOX_ELEMENT_IDS { LL, UR } |
you can use this like : TFElement::getPos(LL) there is also an interface to the elements below More... | |
PosTypeVec | getBBox () const |
PosTypeVec[0] = min, PosTypeVec[1] = max. | |
PosType | getCenter () const |
get center | |
void | setCenter (PosType center) |
set center | |
PosType | getSize () const |
get size | |
void | setSize (PosType size) |
set Size | |
PosType | getMin () const |
get min, same as getPos(LL) | |
void | setMin (PosType ll) |
set Min | |
PosType | getMax () const |
get max, same as getPos(UR) | |
void | setMax (PosType ur) |
set max | |
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 TFElement::PosType | PosType |
scalar type | |
typedef TFElement::PosVecType | PosTypeVec |
typedef TFElement::ValType | ValType |
typedef TFElement::ValVecType | ValTypeVec |
typedef STF::tfSType | SType |
typedef STF::tfDomainVec | PosVecType |
typedef STF::tfRangeVec | ValVecType |
typedef STF::tfVec2 | tfVec2 |
typedef STF::tfRangeVec4 | tfVec4 |
Public Member Functions | |
TFElementBox () | |
construct | |
TFElementBox (const PosType center, const PosType size) | |
virtual | ~TFElementBox () |
virtual TFEltView * | getView (const gutz::vec2i &axes) |
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. | |
virtual ValType | eval (const PosType &pos) const |
not implemented yet | |
ValType | eval (const tfVec2 &tfpos, const gutz::vec2i &posIdx) const |
implementing now | |
virtual void | rasterize2D (NrroSP n, const gutz::vec2i &posIdx, const int kind=STF::TF_RGBA) |
rasterize 2D | |
bool | needRemove () const |
check to see if this element needs to be removed/deleted | |
Protected Member Functions | |
template<class T> void | rasterize2D (Nrro::NrroIter< T > ni) const |
SType | myEval (const SType p2) const |
void | initBox (const PosType center, const PosType size) |
only called by constructor | |
virtual void | updateBox () |
update box | |
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 | |
int | _kind |
gutz::vec2i | _posIdx |
tmp for rasterization | |
STF::tfRangeIdx | _valIdx |
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 from TFElement. Definition at line 31 of file TFElementSTD.h. Referenced by TFElementBox(), and TFView::TFView(). |
|
Definition at line 32 of file TFElementSTD.h. Referenced by getBBox(). |
|
Definition at line 58 of file TFElement.h. Referenced by TFElement::getPosVec(). |
|
Definition at line 56 of file TFElement.h. Referenced by myEval(), and rasterize2D(). |
|
Definition at line 61 of file TFElement.h. Referenced by TFView::TFView(). |
|
Definition at line 62 of file TFElement.h. |
|
Reimplemented from TFElement. Definition at line 33 of file TFElementSTD.h. Referenced by TFElementBox(). |
|
Definition at line 34 of file TFElementSTD.h. |
|
Definition at line 60 of file TFElement.h. Referenced by TFElement::getValVec(). |
|
you can use this like : TFElement::getPos(LL) there is also an interface to the elements below
Definition at line 58 of file TFElementSTD.h. |
|
Definition at line 44 of file TFElementSTD.h. |
|
construct
Definition at line 39 of file TFElementSTD.cpp. References TFElement::_valVec, initBox(), PosType, STF::randval(), and ValType. |
|
Definition at line 46 of file TFElementSTD.cpp. References TFElement::_valVec, initBox(), STF::randval(), size, and ValType. |
|
Definition at line 38 of file TFElementSTD.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_. |
|
|
implementing now
Definition at line 126 of file TFElementSTD.cpp. References _kind, TFElement::_posVec, TFElement::_valVec, STF::ALPHA, gutz::g_min(), height, LL, RADIAL, SEPARABLE, STF::tfSType, UR, width, gutz::vec2< tfSType >::x, and gutz::vec2< tfSType >::y. |
|
not implemented yet
Implements TFElement. Definition at line 81 of file TFElementSTD.h. Referenced by TFView::TFView(). |
|
PosTypeVec[0] = min, PosTypeVec[1] = max.
Definition at line 64 of file TFElementSTD.h. References TFElement::_posVec, and PosTypeVec. |
|
get center
Definition at line 66 of file TFElementSTD.h. References TFElement::_posVec, LL, and UR. Referenced by setCenter(). |
|
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 TFElement::_eval. |
|
Definition at line 48 of file TFElementSTD.h. References _kind. |
|
get max, same as getPos(UR)
Definition at line 75 of file TFElementSTD.h. References TFElement::_posVec, and UR. |
|
Definition at line 158 of file TFElement.h. References TFElement::_posVec, and gutz::vs_max(). |
|
get min, same as getPos(LL)
Definition at line 72 of file TFElementSTD.h. References TFElement::_posVec, and LL. |
|
Definition at line 151 of file TFElement.h. References TFElement::_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 TFElement::_posVec. |
|
Definition at line 141 of file TFElement.h. References TFElement::_posVec. Referenced by TFItem::getTFPosCA(), and TFItem::setTFPosCA(). |
|
Definition at line 139 of file TFElement.h. References TFElement::_posVec, and TFElement::PosVecType. |
|
Definition at line 138 of file TFElement.h. References TFElement::_posVec, and TFElement::PosVecType. Referenced by TFItem::getTFPosCA(), and TFItem::setTFPosCA(). |
|
get size
Definition at line 69 of file TFElementSTD.h. References TFElement::_posVec, LL, and UR. Referenced by setSize(). |
|
Definition at line 174 of file TFElement.h. References TFElement::_valVec, and TFElement::ValVecType. |
|
Definition at line 173 of file TFElement.h. References TFElement::_valVec, and TFElement::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. Implements TFElement. Definition at line 40 of file TFElementSTD.h. |
|
Definition at line 114 of file TFElement.h. References TFElement::_zeroVal. |
|
only called by constructor
Definition at line 56 of file TFElementSTD.cpp. References TFElement::_posVec, and size. Referenced by TFElementBox(). |
|
Definition at line 94 of file TFElementSTD.h. References TFElement::SType. |
|
check to see if this element needs to be removed/deleted
Definition at line 179 of file TFElement.h. References TFElement::_remove. |
|
for each triangle set the current triangle go `till it's completely rasterized Definition at line 199 of file TFElementSTD.cpp. References _posIdx, TFElement::_posVec, _V3, TriRasterInfo< T, TT >::alpha, TriRasterInfo< T, TT >::beta, TriRasterInfo< T, TT >::end(), TriRasterInfo< T, TT >::gamma, TriRasterInfo< T, TT >::getMaxX(), TriRasterInfo< T, TT >::getMinX(), TriRasterInfo< T, TT >::getTri(), TriRasterInfo< T, TT >::incX(), TriRasterInfo< T, TT >::interp2(), LL, TriRasterInfo< T, TT >::maxX, TriRasterInfo< T, TT >::maxY, TriRasterInfo< T, TT >::minX, TriRasterInfo< T, TT >::minY, Triangle< T >::setPoints(), Triangle< T >::setTexCoord(), TriRasterInfo< T, TT >::setTri(), TriRasterInfo< T, TT >::setUp(), TFElement::SType, TFRasterInfo, STF::tfSType, UR, x, TriRasterInfo< T, TT >::x(), y, and TriRasterInfo< T, TT >::y(). |
|
rasterize 2D
Implements TFElement. Definition at line 177 of file TFElementSTD.cpp. References _posIdx, _valIdx, dispatchIter1, n, rasterize2D(), and STF::TF_RGBA. Referenced by rasterize2D(). |
|
unserialize
Reimplemented in SimCore, and VolRenBase. |
|
serialize
Reimplemented in SimCore, and VolRenBase. |
|
set center
Definition at line 69 of file TFElementSTD.cpp. References TFElement::_posVec, getCenter(), LL, and UR. |
|
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 TFElement::_eval. |
|
Definition at line 49 of file TFElementSTD.h. References _kind. |
|
set max
Definition at line 98 of file TFElementSTD.cpp. References TFElement::_posVec, updateBox(), and UR. |
|
set Min
Definition at line 89 of file TFElementSTD.cpp. References TFElement::_posVec, LL, and updateBox(). |
|
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 TFElement::_posVec. Referenced by TFItem::setTFPosCA(). |
|
Definition at line 140 of file TFElement.h. References TFElement::_posVec. |
|
set Size
Definition at line 79 of file TFElementSTD.cpp. References TFElement::_posVec, getSize(), LL, size, and UR. |
|
Definition at line 115 of file TFElement.h. References TFElement::_zeroVal. |
|
update box make sure the max is UR and min is LL Definition at line 107 of file TFElementSTD.cpp. References TFElement::_posVec, LL, and UR. |
|
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 TFElement::getEvaluator(), TFElement::setEvaluator(), and TFElement::TFElement(). |
|
Definition at line 103 of file TFElementSTD.h. |
|
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(). |
|
tmp for rasterization
Definition at line 105 of file TFElementSTD.h. Referenced by rasterize2D(). |
|
Definition at line 203 of file TFElement.h. Referenced by eval(), getBBox(), getCenter(), getMax(), TFElement::getMaxBox(), getMin(), TFElement::getMinBox(), TFElement::getPos(), TFElement::getPosVec(), getSize(), initBox(), rasterize2D(), setCenter(), setMax(), setMin(), TFElement::setPos(), TFElement::setPosVec(), setSize(), and updateBox(). |
|
TFBlend _blend;.
Definition at line 211 of file TFElement.h. Referenced by TFElement::needRemove(), and TFElement::TFElement(). |
|
Definition at line 106 of file TFElementSTD.h. Referenced by rasterize2D(). |
|
Definition at line 204 of file TFElement.h. Referenced by eval(), TFElement::getValVec(), and TFElementBox(). |
|
Definition at line 206 of file TFElement.h. Referenced by TFElement::getZeroVal(), and TFElement::setZeroVal(). |