Kean Walmsley

July 2009

Sun Mon Tue Wed Thu Fri Sat
      1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31  

Twitter Updates

    follow me on Twitter



    « Generating Koch fractals in AutoCAD using .NET - Part 1 | Main | "Custom Objects Masterclass" webcast recording available for download »

    August 02, 2007

    TrackBack

    TrackBack URL for this entry:
    http://www.typepad.com/services/trackback/6a00d83452464869e200e3982158d68833

    Listed below are links to weblogs that reference Generating Koch fractals in AutoCAD using .NET - Part 2:

    Comments

    Just getting started in both C# and programming AutoCAD in it. These are extremely helpful posts. Thank you!

    This does not work on polylines for me though. I have created 2d and 3d polylines. I know there is (used to be) LWPolylines -- is that what we're supposed to use, and what command creates them?

    I watched the vars, and the PLINE command gives me a Polyline2d. I tried converting the type of p1 in the call and the function declaration to Polyline2d, but apparently a Polyline2d does not contain the properties of a Polyline, such as numberOfVertices, etc..

    Please excuse my ignorance! I use AutoCAD all day every day but apparently don't know how to create a polyline!

    AllanC -

    Yes, this code only currently supports optimized (aka lightweight or new-style) polylines - objects of class Polyline. It culd be extended to support old-style polylined (objects of class Polyline2d and Polyline3d), but that is left as an exercise for the reader.

    To create optimized polylines you can set PLINETYPE to 1 or 2 and use the PLINE command, or use CONVERTPOLY to convert your old-style polylines.

    Regards,

    Kean

    Success!

    So I was backwards in thinking LW Polylines were "old style"! Don't know when I would have ever changed PLINETYPE to 0, but I have been trying to get polylines to snap to themselves (actually to extend a polar extension of points already drawn), an ability which seems to have been lost in v2007, and I may have changed it some time during that.

    Thank you very much for the (very rapid) response, and thank you again for this very informative blog.

    Thanks to you, my exploration continues!

    very nice...and I have found resolved here a problem with "circArc2Arc" ;)

    I am trying to enter the world of fractals and apply it in my architectural design... I am basic AutoCad and I am not managing to find out the way to apply your script. where can i find some explanation about that? thank you
    JaHko

    You should probably go back to one of the introductory posts:

    Getting started with Autodesk's APIs

    Working through the initial Labs pointed to by this post will help you understand more about building a .NET application for AutoCAD. You will need to use some version of Visual Studio, by the way.

    Kean

    I was afraid that you may say something like this.... :)
    thank you anyway , i hope i won't give up and that i will not have to become expert in order to draw some fractal geometry ...

    thank you anyway

    JaHko

    Verify your Comment

    Previewing your Comment

    This is only a preview. Your comment has not yet been posted.

    Working...
    Your comment could not be posted. Error type:
    Your comment has been posted. Post another comment

    The letters and numbers you entered did not match the image. Please try again.

    As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

    Having trouble reading this image? View an alternate.

    Working...

    Post a comment

    Feed & Share

    Search