OpendTect-6_4  6.4
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Static Private Attributes | Friends | List of all members
visBase::DataObject Class Reference

DataObject is the base class off all objects that are used in Visualization and ought to be shared in visBase::DataManager. The DataManager owns all the objects and is thus the only one that is allowed to delete it. The destructors on the inherited classes should thus be protected. More...

Inheritance diagram for visBase::DataObject:
[legend]

Public Member Functions

virtual const char * getClassName () const
 
virtual bool isOK () const
 
int id () const
 
void setID (int nid)
 
uiString name () const
 
virtual void setName (const uiString &)
 
osg::Node * osgNode (bool skipswitch=false)
 
const osg::Node * osgNode (bool skipswitch=false) const
 
void enableTraversal (unsigned int mask, bool yn=true)
 
bool isTraversalEnabled (unsigned int mask) const
 
SoNode * getInventorNode ()
 
const SoNode * getInventorNode () const
 
virtual bool turnOn (bool yn)
 
virtual bool isOn () const
 
bool isPickable (bool actively=true) const
 
void setPickable (bool actively, bool passively=true)
 
virtual bool rightClickable () const
 
virtual bool selectable () const
 
void select () const
 
void deSelect () const
 
void updateSel () const
 
virtual bool isSelected () const
 
virtual NotifierAccessselection ()
 
virtual NotifierAccessdeSelection ()
 
virtual NotifierAccessrightClicked ()
 
virtual const TypeSet< int > * rightClickedPath () const
 
virtual void setDisplayTransformation (const visBase::Transformation *)
 
virtual const visBase::TransformationgetDisplayTransformation () const
 
virtual void setRightHandSystem (bool yn)
 
virtual bool isRightHandSystem () const
 
virtual void setPixelDensity (float dpi)
 
virtual float getPixelDensity () const
 
virtual const char * errMsg () const
 
bool serialize (const char *filename, bool binary=false)
 
void setParent (DataObjectGroup *g)
 
template<class T >
T * addNodeState (T *ns)
 
NodeStateremoveNodeState (NodeState *)
 
NodeStategetNodeState (int idx)
 
- Public Member Functions inherited from CallBacker
 CallBacker ()
 
 CallBacker (const CallBacker &)
 
virtual ~CallBacker ()
 
bool attachCB (NotifierAccess &, const CallBack &, bool onlyifnew=false)
 
bool attachCB (NotifierAccess *notif, const CallBack &cb, bool onlyifnew=false)
 
void detachCB (NotifierAccess &, const CallBack &)
 
void detachCB (NotifierAccess *notif, const CallBack &cb)
 
bool isNotifierAttached (NotifierAccess *) const
 Only for debugging purposes, don't use. More...
 

Static Public Member Functions

static int getID (const osg::Node *)
 
static float getDefaultPixelDensity ()
 
static void setVisualizationThread (const void *)
 Call only once from initialization. More...
 
static bool isVisualizationThread ()
 
static void requestSingleRedraw ()
 
static void setCommonViewer (osgViewer::CompositeViewer *)
 
static osgViewer::CompositeViewer * getCommonViewer ()
 

Protected Member Functions

virtual osg::StateSet * getStateSet ()
 
void doAddNodeState (NodeState *ns)
 
virtual void triggerSel ()
 
virtual void triggerDeSel ()
 
virtual void triggerRightClick (const EventInfo *=0)
 
 DataObject ()
 
template<class T >
T * setOsgNode (T *t)
 Must be called during construction. More...
 
void updateNodemask ()
 
- Protected Member Functions inherited from CallBacker
void detachAllNotifiers ()
 Call from the destructor of your inherited object. More...
 

Protected Attributes

DataObjectGroupparent_
 

Private Member Functions

 mRefCountImpl (DataObject)
 
void setOsgNodeInternal (osg::Node *)
 
void updateOsgNodeData ()
 

Private Attributes

ObjectSet< NodeStatenodestates_
 
osg::Node * osgnode_
 
osg::Switch * osgoffswitch_
 
int id_
 
bool ison_
 
uiString name_
 
unsigned int enabledmask_
 

Static Private Attributes

static const void * visualizationthread_
 
static osgViewer::CompositeViewer * commonviewer_
 

Friends

class SelectionManager
 
class Scene
 

Detailed Description

DataObject is the base class off all objects that are used in Visualization and ought to be shared in visBase::DataManager. The DataManager owns all the objects and is thus the only one that is allowed to delete it. The destructors on the inherited classes should thus be protected.

Constructor & Destructor Documentation

visBase::DataObject::DataObject ( )
protected

Member Function Documentation

template<class T >
T* visBase::DataObject::addNodeState ( T *  ns)
inline
void visBase::DataObject::deSelect ( ) const
virtual NotifierAccess* visBase::DataObject::deSelection ( )
inlinevirtual

Reimplemented in visBase::VisualObject.

void visBase::DataObject::doAddNodeState ( NodeState ns)
protected
void visBase::DataObject::enableTraversal ( unsigned int  mask,
bool  yn = true 
)
virtual const char* visBase::DataObject::errMsg ( ) const
inlinevirtual
virtual const char* visBase::DataObject::getClassName ( ) const
inlinevirtual
static osgViewer::CompositeViewer* visBase::DataObject::getCommonViewer ( )
static
static float visBase::DataObject::getDefaultPixelDensity ( )
static
virtual const visBase::Transformation* visBase::DataObject::getDisplayTransformation ( ) const
inlinevirtual
static int visBase::DataObject::getID ( const osg::Node *  )
static
SoNode* visBase::DataObject::getInventorNode ( )
inline
const SoNode* visBase::DataObject::getInventorNode ( ) const
inline
NodeState* visBase::DataObject::getNodeState ( int  idx)
virtual float visBase::DataObject::getPixelDensity ( ) const
virtual
virtual osg::StateSet* visBase::DataObject::getStateSet ( )
protectedvirtual
int visBase::DataObject::id ( ) const
inline
virtual bool visBase::DataObject::isOK ( ) const
inlinevirtual
virtual bool visBase::DataObject::isOn ( ) const
virtual
bool visBase::DataObject::isPickable ( bool  actively = true) const
virtual bool visBase::DataObject::isRightHandSystem ( ) const
inlinevirtual
virtual bool visBase::DataObject::isSelected ( ) const
virtual
bool visBase::DataObject::isTraversalEnabled ( unsigned int  mask) const
static bool visBase::DataObject::isVisualizationThread ( )
static
visBase::DataObject::mRefCountImpl ( DataObject  )
private
uiString visBase::DataObject::name ( ) const
osg::Node* visBase::DataObject::osgNode ( bool  skipswitch = false)
const osg::Node* visBase::DataObject::osgNode ( bool  skipswitch = false) const
NodeState* visBase::DataObject::removeNodeState ( NodeState )
static void visBase::DataObject::requestSingleRedraw ( )
static
virtual bool visBase::DataObject::rightClickable ( ) const
inlinevirtual
virtual NotifierAccess* visBase::DataObject::rightClicked ( )
inlinevirtual
virtual const TypeSet<int>* visBase::DataObject::rightClickedPath ( ) const
inlinevirtual
void visBase::DataObject::select ( ) const
virtual bool visBase::DataObject::selectable ( ) const
inlinevirtual
virtual NotifierAccess* visBase::DataObject::selection ( )
inlinevirtual

Reimplemented in visBase::VisualObject.

bool visBase::DataObject::serialize ( const char *  filename,
bool  binary = false 
)
static void visBase::DataObject::setCommonViewer ( osgViewer::CompositeViewer *  )
static
virtual void visBase::DataObject::setDisplayTransformation ( const visBase::Transformation )
virtual
void visBase::DataObject::setID ( int  nid)
virtual void visBase::DataObject::setName ( const uiString )
virtual

Reimplemented in visBase::Scene.

template<class T >
T* visBase::DataObject::setOsgNode ( T *  t)
inlineprotected

Must be called during construction.

void visBase::DataObject::setOsgNodeInternal ( osg::Node *  )
private
void visBase::DataObject::setParent ( DataObjectGroup g)
inline
void visBase::DataObject::setPickable ( bool  actively,
bool  passively = true 
)

actively: mouse click/drag, key press, etc. passively: hovering (e.g. status info)

virtual void visBase::DataObject::setPixelDensity ( float  dpi)
virtual
virtual void visBase::DataObject::setRightHandSystem ( bool  yn)
inlinevirtual
static void visBase::DataObject::setVisualizationThread ( const void *  )
static

Call only once from initialization.

virtual void visBase::DataObject::triggerDeSel ( )
inlineprotectedvirtual

Is called everytime object is deselected.

Reimplemented in visSurvey::MPEDisplay, visSurvey::LocationDisplay, and visBase::VisualObject.

virtual void visBase::DataObject::triggerRightClick ( const EventInfo = 0)
inlineprotectedvirtual
virtual void visBase::DataObject::triggerSel ( )
inlineprotectedvirtual

Is called everytime object is selected.

Reimplemented in visSurvey::MPEDisplay, and visBase::VisualObject.

virtual bool visBase::DataObject::turnOn ( bool  yn)
virtual
void visBase::DataObject::updateNodemask ( )
protected
void visBase::DataObject::updateOsgNodeData ( )
private
void visBase::DataObject::updateSel ( ) const

Friends And Related Function Documentation

friend class Scene
friend
friend class SelectionManager
friend

Member Data Documentation

osgViewer::CompositeViewer* visBase::DataObject::commonviewer_
staticprivate
unsigned int visBase::DataObject::enabledmask_
private
int visBase::DataObject::id_
private
bool visBase::DataObject::ison_
private
uiString visBase::DataObject::name_
private
ObjectSet<NodeState> visBase::DataObject::nodestates_
private
osg::Node* visBase::DataObject::osgnode_
private
osg::Switch* visBase::DataObject::osgoffswitch_
private
DataObjectGroup* visBase::DataObject::parent_
protected
const void* visBase::DataObject::visualizationthread_
staticprivate

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