texgd is fed by environment variables containing the input formula, the filename of a TeX header, and some other extra information. It outputs quickly and nicely a PNG file with the rendered formula, and leaves as a side effect some reusable TeX fonts in a configurable directory.