4 ms·
Asymptote: 2D and 3D TeX-Aware Vector Graphics Language
- rjrodger 3y agoThis is pretty fun - used it to generate diagrams for my book!
- a_e_k 3y agoYep! I used it for all of the diagrams in my chapter (Ch. 31) in Ray Tracing Gems 2. My diagrams were showing lens optics and it was really nice to be able to parameterize the main inputs (e.g., focal length, sensor distance, object placement, etc.) and then let Asymptote derive everything from there. I could tweak the parameters and have it instantly recalculate the diagram until I found something that looked good. All while keeping everything placed consistently. The other thing I did was to start by creating a single master diagram that was super messy and cluttered but contained everything that I might want. Then I copied that and selectively commented out parts, leaving just the elements that I wanted to highlight. I think I'd have gone crazy if I was trying to calculate and draw everything to scale manually in Illustrator or something like that, while making tweaks across all the figures to keep them consistent. And all was driven from a Makefile, of course.
- hgsgm 3y agoIs asymptote easier than LaTeX TikZ? https://www.overleaf.com/learn/latex/TikZ_package https://www.overleaf.com/learn/latex/TikZ_package
- jimhefferon 3y agoI like it better. I used it for all the diagrams in my latest book. I especially like the 3D. (BTW, the tutorial is first rate.)
- arjvik 3y agoTikz has a LaTeX-inspired syntax that's hard to understand unless you're very competent with LaTeX. You will find yourself constantly looking up syntax for things like loops until you're used to Tikz. Asymptote has a C-like syntax that's very easy to understand and remember. Essentially the only new thing is the data types (i.e. pair, pen) and literals for those types that Asymptote introduces.
- aziis98 3y agoYeah, I really like how they do operators. The ".." concatenation operator is very nice to use and works well even when used in "imperative" code. It's also nice that all operators can be overloaded and the default overloads for pairs and triples can make constructing 2d and 3d shapes very concise. It's a small language but with very reasonable syntax decisions.
- pmalynin 3y agoAh proud to see another great product from my alma mater - University of Alberta.
- Xisesari 3y agoI love Asymptote, however, I still miss one feature: imagine a line and a surface, the line interects the surface; and I want to draw a picture where invsible part of the line is dashed. There are discussions about the feature (solids?). As I underatand, for now, there's no built-in solution. (I could calculate coordinates of invisible part of the line, but it requires some time)
- scrubs 3y agoOh man; I'm checking this out. Plaudits!!!!