Help with GDL
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā2005-02-28 07:27 PM
ā2005-02-28
07:27 PM
cPRISM_ mat, mat, mat,
20, 0'-5.5000",
0'-0.0000", 0'-0.0000", 15,
0'-0.0197", 0'-0.0000", 13,
0'-9.0000", 0'-0.0000", 79,
A, 0'-0.0000", 15,
A-B/tan(90-ang), B, 15,
0'-9.0000", B, 79,
0'-4.2500", B, 15,
0'-4.2500", 0'-4.2500", 15,
0'-3.9875", 0'-4.2500", 79,
0'-3.4706", 0'-4.1588", 79,
0'-2.9773", 0'-3.9793", 79,
0'-2.5227", 0'-3.7168", 79,
0'-2.1206", 0'-3.3794", 79,
0'-1.7832", 0'-2.9773", 79,
0'-1.5207", 0'-2.5227", 79,
0'-1.3412", 0'-2.0294", 79,
0'-1.2500", 0'-1.5125", 79,
0'-1.2500", 0'-1.2500", 15,
0'-0.0000", 0'-1.2500", 15,
0'-0.0000", 0'-0.0000", -1
4 REPLIES 4
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā2005-02-28 08:11 PM
ā2005-02-28
08:11 PM
Mike,
Since three dimensional elements are always auto-scripted as
polygonal shapes, you should try drawing the shape using
lines and arcs then save as GDL object or drag and drop
the drawing into a 2D script.
AC will auto-script 2D elements using "additional status codes" (see manual).
These status codes make arcs instead of segmented approximations
of arcs.
Use the 2D code as the bases for the three dimensional CPRISM command
by substituting the coordinates from the 2D code in the CPRISM command
and correcting the code appropriately for the CPRISM.
HTH,
Peter Devlin
Since three dimensional elements are always auto-scripted as
polygonal shapes, you should try drawing the shape using
lines and arcs then save as GDL object or drag and drop
the drawing into a 2D script.
AC will auto-script 2D elements using "additional status codes" (see manual).
These status codes make arcs instead of segmented approximations
of arcs.
Use the 2D code as the bases for the three dimensional CPRISM command
by substituting the coordinates from the 2D code in the CPRISM command
and correcting the code appropriately for the CPRISM.
HTH,
Peter Devlin
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā2005-03-01 12:22 AM
ā2005-03-01
12:22 AM
Mike wrote:Mike,
I can figure out how to do this with all parts of the code except that which defines the curve. The curve seems to be defined with a series of points versus a center point and radius. It seems like this should be relatively simple, but the solution has eluded me...
Here's a fully developed solution you might use. I choose to use cutplanes for objects like this...it makes scripting the Prism a little more staighforward. It's not the only way to do it but I find it to be the easiest way to make something like this fully parametric. It also uses the special status codes Peter mentioned.
2dScript:
project2 2,270,1
3Dscript:
aa=a/cos(ang)
!!!ESTABLISHES THE CUTPLANE!!!
rotz 90 !!!ROTATES THE CUTPLANE
cutplane -90 !!!SETS THE CUTPLANE
del 1 !!!DELETES THE CUTPLANE ROTATION
!!!ROTATES THE PRISM!!!
addy b/2 !!!SETS PRISM THICKNESS TO CENTERLINE
rotx 90
rotz -ang
cPRISM_ mat, mat, mat,
10, b,
0,0, 15,
0,-rd,15,
aa-cr-offs,-rd,15,
aa-cr-offs,-rd+((rd-cr)/2),15,
aa-cr-offs,-rd+cr+((rd-cr)/2),900, !!!SETS THE CENTERPOINT
aa-offs,-rd+cr+((rd-cr)/2),3000, !!!SETS THE FINAL POINT ON RADIUS
aa-offs,-rd+cr+((rd-cr)/2),15,
aa,-rd+cr+((rd-cr)/2),15,
aa,0,15,
0,0,1
cutend !!!CUTS W/ THE CUTPLANE
See the attached image for more info about the parameters
Hope it helps,
Dan K
Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā2005-03-01 04:03 PM
ā2005-03-01
04:03 PM
Mike,Thank you for all the effort you put in. This small part has been a good exercise to force me to explore the mysteries of GDL
Here's a fully developed solution you might use. I choose to use cutplanes for objects like this...it makes scripting the Prism a little more staighforward. It's not the only way to do it but I find it to be the easiest way to make something like this fully parametric. It also uses the special status codes Peter mentioned.

Anonymous
Not applicable
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ā2005-03-01 06:30 PM
ā2005-03-01
06:30 PM
Mike wrote:Mike,
Thank you for all the effort you put in. This small part has been a good exercise to force me to explore the mysteries of GDL
you're very welcome...I'm happy to do it - GDL was a little painful for me at first and I appreciated all the advice I could get.
If you successful with the script example thus far its a pretty easy exercise to make the part stretchable to repeat the rafters. So many possibilities in GDL !- welcome to the real power of ArchiCAD!!!
Dan K