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

Smoothing option in viz function #535

Open
stla opened this issue Dec 22, 2022 · 9 comments
Open

Smoothing option in viz function #535

stla opened this issue Dec 22, 2022 · 9 comments
Labels
good first issue Good for newcomers help wanted Extra attention is needed viz Issue with visualization recipes

Comments

@stla
Copy link
Contributor

stla commented Dec 22, 2022

Hello,

I exposed my problem here.

In the given answer, the author uses the Makie.mesh! function to plot the mesh, with the option interpolate=false. Is it possible to have such an option with MeshViz.jl? I took a look at the code and it seems you use Makie.meshscatter!, which does not have this option.

@juliohm
Copy link
Member

juliohm commented Dec 22, 2022 via email

@stla
Copy link
Contributor Author

stla commented Dec 22, 2022

Yes, it works. Thanks.

@stla stla closed this as completed Dec 22, 2022
@juliohm
Copy link
Member

juliohm commented Dec 22, 2022 via email

@stla
Copy link
Contributor Author

stla commented Dec 26, 2022

Actually I still have the same problem: if I provide a color per face, the mesh is not smoothed. So I can't do something like this for example, with sharp colors but smoothed: https://youtu.be/vLkNQh3Sv8w

@juliohm
Copy link
Member

juliohm commented Dec 26, 2022

What exactly is smoothed? I am trying to understand what exactly is the difference between the current output and the desired output. On Zulip we have a thread where I asked if you could share some screenshots of the same geometry with the same angle to compare the different results.

@stla
Copy link
Contributor Author

stla commented Dec 26, 2022

On Zulip my two screenshots have the same angle.

By "not smoothed" I mean that we can see the faces of the mesh when we plot it, as if the normals were not taken into account.

Here is an example with rgl. The sphere at right has no normals, it is not smoothed.
Capture du 2022-12-26 19-43-07

@juliohm
Copy link
Member

juliohm commented Dec 26, 2022

Got it. Do you have a PR in mind here that could give this additional flexibility? I don't know how these normals play a role in OpenGL, but Makie probably has an option to use them or not. We just need to forward this option to the low-level Makie function in our recipe.

@stla
Copy link
Contributor Author

stla commented Dec 26, 2022

I don't have a PR in mind. I didn't study MeshViz yet, and I'm not a familiar with Makie. But I believe we can give the normals in Makie and there's an interpolate argument for the colors. Not sure.

@juliohm juliohm reopened this Dec 26, 2022
@juliohm juliohm added enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed labels Dec 26, 2022
@juliohm juliohm changed the title Blurry colors Smoothing option Dec 26, 2022
@juliohm
Copy link
Member

juliohm commented Jul 21, 2023

@stla appreciate if you can take a look at the option you mentioned.

@juliohm juliohm removed the enhancement New feature or request label Jul 27, 2023
@juliohm juliohm transferred this issue from JuliaGeometry/MeshViz.jl Jul 27, 2023
@juliohm juliohm changed the title Smoothing option Smoothing option in viz function Jul 27, 2023
@juliohm juliohm added the viz Issue with visualization recipes label Jul 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed viz Issue with visualization recipes
Projects
None yet
Development

No branches or pull requests

2 participants