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

[all] Speed up spheres rendering + code cleaning (URGENT) #170

Merged
merged 11 commits into from
Mar 1, 2017

Conversation

fredroy
Copy link
Contributor

@fredroy fredroy commented Feb 13, 2017

Speed up by a (huge) factor the rendering of several spheres.
This is done in 2 ways:

On the same computer, for 150K spheres :

  • 0.8fps with previous rendering
  • 22fps with VBO
  • 46 fps with impostors

This task is also the beginning of optimizing draw tools, by removing deprecated glu calls and non optimized OpenGL code ; and by using VBO/IBO and shaders. (class BasicShapesGL)

This PR should resolve more or less the issue #142 .
It depends if this issue talks about spheres only or more generally speeding up rendering itself (in that case, it will need much more commits ;) )

This PR:

  • builds with SUCCESS for all platforms on the CI.
  • does not generate new warnings nor unit test failures.
  • does not break existing scenes.
  • does not break API compatibility.
  • has been reviewed and agreed to be transitional.
  • is more than 1 week old.

Reviewers will merge only if all these checks are true.

@fredroy fredroy added the enhancement About a possible enhancement label Feb 13, 2017
@damienmarchal damienmarchal changed the title Speed up spheres rendering [all] Speed up spheres rendering + code cleaning Feb 14, 2017
@matthieu-nesme
Copy link
Member

YEAH! Thanks Fred, do we have to wait for a week before merging?

@damienmarchal damienmarchal changed the title [all] Speed up spheres rendering + code cleaning [all] Speed up spheres rendering + code cleaning (URGENT) Feb 15, 2017
@damienmarchal
Copy link
Contributor

[ci-build]

1 similar comment
@damienmarchal
Copy link
Contributor

[ci-build]

@guparan guparan merged commit 67a18f0 into sofa-framework:master Mar 1, 2017
@matthieu-nesme
Copy link
Member

@fredroy It is working well, one minor problem is the spheres are darker, is it possible to tweak the shader to display them lighter by default? Thanks.

@fredroy
Copy link
Contributor Author

fredroy commented Mar 3, 2017

You are right that the spheres are too dark ; I forgot to add the ambient component in the final color computation ; I will submit a patch right away.

@fredroy fredroy deleted the draw_fast_spheres branch March 3, 2017 15:22
@fredroy
Copy link
Contributor Author

fredroy commented Mar 3, 2017

Pull-Request : #192

@guparan guparan added the pr: clean Cleaning the code label Jun 29, 2017
@guparan guparan added this to the v17.06 milestone Jun 29, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement About a possible enhancement pr: clean Cleaning the code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants