Merge pull request #215 from LaurensVoerman/submit-SerializerParticle

Submit serializer particle
This commit is contained in:
OpenSceneGraph git repository 2017-03-13 14:25:33 +00:00 committed by GitHub
commit c364bbb19b

View File

@ -36,7 +36,7 @@ bool readParticle( osgDB::InputStream& is, osgParticle::Particle& p )
if ( hasInterpolator ) if ( hasInterpolator )
{ {
is >> is.BEGIN_BRACKET; is >> is.BEGIN_BRACKET;
p.setAlphaInterpolator( is.readObjectOfType<osgParticle::Interpolator>() ); p.setSizeInterpolator( is.readObjectOfType<osgParticle::Interpolator>() );
is >> is.END_BRACKET; is >> is.END_BRACKET;
} }
is >> is.PROPERTY("AlphaInterpolator") >> hasInterpolator; is >> is.PROPERTY("AlphaInterpolator") >> hasInterpolator;
@ -50,7 +50,7 @@ bool readParticle( osgDB::InputStream& is, osgParticle::Particle& p )
if ( hasInterpolator ) if ( hasInterpolator )
{ {
is >> is.BEGIN_BRACKET; is >> is.BEGIN_BRACKET;
p.setAlphaInterpolator( is.readObjectOfType<osgParticle::Interpolator>() ); p.setColorInterpolator( is.readObjectOfType<osgParticle::Interpolator>() );
is >> is.END_BRACKET; is >> is.END_BRACKET;
} }
@ -81,8 +81,8 @@ bool readParticle( osgDB::InputStream& is, osgParticle::Particle& p )
is >> is.END_BRACKET; is >> is.END_BRACKET;
} }
is >> is.END_BRACKET;
} }
is >> is.END_BRACKET;
return true; return true;
} }