Skip to content

[All] VisualModel: implement NVI for init/updateVisual()#4827

Merged
hugtalbot merged 12 commits into
sofa-framework:masterfrom
fredroy:upgrade_updatevisual
Jul 29, 2024
Merged

[All] VisualModel: implement NVI for init/updateVisual()#4827
hugtalbot merged 12 commits into
sofa-framework:masterfrom
fredroy:upgrade_updatevisual

Conversation

@fredroy
Copy link
Copy Markdown
Contributor

@fredroy fredroy commented Jul 12, 2024

... and add VisualParameters as a parameter to their signature.

Based on

Continue on what has been introduced by:

Little difference, this PR does not only do the NVI thing but it adds the visualparameters as input.
This seems consistent (to me) with the fact that init/update visual as supposed to be called when there is a draw context (like drawVisual).
The nice side effect (and it was the intent at the beginning) is that updatevisual wont be called anymore if the component state is wrong, showVisualModels flag is not set or not enabled.

+ cleanings here and there in the visual/gl components

Unfortunately, breaking ⚠️

[ci-depends-on https://github.com/sofa-framework/SofaPython3/pull/423]
[ci-depends-on https://github.com/sofa-framework/SofaSphFluid/pull/1]

TEMP:
[ci-depends-on https://github.com/sofa-framework/BeamAdapter/pull/153]


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

@fredroy fredroy added pr: enhancement About a possible enhancement pr: breaking Change possibly inducing a compilation error pr: fix Fix a bug pr: status to review To notify reviewers to review this pull-request pr: clean Cleaning the code labels Jul 12, 2024
@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 12, 2024

[ci-depends-on] detected during build #2.

To unlock the merge button, you must

@fredroy
Copy link
Copy Markdown
Contributor Author

fredroy commented Jul 12, 2024

[ci-build][with-all-tests]

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 12, 2024

[ci-depends-on] detected during build #3.

To unlock the merge button, you must

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 12, 2024

[ci-depends-on] detected during build #4.

To unlock the merge button, you must

Comment thread Sofa/GL/Component/Shader/src/sofa/gl/component/shader/Light.cpp Outdated
doDrawVisual(vparams);
}

void VisualModel::updateVisual(const VisualParams* vparams)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I have a deep feeling of cleaness when I see this kind of refactoring (factoring things in the base class)

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 12, 2024

[ci-depends-on] detected during build #5.

To unlock the merge button, you must

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 12, 2024

[ci-depends-on] detected during build #6.

To unlock the merge button, you must

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 15, 2024

[ci-depends-on] detected during build #7.

To unlock the merge button, you must

@fredroy
Copy link
Copy Markdown
Contributor Author

fredroy commented Jul 16, 2024

[ci-build][with-all-tests][force-full-build]

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 16, 2024

[ci-depends-on] detected during build #8.

To unlock the merge button, you must

@fredroy fredroy force-pushed the upgrade_updatevisual branch from d4e7b0a to fd4e090 Compare July 24, 2024 00:31
@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 24, 2024

[ci-depends-on] detected during build #9.

To unlock the merge button, you must

@hugtalbot hugtalbot 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 Jul 24, 2024
@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 25, 2024

[ci-depends-on] detected during build #10.

To unlock the merge button, you must

@fredroy fredroy force-pushed the upgrade_updatevisual branch from b782d08 to e8a69ca Compare July 26, 2024 00:38
@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 26, 2024

[ci-depends-on] detected during build #11.

To unlock the merge button, you must

@fredroy fredroy force-pushed the upgrade_updatevisual branch from e8a69ca to 4b3a46b Compare July 26, 2024 01:20
@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 26, 2024

[ci-depends-on] detected during build #12.

To unlock the merge button, you must

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 29, 2024

[ci-depends-on] detected during build #13.

To unlock the merge button, you must

@hugtalbot
Copy link
Copy Markdown
Contributor

[ci-build][with-all-tests]

@sofabot
Copy link
Copy Markdown
Collaborator

sofabot commented Jul 29, 2024

[ci-depends-on] detected during build #14.

All dependencies are merged/closed and all ExternalProject pointers are up-to-date. Congrats! 👍

@hugtalbot hugtalbot merged commit e092b4a into sofa-framework:master Jul 29, 2024
@hugtalbot hugtalbot deleted the upgrade_updatevisual branch July 29, 2024 09:36
@hugtalbot hugtalbot added this to the v24.12 milestone Jul 31, 2024
@bakpaul bakpaul mentioned this pull request Dec 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: breaking Change possibly inducing a compilation error pr: clean Cleaning the code pr: enhancement About a possible enhancement pr: fix Fix a bug 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