Point position program.

Discussion in 'AutoCAD' started by BillZ, Jun 2, 2004.

  1. BillZ

    BillZ Guest

    R2005 Vlisp:

    I am trying to put a program together that hopefully will create some interest is surface manipulation here at work.

    If I want to lay out a set of points that represent a surface area and want to have it so that it one point is moved, the others will move to keep the same space in between them, can I do that with reactors?
    I just want some ideas for what direction I should go here.

    Thanks

    Bill
     
    BillZ, Jun 2, 2004
    #1
  2. BillZ

    Jürg Menzi Guest

    Bill

    How about Groups?

    Cheers
     
    Jürg Menzi, Jun 2, 2004
    #2
  3. BillZ

    BillZ Guest

    How about Groups?

    Dunno,

    I would like the best way to minipulate.keep track of what's going on with them.

    Any examples/thoughts?

    Bill
     
    BillZ, Jun 2, 2004
    #3
  4. BillZ

    Jürg Menzi Guest

    Stand by, I'll give you a sample...

    Cheers
     
    Jürg Menzi, Jun 2, 2004
    #4
  5. BillZ

    BillZ Guest

    Ah, I think I see what you are saying.
    But I would like the other points to move as if the area were as a peice of material or sheet metal, twist and flex.
    That type of move with same distance.
    Something I've thought about for a while.
    There is a lot of programs out there that simulate models for molds but none for shaping sheet material as it's formed.


    Bill
     
    BillZ, Jun 2, 2004
    #5
  6. BillZ

    Joe Burke Guest

    Billl,

    Does this help? I dunno squat about reactors.

    ;move point list given a reference point
    ;which represents a vector from 0,0,0 to reference point
    (defun AddPts (plst pt)
    (if (atom (car plst))
    (setq plst (list plst))
    )
    (mapcar '(lambda (p) (mapcar '+ p pt)) plst)
    )

    Joe Burke


    surface manipulation here at work.
    it so that it one point is moved, the others will move to keep the same space in
    between them, can I do that with reactors?
     
    Joe Burke, Jun 2, 2004
    #6
  7. BillZ

    Jürg Menzi Guest

    Hi Bill

    Guess couldn't bet what you are looking for... but:
    - Make a group with the related points
    - Toggle selectable by Ctrl+Shift+A
    - Below an (old) sample to work with groups by code:
    ;
    ; -- Function EditGroup
    ; Create, append or explode a group with the appropriate name.
    ; Arguments [Type]:
    ; Nme = Group name [STR]
    ; Css = Selection set [PICKSET] *)
    ; Flg = Mode True = Explode group
    ; False = Create or append group
    ; Return [Type]:
    ; > null
    ; Notes:
    ; *) Necessary if Flg = True, else False
    ;
    (defun EditGroup (Nme Css Flg / GrpDct GrpLst)
    (setq GrpDct (dictsearch (namedobjdict) "ACAD_GROUP"))
    (if GrpDct
    (progn
    (setq GrpLst (mapcar
    '(lambda (l) (cond ((= (car l) 3) (cdr l)) (T nil)))
    GrpDct
    )
    )
    (if (member (strcase Nme) GrpLst)
    (if Flg
    (command "_.-GROUP" "_EXPLODE" Nme)
    (command "_.-GROUP" "_ADD" Nme Css "")
    )
    (if (not Flg)
    (command "_.-GROUP" "_CREATE" Nme "" Css "")
    )
    )
    )
    (if (not Flg)
    (command "_.-GROUP" "_CREATE" Nme "" Css "")
    )
    )
    (princ)
    )

    Cheers
     
    Jürg Menzi, Jun 2, 2004
    #7
  8. BillZ

    Jürg Menzi Guest

    Hi Bill

    I've posted yesterday evening but it's not visible in news reader,
    web browser works...
    We can travel to other planets but aren't able to synchronize two ng
    systems... nasty >8-(

    Cheers
     
    Jürg Menzi, Jun 3, 2004
    #8
  9. BillZ

    BillZ Guest

    Thanks,
    I have a feeling I am going to need something that reads the position of each point in relationship to each other.
    I think I am in uncharted territory.


    Bill
     
    BillZ, Jun 3, 2004
    #9
  10. BillZ

    BillZ Guest

    Thanks Joe,

    I'll try this.


    Bill
     
    BillZ, Jun 3, 2004
    #10
  11. BillZ

    Jürg Menzi Guest

    Hi Bill

    Did you read my post in web browser?

    Repost:
    Guess couldn't be what you are looking for... but:
    - Make a group with the related points
    - Toggle selectable by Ctrl+Shift+A
    - Below an (old) sample to work with groups by code:
    ;
    ; -- Function EditGroup
    ; Create, append or explode a group with the appropriate name.
    ; Arguments [Type]:
    ; Nme = Group name [STR]
    ; Css = Selection set [PICKSET] *)
    ; Flg = Mode True = Explode group
    ; False = Create or append group
    ; Return [Type]:
    ; > null
    ; Notes:
    ; *) Necessary if Flg = True, else False
    ;
    (defun EditGroup (Nme Css Flg / GrpDct GrpLst)
    (setq GrpDct (dictsearch (namedobjdict) "ACAD_GROUP"))
    (if GrpDct
    (progn
    (setq GrpLst (mapcar
    '(lambda (l) (cond ((= (car l) 3) (cdr l)) (T nil)))
    GrpDct
    )
    )
    (if (member (strcase Nme) GrpLst)
    (if Flg
    (command "_.-GROUP" "_EXPLODE" Nme)
    (command "_.-GROUP" "_ADD" Nme Css "")
    )
    (if (not Flg)
    (command "_.-GROUP" "_CREATE" Nme "" Css "")
    )
    )
    )
    (if (not Flg)
    (command "_.-GROUP" "_CREATE" Nme "" Css "")
    )
    )
    (princ)
    )

    Cheers
     
    Jürg Menzi, Jun 3, 2004
    #11
  12. BillZ

    BillZ Guest

    Yes,

    Thanks


    Bill
     
    BillZ, Jun 3, 2004
    #12
  13. BillZ

    Anne Brown Guest

    Jurg -

    To try to track down any synch problems, I compared the messages
    in HTTP and NNTP and they match exactly. Nothing posted on one
    side doesn't show on the other??

    What post are you referencing? Date/time/first line?
     
    Anne Brown, Jun 3, 2004
    #13
  14. BillZ

    Jürg Menzi Guest

    Hi Anne

    Thx for answer...
    The message is visible in web browser but not in nntp.
    Below a copy from my post, sent with Netscape 4.75 (the Body is shortened):

    X-Mozilla-Status:
    0001
    X-Mozilla-Status2:
    00000000
    Nachrichten-ID:
    <>
    Datum:
    Wed, 02 Jun 2004 21:44:52 +0200
    Von:
    Jürg Menzi <>
    X-Mailer:
    Mozilla 4.75 [de] (Windows NT 5.0; U)
    X-Accept-Language:
    de
    MIME-Version:
    1.0
    Foren:
    autodesk.autocad.customization
    Betreff:
    Re: Point position program.
    Referenzen:
    <>

    <>
    Content-Type:
    text/plain; charset=us-ascii
    Content-Transfer-Encoding:
    7bit




    Hi Bill

    Guess couldn't bet what you are looking for... but:
    - Make a group with the related points
    - Toggle selectable by Ctrl+Shift+A
    - Below an (old) sample to work with groups by code:
    ;
    ; -- Function EditGroup
    ; Create, append or explode a group with the appropriate name.
    ; Arguments [Type]:
    ; Nme = Group name [STR]
    ; Css = Selection set [PICKSET] *)
    ; Flg = Mode True = Explode group
    ; False = Create or append group
    ; Return [Type]:
    ; > null
    ; Notes:
    ; *) Necessary if Flg = True, else False
    ;
    <snip>

    Cheers
     
    Jürg Menzi, Jun 3, 2004
    #14
  15. BillZ

    Anne Brown Guest

    Fired up an old copy of Netscape 4.7 just to be sure and I see
    your original message. Also see it in Outlook Express. Might want
    to clear your cache and reload.

    Anne
     
    Anne Brown, Jun 3, 2004
    #15
  16. BillZ

    Jürg Menzi Guest

    Hi Anne
    Must be my chache... thank you.

    Cheers
     
    Jürg Menzi, Jun 3, 2004
    #16
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.