Fillet Knots

 05 May 2013 #1 JokerMartini Expert   portfolio John Martini CG Supervisor, 3D, Maxscript, VFX Ingenuity Engine Los Angeles, USA   Join Date: Mar 2009 Posts: 1,333 Fillet Knots I'm trying to think of the best way to fillet a spline knot. My guess would be to approach it like this. Find the desired knot you wish to fillet. Then take the desired radius chosen by the user (in this case 10cm) and create a knot on each spline 10cm from the selected knot. Then delete the knot in between them after adjusting the handles to make a curved radius. Below is s start just basic setup. Like to know what others think. `````` delete objects sp = splineshape pos:[0,0,0] wirecolor:yellow addNewSpline sp addKnot sp 1 #corner #line [25,25,0] addKnot sp 1 #corner #line [-5,25,0] addKnot sp 1 #corner #line [-5,-10,0] addNewSpline sp addKnot sp 2 #corner #line [10,5,0] addKnot sp 2 #corner #line [-15,5,0] addKnot sp 2 #corner #line [-15,-10,0] addNewSpline sp addKnot sp 3 #corner #line [-10,20,0] addKnot sp 3 #corner #line [-5,35,0] addKnot sp 3 #corner #line [10,15,0] updateShape sp -- update shape clearlistener() for k = 1 to numsplines sp do ( --fillet second knot of each spline with a radius of 10 )`````` __________________ ____________ ___ __ _ John A. Martini JokerMartini@hotmail.com www.JokerMartini.com share quote
 05 May 2013 #2 JokerMartini Expert   portfolio John Martini CG Supervisor, 3D, Maxscript, VFX Ingenuity Engine Los Angeles, USA   Join Date: Mar 2009 Posts: 1,333 Example This better illustrates what I was talking about method wise. Obviously there is a lot of room for improvement as this would only work in a perfect scenario. Just an idea though.... `````` delete objects sp = splineshape pos:[0,0,0] wirecolor:yellow addNewSpline sp addKnot sp 1 #corner #line [25,25,0] addKnot sp 1 #corner #line [-5,25,0] addKnot sp 1 #corner #line [-5,-10,0] -- addNewSpline sp -- addKnot sp 2 #corner #line [10,5,0] -- addKnot sp 2 #corner #line [-15,5,0] -- addKnot sp 2 #corner #line [-15,-10,0] -- addNewSpline sp -- addKnot sp 3 #corner #line [-10,20,0] -- addKnot sp 3 #corner #line [-5,35,0] -- addKnot sp 3 #corner #line [10,15,0] updateShape sp -- update shape radius = 10.0 clearlistener() for k = 1 to numsplines sp do ( parts = getSegLengths sp 1 format "%\n" parts refineA = (parts[3]-radius)/parts[3] as float refineB = (radius)/parts[4] as float print refineA print refineB refineSegment sp 1 1 refineA refineSegment sp 1 3 refineB ) deleteKnot sp 1 3 --knot one adjustments knotA = getKnotPoint sp 1 2 setOutVec sp 1 2 (knotA += [-5,0,0]) --knot two adjustments knotB = getKnotPoint sp 1 3 setInVec sp 1 3 (knotB += [0,5,0]) updateShape sp --update the shape to see the result sp.vertexTicks = true `````` __________________ ____________ ___ __ _ John A. Martini JokerMartini@hotmail.com www.JokerMartini.com share quote
 05 May 2013 #3 Wheiraucher 3dhippie   portfolio David Shelton 3d generalist Mainz, Germany   Join Date: Jul 2005 Posts: 360 Anything wrong with the method that is already available? splineOps.startFillet Enters "Fillet" command mode - valid in Vertex Sub-Object level. See Editable Spline Modify Panel Command Modes and Operations for full list of UI-related methods. share quote
 05 May 2013 #4 Wheiraucher 3dhippie   portfolio David Shelton 3d generalist Mainz, Germany   Join Date: Jul 2005 Posts: 360 oh, I just noticed that this will simply start the fillet mode. sorry . share quote
 05 May 2013 #5 JokerMartini Expert   portfolio John Martini CG Supervisor, 3D, Maxscript, VFX Ingenuity Engine Los Angeles, USA   Join Date: Mar 2009 Posts: 1,333 I have a circle with a radius of 10 at the position [0,0,0] How does it calculate the Y of the first knot's in vec [10,-5.51786,0] Below is an image with 2 arcs. One is 90 degrees the other is 45 degrees. How can I calculate the handles positions to create my own arcs? __________________ ____________ ___ __ _ John A. Martini JokerMartini@hotmail.com www.JokerMartini.com Last edited by JokerMartini : 05 May 2013 at 05:22 PM. share quote
 07 July 2013 #6 JokerMartini Expert   portfolio John Martini CG Supervisor, 3D, Maxscript, VFX Ingenuity Engine Los Angeles, USA   Join Date: Mar 2009 Posts: 1,333 Anyone have any ideas how you calculate the in and out vectors of a spline's knot to make a arc? __________________ ____________ ___ __ _ John A. Martini JokerMartini@hotmail.com www.JokerMartini.com share quote
 07 July 2013 #7 TheOnlyAaron Expert   portfolio Aaron Dabelow Technical Director MAKE Minneapolis, United States Minor Outlying Islands   Join Date: May 2005 Posts: 291 Not an answer per se, but looks like someone did something similar. Perhaps it will give you an idea of how they did it. http://blenderartists.org/forum/sho...D-fillet-script __________________ Debris Maker Portfolio Blog share quote
 07 July 2013 #8 CGTalk Moderation Expert   Join Date: Sep 2003 Posts: 1,066,473 Thread automatically closed This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum. share quote

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts vB code is On Smilies are On [IMG] code is On HTML code is Off CGSociety Society of Digital Artists www.cgsociety.org Powered by vBulletinCopyright ©2000 - 2006, Jelsoft Enterprises Ltd.