-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PI - 260] Implement spline interpolation #34
base: master
Are you sure you want to change the base?
Conversation
@@ -35,20 +36,24 @@ class JointProcess | |||
explicit JointProcess(uint8_t joint_id, float position = 0.0); | |||
|
|||
void set_target_position(float target_position, float speed = 1.0); | |||
void set_spline(keisan::Spline spline); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i suggest to pass by const ref instead (const keisan::Spline&
).
src/akushon/action/model/action.cpp
Outdated
uint8_t joint_id = joint.get_id(); | ||
|
||
if (joint_splines.find(joint_id) != joint_splines.end()) { | ||
joint_splines[joint_id] = new keisan::SmoothSpline(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please use std::shared_ptr
instead, it's more safe. And you don't need to delete this later.
Jira Link: https://ichiro-its.atlassian.net/browse/PI-260
Description
Implemented spline interpolation for motion for smoother motions, can toggle whether to use spline or not from the actions json.
Type of Change
How Has This Been Tested?
Checklist:
feature/JIRA-ID-SHORT-DESCRIPTION
if has a JIRA ticketenhancement/SHORT-DESCRIPTION
if has/has no JIRA ticket and contain enhancementhotfix/SHORT-DESCRIPTION
if the change doesn't need to be tested (urgent)