Skip to content

Commit

Permalink
Fixing post_processing plots (#2295)
Browse files Browse the repository at this point in the history
* Using grid instead of mesh

* Fixing empty plots.
Adding a cmap to avoid buggy plots

* Undo using grid.

---------

Co-authored-by: Camille <[email protected]>
  • Loading branch information
germa89 and clatapie authored Sep 4, 2023
1 parent 84e76c1 commit 19fcd61
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/ansys/mapdl/core/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -398,6 +398,9 @@ def _general_plotter(
UserWarning,
)

if not cmap:
cmap = "bwr"

if background:
plotter.set_background(background)

Expand Down Expand Up @@ -442,7 +445,7 @@ def _general_plotter(
for each_mesh in mesh_:
plotter.add_mesh(
each_mesh,
scalars=None, # scalars,
scalars=scalars,
scalar_bar_args=scalar_bar_args,
color="w", # mesh.get("color", color),
style=mesh.get("style", style),
Expand Down

0 comments on commit 19fcd61

Please sign in to comment.