Calc Scale Routine?

Discussion in 'AutoCAD' started by powermixx, Oct 1, 2004.

  1. powermixx

    powermixx Guest

    Does anyone have an existing routne that calculates a scale factor? Example:
    I have objects on the screen that need to be scaled a certain factor. The script I'm looking for will prompt the user to select 2 points for the existing items, then 2 points for the desired scale. It would then return a number showing the scale factor needed. Does this exist in AutoCAD 2005 or does anyone have a LSP for it? Thanks!

    Robert
     
    powermixx, Oct 1, 2004
    #1
  2. powermixx

    C Witt Guest

    command: scale , reference ?

    that work for you?
     
    C Witt, Oct 1, 2004
    #2
  3. powermixx

    BillZ Guest

    Why not the "R" option of the scale command?
     
    BillZ, Oct 1, 2004
    #3
  4. powermixx

    R.K. McSwain Guest

    Do you *need* this number, or do you just want to scale the objects?

    Look into the scale command, using the 'reference' option, then use CAL, dist(cur,cur) to obtain the destination distance.

    Command: scale
    Select objects: Specify opposite corner: 4 found
    Select objects:
    Specify base point: endp
    of
    Specify scale factor or [Reference]: R
    Specify reference length <1>: endp
    of Specify second point: endp
    of
    Specify new length: 'cal1506.7


    This could be put into a macro fairly easy.
     
    R.K. McSwain, Oct 1, 2004
    #4
  5. powermixx

    C Witt Guest

    RK,

    why would you need to use cal?? just pick the points per normal..

     
    C Witt, Oct 1, 2004
    #5
  6. powermixx

    R.K. McSwain Guest

    Because your first 'reference' point must also be your first point when specifying the desired distance.
    I understood the original question to mean he wants to pick two points on the object(s) to be scaled, then two separate points to specify the distance.
     
    R.K. McSwain, Oct 1, 2004
    #6
  7. powermixx

    C Witt Guest

    to each there own I guess..

     
    C Witt, Oct 1, 2004
    #7
  8. powermixx

    R.K. McSwain Guest

    Ok, I'm lost.

    How do you use SCALE with the reference option, with 4 unique points?

    (2 points to describe the starting distance and 2 points to describe the destination distance.)
     
    R.K. McSwain, Oct 1, 2004
    #8
  9. If four distinct points are what's desired, maybe Align would do it.

    Kent Cooper, AIA


    ...
    Because your first 'reference' point must also be your first point when
    specifying the desired distance.
    I understood the original question to mean he wants to pick two points on
    the object(s) to be scaled, then two separate points to specify the
    distance.
     
    Kent Cooper, AIA, Oct 1, 2004
    #9
  10. ...
    It depends on whether you care where the scaled object(s) end(s) up in
    relation to their(its) original position. If the 2 points defining the
    starting distance are A and B, and the two points defining the destination
    distance are C and D, you can:

    Invoke SCALE;
    Select the objects;
    Pick C for the base point for scaling around;
    Select the Reference option:
    Pick points A and B to define the reference distance (that doesn't NEED to
    have any relation to the base point, though in actual use it usually does);
    Pick point D for the destination distance (this one does have to be in
    relation to the base point, which is why you'd pick C for that first).

    But this only works if it's acceptable to use C (or D) as the scaling base
    point. You might then need to move the scaled stuff. If you need A or B to
    be the base point, maybe CAL is a way to go, or a lisp routine.

    Kent Cooper, AIA
     
    Kent Cooper, AIA, Oct 1, 2004
    #10
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.