<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!] in Visual LISP, AutoLISP and General Customization Forum</title>
    <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12977705#M9910</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="lisp"&gt;(defun c:NNN ()
  ; Fit and Uniform
  (setvar "SPLMETHOD" 0) 
  (setvar "SPLKNOTS" 2) 

  (setq n 180)
  (setq points_right '())
  (setq points_left '())
  
  ; Count-Right-Point
  (setq m 0)
  (while (&amp;lt;= m 90)
    (setq theta_prime (- (* m (/ 180.0 n)) 45))
    (setq r_prime (/ (+ theta_prime 45) (/ 180.0 n)))
    (setq x (* r_prime (cos (degrees-to-radians theta_prime))))
    (setq y (* r_prime (sin (degrees-to-radians theta_prime))))
    (setq points_right (append points_right (list (list x y 0))))
    (setq m (1+ m))
  )
  
  ; Count-Left-Point
  (setq m 0)
  (while (&amp;lt;= m 90)
    (setq theta_double_prime (+ (* m (/ 180.0 n)) 45))
    (setq r_double_prime (/ (- theta_double_prime 45) (/ 180.0 n)))
    (setq x (* r_double_prime (cos (degrees-to-radians theta_double_prime))))
    (setq y (* r_double_prime (sin (degrees-to-radians theta_double_prime))))
    (setq points_left (append points_left (list (list x y 0))))
    (setq m (1+ m))
  )
  
  ; Draw-Right-Spline
  (command "_SPLINE")
  (foreach pt points_right
    (command pt)
  )
  (command "") 
  (command "")
  (command "")
  
  ; Draw-Left-Spline
  (command "_SPLINE")
  (foreach pt points_left
    (command pt)
  )
  (command "")
  (command "")
  (command "")

  ; Circular
  (command "CIRCLE" '(0 0 0) "90")
)
  
(princ "\n 'NNN' ")
(princ)

(c:NNN)
(princ)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Hi, Good friend!&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Since my code is complex, I simplified it to this sample.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;I hope you can modify it to be able to generate Fit-Uniform-Spline directly.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;If this is really not possible, I hope I can generate it first as a normal spline curve and then change it to Fit-Uniform-Spline.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Really thanks a lot you!&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Thanks!&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 23 Aug 2024 17:31:21 GMT</pubDate>
    <dc:creator>U-O-U</dc:creator>
    <dc:date>2024-08-23T17:31:21Z</dc:date>
    <item>
      <title>[Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12972411#M9908</link>
      <description>&lt;P&gt;&lt;FONT size="4"&gt;I need to generate the required spline curve automatically with an LSP script: directly generated Fit-Uniform-Spline (not first generated and then set to "Fit-Uniform").&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;But I realized that I can't do it, it's a bit complicated, please hear me out ......&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(setvar "SPLMETHOD" 0)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(setvar "SPLKNOTS" 2)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;At first I used the method of changing system variables to try to solve the problem quickly.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;&lt;FONT size="4"&gt;Result: entmake and command can't inherit these two system variables, it's not that the change didn't work, but these two system variables are only valid for manual input, and with code you can only generate Fit-Chord-Spline.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;'(72 . 2)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;I didn't give in and tried to set it up directly with entmake.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;&lt;FONT size="4"&gt;Result: The CAD website doesn't have a detailed description of "SPLINE (DXF) Group code 72", and ChatGpt tells me that 2 stands for "Uniform", but no matter what I change it to, the resulting spline is always Fit-Chord-Spline.&amp;nbsp;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(initcommandversion 1)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(command "-SPLINE" "Method" "Fit" "Knots" "Uniform")&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(initcommandversion 0)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;Still haven't given up! This time I used command to set the parameters directly!&lt;/FONT&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT size="4" color="#FF6600"&gt;Result: no! It seems that since a long time ago CAD doesn't support calling "M" and "K" via command, and restoring the old version with initcommandversion didn't work, so I suspect that these functions have been completely removed.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(setq splineObj (vla-AddSpline modelSpace points_right_variant nil nil))&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(vla-put-KnotParameterization splineObj acUniformKnotParameterization)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#666699"&gt;&lt;U&gt;&lt;EM&gt;&lt;FONT size="4"&gt;(vla-put-Method splineObj acFitMethod)&lt;/FONT&gt;&lt;/EM&gt;&lt;/U&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;I'm not convinced! Tried to use the unfamiliar ActiveX, thinking that utilizing the API would surely work.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;&lt;FONT size="4"&gt;Result: I wrote half a day's worth of code and couldn't write a script that would generate a spline curve properly! ActiveX was too difficult and I didn't understand it at all!&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="5" color="#0000FF"&gt;&lt;STRONG&gt;My core need:&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;&lt;STRONG&gt;(1) The best result is to generate Fit-Uniform-Spline directly using entmake or command, either by inheriting system variables or by setting it directly with a command.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;&lt;STRONG&gt;(2) Barely acceptable result is to generate Fit-Chord-Spline and then modify it to Fit-Uniform-Spline after generating Fit-Chord-Spline.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4"&gt;&lt;STRONG&gt;(3) If the esteemed big guys are willing, I'd also like to get an LSP script that generates Fit-Uniform-Spline via ActiveX API, mainly because I'm curious about how to implement it.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;&lt;STRONG&gt;First time in the community, hopefully some of the big guys can help me out as a newbie who doesn't know anything.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;FONT size="5"&gt;As a final note, my CAD version is the mechanical version of the 2024, thanks!&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Aug 2024 14:07:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12972411#M9908</guid>
      <dc:creator>U-O-U</dc:creator>
      <dc:date>2024-08-21T14:07:30Z</dc:date>
    </item>
    <item>
      <title>Re: [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12975501#M9909</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/15063406"&gt;@U-O-U&lt;/a&gt;&amp;nbsp;Please upload you sample.DWG , points as CSV&amp;nbsp; xx,yy , I will try to do by VLX.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 22 Aug 2024 18:00:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12975501#M9909</guid>
      <dc:creator>devitg</dc:creator>
      <dc:date>2024-08-22T18:00:10Z</dc:date>
    </item>
    <item>
      <title>Re: [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12977705#M9910</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="lisp"&gt;(defun c:NNN ()
  ; Fit and Uniform
  (setvar "SPLMETHOD" 0) 
  (setvar "SPLKNOTS" 2) 

  (setq n 180)
  (setq points_right '())
  (setq points_left '())
  
  ; Count-Right-Point
  (setq m 0)
  (while (&amp;lt;= m 90)
    (setq theta_prime (- (* m (/ 180.0 n)) 45))
    (setq r_prime (/ (+ theta_prime 45) (/ 180.0 n)))
    (setq x (* r_prime (cos (degrees-to-radians theta_prime))))
    (setq y (* r_prime (sin (degrees-to-radians theta_prime))))
    (setq points_right (append points_right (list (list x y 0))))
    (setq m (1+ m))
  )
  
  ; Count-Left-Point
  (setq m 0)
  (while (&amp;lt;= m 90)
    (setq theta_double_prime (+ (* m (/ 180.0 n)) 45))
    (setq r_double_prime (/ (- theta_double_prime 45) (/ 180.0 n)))
    (setq x (* r_double_prime (cos (degrees-to-radians theta_double_prime))))
    (setq y (* r_double_prime (sin (degrees-to-radians theta_double_prime))))
    (setq points_left (append points_left (list (list x y 0))))
    (setq m (1+ m))
  )
  
  ; Draw-Right-Spline
  (command "_SPLINE")
  (foreach pt points_right
    (command pt)
  )
  (command "") 
  (command "")
  (command "")
  
  ; Draw-Left-Spline
  (command "_SPLINE")
  (foreach pt points_left
    (command pt)
  )
  (command "")
  (command "")
  (command "")

  ; Circular
  (command "CIRCLE" '(0 0 0) "90")
)
  
(princ "\n 'NNN' ")
(princ)

(c:NNN)
(princ)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Hi, Good friend!&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Since my code is complex, I simplified it to this sample.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;I hope you can modify it to be able to generate Fit-Uniform-Spline directly.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;If this is really not possible, I hope I can generate it first as a normal spline curve and then change it to Fit-Uniform-Spline.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Really thanks a lot you!&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="4" color="#333399"&gt;&lt;STRONG&gt;Thanks!&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2024 17:31:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12977705#M9910</guid>
      <dc:creator>U-O-U</dc:creator>
      <dc:date>2024-08-23T17:31:21Z</dc:date>
    </item>
    <item>
      <title>Re: [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12982780#M9911</link>
      <description>&lt;P&gt;You are correct in that it appears there is no direct way via VLISP to create a spline with a knot parametrization set to Uniform.&amp;nbsp; Very frustrating.&amp;nbsp; As you know, it's easy to do interactively via the spline command or by manually changing the knot parametrization parameter to Uniform after spline creation in the Properties dialog box.&amp;nbsp; Note that when the spline command is given, knot parametrization is automatcally changed to Chord no matter what has been set with with the system variable&amp;nbsp;SPLKNOTS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you really need to create the uniform spline directly you could consider wrtiting code to detemine the location of the CVs for a given set of Fit Points.&amp;nbsp; The math is not for the light of heart and I'm not sure I get all of it!&lt;/P&gt;&lt;P&gt;Here's the equation (from "The NURBS Book" by Lee Piegl and Wayne Tiller)&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="leeminardi_0-1724722051900.png" style="width: 600px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/1402214i78EAD08EC916541F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="leeminardi_0-1724722051900.png" alt="leeminardi_0-1724722051900.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;N(i,p) is the basis function for the B-spline.&amp;nbsp; Of course this requires solving the linear et of simultaneous equations.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Why do you need a Uniform fit?&amp;nbsp; Can the differences in the spline your prgram will create of a consistent general shape?&amp;nbsp; If so, perhaps you could determine the appropriate placement of CVs from a pattern tha emerges when looking at a set of curves you need.&amp;nbsp;&lt;/P&gt;&lt;P&gt;You might also consider getting the shape you need by modifying kno weigh values as required when needing to crete an exact arc with a NURBS spline.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It would help to know more about your application.&amp;nbsp; It looks like you are trying to create a cycloid.&lt;/P&gt;</description>
      <pubDate>Tue, 27 Aug 2024 01:38:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12982780#M9911</guid>
      <dc:creator>leeminardi</dc:creator>
      <dc:date>2024-08-27T01:38:57Z</dc:date>
    </item>
    <item>
      <title>Re: [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12991440#M9912</link>
      <description>Thank you very much for your reply, I've been working on more complex code lately so I didn't get back to you in time, sorry!&lt;BR /&gt;The method you gave is too difficult, I don't need to modify the spline curve a lot, I'll opt for manual modification for now until the official CAD fix.&lt;BR /&gt;Thanks again!</description>
      <pubDate>Fri, 30 Aug 2024 13:08:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12991440#M9912</guid>
      <dc:creator>U-O-U</dc:creator>
      <dc:date>2024-08-30T13:08:28Z</dc:date>
    </item>
    <item>
      <title>Re: [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12997114#M9913</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/15063406"&gt;@U-O-U&lt;/a&gt;Currently have no time to jump into solving your request, but you may look how this post about &lt;A href="https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/catmull-rom-spline-from-lwpolyline/m-p/9040347#M390178" target="_blank" rel="noopener"&gt;Catmull-Rom spline&lt;/A&gt;. just as an idea. You can con convert resulting lwpolyline to spline for even better smoothness.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Sep 2024 07:37:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/12997114#M9913</guid>
      <dc:creator>hak_vz</dc:creator>
      <dc:date>2024-09-03T07:37:10Z</dc:date>
    </item>
    <item>
      <title>回复： [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/13006693#M9914</link>
      <description>&lt;P&gt;Update!&lt;BR /&gt;I have been told by some powerful people that if you use command to generate Spline, then by prefixing each piece of code that generates Spline with (initcommandversion 2) you are able to force the latest version to be used, inherit the system variables, and fulfill the requirements.&lt;BR /&gt;But after my attempts to generate Splines with command, there are tons of intractable problems that I can hardly express in a few words, I can only say that I refuse to use command to generate Splines.&lt;BR /&gt;Apart from command, all I can think of is entmake and vla-object, but neither of them can be affected by initcommandversion, so it still doesn't solve the problem.&lt;BR /&gt;That's probably it.&lt;/P&gt;</description>
      <pubDate>Sat, 07 Sep 2024 16:00:03 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/13006693#M9914</guid>
      <dc:creator>U-O-U</dc:creator>
      <dc:date>2024-09-07T16:00:03Z</dc:date>
    </item>
    <item>
      <title>回复： [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/13006825#M9915</link>
      <description>&lt;P&gt;I didn't have any luck either.&amp;nbsp; I tried the following which still did not creat a Unifrom parameterization spline.&amp;nbsp; Perhaps a VLISP Guru can jump in here.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;(defun c:test (/) 
  (setq ptList (list '(1 1 0) '(4 2 0) '(10 0 0) '(8 4 0) '(3 3)))
  (setvar "SPLKNOTS" 2) 
  (command "_spline")
  (setvar "SPLKNOTS" 2) 
  (while (= (getvar "cmdactive") 1)
    (repeat (setq x (length ptList))
      ( initcommandversion 2)(setvar "SPLKNOTS" 2) 
       (command  (nth (setq x (- x 1)) ptList))
    )					
    (command "")			
  )
  (princ)
)&lt;/LI-CODE&gt;&lt;P&gt;l&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Sep 2024 19:11:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/13006825#M9915</guid>
      <dc:creator>leeminardi</dc:creator>
      <dc:date>2024-09-07T19:11:30Z</dc:date>
    </item>
    <item>
      <title>回复： [Shocker CAD!]You can never modify a spline curve in an LSP script?[About Knots and Uniform!]</title>
      <link>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/13028078#M9916</link>
      <description>&lt;DIV&gt;BREAKING NEWS! Good news!&lt;BR /&gt;A powerful man named “Nigma” has given the right answer!&lt;BR /&gt;In the case of creating a Spline using activeX, just add two lines of code at the end to fulfill the requirement.&lt;BR /&gt;The sample code is as follows:&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="lisp"&gt;(setq splineObj (vla-addSpline modelSpace points start end))


  (vla-put-splinemethod splineObj 0)
  (vla-put-KnotParameterization splineObj 2)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you very much “Nigma” and thank you for your interest!&lt;BR /&gt;Thank you very much!&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 18 Sep 2024 11:07:07 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/shocker-cad-you-can-never-modify-a-spline-curve-in-an-lsp-script/m-p/13028078#M9916</guid>
      <dc:creator>U-O-U</dc:creator>
      <dc:date>2024-09-18T11:07:07Z</dc:date>
    </item>
  </channel>
</rss>

