Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Very Tecchy - Can I convert a curve....into numbers?

Status
Not open for further replies.

alanbloom

Technical User
Apr 22, 2005
81
GB
I have a complex curve in Illustrator and ideally (for scientific purposes) I could really do with creating a data sheet, which will give they coordinate of the curve for every small step in the x coordinate.

Tricky question....

I need to make a graph in a spreadsheet so it's basically converting an illustrator path into x and y numbers...

Any insight appreciated...

Thanks

 
Alan:

I can do part of it, but you'll probably have to do some scripting...

In order to get the coordinates of a number of points along your curve, create a scatter brush from a small circle (about the size of the increment you wish to use), set all parameters for the brush to 0 (which should be the default), then apply the brush to your curve.

Next, Expand the brush, ungroup the result, delete the curve (save a bloomin' backup first) and you have circles neatly following the coordinates along your curve.

They are in sequence, so you should be able to select them in turn, front to back, which should be from one end of the curve to the other.

Next, you'll need to harvest the information and place it into a data sheet. That's where the scripting comes in.

You may have to scale up your curve to get the coordinates to be accurate (at small sizes the scatter brush gets inaccurate) but converting the numbers back once you get them out should be a cinch.

HTH

Bert

 
Uhmmm, sorry, I misled you. I said set everything on the brush to 0, but you'll actually want to leave the size and spacing at 100%, not 0. If you leave the defaults as they come, you'll be fine.



 
Thanks for the help -

Do you know what procedure to use for the scripting? I've had little experience with it although I know bits about it and it's capabilities.

Cheers

Alan
 
Alan:

My javascripting skills are next to none, but I'd try to write something like this:

1. Pick the first (backmost) object;
2. Get its coordinates, write them to a file;
3. Repeat.

Bert

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top