Skip to content

Commit

Permalink
Use quartic easing curve for long zoom animation
Browse files Browse the repository at this point in the history
Seems to look a bit closer to the original behavior.
  • Loading branch information
guillaumechereau committed Dec 15, 2020
1 parent 6c702cc commit 1929d93
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/StelMovementMgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ void Smoother::setTarget(double start, double aim, double duration)
this->progress = 0;
// Compute best easing curve depending on the speed of animation.
if (duration >= 1.0)
easingCurve = QEasingCurve(QEasingCurve::InOutQuad);
easingCurve = QEasingCurve(QEasingCurve::InOutQuart);
else
easingCurve = QEasingCurve(QEasingCurve::OutQuad);

This comment has been minimized.

Copy link
@alex-w

alex-w Dec 15, 2020

Member

Should be OutQuart here too?

}
Expand Down

1 comment on commit 1929d93

@guillaumechereau
Copy link
Contributor Author

@guillaumechereau guillaumechereau commented on 1929d93 Dec 15, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried different values and this one seemed the 'nicest'. I think OutQuart should be fine as well yes.

Please sign in to comment.