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

[SofaBaseTopology] Ensure to add a topology EndingEvent before propagating to all topologyData #2376

Merged
merged 1 commit into from
Oct 6, 2021

Conversation

epernod
Copy link
Contributor

@epernod epernod commented Oct 1, 2021

Add topology EndingEvent to the queue of event each time before propagating. This event can be catch by callback if needed.
See next PR with uniformMass


By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).


Reviewers will merge this pull-request only if

  • it builds with SUCCESS for all platforms on the CI.
  • it does not generate new warnings.
  • it does not generate new unit test failures.
  • it does not generate new scene test failures.
  • it does not break API compatibility.
  • it is more than 1 week old (or has fast-merge label).

@epernod epernod added pr: fast merge Minor change that can be merged without waiting for the 7 review days pr: status to review To notify reviewers to review this pull-request pr: new feature Implement a new feature labels Oct 1, 2021
@epernod epernod self-assigned this Oct 1, 2021
@@ -434,6 +434,8 @@ void PointSetTopologyModifier::propagateTopologicalChanges()
{
if (m_container->beginChange() == m_container->endChange()) return; // nothing to do if no event is stored

sofa::core::topology::EndingEvent* e = new sofa::core::topology::EndingEvent();
Copy link
Contributor

Choose a reason for hiding this comment

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

pointer destructor ?

@fredroy fredroy added pr: status ready Approved a pull-request, ready to be squashed and removed pr: status to review To notify reviewers to review this pull-request labels Oct 6, 2021
@epernod epernod merged commit b60c933 into sofa-framework:master Oct 6, 2021
@epernod epernod deleted the inf_topo_propagate branch October 20, 2021 22:33
guparan pushed a commit that referenced this pull request Oct 28, 2021
…2377)

This PR depends on #2374 #2375 and #2376 and should be rebased before review.

- Remove old method `handleTopologyChange`
- Turn d_indices into TopologySubsetIndices, this automatically fix the topological changes update. 
- Fix the use of subset indices combined with topology changes.
- Add callback on endingEvent to update the totalMass/vertexMass
- Fix the center of gravity display when using subset of indices

______________________________________________________

Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
Co-authored-by: Frederick Roy <fredroy@users.noreply.github.com>
fredroy added a commit to fredroy/sofa that referenced this pull request Nov 8, 2021
…ofa-framework#2377)

This PR depends on sofa-framework#2374 sofa-framework#2375 and sofa-framework#2376 and should be rebased before review.

- Remove old method `handleTopologyChange`
- Turn d_indices into TopologySubsetIndices, this automatically fix the topological changes update. 
- Fix the use of subset indices combined with topology changes.
- Add callback on endingEvent to update the totalMass/vertexMass
- Fix the center of gravity display when using subset of indices

______________________________________________________

Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
Co-authored-by: Frederick Roy <fredroy@users.noreply.github.com>
@guparan guparan added this to the v21.12 milestone Nov 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: fast merge Minor change that can be merged without waiting for the 7 review days pr: new feature Implement a new feature pr: status ready Approved a pull-request, ready to be squashed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants