Jump to content

Recommended Posts

Posted

hi

i'm tying to create a script with arcs in, i get arc data from a text file cvs format, which looks like this = start of arc 190,0 end of arc 200,10 centre of arc 190,10 as you can see it's a 10mm radius i think these are absolute measurements .

 

i'm not sure on the format for 3 pt arcs in scripts ?

 

cheers

jimpcfd

Posted

IMO, you should really consider using a LISP routine instead.

 

If you post a sample .CSV file, I can at least give you a push-start in the right direction.

Posted
IMO, you should really consider using a LISP routine instead.

 

If you post a sample .CSV file, I can at least give you a push-start in the right direction.

 

hi Renderman

 

below is the format, i hope it makes sense?

cheers

jimpcfd

Posted

her we forgot to paste !!!

 

L,0,10,0,190

A,190,0,200,10,190,10,1

L,200,10,200,90

A,200,90,190,100,190,90,1

L,190,100,10,100

A,10,100,0,90,10,90,1

L,0,90,0,10

A,0,10,10,0,10,10,1

 

 

 

L = LINE START X,START Y, END X,END Y.

 

A = ARC START X, START Y, END X, END Y, CENTRE , CENTRE Y.

 

cheers

Jimpcfd

Posted

This is the full spec

 

l,0,10,0,190

a,190,0,200,10,190,10,1

l,200,10,200,90

a,200,90,190,100,190,90,1

l,190,100,10,100

a,10,100,0,90,10,90,1

l,0,90,0,10

a,0,10,10,0,10,10,1

 

 

 

l = line start x,start y, end x,end y.

 

A = arc start x, start y, end x, end y, centre , centre y.

1 means counterclockwise and 0 would mean clockwise

 

caps lock stuck !!!

 

Cheers

jimpcfd

Posted
IMO, you should really consider using a LISP routine instead.

 

If you post a sample .CSV file, I can at least give you a push-start in the right direction.

 

 

 

do you think Lisp is the best way to go with this ?

:?

Posted

Why not just use excel to write a script you just need new column thats made up of what you have now, can copy and paste also direct to command line. excel has macro basicly its VBA can have look up table for a arcs L lines etc

 

L,0,10,0,190 becomes in new single column Line 0,10 0,190

a,190,0,200,10,190,10,1 becomes arc 90,0 200,10 190,10

 

Yes it can be done in lisp also you use the , to break down variables and a cond A L C etc arc line circle

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...