Project

imaginator

0.0
No commit activity in last 3 years
No release in over 3 years
Image generator for LaTeX/Graphviz source
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 1.8.3
 Project Readme

README

Imaginator is a ruby library to generate images from LaTeX/Graphviz code in a background job. This library is derived from my latex-renderer library.

Usage

Imaginator.uri = 'drbunix://tmp/imaginator.sock'
Imaginator.dir = '/tmp/imaginator'

Imaginator.run do |server|
  server.add_renderer(:math,  Imaginator::LaTeX.new)
  server.add_renderer(:dot,   Imaginator::Graphviz.new(:cmd => 'dot'))
  server.add_renderer(:neato, Imaginator::Graphviz.new(:cmd => 'neato'))
  server.add_renderer(:twopi, Imaginator::Graphviz.new(:cmd => 'twopi'))
  server.add_renderer(:circo, Imaginator::Graphviz.new(:cmd => 'circo'))
  server.add_renderer(:fdp,   Imaginator::Graphviz.new(:cmd => 'fdp'))
end

...

name = Imaginator.get.enqueue(:math, '1+1')
...
filename = Imaginator.get.result(name)

TODO

  • Write unit tests or specs

Authors

Daniel Mendler

License

This library is released under the MIT license.