diff options
author | Aaron Franke <arnfranke@yahoo.com> | 2022-11-01 08:11:09 -0500 |
---|---|---|
committer | Aaron Franke <arnfranke@yahoo.com> | 2022-11-01 09:28:12 -0500 |
commit | 83634119d42595498e42685556a577c12145e20b (patch) | |
tree | bdd670ec6732d4cf479f3185806331b16f3f6fc8 /tests/scene | |
parent | e6751549cf7247965d1744b8c464f5e901006f21 (diff) |
Replace Quaternion Euler constructor with `from_euler` method
Diffstat (limited to 'tests/scene')
-rw-r--r-- | tests/scene/test_animation.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/scene/test_animation.h b/tests/scene/test_animation.h index 9199713fd9..ca80f0ecab 100644 --- a/tests/scene/test_animation.h +++ b/tests/scene/test_animation.h @@ -140,13 +140,13 @@ TEST_CASE("[Animation] Create 3D rotation track") { Ref<Animation> animation = memnew(Animation); const int track_index = animation->add_track(Animation::TYPE_ROTATION_3D); animation->track_set_path(track_index, NodePath("Enemy:rotation")); - animation->rotation_track_insert_key(track_index, 0.0, Quaternion(Vector3(0, 1, 2))); - animation->rotation_track_insert_key(track_index, 0.5, Quaternion(Vector3(3.5, 4, 5))); + animation->rotation_track_insert_key(track_index, 0.0, Quaternion::from_euler(Vector3(0, 1, 2))); + animation->rotation_track_insert_key(track_index, 0.5, Quaternion::from_euler(Vector3(3.5, 4, 5))); CHECK(animation->get_track_count() == 1); CHECK(!animation->track_is_compressed(0)); - CHECK(Quaternion(animation->track_get_key_value(0, 0)).is_equal_approx(Quaternion(Vector3(0, 1, 2)))); - CHECK(Quaternion(animation->track_get_key_value(0, 1)).is_equal_approx(Quaternion(Vector3(3.5, 4, 5)))); + CHECK(Quaternion(animation->track_get_key_value(0, 0)).is_equal_approx(Quaternion::from_euler(Vector3(0, 1, 2)))); + CHECK(Quaternion(animation->track_get_key_value(0, 1)).is_equal_approx(Quaternion::from_euler(Vector3(3.5, 4, 5)))); Quaternion r_interpolation; |