Skip to content

Commit

Permalink
use png instead of svg for docs output
Browse files Browse the repository at this point in the history
  • Loading branch information
j-fu committed Jun 7, 2024
1 parent d3d2e60 commit 7a7aa06
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 24 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "SimplexGridFactory"
uuid = "57bfcd06-606e-45d6-baf4-4ba06da0efd5"
authors = ["Juergen Fuhrmann <juergen.fuhrmann@wias-berlin.de>"]
version = "2.1.0"
version = "2.1.1"

[deps]
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
Expand Down
30 changes: 15 additions & 15 deletions examples/examples2d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function triangulation_of_domain()
end

#
# ![](triangulation_of_domain.svg)
# ![](triangulation_of_domain.png)
#

#
Expand Down Expand Up @@ -80,7 +80,7 @@ function nicer_triangulation_of_domain()
builder
end
#
# ![](nicer_triangulation_of_domain.svg)
# ![](nicer_triangulation_of_domain.png)
#

# ## Triangulation with subregions
Expand Down Expand Up @@ -120,7 +120,7 @@ function triangulation_of_domain_with_subregions()
builder
end
#
# ![](triangulation_of_domain_with_subregions.svg)
# ![](triangulation_of_domain_with_subregions.png)
#

# ## Direct specification of input arrays
Expand All @@ -138,7 +138,7 @@ function direct_square(Generator = Triangulate)
regionvolumes = [0.01])
end
#
# ![](direct_square.svg)
# ![](direct_square.png)
#

# ## Local refinement
Expand Down Expand Up @@ -179,7 +179,7 @@ function square_localref()
builder
end
#
# ![](square_localref.svg)
# ![](square_localref.png)
#

# ## Domain with holes
Expand Down Expand Up @@ -245,7 +245,7 @@ function swiss_cheese_2d()
builder
end
#
# ![](swiss_cheese_2d.svg)
# ![](swiss_cheese_2d.png)
#

# ## Glueing in another grid
Expand Down Expand Up @@ -297,7 +297,7 @@ function glue_2d()
grid2 = glue(grid1, grid2)
end
#
# ![](glue_2d.svg)
# ![](glue_2d.png)
#


Expand All @@ -307,27 +307,27 @@ using GridVisualize
function generateplots(picdir; Plotter = nothing)
if isdefined(Plotter, :Makie)
size = (600, 300)
Plotter.activate!(; type = "svg", visible = false)
Plotter.activate!(; type = "png", visible = false)

p = builderplot(triangulation_of_domain(); Plotter, size)
Plotter.save(joinpath(picdir, "triangulation_of_domain.svg"),p)
Plotter.save(joinpath(picdir, "triangulation_of_domain.png"),p)

p = builderplot(nicer_triangulation_of_domain(); Plotter, size)
Plotter.save(joinpath(picdir, "nicer_triangulation_of_domain.svg"),p)
Plotter.save(joinpath(picdir, "nicer_triangulation_of_domain.png"),p)

p = builderplot(triangulation_of_domain_with_subregions(); Plotter, size)
Plotter.save(joinpath(picdir, "triangulation_of_domain_with_subregions.svg"),p)
Plotter.save(joinpath(picdir, "triangulation_of_domain_with_subregions.png"),p)

p = builderplot(square_localref(); Plotter, size)
Plotter.save(joinpath(picdir, "square_localref.svg"),p)
Plotter.save(joinpath(picdir, "square_localref.png"),p)

p = gridplot(direct_square(); Plotter, size)
Plotter.save(joinpath(picdir, "direct_square.svg"),p)
Plotter.save(joinpath(picdir, "direct_square.png"),p)

p = builderplot(swiss_cheese_2d(); Plotter, size)
Plotter.save(joinpath(picdir, "swiss_cheese_2d.svg"),p)
Plotter.save(joinpath(picdir, "swiss_cheese_2d.png"),p)

p = gridplot(glue_2d(); Plotter, size)
Plotter.save(joinpath(picdir, "glue_2d.svg"),p)
Plotter.save(joinpath(picdir, "glue_2d.png"),p)
end
end
16 changes: 8 additions & 8 deletions examples/examples3d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ function tetrahedralization_of_cube()

simplexgrid(builder; maxvolume = 0.001)
end
# ![](tetrahedralization_of_cube.svg)
# ![](tetrahedralization_of_cube.png)

# ## Cube based on primitves
#
Expand Down Expand Up @@ -83,7 +83,7 @@ function tet_cube_with_primitives()
simplexgrid(builder)
end

# ![](tet_cube_with_primitives.svg)
# ![](tet_cube_with_primitives.png)

# ## Glue-in of existing grid
#
Expand Down Expand Up @@ -113,7 +113,7 @@ function glue_3d()
glue(gouter, grid3; g1regions = 1:6, interface = 7)
end
#
# ![](glue_3d.svg)
# ![](glue_3d.png)
#

# ## Load STL model
Expand All @@ -129,7 +129,7 @@ function stl_3d()
simplexgrid(b; maxvolume = 1.0e-2)
end
#
# ![](stl_3d.svg)
# ![](stl_3d.png)
#


Expand All @@ -142,19 +142,19 @@ function generateplots(picdir; Plotter = nothing)

Plotter.clf()
gridplot(tetrahedralization_of_cube(); Plotter, size, zplane = 0.5)
Plotter.savefig(joinpath(picdir, "tetrahedralization_of_cube.svg"))
Plotter.savefig(joinpath(picdir, "tetrahedralization_of_cube.png"))

Plotter.clf()
gridplot(tet_cube_with_primitives(); Plotter, size, zplane = 5, azim = 47, elev = 80, interior = false)
Plotter.savefig(joinpath(picdir, "tet_cube_with_primitives.svg"))
Plotter.savefig(joinpath(picdir, "tet_cube_with_primitives.png"))

Plotter.clf()
gridplot(glue_3d(); Plotter, size, azim = 0, elev = 15, xplanes = [5])
Plotter.savefig(joinpath(picdir, "glue_3d.svg"))
Plotter.savefig(joinpath(picdir, "glue_3d.png"))

Plotter.clf()
gridplot(stl_3d(); Plotter, size, xplanes = [5])
Plotter.savefig(joinpath(picdir, "stl_3d.svg"))
Plotter.savefig(joinpath(picdir, "stl_3d.png"))

end
end

2 comments on commit 7a7aa06

@j-fu
Copy link
Member Author

@j-fu j-fu commented on 7a7aa06 Jun 7, 2024

Choose a reason for hiding this comment

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

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

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

Registration pull request created: JuliaRegistries/General/108467

Tip: Release Notes

Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.

@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v2.1.1 -m "<description of version>" 7a7aa0684a250c41f56967b1b73188aa5b8fbad6
git push origin v2.1.1

Please sign in to comment.