Skip to content

Conversation

@damienmarchal
Copy link
Contributor

@damienmarchal damienmarchal commented Jul 14, 2025

Related to the issue: #5556
The PR is based on #5566, please merge it to make the difference clear.

At this step, it is unclear to me how to move forward.
The Context seems to be a not very well defined concept as it shares properties with the scene graph structure.

The fact it stores data field like dt, t, gravity... and it is also a BaseObject makes me think that possible path could be to simply add make it to the factory and have the context as one of the a node component. The get<> should probably be moved out of the context unless we want a context to explore the local children and objects or not.

def createScene(root):
       root.addObject("Context", dt=0.01, gravity=[0.0,9.8,1.8])      

This will breaks everything that makes the assumption that dt, node are node attributes.


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).

@damienmarchal damienmarchal added the pr: status to review To notify reviewers to review this pull-request label Jul 14, 2025
@damienmarchal damienmarchal changed the title Merge BaseContext and Context [Sofa.Core] Merge BaseContext and Context Jul 14, 2025
@damienmarchal damienmarchal added pr: status wip Development in the pull-request is still in progress and removed pr: status to review To notify reviewers to review this pull-request labels Jul 16, 2025
@hugtalbot hugtalbot added the refactoring Refactor code label Jul 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: status wip Development in the pull-request is still in progress refactoring Refactor code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants