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

[SofaPython3] Changes how addObject process its arguments when they are of type: numpy & data #198

Merged

Commits on Sep 23, 2021

  1. [SofaPython3] Add type coercion from numpy array to sofa parsable str…

    …ing (in object creation)
    
    So we can write:
    ```python
    def createScene(root):
    	root.addObject("MechanicalObject", name="loader", filename="mesh/cube.obj")
    	root.addObject("MechanicalObject", name="dofs", position=root.loader.position)        # to make a link
    	root.addObject("MechanicalObject", name="dofs", position=root.loader.position.value)  # to make a copy by value
    ```
    damienmarchal committed Sep 23, 2021
    Configuration menu
    Copy the full SHA
    8536c1c View commit details
    Browse the repository at this point in the history
  2. [SofaPython] Restore the copy by default approach in toSofaParsableSt…

    …ring
    
    Because it breaks bckward compatibility and was not really better.
    damienmarchal committed Sep 23, 2021
    Configuration menu
    Copy the full SHA
    e7a9eaf View commit details
    Browse the repository at this point in the history
  3. [Sofa.Core] Add an attribute 'link' to Binding_BaseData.

    So we can write:
    object.position.link instead of object.position.getLinkPath()
    
    Which will make the syntax a bit more compact.
    
    Signed-off-by: Damien Marchal <damien.marchal@univ-lille1.fr>
    damienmarchal committed Sep 23, 2021
    Configuration menu
    Copy the full SHA
    f1bd435 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    5c12fc4 View commit details
    Browse the repository at this point in the history
  5. SofaPython3] Do link by default.

    Signed-off-by: Damien Marchal <damien.marchal@univ-lille1.fr>
    damienmarchal committed Sep 23, 2021
    Configuration menu
    Copy the full SHA
    e2d1234 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    292ccec View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    9c1d0c9 View commit details
    Browse the repository at this point in the history

Commits on Sep 27, 2021

  1. Configuration menu
    Copy the full SHA
    33a34c1 View commit details
    Browse the repository at this point in the history

Commits on Oct 28, 2021

  1. Configuration menu
    Copy the full SHA
    2eda47f View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    44dbe9c View commit details
    Browse the repository at this point in the history