Added Property::getModifiedCount() + dirty() to help with tracking changes. Added VolumeSettings serializers for Property objects

git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14421 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
Robert Osfield
2014-08-25 16:56:47 +00:00
parent 6126379362
commit d1bf811331
6 changed files with 44 additions and 17 deletions

View File

@@ -19,12 +19,14 @@
using namespace osgVolume;
Property::Property()
Property::Property():
_modifiedCount(0)
{
}
Property::Property(const Property& property,const osg::CopyOp& copyop):
osg::Object(property,copyop)
osg::Object(property,copyop),
_modifiedCount(0)
{
}
@@ -49,6 +51,7 @@ CompositeProperty::CompositeProperty(const CompositeProperty& compositeProperty,
void CompositeProperty::clear()
{
_properties.clear();
dirty();
}
/////////////////////////////////////////////////////////////////////////////
@@ -136,6 +139,7 @@ AlphaFuncProperty::AlphaFuncProperty(const AlphaFuncProperty& afp,const osg::Cop
void AlphaFuncProperty::setValue(float v)
{
dirty();
_uniform->set(v);
_alphaFunc->setReferenceValue(v);
}