Commit 1276abd2 authored by Alexandre Duret-Lutz's avatar Alexandre Duret-Lutz
Browse files

* wrap/python/cgi/ltl2tgba.in: Convert GIFs to PNGs. Restrict

the size of dot's output to 1024x1024.
* src/tgbaalgos/dotty.cc (dotty_bfs::start): Do not preset
the size of the graph.  Set height=0 for the invisible state.
parent e88b41d8
2003-08-07 Alexandre Duret-Lutz <adl@gnu.org>
* wrap/python/cgi/ltl2tgba.in: Convert GIFs to PNGs. Restrict
the size of dot's output to 1024x1024.
* src/tgbaalgos/dotty.cc (dotty_bfs::start): Do not preset
the size of the graph. Set height=0 for the invisible state.
2003-08-06 Alexandre Duret-Lutz <adl@gnu.org>
* src/ltlparse/ltlparse.yy: Fix precedence OP_OR < OP_XOR < OP_AND.
......
......@@ -18,8 +18,7 @@ namespace spot
start()
{
os_ << "digraph G {" << std::endl;
os_ << " size=\"7.26,10.69\"" << std::endl;
os_ << " 0 [label=\"\", style=invis]" << std::endl;
os_ << " 0 [label=\"\", style=invis, height=0]" << std::endl;
os_ << " 0 -> 1" << std::endl;
}
......
......@@ -37,5 +37,8 @@ You have to install the script yourself if you want to test it.
will run the script when the HTTP server processes the
request.
ltl2tgba purges old files (>10min) from this directory
ltl2tgba purges old files (>10min) from this directory
each time it runs.
4) `dot' from the GraphViz package, and `convert' from
the ImageMagick package should be in the PATH.
......@@ -126,9 +126,11 @@ if show_formula_gif:
outfile = spot.ofstream(imgprefix + '-f.dot')
spot.dotty(outfile, f)
del outfile
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-o',
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
imgprefix + '-f.gif', imgprefix + '-f.dot')
print '<img src="' + imgprefix + '-f.gif">'
os.spawnlp(os.P_WAIT, 'convert', 'convert',
imgprefix + '-f.gif', imgprefix + '-f.png')
print '<img src="' + imgprefix + '-f.png">'
print '<H2>Automaton</H2>'
......@@ -155,9 +157,11 @@ if show_automaton_gif:
outfile = spot.ofstream(imgprefix + '-a.dot')
spot.dotty_reachable(outfile, concrete)
del outfile
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-o',
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
imgprefix + '-a.gif', imgprefix + '-a.dot')
print '<img src="' + imgprefix + '-a.gif">'
os.spawnlp(os.P_WAIT, 'convert', 'convert',
imgprefix + '-a.gif', imgprefix + '-a.png')
print '<img src="' + imgprefix + '-a.png">'
if show_degen_dot or show_degen_gif:
......@@ -174,9 +178,11 @@ if show_degen_dot or show_degen_gif:
outfile = spot.ofstream(imgprefix + '-d.dot')
spot.dotty_reachable(outfile, degen)
del outfile
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-o',
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
imgprefix + '-d.gif', imgprefix + '-d.dot')
print '<img src="' + imgprefix + '-d.gif">'
os.spawnlp(os.P_WAIT, 'convert', 'convert',
imgprefix + '-d.gif', imgprefix + '-d.png')
print '<img src="' + imgprefix + '-d.png">'
else:
degen = 0
......@@ -200,9 +206,11 @@ if show_relation_dot or show_relation_set or show_relation_gif:
spot.bdd_print_dot(outfile, concrete.get_dict(),
concrete.get_core_data().relation)
del outfile
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-o',
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
imgprefix + '-b.gif', imgprefix + '-b.dot')
print '<img src="' + imgprefix + '-b.gif">'
os.spawnlp(os.P_WAIT, 'convert', 'convert',
imgprefix + '-b.gif', imgprefix + '-b.png')
print '<img src="' + imgprefix + '-b.png">'
if show_acceptance_dot or show_acceptance_set or show_acceptance_gif:
print '<H3>Acceptance relation</H3>'
......@@ -217,9 +225,11 @@ if show_acceptance_dot or show_acceptance_set or show_acceptance_gif:
spot.bdd_print_dot(outfile, concrete.get_dict(),
concrete.get_core_data().accepting_conditions)
del outfile
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-o',
os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
imgprefix + '-c.gif', imgprefix + '-c.dot')
print '<img src="' + imgprefix + '-c.gif">'
os.spawnlp(os.P_WAIT, 'convert', 'convert',
imgprefix + '-c.gif', imgprefix + '-c.png')
print '<img src="' + imgprefix + '-c.png">'
if show_lbtt:
print '<H3>LBTT conversion</H3>'
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment