GalerkinToolkit.jl icon indicating copy to clipboard operation
GalerkinToolkit.jl copied to clipboard

Use Makie instead of paraview as the default visualization method in the tutorials

Open fverdugo opened this issue 1 year ago • 3 comments

WIP in this branch: https://github.com/fverdugo/GalerkinToolkit.jl/tree/makie

cc @raar1 @Cmurilochem

I have some low level functions already:

Screenshot from 2024-09-24 18-00-52

fverdugo avatar Sep 24 '24 16:09 fverdugo

Basic tooling added in https://github.com/fverdugo/GalerkinToolkit.jl/commit/05d36d2ee18d4b60e954266de2195499184ad370 to visualize with Makie. It Should be enough for the Poisson tutorial.

These functions have been added

# Visualize mesh
Makie.plot(mesh;edgecolor=:black)

# Visualize FE function
Makie.plot(Ω;color=uh)

Some important details missing:

Fix before merging

  • [x] Use an Extension module instead of adding Makie directly as a dependency: https://www.youtube.com/watch?v=TiIZlQhFzyk @Cmurilochem https://docs.makie.org/stable/explanations/recipes#Makie-Package-Extension
  • [x] vtk_plot vs save_vtk (redundant). Maybe keep the first, but using the low level functions of the second. @fverdugo EDIT: The solution was to remove vtk_plot and vtk_save and add new methods to the existing function WriteVTK.vtk_grid.

Fix later

  • [ ] Fix shadows (orientation of triangles)
  • [ ] Add suport for quads/hexs (simplexify)
  • [ ] Fix camera positioning
  • [ ] Fix ugly edges
  • [ ] Visualization of PMeshes

We can merge a first version to main after fixing the first and second items. In this way we can already write the tutorials using these new functions. The other items can be fixed later.

fverdugo avatar Sep 25 '24 16:09 fverdugo

@Cmurilochem the branch below is ready to start with the extension module

https://github.com/fverdugo/GalerkinToolkit.jl/tree/makie

fverdugo avatar Sep 27 '24 15:09 fverdugo

@Cmurilochem the branch below is ready to start with the extension module

https://github.com/fverdugo/GalerkinToolkit.jl/tree/makie

Thanks @fverdugo. I will start today looking into it.

Cmurilochem avatar Oct 02 '24 06:10 Cmurilochem