I'd like to know what LuaTeX offers in terms of graphics: I'm mostly interested in pstricks and tikz/pgfplots. Could it help tikz to run faster? Would it help tikz to handle 3D non-parallel figures? (which is not available yet and is CPU consuming). What could it bring to the pstricks package users?

  • 2
    Are you offering to write the necessary code :-) – Joseph Wright Jan 8 '11 at 19:32
  • not really :) I'm super bad at coding anything. I'm just foreseeing interesting coming possibilities. If I can be of any help, I'll be happy though. – pluton Jan 8 '11 at 19:42
  • Apart from PSTricks and TikZ, there are other solutions for graphics: metapost, which is in active development and part of LuaTeX/ConTeXt, and Asymptote, which is very good at 3D graphics. – Philipp Jan 8 '11 at 21:23
  • yes about metapost. I'm not a big fan of asymptote. A luametapost could be nice as well :) – pluton Jan 8 '11 at 21:25
  • @Philipp: Metapost is in active development? Who does it? – user2478 Jan 27 '11 at 8:55

In principle, LuaTeX offers more flexibility, and in particular more speed, for Tikz, pgfplots, etc. This is because the work (especially floating-point maths) is going to be much easier to do in Lua than in TeX. On the other hand, PStricks uses the PostScript language for the hard work, and it already offers native support for a lot of this work. So there is much less scope for assisting there. (Herbert may have more to say on PStricks, I suspect.)

  • A Lua backend for pgf-math would be really useful! – Caramdir Jan 8 '11 at 19:59
  • @Caramdir. Probably not so hard, as you need to do very little for most of the maths, and it becomes a 'glue job'. I guess it is a question of time. (At some stage, we'll need to think about this for LaTeX3, but at the moment I'd prefer to focus on other issues.) – Joseph Wright Jan 8 '11 at 20:00
  • @Joseph: can you elaborate on "we'll need to think about this for LaTeX3". Thanks. And yes, that'd be great if Herbert could comment on pstricks and LuaTeX. – pluton Jan 10 '11 at 16:30
  • @pluton. There are places (for example floating-point work) were it's possible to do stuff with TeX but would be much faster in Lua. So there will be areas where we'll want to have TeX code for pdfTeX and XeTeX, with a Lua alternative 'hidden' within the same LaTeX3 interface. See the l3fp module, where I'd like to implement \fp_div:Nn, etc. in Lua. The idea would be that for packages that do not require LuaTeX there is still a performance benefit without needing to worry about the detail (of course, I have to do that). – Joseph Wright Jan 10 '11 at 17:01
  • I've done some testing, and it turns out that pgf's non-floating point math functions are faster than Lua's. Of course the Lua functions offer higher precision and a bigger range than any calculations with TeX's dimensions can achieve. – Caramdir Jan 11 '11 at 1:13

Recently the developer of tkz-euclide, tkz-graphe and some other graphics package has announced on fr.comp.text.tex that he will adapts his code to Lua (now it's gnuplot who does the job to calculate coordinate).

P.S. I would like to do a comment of these «answer», but i haven't enough reputation yet to comment

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.