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

`introspect` for graphs which are not trees

Open danrocag opened this issue 3 years ago • 0 comments

introspect behaves in a somewhat weird way when given a graph which is not a tree. For example, if we apply it to the Sierpinski fractal from the tutorial:

function sierpinski(n)
    if n == 0
        compose(context(), polygon([(1,1), (0,1), (1/2, 0)]))
    else
        t = sierpinski(n - 1)
        compose(context(),
                (context(1/4,   0, 1/2, 1/2), t),
                (context(  0, 1/2, 1/2, 1/2), t),
                (context(1/2, 1/2, 1/2, 1/2), t))
    end
 #end

introspect(sierpinski(3))

Then the edges are correct, but many irrelevant copies of the vertices are shown. Can this be fixed?

danrocag avatar Apr 21 '21 12:04 danrocag