JuliaGeometry / GeometryTypes.jl

Geometry types for Julia
Other
67 stars 41 forks source link

Exact commands to use GLVisualize? #121

Closed nro-bot closed 6 years ago

nro-bot commented 6 years ago

Hello, The README.md says "Some of the types offered by GeometryTypes visualized with GLVisualize"

Would it be possible to see the exact commands (or at least an example) of how the images were rendered?

Thanks!

edljk commented 6 years ago

Makie.jl (which calls GLVisualize) is perhaps easier to learn. See the following example for ploting a sphere

using Makie, GeometryTypes
scene = Scene(resolution = (500, 500))
MakiE.mesh(Sphere(Point3f0(0), 1f0))
center!(scene)

Other examples can be found here (just replace MakiE by Makie :-)).

SimonDanisch commented 6 years ago
using GLVisualize, GeometryTypes
prim = ... # the code from the example
_view(visualize(prim))

I had to do GLNormalMesh(prim) for the 3D primitives, but that just might be because I'm on a weird Makie refactor GLVisualize branch ;)