Skip to content
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

Deprecate CalcCenterOfMassPosition() in favor of CalcCenterOfMassPositionInWorld(). #14537

Closed
mitiguy opened this issue Jan 15, 2021 · 2 comments

Comments

@mitiguy
Copy link
Contributor

mitiguy commented Jan 15, 2021

While working on #14268, we decided that for a consistent API for center of mass methods, it would be beneficial to deprecate CalcCenterOfMassPosition() in favor of CalcCenterOfMassPositionInWorld().

As decided in issue #14268, the public API for center of mass methods names are (or will be):
Vector3 CalcCenterOfMassPositionInWorld(const systems::Context& context) const;
Vector3 CalcCenterOfMassVelocityInWorld(const systems::Context& context) const;
Vector3 CalcCenterOfMassAccelerationInWorld(const systems::Context& context) const;

Vector3 CalcCenterOfMassPositionInWorld(const systems::Context& context,
const std::vector& model_instances) const;
Vector3 CalcCenterOfMassVelocityInWorld(const systems::Context& context,
const std::vector& model_instances) const;
Vector3 CalcCenterOfMassAccelerationInWorld(const systems::Context& context,
const std::vector& model_instances) const;

@mitiguy
Copy link
Contributor Author

mitiguy commented Jan 15, 2021

Created PR #14538

@mitiguy
Copy link
Contributor Author

mitiguy commented Feb 12, 2021

Note: I created the file CppPythonDeprecateAP as an example of how to deprecate a C++ method which has a corresponding Python API. That example draws on this PR #14538.  It relates to issue #10605. Although the goal of this PR #14538 was a simple name change, the deprecation process required many (non-obvious) steps.

josephsnyder pushed a commit to EricCousineau-TRI/drake that referenced this issue Mar 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant