Spiro 0.01 release

raph's picture

Typophiles,

After years of talking about a spiral-based curve editing tool, the provisional patent application is filed, and I've made an unpolished release of the stuff I have now. Brave souls can check it out to see what I've been talking about. Others among you may choose to wait until there's a release that's not quite as spartan.

I made a Mac build, but loading and saving is more or less not implemented (you can kinda make it work using the commandline, but it really needs a file dialog). Background images (for tracing) are not supported yet either.

The solver has also not been tuned for numerical robustness, so when you play around with it, you'll often see it fail to solve the spline. It does work reliably when the pattern plate represents a real font shape rather than random points, though.

It's free software (GPL), and patches for improvements are greatly appreciated.

http://levien.com/spiro/

Toby's picture

Great stuff, congrats! I see this as a better, more useful alternative to the sketch mode in Fontlab.

clauses's picture

Great stuff! Should speed up a 'start designing directly on the computer' sort of a work process. Will it be compatible with UFO's or Fontlab files?

guifa's picture

Great program. I did some quick sketching to figure out how it works. However on the Mac version I'm getting a few anomalies, though I'm not sure if it's Mac-specific or not (though they are pretty. They occur when I'm dragging points around, and and in drag randomly at certain points the design will "expload" into some of the forms you see below. If you need any help with the Mac OS X programming side I'd be willing to help out if you'd like.




«El futuro es una línea tan fina que apenas nos damos cuenta de pintarla nosotros mismos». (La Luz Oscura, por Javier Guerrero)

hrant's picture

Pretty - but letters, please!

hhp

blank's picture

I would so love to see Adobe license this stuff for Illustrator CS 5.

sgh's picture

Congratulations on your release, Raph! Good luck with writing your dissertation---I look forward to reading the math behind these curves.

You might also want to mention on your web page that ppedit compiles on Linux (and from looking at the Makefile, probably Windows, too). For those who don't want to compile ppedit to try it themselves, let me describe the basics:

Curves are drawn with curve, corner, and tangent points as normal, but there are only on-curve points---no off-curve points. The shape of the interpolated spline can be changed by adding more points to the curve and then moving them. Moving a point added to a Bezier curve is a pain, because then all of the off-curve control points have to be recalculated to make the curve smooth. However, Raph's program recalculates the spline to be smooth as you move the point (this is made easier by using the Cornu spirals, from my understanding), so that you always have a smooth curve. It's actually more intuitive than I thought it would be, but it still takes some getting used to.

raph's picture

Thanks for all the positive feedback!

@guifa: if you want to try your hand at adding open/save dialogs, that would be appreciated (currently, Apple-S just saves into a file called "plate"). Just make sure any Mac-specific code is bracketed by #ifdef X3_CARBON, so it doesn't break the Linux build.

The solver is known not to be numerically stable when the angles get big. If you stick with small angles, those pretty but unuseful spirals won't happen. I'm working on a more stable solver, but it's not ready yet. This stuff is rocket science, literally - the math I'm using is based on the calculus of variations, which has applications in computing optimal trajectories for spacecraft.

@hrant: Inconsolata was designed entirely using these spirals, as was Christian Gothic and pretty much all of my work-in-progress for the last year or so. The .plate files for Inconsolata are all posted.

On the Mac, you can open a .plate file by going to the directory containing ppedit.app, and typing "./ppedit.app/Contents/MacOS/ppedit u.plate". Obviously, a real Open dialog would be much more useful.

@sgh: the Windows port is started, but far from complete. I probably won't finish it myself, because I've lately become more interested in porting the code to a web app.

@clauses: I'm not able (due to time constraints) to do any of that kind of integration work myself, but would be happy to help others do so. In the case of Fontlab compatibility, for you to be able to edit interactively inside the app, they'd probably need to license the technology. A plug-in or a batch-mode converter could probably be done as a separate module, though, which would be compatible with the free GPL licensing terms.

And there's been talk of using the UFO format as a container for the curves, similar to the .plate file but in XML. (It's said that XML is for people who feel that Lisp doesn't have enough parentheses).

@jpad: I would love that, of course.

Because I'm starting at Google in a couple weeks, I won't be beating the bushes myself to push this technology out into the world. To a large extent, I'm "throwing the technology over the fence." It's an opportunity to see what the community can do with it, both in the free software world (it's being demoed today at LGM in Montreal), and whether users can generate enough interest and excitement to spur proprietary vendors to pony up for a license. It is my experience that companies tend to be extremely reluctant to do such things. I'd like to be proven wrong, but that's the main reason I'm taking a job in the advertising industry rather than trying to make a go on my own with technology licensing.

blank's picture

Well, I hope the people at inkscape see your work and consider adding it to theirs. Good luck at Google.

guifa's picture

I could see a lot of nice things that could be in an OS X specific build. I'll take a look at the code when I get a chance and see if there's a way I can convert (or maybe it's already being done) the drawing view into an NSView. Once that's done, it seems you basically have everything you need to make a really sharp looking Mac app.

And hrant: those are too letters ... for my ... uh... dingbat font.

«El futuro es una línea tan fina que apenas nos damos cuenta de pintarla nosotros mismos». (La Luz Oscura, por Javier Guerrero)

clauses's picture

Oh God I'd wish I could program. These new kinds of approaches to designing digital type on the terms of a digital process are needed. The way the hand could draw the 'right' curves on paper is lost in the Bézier approach. Combine what you are doing with something like Metafont and we would have something truly mindblowing. Ahh dreams.

abattis's picture

@clauses: It is compatible with FontForge's SFD, and as Fontforge recently added python scripting and native UFO support, you should be able to pipe it through FontForge to UFO and to FontLab. Why you'd want FontLab at all is a mystery to me, though, since Spiro and FontForge is more than capable - just look at Inconsolata :-) Also, regarding MetaFont, I figure the way it goes directly from code to bitmaps is its biggest problem. If it went to (Spiro) outlines, that would allow a "dreamweaver" code/design view and workflow.

@guifa: Mac OS X only features would be a shame - I hope it will remain as cross platform as possible

@jpad: I was discussing Inkscape integration with the Inkscape developers at the LGM today and its definitely going in, although on a medium time frame - as part of the existing lib2geom efforts.

guifa's picture

I didn't mean OS X only features per se. Only that I think it would be possible to encapsulate the spiral view into an NSView, thus making it no different to Interface Builder than an NSTextField. Again, I've not had a look at the source yet (I do plan on it tho) and so I'm not sure how separate you've got the different parts of the app, although if you're heading off to Google I'd imagine it's nicely modularised.

There are menu options for changing betwixt corner and curve points, etc. With those hooks, it could definitely open up some interesting possibilities if it can be made into a framework, which would still (I'd think) remain quite platform independent as well as make it more accessible to other developers for any number of other applications besides just font-design. If I'm rambling a bit excuse me, it is cinco de mayo (well, now it's seis de mayo).

«El futuro es una línea tan fina que apenas nos damos cuenta de pintarla nosotros mismos». (La Luz Oscura, por Javier Guerrero)

hrant's picture

> Why you’d want FontLab at all is a mystery to me

Come on.

> regarding MetaFont, I figure the way it goes directly
> from code to bitmaps is its biggest problem.

It's not a problem if you see it for what it is: a combination of glyph descriptor and RIP. But a very real -and somewhat related- problem of Metafont is its foundation on the theory that letters should have skeletons. This is a naive, primitive and fatal fallacy, and one at the heart of chirography as well. It's the reason Computer Modern looks so crappy.

hhp

raph's picture

@guifa: It's an HIView, which is almost the same thing as an NSView.

You'll find that the code is factored to be quite modular, but perhaps not quite in the way that you'd expect. Writing truly cross-platform apps is hard. If I didn't care about that, I'd have done this as a Cocoa app, in Objective C, using NIB's. As it is, the UI is built procedurally, and there's a layer (x3) which translates that into the code for Carbon or Gtk+2. (it could do Windows too; that's a Small Matter of Programming).

So, for example, the menu item for "delete point" is created thus:

x3menuitem(menu, "Delete Point", "delp", "<cmd>d");

The point is that you don't have to do redo all the UI work for each platform. An earlier version (see carbon_main.c) did load a NIB, and that was ok, but I like it better the way it is now.

@abattis: It is compatible with FontForge’s SFD

Not really. There's a batch-mode converter that spits out .sfd files. It's certainly doable to write a batch-mode converter for (cubic Bezier flavor) UFO's, or whatever FontLab accepts most natively. Given that FontLab is Python-scriptable, it should also be quite feasible to write a non-interactive import plugin that can be selected from the UI. In other words, an "import spiro plate" menu item.

There are different levels of compatibility. Batch-mode conversion is the lowest, interactive editing with lossless round-trip is the highest. If people seriously want to use these tools in production, anything less than that is a time-waster.

And as for FontForge, it kinda works for me, but there are lots of features of FontLab I miss, like stroke offset that isn't horribly buggy, Python scripting, a sane UI for OpenType contextual programming, etc. I've also had to fix a few bugs in it. Fortunately, because I am a rocket scientist, I can do that, but for most type designers, I think the experience will be less than fulfilling.

@hrant: problem of Metafont is its foundation on the theory that letters should have skeletons.

Metafont doesn't force you into that mode. The Computer Modern fonts are all defined as strokes, but AMS Euler is done more or less using the same technology as Adobe Type 1. Of course, Euler doesn't have any of the optical scaling or variation features either.

@clauses: The real power of Spiro comes out when you combine the spline fitter with techniques for variation. I have some ideas on this, which I will write up soon. My experiments thus far have been very encouraging, suggesting that it will be much easier to use than Multiple Master technology. Here's an experiment I did with linear interpolation of the control points to blend a weight axis:

The advantage of this technique is that all of the blends are guaranteed to have smooth curvature too. Using Beziers, in the general case, there's no guarantee of smoothness of any kind.

hrant's picture

Metafont does support outlining and not just expanded strokes, but the only real reason to use Metafont is its parametric abilities, and (please correct me if I'm wrong) these only work with strokes. What would be amazing is if somehow we could use parametrics with outlines; even more amazing would be a GUI for that!

The variation angle you mention seems very interesting, although
I don't get exactly why spirals would be better at it than beziers.

> lossless round-trip

Do you really mean that?
1) I thought it can't be lossless.
2) It really only has to be one-way to be sufficiently useful.

hhp

sgh's picture

@hrant: Metafont does support outlining and not just expanded strokes, but the only real reason to use Metafont is its parametric abilities, and (please correct me if I’m wrong) these only work with strokes.

MetaPost (essentially MetaFont for Postscript) supports outlines, and of course since everything is scriptable, parametric abilities are available to work with strokes. MetaType1 is a set of MetaPost macros that makes it easy to make a CFF-based font (Type1 or CFF-flavored OTF). My font Aurulent Sans is being developed using MetaType1. The use of a weight parameter can be seen when comparing the regular and bold weights.

What would be amazing is if somehow we could use parametrics with outlines; even more amazing would be a GUI for that!

The ability to script is much more powerful than just the parametrics, and GUIs aren't very good for representing scripts. If you're just interested in the parametrics, then it might be possible to represent them graphically, but here the main problem is that the dimension of the parameter space is probably too high to represent visually in a meaningful form.

hrant's picture

> parametric abilities are available to work with strokes.

So has anybody designed a MetaPost outline font where the x-height is parametric?

> Aurulent Sans ... weight parameter

It's nice to see such an effort. The question is (and this might be difficult to answer) was it worth the effort, compared to a "plain" interpolation setup in FontLab?

> the dimension of the parameter space is probably too high to represent visually

Maybe I'm not getting you, but for a font that's meant
to be read the parameters can't really stray too far...

> The ability to script is much more powerful than just the parametrics

But FontLab has the former, but not the latter,
so the valuable sort of power is in the latter.

hhp

rosaiani's picture

I like this a lot, this should be a great option to Bezier editing, hopefully it will make my s (no pun intended) look better!
Congratulations, and I think we are in front of the next Pierre Bezier right here...
Very honored cheers
Rodrigo

abattis's picture

@Raph: And as for FontForge, it kinda works for me, but there are lots of features of FontLab I miss, like stroke offset that isn’t horribly buggy, Python scripting, a sane UI for OpenType contextual programming

Python scripting got added to FontForge last week, along with a total rework of OpenType features and lookups.

raph's picture

@abattis: Python scripting got added to FontForge last week

That's seriously cool news. I can still imagine that most professional type designers would rather use FontLab though.

@hrant: > the dimension of the parameter space is probably too high to represent visually

Computer Modern has something on the order of 60 parameters for things ranging from the obvious ascender/descender height to more subtle things like the parameters for the serifs. That's a very high dimensionality of the parameter space, even if the amount of the change is subtle.

The key to making variation work for people who don't have advanced computer science degrees is to keep the number of dimensions down. Here's an outline of my ideas for that:

1. For optical scaling, use stroke offset for the bulk of the effect, with a little optional squooshing.

2. For things like ascender and descender lengths, allow points to be put on frames which can move independently of the main em. So, then, to lengthen descenders, pull the descender frame (global to the font) down.

3. For everything else, do interpolation. My gut feeling is that 2-dimensional interpolation (the corners of a quadrilateral) is the most that is intuitive to work with, and, if you can keep it to one, that's even better.

The number of active frames in any one glyph should be no more than three or so. The main thing interpolation is used for is weight (like the above image).

Also note that one of the most important aspects of optical scaling is the spacing and kerning. That can probably be done using simple interpolation between a "big" and a "little" size.

@rosaini: Thanks! Nice spirals in your avatar.

sgh's picture

@hrant: So has anybody designed a MetaPost outline font where the x-height is parametric?

x-height is a parameter in Aurulent Sans, and I imagine it is as well in other MetaType1-designed fonts, such as Antykwa Toruńska, Antykwa Półtawskiego, Kurier, and Iwona.

The question is (and this might be difficult to answer) was it worth the effort, compared to a “plain” interpolation setup in FontLab?

To me, scripting the outline of a glyph is MUCH easier than drawing it graphically. I find it much easier to say "Put point A here. Put point B here. Put point C here. Put point D 1/3 of the way between B and C. Draw a smooth curve from A to D to E, etc". That way I don't have to worry about whether the curve is smooth or not, where to put control points, etc. (Well, that's a bit of lie, often I need to give MetaType1 a little bit more help, but not too often.) And if the width changes, or the x-height changes, then the position of point A, etc is automatically recalculated when the scripts are run again.

The ability to script is much more powerful than just the parametrics

But FontLab has the former, but not the latter,
so the valuable sort of power is in the latter.

I have never used FontLab, so I don't know its scripting language. However, based on your comment, it sounds like it is not as powerful as MetaType1. Can you do the type of outline construction I described above? The parametric power comes from using the parameters in the construction. Of course, it is also (somewhat) difficult to create construction scripts that capture parameters. See this discussion and this discussion for thoughts on why a more parametric approach has not been more frequently used.

hrant's picture

> That’s a very high dimensionality of the parameter space

OK. Was that what Stephen was talking about? Also: assuming
the parameters don't interact (too much) couldn't one decide
to display/manipulate one or two at a time?

> x-height is a parameter in Aurulent Sans

Could we see how [well] it works out?

> based on your comment, it sounds like it is not as powerful as MetaType1.

What comment?
FontLab's scripting is Python, and everybody says it's plenty powerful.

What would be nice is to fold in parametric design.

> See this discussion and this discussion

The two links are the same.

hhp

sgh's picture

@hrant: Was that what Stephen was talking about? (regarding high dimensionality)

Yes.

sgh> based on your comment, it sounds like it is not as powerful as MetaType1.

hrant> What comment?
FontLab’s scripting is Python, and everybody says it’s plenty powerful.

The comment I was referring to was:

sgh> The ability to script is much more powerful than just the parametrics

hrant> But FontLab has the former, but not the latter,
so the valuable sort of power is in the latter.

You seem to be saying that parametric design cannot be done with FontLab's scripting tools. As I mentioned, I have never used FontLab, so I have no idea what the actual capability is. Just because FontLab uses Python, though, does not mean that the FontLab Python interface allows the needed operations. Possibly more importantly, is whether the interface makes it easy to design glyphs parametrically.

Here's an easy test for someone who knows Python scripting in FontLab: given the parameters of width, cap height, left and right side-bearing, vertical stroke width, and horizontal stroke width, draw a sans serif uppercase H. Then draw an uppercase O. If this can be done easily, then FontLab scripting has the potential for parametric design.

The two links are the same.

Oops. The two links should have been this discussion and this discussion.

sgh's picture

sgh> x-height is a parameter in Aurulent Sans

hrant> Could we see how [well] it works out?

What would you like to see?

clauses's picture

Did anyone ever get to play around with FontChameleon Pro before it was pulled from public consumption? Voices seem to rave about how fantastic it was. I guess it was not fully parametric, but relied to some extent on some predesigned endpoint to interpolate from? The reason I'm thinking about it is the fact that a number of parametric type engines have come and gone through the years. There is Metafont, FontChameleon, Incubator(?), LiveType and some HP stuff i forgot the name of. Why where they never successful? I can certainly understand why Metafont never went of the ground as it's made for the programmer and not for the designer (correct me if I'm wrong here). Is this parametric approach simply too complicated for the designer to take anywhere, or was it just the lack of GUI that kept it off? FontChamelon seemed to go all the way to the user, skipping the designer, which was it's point I guess.

@Raph: That interpolation you showed is exactly what I want.

hrant's picture

> You seem to be saying that parametric design
> cannot be done with FontLab’s scripting tools.

No, I don't know enough to say either way (and I don't see how I implied otherwise). On the other hand Python being a fully capable language shouldn't have a problem. The real problem is that there's not enough money in type for something that hard to happen, at least not quickly.

> whether the interface makes it easy to design glyphs parametrically.

To most people that means a GUI, and the answer is definitely
No in the case of FontLab... but really just as No for anything else.

> What would you like to see?

Let's say "skagy" varying from a pretty small to a pretty large x-height.

FontChameleon: I think I had a copy once, didn't get to really use it, and
then something quite mysterious happened and we've become deprived.

hhp

Christian Robertson's picture

Wow. This is really nice. Kudos for sharing the code. I'm hoping that we'll see more in the future.

Any thoughts on releasing the code under a more permissive license so it can be used in a certain well known commercial app? I realize that there is the remote potential that you might be able to license it, but it would be a real shame if the stuff never got picked up.

Christian Robertson's picture

If you need any convincing about the value of this technology, sit down and try to draw an s. It's fantastic. What took me forever to figure out with beziers happened almost automatically here.

raph's picture

Christian: suffice it to say that I've put a lot of thought into my licensing strategy, and am pretty happy with it.

Basically, if you're a type designer and want to have this kind of curve drawing tool in a production environment, you have four choices:

1. Learn to code and do it yourself.

2. Show some love to the free software community, and encourage them to integrate it into their leading design apps (Inkscape, FontForge).

3. Lobby the proprietary app vendors to license it.

4. Sit on your @ss and hope somebody else does 1-3.

Glad you like it!

rosaiani's picture

This makes my self esteem rise a million percent. It was done in 10 minutes.

Wish I could export it to illutrator and to hell with the pen tool ;)

William Berkson's picture

>Million percent

Hate to burst your bubble, but your S doesn't have the curves of Christian Robertson's S--and it isn't as good. You can debate how much it is Christian and how much the spiral tools. But here Christian says it was natural and easy for him to get a result with the spiral tools that would have been difficult and laborious with Bezier curves.

dberlow's picture

This is extremely interesting and I'm sure useful. The "traditional" S test, however, is of a specific S. And even before that, the "traditional" contour format test is to scan and digitize an FC-339 8 1/4" French Curve. e.g. http://www.steinlaufandstoller.com/French%20Curves%20Plastic.htm, and then, in this case, do post digitization traslations to CB and QB, so you can see it filled to black in output, or on the screen as the case may be.

William Berkson's picture

>French Curve

Looking at some internet sites, it seems that the most widely used French Curves are composed of sections of parabolas, hyperbolas, and elipses. These are all conic sections, can be described by quadratic equations, and hence can be drawn perfectly by quadratic bezier curves.

The Cornu spirals here are different. If I understand it rightly, sections between knots cannot be drawn accurately with either a *single* quadratic or cubic curve, though of course they can be approximated with multiple curves of either type.

I don't know if the Cornu spiral is on any French Curves.

raph's picture

@dberlow: The fact of a standardized test for drawing ability is most interesting. Do you have a cite in a book or journal for that test? If not, I can always do "personal communication".

I took your challenge, starting with an image of the FC-339 from the C-thru site. The drawing took about 8 minutes, and there are a total of 50 points.

And the conversion to Beziers (43 segments, each of which has 3 control points):

And here it is filled (PDF here if you want to print it out).

How'd I do?

@William: I believe it is used on some real french curves, because it's one of the relatively few analytical curves that has a nice inflection point in it. But I don't have a good cite. Again, one would be useful.

hrant's picture

William, as I explained in the other thread, it's not about evaluating the results out of context, it's about how much effort Raph's method saves. Whether Rodrigo's "S" is better or worse than Christian's is irrelevant; the point is to consider how much effort each of them saved in getting to that in-some-way satisfactory result.

> the “traditional” contour format test is to scan and digitize ...
> http://www.steinlaufandstoller.com/French%20Curves%20Plastic.htm

Why does one have to wait 9+ years to be told something this relevant! :-/
When you think about it though I guess it's common sense. Aaah, hindsight!

BTW, what exactly is the traditional "S" test?

> ... can be drawn perfectly by quadratic bezier curves.

Yet once more: it's not about this being possible
or not, it's about this being worth doing or not.
"Perfectly" should not come into the discussion.

It's possible to go to the grocery store crawling on
your back, naked. This does not make it worth doing.
And the "imperfection" of using a car, a bicycle or
your feet does not make any of those a bad idea.

> The drawing took about 8 minutes, and there are a total of 50 points.

Now this is getting relevant. How much time would it take you to do it with beziers? It would be useful here to ask David to time himself with both methods too, since you'd like to get the view form both ends: somebody used to drawing with cornus more and somebody used to drawing with beziers more.

Also, some overlays would be very useful, since your "thresh" and "optim" settings don't mean anything to us. An overlay of the spiral original over the converted bezier, and one of the end result black shape over the original piece of plastic. Please? :-)

hhp

hrant's picture

Christian:
> What took me forever to figure out with
> beziers happened almost automatically here.

That implies cornus are better when you're starting out in type design; but an equally important issue is: for somebody with experience with beziers, would you say they're about the same in the end, or do cornus have an advantage there too?

> 3. Lobby the proprietary app vendors to license it.

To me adding cornu support seems like just the ticket to encourage upgrades to FontLab 6... In fact right this minute they might be desperately trying to figure out how to add value to their product to keep the upgrade money coming! That said, an email campaign by users can only help.

BTW Raph: what term should we be using for this - cornus, spirals, or what?
Something short would be great.

hhp

kentlew's picture

Hrant: BTW, what exactly is the traditional “S” test?

David will correct me if I'm wrong, but from what I understand from a conversation with Mike Parker, the traditional test administered to someone applying for employment in the Linotype drawing office, in the "good ol' days," was the task of reproducing freehand (I'm talking about drawing here -- pencils and paper, you know) a specific 'S' from a given model typeface, in order to gauge their innate talent and skill.

I don't know if it was the same 'S' each time, or if there was a time limit.

-- K.

hrant's picture

Maybe not a strict time-limit, but I'm sure at least an
internal biological stopwatch would've been running! :-)

BTW, isn't today's "freehand" direct-digital?

hhp

raph's picture

@hrant: An overlay of the spiral original over the converted bezier

The Bezier version is a 1px red stroke, and the spiral version is on top in black. You can see a teeny difference on the left hand of the top curve. If you tweak the "thresh" parameter, it'll add more Beziers to make the error go as small as you like. I picked the .01 number as the default for my work because the error is just below the threshold of what you can see when you look at the shapes side-by-side. Setting it to .001 adds nine beziers (for a total of 52), and the visual difference becomes undetectable even when zoomed. Btw, if you want to zoom in on the above comparison, I put up a PDF.

I tried overlaying the black-filled version over the original photo, but I couldn't get anything that seemed as clear as the first image above, partly because of the low contrast of the original. I have done the same thing with letters - maybe I should post some images from that?

what term should we be using for this - cornus, spirals, or what?

I kinda like "spirals". Cornu spirals are actually only one case. The most general case is a third order polynomial spiral, which I sometimes abbreviate "spiro". Incidentally, Cornu didn't invent the spiral bearing his name, Euler did, so they should really be called "Euler spirals".

How much time would it take you to do it with beziers?

Well, for me to do it wouldn't exactly be fair, because I want my tools to win. But I'd be very interested to learn how long it takes you, Hrant, and whether you're as satisfied with the technical quality.

Actually, what I think I'd like to do is pose a real challenge. Maybe a neutral Typophile person (Tiff? Stephen?) could serve as moderator. It would go something like this: the moderator selects a high quality image of a predigital glyph, something like 1000px square, and posts it at a pre-arranged time. Then, people post followups to that thread containing their best shot, using the tools of their choice - Spiro, Illustrator, FontLab, QB's, CB's, IkarusMaster, whatever. Reports of drawing time can be verified by the post timestamp, and then the moderator would judge the quality.

Sound like fun? I would write up the results in a section of my thesis, as part of the case I'm trying to make is that spirals are more intuitive, more productive, and more conducive to high-quality results. Going up against the best skills of Typophiles would be a real way to falsifiably test those claims.

cuttlefish's picture

Raph:
I managed to make your test program crash.

PID: 901
Thread: 0

Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_INVALID_ADDRESS (0x0001) at 0xc0000000

Should I send you the full report?

hrant's picture

> The Bezier version is a 1px red stroke, and the spiral version is on top in black.

Oh.
Well goldangit then that's plenty close enough!

It's nice to see that such a close approximation
doesn't result in an infestation of vertices.

What does the "optim" setting do?

Concerning an overlay of the physical French curve and your end-result, we don't really need the former, we just need the original (1-bit) shape you started with. But if you think the threshold for that is as tight as the first overlay, don't bother.

> Cornu didn’t invent the spiral bearing his name, Euler did

Well, and apparently Pierre didn't invent beziers, Paul de Casteljau did, but these things can stick and trying to unstick them distracts from true work! On the other hand Euler was da man (as Laplace* found out the hard way) and it's early days so maybe we can do something.

* Or was it somebody else? I'm vaguely it might have been an Englishman instead. Whoever it was invented some polynomial math, and then found out it was merely a special case of something Euler had done long before!

> I’d be very interested to learn how long it takes you, Hrant

Yeah, me too. Windows version please!

Your broader challenge sounds fun and relevant.
But no need to bother with formal timekeeping - we can trust us.

hhp

raph's picture

What does the “optim” setting do?

It's a speed/optimization tradeoff. At zero, it's interactively fast but generates about three times as many Beziers as is needed. At three, it (currently) takes about a minute, but generates something like the absolute most optimized cubic Bezier representation possible for the curve. The main thing it's doing at level 3 is exhaustively searching all points along the curve to find the best points to break - at the lower levels, it just splits the curve in half whenever a single Bezier is not sufficient. There'll be more detail in my thesis, of course.

But no need to bother with formal timekeeping - we can trust us.

I think we can too, but I'd like to remove as many variables that could spoil the results as I can.

rosaiani's picture

Not trying to compare to his at all William (his S sure is a very nice S), it'll probably take a million years till a get the letter s to look like I want it to... It may not look perfect, but it certain took 1/millionth of the time to get done. If the tool is useful only to know that I suck at drawing "s" in less time, it's fair enough for me.

hrant's picture

I'm surprised the conversion is so computationally intensive.
Must be a good sign. :-)

hhp

G T's picture

raph,

May I ask how you converted to beziers?

I am unable to export my doodlings in any way, and the save option doesn't appear to do anything.

I do find spiro a much quicker and intuitive way of drawing. I have used the bezier tool for many years and feel that I am quite proficient, but this is so quick. It seems more natural.

Thanks,

G

TBiddy's picture

This looks like some amazing stuff. I'm surprised more type designers haven't chimed in on this conversation. Where are you all?

raph's picture

@Graham_Taylor: May I ask how you converted to beziers?

This part of the code is very rough and unfinished. When you press Apple-S, it saves the file "plate" into the file system, into the current directory, not sure exactly where that is by default on a mac. (a quick test reveals that it seems to go into / , which is not friendly behavior). Similarly, when you press Apple-P, it saves a PostScript file to /tmp/foo.ps. I then use some command-line scripts (mostly written in Python) to optimize the Beziers, etc. These scripts ship in the spiro tarball, but not in the ppedit.dmg disk image.

Dave Crossland (abattis) is planning on writing better documentation soon, which I think will be very helpful.

@biddy: thanks!

crossgrove's picture

Didn't have time until now to test it. I learned to digitize type with Ikarus, so it's not completely unfamiliar. It seems to be flexible enough to allow the fine tuning I want, but right now, I'm so acclimated to beziers that I'd need more time to get used to the different behavior. I couldn't necessarily compare my drawing speed between Beziers and spirals because most of my actual design work is spent adjusting existing outlines. I don't do a lot of revivals, and I don't do big finished drawings anymore, so the speed at which I can digitize an outline isn't a big factor. Major editing happens after the first round of proofs. I can already slap an outline together in bezier format in record time. It's not finished no matter how much I fuss over it initially.

Raph, I don't want to rain on your challenge, but this means I can't gauge quality or speed based on immediate digitization results; it's very iterative, and "accuracy" isn't my concern, rightness of design is, which is revealed with testing and use.

raph's picture

crossgrove: You make a very good point. Making good, quick digitizations isn't the only way to evaluate curve-drawing techniques.

My subjective experience is that Spiro is extremely good for making fine edits. You can tweak points around without having to worry about technical details like extremal points, and, in general, the changes "make sense". I've done quite a bit of this with both my revivals and my original designs (Inconsolata and Cecco). The warm, fuzzy feeling that I get when drawing has done a lot to motivate me to go more deeply into the math behind the curves, so that I know at multiple levels that the curves are "right."

At some point, you go beyond what can be quantified, and into the realm of what it feels like to use the tool. I'm hoping that enough people spend enough time playing with it that I can start to get more insight into that, in addition to my own personal experience.

hrant's picture

> You can tweak points around without having to
> worry about technical details like extremal points

This I don't get. You don't have to worry about extrema when you're doing bezier drawing either - you can add those in later, which furthermore is something you'd have to do with/after spiral-to-bezier conversion anyway.

> into the realm of what it feels like to use the tool.

Yyyup.

hhp

Syndicate content Syndicate content