Property
Go to the documentation of this file.
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2009 Robert Osfield
*
* This library is open source and may be redistributed and/or modified under
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
* (at your option) any later version. The full license is in LICENSE file
* included with this distribution, and on the openscenegraph.org website.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* OpenSceneGraph Public License for more details.
*/
#ifndef OSGVOLUME_PROPERTY
#define OSGVOLUME_PROPERTY 1
#include <osg/TransferFunction>
#include <osg/Uniform>
#include <osg/AlphaFunc>
#include <osgGA/GUIEventHandler>
#include <osgVolume/Export>
namespace osgVolume {
// forward decarle
class Property;
class CompositeProperty;
class SwitchProperty;
class TransferFunctionProperty;
class ScalarProperty;
class IsoSurfaceProperty;
class MaximumIntensityProjectionProperty;
class LightingProperty;
class AlphaFuncProperty;
class SampleRatioProperty;
class SampleRatioWhenMovingProperty;
class SampleDensityProperty;
class SampleDensityWhenMovingProperty;
class TransparencyProperty;
class ExteriorTransparencyFactorProperty;
class VolumeSettings;
class OSGVOLUME_EXPORT PropertyVisitor
{
public:
PropertyVisitor(bool traverseOnlyActiveChildren=true);
virtual ~PropertyVisitor() {}
virtual void apply(Property&);
virtual void apply(CompositeProperty&);
virtual void apply(SwitchProperty&);
virtual void apply(TransferFunctionProperty&);
virtual void apply(ScalarProperty&);
virtual void apply(IsoSurfaceProperty&);
virtual void apply(AlphaFuncProperty&);
virtual void apply(MaximumIntensityProjectionProperty&);
virtual void apply(LightingProperty&);
virtual void apply(SampleRatioProperty&);
virtual void apply(SampleRatioWhenMovingProperty&);
virtual void apply(SampleDensityProperty&);
virtual void apply(SampleDensityWhenMovingProperty&);
virtual void apply(TransparencyProperty&);
virtual void apply(ExteriorTransparencyFactorProperty&);
virtual void apply(VolumeSettings&);
bool _traverseOnlyActiveChildren;
};
class OSGVOLUME_EXPORT Property : public osg::Object
{
public:
Property();
Property(const Property&,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, Property);
void dirty() { ++_modifiedCount; }
void setModifiedCount(unsigned int c) { _modifiedCount = c; }
unsigned int getModifiedCount() const { return _modifiedCount; }
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
virtual void traverse(PropertyVisitor& /*pv*/) {}
protected:
virtual ~Property();
unsigned int _modifiedCount;
};
class OSGVOLUME_EXPORT CompositeProperty : public Property
{
public:
CompositeProperty();
CompositeProperty(const CompositeProperty& compositeProperty,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, CompositeProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
virtual void traverse(PropertyVisitor& pv)
{
for(Properties::iterator itr = _properties.begin();
itr != _properties.end();
++itr)
{
(*itr)->accept(pv);
}
}
void clear();
typedef std::vector< osg::ref_ptr<Property> > Properties;
void setProperty(unsigned int i, Property* property) { if (i>=_properties.size()) _properties.resize(i+1); _properties[i] = property; }
template<class T> void setProperty(unsigned int i, const osg::ref_ptr<T>& p) { setProperty(i, p.get()); }
Property* getProperty(unsigned int i) { return i<_properties.size() ? _properties[i].get() : 0; }
const Property* getProperty(unsigned int i) const { return i<_properties.size() ? _properties[i].get() : 0; }
void addProperty(Property* property) { _properties.push_back(property); dirty(); }
template<class T> void addProperty(const osg::ref_ptr<T>& p) { addProperty(p.get()); }
void removeProperty(unsigned int i) { _properties.erase(_properties.begin()+i); }
unsigned int getNumProperties() const { return _properties.size(); }
protected:
virtual ~CompositeProperty() {}
Properties _properties;
};
class OSGVOLUME_EXPORT SwitchProperty : public CompositeProperty
{
public:
SwitchProperty();
SwitchProperty(const SwitchProperty& switchProperty,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, SwitchProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
virtual void traverse(PropertyVisitor& pv)
{
if (pv._traverseOnlyActiveChildren)
{
if (_activeProperty>=0 && static_cast<unsigned int>(_activeProperty)<=getNumProperties())
{
_properties[_activeProperty]->accept(pv);
}
}
else
{
CompositeProperty::traverse(pv);
}
}
void setActiveProperty(int i) { _activeProperty = i; dirty(); }
int getActiveProperty() const { return _activeProperty; }
protected:
virtual ~SwitchProperty() {}
int _activeProperty;
};
class OSGVOLUME_EXPORT TransferFunctionProperty : public Property
{
public:
TransferFunctionProperty(osg::TransferFunction* tf = 0);
TransferFunctionProperty(const TransferFunctionProperty& tfp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, TransferFunctionProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
void setTransferFunction(osg::TransferFunction* tf) { _tf = tf; }
osg::TransferFunction* getTransferFunction() { return _tf.get(); }
const osg::TransferFunction* getTransferFunction() const { return _tf.get(); }
protected:
virtual ~TransferFunctionProperty() {}
osg::ref_ptr<osg::TransferFunction> _tf;
};
class OSGVOLUME_EXPORT ScalarProperty : public Property
{
public:
ScalarProperty(const std::string& scaleName, float value);
ScalarProperty(const ScalarProperty& scalarProperty,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, ScalarProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
virtual void setValue(float v) { _uniform->set(v); dirty(); }
float getValue() const { float v; _uniform->get(v); return v; }
osg::Uniform* getUniform() { return _uniform.get(); }
const osg::Uniform* getUniform() const { return _uniform.get(); }
protected:
virtual ~ScalarProperty() {}
ScalarProperty();
osg::ref_ptr<osg::Uniform> _uniform;
};
class OSGVOLUME_EXPORT IsoSurfaceProperty : public ScalarProperty
{
public:
IsoSurfaceProperty(float value=1.0f);
IsoSurfaceProperty(const IsoSurfaceProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, IsoSurfaceProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~IsoSurfaceProperty() {}
};
class OSGVOLUME_EXPORT AlphaFuncProperty : public ScalarProperty
{
public:
AlphaFuncProperty(float value=1.0f);
AlphaFuncProperty(const AlphaFuncProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, AlphaFuncProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
virtual void setValue(float v);
osg::AlphaFunc* getAlphaFunc() { return _alphaFunc.get(); }
const osg::AlphaFunc* getAlphaFunc() const { return _alphaFunc.get(); }
protected:
virtual ~AlphaFuncProperty() {}
osg::ref_ptr<osg::AlphaFunc> _alphaFunc;
};
class OSGVOLUME_EXPORT MaximumIntensityProjectionProperty : public Property
{
public:
MaximumIntensityProjectionProperty();
MaximumIntensityProjectionProperty(const MaximumIntensityProjectionProperty& mipp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, MaximumIntensityProjectionProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~MaximumIntensityProjectionProperty() {}
};
class OSGVOLUME_EXPORT LightingProperty : public Property
{
public:
LightingProperty();
LightingProperty(const LightingProperty& mipp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, LightingProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~LightingProperty() {}
};
class OSGVOLUME_EXPORT SampleDensityProperty : public ScalarProperty
{
public:
SampleDensityProperty(float value=1.0f);
SampleDensityProperty(const SampleDensityProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, SampleDensityProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~SampleDensityProperty() {}
};
class OSGVOLUME_EXPORT SampleDensityWhenMovingProperty : public ScalarProperty
{
public:
SampleDensityWhenMovingProperty(float value=1.0f);
SampleDensityWhenMovingProperty(const SampleDensityWhenMovingProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, SampleDensityWhenMovingProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~SampleDensityWhenMovingProperty() {}
};
class OSGVOLUME_EXPORT SampleRatioProperty : public ScalarProperty
{
public:
SampleRatioProperty(float value=1.0f);
SampleRatioProperty(const SampleRatioProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, SampleRatioProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~SampleRatioProperty() {}
};
class OSGVOLUME_EXPORT SampleRatioWhenMovingProperty : public ScalarProperty
{
public:
SampleRatioWhenMovingProperty(float value=1.0f);
SampleRatioWhenMovingProperty(const SampleRatioWhenMovingProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, SampleRatioWhenMovingProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~SampleRatioWhenMovingProperty() {}
};
class OSGVOLUME_EXPORT TransparencyProperty : public ScalarProperty
{
public:
TransparencyProperty(float value=1.0f);
TransparencyProperty(const TransparencyProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, TransparencyProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~TransparencyProperty() {}
};
class OSGVOLUME_EXPORT ExteriorTransparencyFactorProperty : public ScalarProperty
{
public:
ExteriorTransparencyFactorProperty(float value=0.0f);
ExteriorTransparencyFactorProperty(const ExteriorTransparencyFactorProperty& isp,const osg::CopyOp& copyop=osg::CopyOp::SHALLOW_COPY);
META_Object(osgVolume, ExteriorTransparencyFactorProperty);
virtual void accept(PropertyVisitor& pv) { pv.apply(*this); }
protected:
virtual ~ExteriorTransparencyFactorProperty() {}
};
class OSGVOLUME_EXPORT CollectPropertiesVisitor : public osgVolume::PropertyVisitor
{
public:
CollectPropertiesVisitor(bool traverseOnlyActiveChildren=true);
virtual void apply(TransferFunctionProperty&);
virtual void apply(ScalarProperty&);
virtual void apply(IsoSurfaceProperty& iso);
virtual void apply(AlphaFuncProperty& af);
virtual void apply(MaximumIntensityProjectionProperty& mip);
virtual void apply(LightingProperty& lp);
virtual void apply(SampleDensityProperty& sdp);
virtual void apply(SampleDensityWhenMovingProperty& sdp);
virtual void apply(SampleRatioProperty& sdp);
virtual void apply(SampleRatioWhenMovingProperty& sdp);
virtual void apply(TransparencyProperty& tp);
virtual void apply(ExteriorTransparencyFactorProperty& tp);
osg::ref_ptr<TransferFunctionProperty> _tfProperty;
osg::ref_ptr<IsoSurfaceProperty> _isoProperty;
osg::ref_ptr<AlphaFuncProperty> _afProperty;
osg::ref_ptr<MaximumIntensityProjectionProperty> _mipProperty;
osg::ref_ptr<LightingProperty> _lightingProperty;
osg::ref_ptr<SampleDensityProperty> _sampleDensityProperty;
osg::ref_ptr<SampleDensityWhenMovingProperty> _sampleDensityWhenMovingProperty;
osg::ref_ptr<SampleRatioProperty> _sampleRatioProperty;
osg::ref_ptr<SampleRatioWhenMovingProperty> _sampleRatioWhenMovingProperty;
osg::ref_ptr<TransparencyProperty> _transparencyProperty;
osg::ref_ptr<ExteriorTransparencyFactorProperty> _exteriorTransparencyFactorProperty;
};
class OSGVOLUME_EXPORT PropertyAdjustmentCallback : public osgGA::GUIEventHandler, public osg::StateSet::Callback
{
public:
PropertyAdjustmentCallback();
PropertyAdjustmentCallback(const PropertyAdjustmentCallback&,const osg::CopyOp&);
META_Object(osgVolume, PropertyAdjustmentCallback);
virtual NodeCallback* asNodeCallback() { return osg::NodeCallback::asNodeCallback(); }
virtual const NodeCallback* asNodeCallback() const { return osg::NodeCallback::asNodeCallback(); }
virtual DrawableEventCallback* asDrawableEventCallback() { return osg::DrawableEventCallback::asDrawableEventCallback(); }
virtual const DrawableEventCallback* asDrawableEventCallback() const { return osg::DrawableEventCallback::asDrawableEventCallback(); }
virtual osgGA::EventHandler* asEventHandler() { return osgGA::EventHandler::asEventHandler(); }
virtual const osgGA::EventHandler* asEventHandler() const { return osgGA::EventHandler::asEventHandler(); }
virtual bool run(osg::Object* object, osg::Object* data) { return osgGA::GUIEventHandler::run(object, data); }
void setKeyEventCycleForward(int key) { _cyleForwardKey = key; }
int getKeyEventCycleForward() const { return _cyleForwardKey; }
void setKeyEventCycleBackward(int key) { _cyleBackwardKey = key; }
int getKeyEventCycleBackward() const { return _cyleBackwardKey; }
void setKeyEventActivatesTransparencyAdjustment(int key) { _transparencyKey = key; }
int getKeyEventActivatesTransparencyAdjustment() const { return _transparencyKey; }
void setKeyEventActivatesExteriorTransparencyFactorAdjustment(int key) { _exteriorTransparencyFactorKey = key; }
int getKeyEventActivatesExteriorTransparencyFactorAdjustment() const { return _exteriorTransparencyFactorKey; }
void setKeyEventActivatesSampleDensityAdjustment(int key) { _sampleDensityKey = key; }
int getKeyEventActivatesSampleDensityAdjustment() const { return _sampleDensityKey; }
void setKeyEventActivatesAlphaFuncAdjustment(int key) { _alphaFuncKey = key; }
int getKeyEventActivatesAlphaFuncAdjustment() const { return _alphaFuncKey; }
virtual bool handle(const osgGA::GUIEventAdapter& ea,osgGA::GUIActionAdapter&, osg::Object* object, osg::NodeVisitor*);
int _cyleForwardKey;
int _cyleBackwardKey;
int _transparencyKey;
int _exteriorTransparencyFactorKey;
int _alphaFuncKey;
int _sampleDensityKey;
bool _updateTransparency;
bool _updateExteriorTransparencyFactor;
bool _updateAlphaCutOff;
bool _updateSampleDensity;
};
}
#endif
AlphaFunc
GUIEventHandler
TransferFunction
Uniform
osgGA::EventHandler
Definition EventHandler:34
osgGA::EventHandler::asEventHandler
virtual EventHandler * asEventHandler()
Definition EventHandler:52
osgGA::GUIActionAdapter
Definition GUIActionAdapter:62
osgGA::GUIEventAdapter
Definition GUIEventAdapter:82
osgGA::GUIEventHandler
Definition GUIEventHandler:50
osgVolume::AlphaFuncProperty
Definition Property:278
osgVolume::AlphaFuncProperty::~AlphaFuncProperty
virtual ~AlphaFuncProperty()
Definition Property:298
osgVolume::AlphaFuncProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:287
osgVolume::AlphaFuncProperty::setValue
virtual void setValue(float v)
osgVolume::AlphaFuncProperty::AlphaFuncProperty
AlphaFuncProperty(const AlphaFuncProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::AlphaFuncProperty::META_Object
META_Object(osgVolume, AlphaFuncProperty)
osgVolume::AlphaFuncProperty::getAlphaFunc
const osg::AlphaFunc * getAlphaFunc() const
Definition Property:293
osgVolume::AlphaFuncProperty::_alphaFunc
osg::ref_ptr< osg::AlphaFunc > _alphaFunc
Definition Property:300
osgVolume::AlphaFuncProperty::getAlphaFunc
osg::AlphaFunc * getAlphaFunc()
Definition Property:291
osgVolume::AlphaFuncProperty::AlphaFuncProperty
AlphaFuncProperty(float value=1.0f)
osgVolume::CollectPropertiesVisitor::CollectPropertiesVisitor
CollectPropertiesVisitor(bool traverseOnlyActiveChildren=true)
osgVolume::CollectPropertiesVisitor::_afProperty
osg::ref_ptr< AlphaFuncProperty > _afProperty
Definition Property:468
osgVolume::CollectPropertiesVisitor::_sampleRatioProperty
osg::ref_ptr< SampleRatioProperty > _sampleRatioProperty
Definition Property:473
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(SampleRatioProperty &sdp)
osgVolume::CollectPropertiesVisitor::_exteriorTransparencyFactorProperty
osg::ref_ptr< ExteriorTransparencyFactorProperty > _exteriorTransparencyFactorProperty
Definition Property:476
osgVolume::CollectPropertiesVisitor::_tfProperty
osg::ref_ptr< TransferFunctionProperty > _tfProperty
Definition Property:466
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(ExteriorTransparencyFactorProperty &tp)
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(ScalarProperty &)
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(IsoSurfaceProperty &iso)
osgVolume::CollectPropertiesVisitor::_sampleRatioWhenMovingProperty
osg::ref_ptr< SampleRatioWhenMovingProperty > _sampleRatioWhenMovingProperty
Definition Property:474
osgVolume::CollectPropertiesVisitor::_sampleDensityWhenMovingProperty
osg::ref_ptr< SampleDensityWhenMovingProperty > _sampleDensityWhenMovingProperty
Definition Property:472
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(SampleRatioWhenMovingProperty &sdp)
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(SampleDensityWhenMovingProperty &sdp)
osgVolume::CollectPropertiesVisitor::_isoProperty
osg::ref_ptr< IsoSurfaceProperty > _isoProperty
Definition Property:467
osgVolume::CollectPropertiesVisitor::_sampleDensityProperty
osg::ref_ptr< SampleDensityProperty > _sampleDensityProperty
Definition Property:471
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(TransferFunctionProperty &)
osgVolume::CollectPropertiesVisitor::_transparencyProperty
osg::ref_ptr< TransparencyProperty > _transparencyProperty
Definition Property:475
osgVolume::CollectPropertiesVisitor::_mipProperty
osg::ref_ptr< MaximumIntensityProjectionProperty > _mipProperty
Definition Property:469
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(AlphaFuncProperty &af)
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(TransparencyProperty &tp)
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(LightingProperty &lp)
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(MaximumIntensityProjectionProperty &mip)
osgVolume::CollectPropertiesVisitor::_lightingProperty
osg::ref_ptr< LightingProperty > _lightingProperty
Definition Property:470
osgVolume::CollectPropertiesVisitor::apply
virtual void apply(SampleDensityProperty &sdp)
osgVolume::CompositeProperty
Definition Property:101
osgVolume::CompositeProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:111
osgVolume::CompositeProperty::addProperty
void addProperty(const osg::ref_ptr< T > &p)
Definition Property:137
osgVolume::CompositeProperty::getNumProperties
unsigned int getNumProperties() const
Definition Property:141
osgVolume::CompositeProperty::removeProperty
void removeProperty(unsigned int i)
Definition Property:139
osgVolume::CompositeProperty::_properties
Properties _properties
Definition Property:148
osgVolume::CompositeProperty::CompositeProperty
CompositeProperty(const CompositeProperty &compositeProperty, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::CompositeProperty::getProperty
Property * getProperty(unsigned int i)
Definition Property:131
osgVolume::CompositeProperty::addProperty
void addProperty(Property *property)
Definition Property:135
osgVolume::CompositeProperty::~CompositeProperty
virtual ~CompositeProperty()
Definition Property:145
osgVolume::CompositeProperty::META_Object
META_Object(osgVolume, CompositeProperty)
osgVolume::CompositeProperty::getProperty
const Property * getProperty(unsigned int i) const
Definition Property:133
osgVolume::CompositeProperty::traverse
virtual void traverse(PropertyVisitor &pv)
Definition Property:113
osgVolume::CompositeProperty::setProperty
void setProperty(unsigned int i, Property *property)
Definition Property:127
osgVolume::CompositeProperty::CompositeProperty
CompositeProperty()
osgVolume::CompositeProperty::Properties
std::vector< osg::ref_ptr< Property > > Properties
Definition Property:125
osgVolume::CompositeProperty::setProperty
void setProperty(unsigned int i, const osg::ref_ptr< T > &p)
Definition Property:129
osgVolume::CompositeProperty::clear
void clear()
osgVolume::ExteriorTransparencyFactorProperty
Definition Property:430
osgVolume::ExteriorTransparencyFactorProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:439
osgVolume::ExteriorTransparencyFactorProperty::ExteriorTransparencyFactorProperty
ExteriorTransparencyFactorProperty(const ExteriorTransparencyFactorProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::ExteriorTransparencyFactorProperty::~ExteriorTransparencyFactorProperty
virtual ~ExteriorTransparencyFactorProperty()
Definition Property:443
osgVolume::ExteriorTransparencyFactorProperty::ExteriorTransparencyFactorProperty
ExteriorTransparencyFactorProperty(float value=0.0f)
osgVolume::ExteriorTransparencyFactorProperty::META_Object
META_Object(osgVolume, ExteriorTransparencyFactorProperty)
osgVolume::IsoSurfaceProperty
Definition Property:261
osgVolume::IsoSurfaceProperty::META_Object
META_Object(osgVolume, IsoSurfaceProperty)
osgVolume::IsoSurfaceProperty::IsoSurfaceProperty
IsoSurfaceProperty(const IsoSurfaceProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::IsoSurfaceProperty::IsoSurfaceProperty
IsoSurfaceProperty(float value=1.0f)
osgVolume::IsoSurfaceProperty::~IsoSurfaceProperty
virtual ~IsoSurfaceProperty()
Definition Property:274
osgVolume::IsoSurfaceProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:270
osgVolume::LightingProperty
Definition Property:322
osgVolume::LightingProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:331
osgVolume::LightingProperty::META_Object
META_Object(osgVolume, LightingProperty)
osgVolume::LightingProperty::~LightingProperty
virtual ~LightingProperty()
Definition Property:335
osgVolume::LightingProperty::LightingProperty
LightingProperty()
osgVolume::LightingProperty::LightingProperty
LightingProperty(const LightingProperty &mipp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::MaximumIntensityProjectionProperty
Definition Property:304
osgVolume::MaximumIntensityProjectionProperty::MaximumIntensityProjectionProperty
MaximumIntensityProjectionProperty(const MaximumIntensityProjectionProperty &mipp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::MaximumIntensityProjectionProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:313
osgVolume::MaximumIntensityProjectionProperty::~MaximumIntensityProjectionProperty
virtual ~MaximumIntensityProjectionProperty()
Definition Property:317
osgVolume::MaximumIntensityProjectionProperty::MaximumIntensityProjectionProperty
MaximumIntensityProjectionProperty()
osgVolume::MaximumIntensityProjectionProperty::META_Object
META_Object(osgVolume, MaximumIntensityProjectionProperty)
osgVolume::PropertyAdjustmentCallback::asEventHandler
virtual const osgGA::EventHandler * asEventHandler() const
Definition Property:497
osgVolume::PropertyAdjustmentCallback::setKeyEventActivatesSampleDensityAdjustment
void setKeyEventActivatesSampleDensityAdjustment(int key)
Definition Property:513
osgVolume::PropertyAdjustmentCallback::getKeyEventActivatesAlphaFuncAdjustment
int getKeyEventActivatesAlphaFuncAdjustment() const
Definition Property:517
osgVolume::PropertyAdjustmentCallback::PropertyAdjustmentCallback
PropertyAdjustmentCallback()
osgVolume::PropertyAdjustmentCallback::_sampleDensityKey
int _sampleDensityKey
Definition Property:526
osgVolume::PropertyAdjustmentCallback::_exteriorTransparencyFactorKey
int _exteriorTransparencyFactorKey
Definition Property:524
osgVolume::PropertyAdjustmentCallback::getKeyEventActivatesSampleDensityAdjustment
int getKeyEventActivatesSampleDensityAdjustment() const
Definition Property:514
osgVolume::PropertyAdjustmentCallback::_updateTransparency
bool _updateTransparency
Definition Property:528
osgVolume::PropertyAdjustmentCallback::setKeyEventActivatesAlphaFuncAdjustment
void setKeyEventActivatesAlphaFuncAdjustment(int key)
Definition Property:516
osgVolume::PropertyAdjustmentCallback::_updateAlphaCutOff
bool _updateAlphaCutOff
Definition Property:530
osgVolume::PropertyAdjustmentCallback::_cyleBackwardKey
int _cyleBackwardKey
Definition Property:522
osgVolume::PropertyAdjustmentCallback::setKeyEventActivatesTransparencyAdjustment
void setKeyEventActivatesTransparencyAdjustment(int key)
Definition Property:507
osgVolume::PropertyAdjustmentCallback::META_Object
META_Object(osgVolume, PropertyAdjustmentCallback)
osgVolume::PropertyAdjustmentCallback::asEventHandler
virtual osgGA::EventHandler * asEventHandler()
Definition Property:496
osgVolume::PropertyAdjustmentCallback::getKeyEventCycleForward
int getKeyEventCycleForward() const
Definition Property:502
osgVolume::PropertyAdjustmentCallback::asDrawableEventCallback
virtual DrawableEventCallback * asDrawableEventCallback()
Definition Property:493
osgVolume::PropertyAdjustmentCallback::getKeyEventActivatesTransparencyAdjustment
int getKeyEventActivatesTransparencyAdjustment() const
Definition Property:508
osgVolume::PropertyAdjustmentCallback::_cyleForwardKey
int _cyleForwardKey
Definition Property:521
osgVolume::PropertyAdjustmentCallback::getKeyEventActivatesExteriorTransparencyFactorAdjustment
int getKeyEventActivatesExteriorTransparencyFactorAdjustment() const
Definition Property:511
osgVolume::PropertyAdjustmentCallback::setKeyEventCycleBackward
void setKeyEventCycleBackward(int key)
Definition Property:504
osgVolume::PropertyAdjustmentCallback::getKeyEventCycleBackward
int getKeyEventCycleBackward() const
Definition Property:505
osgVolume::PropertyAdjustmentCallback::PropertyAdjustmentCallback
PropertyAdjustmentCallback(const PropertyAdjustmentCallback &, const osg::CopyOp &)
osgVolume::PropertyAdjustmentCallback::asDrawableEventCallback
virtual const DrawableEventCallback * asDrawableEventCallback() const
Definition Property:494
osgVolume::PropertyAdjustmentCallback::asNodeCallback
virtual const NodeCallback * asNodeCallback() const
Definition Property:491
osgVolume::PropertyAdjustmentCallback::run
virtual bool run(osg::Object *object, osg::Object *data)
Definition Property:499
osgVolume::PropertyAdjustmentCallback::handle
virtual bool handle(const osgGA::GUIEventAdapter &ea, osgGA::GUIActionAdapter &, osg::Object *object, osg::NodeVisitor *)
osgVolume::PropertyAdjustmentCallback::_updateExteriorTransparencyFactor
bool _updateExteriorTransparencyFactor
Definition Property:529
osgVolume::PropertyAdjustmentCallback::_transparencyKey
int _transparencyKey
Definition Property:523
osgVolume::PropertyAdjustmentCallback::setKeyEventCycleForward
void setKeyEventCycleForward(int key)
Definition Property:501
osgVolume::PropertyAdjustmentCallback::asNodeCallback
virtual NodeCallback * asNodeCallback()
Definition Property:490
osgVolume::PropertyAdjustmentCallback::setKeyEventActivatesExteriorTransparencyFactorAdjustment
void setKeyEventActivatesExteriorTransparencyFactorAdjustment(int key)
Definition Property:510
osgVolume::PropertyAdjustmentCallback::_updateSampleDensity
bool _updateSampleDensity
Definition Property:531
osgVolume::PropertyAdjustmentCallback::_alphaFuncKey
int _alphaFuncKey
Definition Property:525
osgVolume::PropertyVisitor
Definition Property:46
osgVolume::PropertyVisitor::apply
virtual void apply(AlphaFuncProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(SampleDensityWhenMovingProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(ScalarProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(TransparencyProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(IsoSurfaceProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(CompositeProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(MaximumIntensityProjectionProperty &)
osgVolume::PropertyVisitor::PropertyVisitor
PropertyVisitor(bool traverseOnlyActiveChildren=true)
osgVolume::PropertyVisitor::apply
virtual void apply(SampleRatioWhenMovingProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(ExteriorTransparencyFactorProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(SwitchProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(VolumeSettings &)
osgVolume::PropertyVisitor::apply
virtual void apply(SampleDensityProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(TransferFunctionProperty &)
osgVolume::PropertyVisitor::_traverseOnlyActiveChildren
bool _traverseOnlyActiveChildren
Definition Property:70
osgVolume::PropertyVisitor::apply
virtual void apply(SampleRatioProperty &)
osgVolume::PropertyVisitor::apply
virtual void apply(Property &)
osgVolume::PropertyVisitor::apply
virtual void apply(LightingProperty &)
osgVolume::PropertyVisitor::~PropertyVisitor
virtual ~PropertyVisitor()
Definition Property:51
osgVolume::Property
Definition Property:75
osgVolume::Property::META_Object
META_Object(osgVolume, Property)
osgVolume::Property::setModifiedCount
void setModifiedCount(unsigned int c)
Definition Property:87
osgVolume::Property::Property
Property(const Property &, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::Property::Property
Property()
osgVolume::Property::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:90
osgVolume::Property::dirty
void dirty()
Definition Property:85
osgVolume::Property::_modifiedCount
unsigned int _modifiedCount
Definition Property:97
osgVolume::Property::traverse
virtual void traverse(PropertyVisitor &)
Definition Property:91
osgVolume::Property::~Property
virtual ~Property()
osgVolume::Property::getModifiedCount
unsigned int getModifiedCount() const
Definition Property:88
osgVolume::SampleDensityProperty
Definition Property:341
osgVolume::SampleDensityProperty::META_Object
META_Object(osgVolume, SampleDensityProperty)
osgVolume::SampleDensityProperty::SampleDensityProperty
SampleDensityProperty(float value=1.0f)
osgVolume::SampleDensityProperty::SampleDensityProperty
SampleDensityProperty(const SampleDensityProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::SampleDensityProperty::~SampleDensityProperty
virtual ~SampleDensityProperty()
Definition Property:354
osgVolume::SampleDensityProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:350
osgVolume::SampleDensityWhenMovingProperty
Definition Property:359
osgVolume::SampleDensityWhenMovingProperty::~SampleDensityWhenMovingProperty
virtual ~SampleDensityWhenMovingProperty()
Definition Property:372
osgVolume::SampleDensityWhenMovingProperty::SampleDensityWhenMovingProperty
SampleDensityWhenMovingProperty(const SampleDensityWhenMovingProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::SampleDensityWhenMovingProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:368
osgVolume::SampleDensityWhenMovingProperty::META_Object
META_Object(osgVolume, SampleDensityWhenMovingProperty)
osgVolume::SampleDensityWhenMovingProperty::SampleDensityWhenMovingProperty
SampleDensityWhenMovingProperty(float value=1.0f)
osgVolume::SampleRatioProperty
Definition Property:377
osgVolume::SampleRatioProperty::~SampleRatioProperty
virtual ~SampleRatioProperty()
Definition Property:390
osgVolume::SampleRatioProperty::META_Object
META_Object(osgVolume, SampleRatioProperty)
osgVolume::SampleRatioProperty::SampleRatioProperty
SampleRatioProperty(const SampleRatioProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::SampleRatioProperty::SampleRatioProperty
SampleRatioProperty(float value=1.0f)
osgVolume::SampleRatioProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:386
osgVolume::SampleRatioWhenMovingProperty
Definition Property:395
osgVolume::SampleRatioWhenMovingProperty::META_Object
META_Object(osgVolume, SampleRatioWhenMovingProperty)
osgVolume::SampleRatioWhenMovingProperty::SampleRatioWhenMovingProperty
SampleRatioWhenMovingProperty(float value=1.0f)
osgVolume::SampleRatioWhenMovingProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:404
osgVolume::SampleRatioWhenMovingProperty::~SampleRatioWhenMovingProperty
virtual ~SampleRatioWhenMovingProperty()
Definition Property:408
osgVolume::SampleRatioWhenMovingProperty::SampleRatioWhenMovingProperty
SampleRatioWhenMovingProperty(const SampleRatioWhenMovingProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::ScalarProperty
Definition Property:227
osgVolume::ScalarProperty::~ScalarProperty
virtual ~ScalarProperty()
Definition Property:252
osgVolume::ScalarProperty::ScalarProperty
ScalarProperty()
osgVolume::ScalarProperty::ScalarProperty
ScalarProperty(const ScalarProperty &scalarProperty, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::ScalarProperty::ScalarProperty
ScalarProperty(const std::string &scaleName, float value)
osgVolume::ScalarProperty::_uniform
osg::ref_ptr< osg::Uniform > _uniform
Definition Property:256
osgVolume::ScalarProperty::getUniform
const osg::Uniform * getUniform() const
Definition Property:248
osgVolume::ScalarProperty::setValue
virtual void setValue(float v)
Definition Property:239
osgVolume::ScalarProperty::getUniform
osg::Uniform * getUniform()
Definition Property:245
osgVolume::ScalarProperty::getValue
float getValue() const
Definition Property:242
osgVolume::ScalarProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:236
osgVolume::ScalarProperty::META_Object
META_Object(osgVolume, ScalarProperty)
osgVolume::SwitchProperty
Definition Property:153
osgVolume::SwitchProperty::META_Object
META_Object(osgVolume, SwitchProperty)
osgVolume::SwitchProperty::SwitchProperty
SwitchProperty(const SwitchProperty &switchProperty, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::SwitchProperty::~SwitchProperty
virtual ~SwitchProperty()
Definition Property:190
osgVolume::SwitchProperty::setActiveProperty
void setActiveProperty(int i)
Definition Property:183
osgVolume::SwitchProperty::traverse
virtual void traverse(PropertyVisitor &pv)
Definition Property:165
osgVolume::SwitchProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:163
osgVolume::SwitchProperty::SwitchProperty
SwitchProperty()
osgVolume::SwitchProperty::_activeProperty
int _activeProperty
Definition Property:192
osgVolume::SwitchProperty::getActiveProperty
int getActiveProperty() const
Definition Property:186
osgVolume::TransferFunctionProperty
Definition Property:196
osgVolume::TransferFunctionProperty::META_Object
META_Object(osgVolume, TransferFunctionProperty)
osgVolume::TransferFunctionProperty::_tf
osg::ref_ptr< osg::TransferFunction > _tf
Definition Property:221
osgVolume::TransferFunctionProperty::getTransferFunction
osg::TransferFunction * getTransferFunction()
Definition Property:212
osgVolume::TransferFunctionProperty::getTransferFunction
const osg::TransferFunction * getTransferFunction() const
Definition Property:215
osgVolume::TransferFunctionProperty::~TransferFunctionProperty
virtual ~TransferFunctionProperty()
Definition Property:219
osgVolume::TransferFunctionProperty::setTransferFunction
void setTransferFunction(osg::TransferFunction *tf)
Definition Property:209
osgVolume::TransferFunctionProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:206
osgVolume::TransferFunctionProperty::TransferFunctionProperty
TransferFunctionProperty(const TransferFunctionProperty &tfp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::TransferFunctionProperty::TransferFunctionProperty
TransferFunctionProperty(osg::TransferFunction *tf=0)
osgVolume::TransparencyProperty
Definition Property:413
osgVolume::TransparencyProperty::~TransparencyProperty
virtual ~TransparencyProperty()
Definition Property:426
osgVolume::TransparencyProperty::TransparencyProperty
TransparencyProperty(float value=1.0f)
osgVolume::TransparencyProperty::META_Object
META_Object(osgVolume, TransparencyProperty)
osgVolume::TransparencyProperty::TransparencyProperty
TransparencyProperty(const TransparencyProperty &isp, const osg::CopyOp &copyop=osg::CopyOp::SHALLOW_COPY)
osgVolume::TransparencyProperty::accept
virtual void accept(PropertyVisitor &pv)
Definition Property:422
osgVolume::VolumeSettings
Definition VolumeSettings:23
osg::AlphaFunc
Definition AlphaFunc:24
osg::Callback::run
virtual bool run(osg::Object *object, osg::Object *data)
Definition Callback:80
osg::CopyOp
Definition CopyOp:41
osg::CopyOp::SHALLOW_COPY
@ SHALLOW_COPY
Definition CopyOp:47
osg::DrawableEventCallback::asDrawableEventCallback
virtual DrawableEventCallback * asDrawableEventCallback()
Definition Callback:330
osg::DrawableEventCallback::DrawableEventCallback
DrawableEventCallback()
Definition Callback:322
osg::NodeCallback::NodeCallback
NodeCallback()
Definition Callback:219
osg::NodeCallback::asNodeCallback
virtual NodeCallback * asNodeCallback()
Definition Callback:227
osg::NodeVisitor
Definition NodeVisitor:82
osg::Object
Definition Object:61
osg::TransferFunction
Definition TransferFunction:31
osg::Uniform
Definition Uniform:414
osg::ref_ptr
Definition ref_ptr:32
osg::ref_ptr::get
T * get() const
Definition ref_ptr:117
osgVolume
Export
OSGVOLUME_EXPORT
#define OSGVOLUME_EXPORT
Definition osgVolume/Export:39
osg::StateSet::Callback
Definition StateSet:446