]> git.tdb.fi Git - libs/gl.git/blobdiff - source/animation/animation.cpp
Use default member initializers for simple types
[libs/gl.git] / source / animation / animation.cpp
index a9278e3de00836b3eb9e2ebe56ff908e2da207ed..76d9552e1771530945f6f7bba02f79b70064b979 100644 (file)
@@ -16,11 +16,6 @@ using namespace std;
 namespace Msp {
 namespace GL {
 
-Animation::Animation():
-       armature(0),
-       looping(false)
-{ }
-
 Animation::~Animation()
 {
        for(TimedKeyFrame &k: keyframes)
@@ -489,23 +484,12 @@ Matrix Animation::Iterator::get_pose_matrix(unsigned link) const
 }
 
 
-Animation::Loader::Loader(Animation &a):
-       DataFile::CollectionObjectLoader<Animation>(a, 0)
-{
-       init();
-}
-
-Animation::Loader::Loader(Animation &a, Collection &c):
-       DataFile::CollectionObjectLoader<Animation>(a, &c)
+Animation::Loader::Loader(Animation &a, Collection *c):
+       DataFile::CollectionObjectLoader<Animation>(a, c),
+       start_slope(1),
+       end_slope(1),
+       slopes_set(0)
 {
-       init();
-}
-
-void Animation::Loader::init()
-{
-       start_slope = 1;
-       end_slope = 1;
-       slopes_set = 0;
        add("armature", &Animation::armature);
        add("control_keyframe", &Loader::control_keyframe);
        add("control_keyframe", &Loader::control_keyframe_inline);