snowman Posted August 15, 2004 Share Posted August 15, 2004 Hi, I'm wondering if I could get some advice with 3D Modeling. I am working on a pavillion tower that slants upward. It is wrapped in a rectangular piece of metal skin. I have problem getting the exact shape I want(the hard part is the keeping the skin rectangular). I've tried several ways such as tapper extrude but always end up with skin that looks trapazoidal. When I used the Extrude along Path command the Panel slants in only one direction instead of inward. could someone offer me some advise? (the shape is so easy to achieve in physical model as shown in the attached photo). Thanks,jean Quote Link to comment
propstuff Posted August 16, 2004 Share Posted August 16, 2004 I had a go at this with "resonable" success using Lofting. Make a Helix Spiral to serve as a Centre line. Make a truncated cone in the same place, of the same dimensions, to serve as a surface guide. (I lofted between 2 NURBS circles which had the start and end diameters of the Helix). Make a 2Degree straight NURBS line Profile as the width of your piece of metal. Go to a front or side view and place the profile so that the centre vertex lies on the helix guide. Rotate the guide around it's centre so that it is perpendicular (guess) to the helix. Go to the view perpendicular to your current view and rotate the profile again so that it "lies on" the truncated cone guide. Duplicate the profile and repeat up the helix. (I used the quadrants of the truncated cone to produce a total of 5 profiles) You should end up with a series of staight lines perpendicular to the helix around their centre points and all lying on the surface of the cone. Loft between the profiles. When I did this the resulting loft didnot lie on the surface of the cone. I tried to use the Loft with Rail mode to force the Loft to follow the helix as it joined the profiles but kept getting "Profiles do not intersect the Rail" error messages. I couldn't get them to intersect no matter how much I fiddled with them. Perhaps The loft with rail tool will only work with a profile at each end of the rail; I couldn't find any reference to this in the Manual at all. HTH, Good luck, N. [ 08-17-2004, 04:51 AM: Message edited by: propstuff ] Quote Link to comment
tom kyler_dup1 Posted August 17, 2004 Share Posted August 17, 2004 Jean, Your problem isn't as much modeling related as it is layout related. The way to model that shape is to create two nurbs curves....one for the top edge of your rectangle and one for the bottom and then loft the two together. Of course the problem lies in creating the 3D nurbs curves. I'm keeping in mind that your trying to maintain a rectangle shape as it wraps around the truncated cone. Unfortunately, a tapered shape doesn't lend itself to a rectangle "spiraling" up the shape very easy, except at low taper angles of the cone and/or high helix angles of the rectangle, but then you run into some other problems. There's two way to attack this in my opinion. (1). Unfold your cone like shown below. There are formulas for this on the web...and then overlay your rectangle. This shows where your rectangle will lie on the truncated cone. I know it looks funny, even an optical illusion, but that is the way it will be. So place your rectangle, then use the grid to determine some offset points. Then in plan view and front view, you can play with the nurbs verticies and "map" them out in polar coordinates....just like plotting in math class. Use the same number of verticies for the top and bottom curve. The other option (2) is quicker and easier and cheaper, and that is to approximate it, fake it, or reduce the taper angle of your tower...the closer you get to a cylinder shape, the easier it is to approximate. If you want to maintain that rectangle shape, then you definitely have a challenging shape to model there. Best of luck. [ 08-17-2004, 11:02 AM: Message edited by: tom kyler ] Quote Link to comment
propstuff Posted August 18, 2004 Share Posted August 18, 2004 Hey Tom, your method is as convoluted as mine! ;-) Have you been able to get a Loft along Rail to work with intermediate profiles as well as profiles at each end of the rail? (see my post above) Ive gone to the extent of manually editing vertex XYZ locations of the Rail and profiles to get them to be co-incident (snapping just doesn't happen) but I still get "Profiles don't intersect" messages. N. Quote Link to comment
tom kyler_dup1 Posted August 18, 2004 Share Posted August 18, 2004 Yes, I have that problem almost everytime I try to use it. If I recall, I even sent a file to Biplab for him to mess with...it was a twisting handrail for a stair...with two end profiles and maybe 3 intermediates. I couldn't get that thing to work. I think that function needs some work, I've seen other posts that relate to controlling the "twist" of a profile as it's extruded and I hope it gets some attention, I seems to use it a lot. And yes that method is convoluted too, that's why I didn't try to model it :-) [ 08-18-2004, 09:52 AM: Message edited by: tom kyler ] Quote Link to comment
lamberto previati Posted August 23, 2004 Share Posted August 23, 2004 Hello, i'ave a script for this kind of construction problem. Script i'snt professional and haven't a dialog window for parameter input but a bit confidence with script editor is request. The script draw a rectangular surface (NURBS type) over a conical one. These are two examples: If you are interest in it contact me or reply in this forum. Ciao Lamberto Quote Link to comment
tom kyler_dup1 Posted August 23, 2004 Share Posted August 23, 2004 Lamberto, pictures didn't come through, but defintely interested in that kind of a script. Quote Link to comment
lamberto previati Posted August 23, 2004 Share Posted August 23, 2004 Oopps. How can I insert correctly the pictures? What command? Thank Lamberto. Quote Link to comment
propstuff Posted August 23, 2004 Share Posted August 23, 2004 Lamberto, the image must be hosted on another site. After using the instant "Image" button, the code should look something like : except without the gaps between the tags and the URL check using the preview button to see if it's worked. Likewise interested in script cheers, N. [ 08-23-2004, 07:09 AM: Message edited by: propstuff ] Quote Link to comment
tom kyler_dup1 Posted August 23, 2004 Share Posted August 23, 2004 Lamberto, that is a wonderful script, very well executed. I'll post a picture of the results for everybody later in the day. [ 08-23-2004, 09:09 PM: Message edited by: tom kyler ] Quote Link to comment
snowman Posted August 23, 2004 Author Share Posted August 23, 2004 Wow, thanks for all the advise. I'm most interested in the new script and will give it a try (never done it before). I've tried the Propstuff's method and have the same problem. Might end up fudging the drawing and relying on the physical model for dimensions. Thanks. jean Quote Link to comment
snowman Posted August 23, 2004 Author Share Posted August 23, 2004 Hi Lamberto, Could you give me some more help on how to create the script file (Sorry I'm new at this and do not know the exact steps)? Do I go to Organize/Scripts/Create plug-in to create the script? I tried it this way but could not get it to show up in vectorscript palettes. Thanks, jean Quote Link to comment
tom kyler_dup1 Posted August 23, 2004 Share Posted August 23, 2004 Jean, Plug-ins don't exist in the vectorscript palette. The easiest way to is use the resource palette, just right click (or control-click on mac) and select the second option "New resource on ......" and then select Vectorscript. You can name the palette if you wan't, but I just leave the default name in there. I also leave the default name for the script...the script editor will pop up and you can paste the code in there. Then it will show up in the vectorscript palette. After that, you can just mess with the constants in the first part of the script to size your cone and rectangle. Quote Link to comment
Ziska Posted August 23, 2004 Share Posted August 23, 2004 Mac 10.3.4 VW 11 gets the following error message: Line #2: kr= 25; {radius of base cone} | { Error: Identifier not declared. } Quote Link to comment
tom kyler_dup1 Posted August 23, 2004 Share Posted August 23, 2004 Ziska, You've cut and pasted too much....there's a line in there that says ..."{copy lines below}. You should copy everything below this line and you should be fine. Quote Link to comment
lamberto previati Posted August 23, 2004 Share Posted August 23, 2004 Snowman, Tom Kyler have good explaned you the way for script using. If you have still problems i send you a VW file with script. My suggestion is copy text script and save it in any folder on your hard disk as file text. This script is only prototype script for any next better solution as type PIO and ParametricObject, but I haven't time for this and i use the script editor metod for my execution. Is no elegance but functional. Ziska, { Error: Identifier not declared. } This problem type sound like a missing line. Have you copied all lines of the script? Quote Link to comment
Ziska Posted August 24, 2004 Share Posted August 24, 2004 copied everything below {copy lines below} got the following error message: Line #141: CrG:=2*kPi*DistG; | { Error: Identifier not declared. } | { Error: Did not expect this after end of statement - missing ;? } Quote Link to comment
tom kyler_dup1 Posted August 24, 2004 Share Posted August 24, 2004 Ziska, a majority of the time, you'll get that message when the line before it (140 in this case) is missing a semi-colon at the end of that line. You might try re-copying it...I know that sounds trivial, but for me, cutting and pasting in VW11 resulted in a correctly compiled script and it ran great. Quote Link to comment
tom kyler_dup1 Posted August 24, 2004 Share Posted August 24, 2004 Here's a screenshot Quote Link to comment
lamberto previati Posted August 24, 2004 Share Posted August 24, 2004 I'm unable to attach image, sorry. The script. This script traspose the 2D value (like Tom Kyler's cone unfolded explanation) in 3D point. Therefore, this script, approximate the rectangular surface. Well.... You access to the script editor old down Alt and double click on its name when in your script palettes. After SCRIPT EDITOR open, you can edit some paramters, notice that these values are all the constant values. Here my last parameters setting (in mm): {CONE PARAMETER} kr= 25; {radius of base cone} kH= 400; {Height of cone} {RECTANGLE SURFACE PARAMETER} kLu= 130; {Rectangle Length } kAlt=80; {Rectangle Height} kRot= 25; {Rectangle rotation. O? degrees one side is complanar to the cone base} {Point affination} kn=64; {segment for curve} knRip=10; {number of curves} After setting, click OK botton and run script with double click on its name in your palettes script. Ok, this SCRIPT IS PROTOTYPE and FREE, but any suggestions or criticaly are welcome. Good work. Ciao Lamberto {Copy lines bellow} {Arch. Lamberto Previati ?2004/08 La procedura consente di disegnare un rettangolo dato in termini di Lunghezza/Larghezza/AngoloDiRotazione, sulla superficie conica data in termini di RaggioDiBase/Altezza. } PROCEDURE RectSurfOverConicSurface; CONST {ATTENZIONE le unit? di misure assunte sono quelle impostate} {CONE PARAMETER} kr= 25; {radius of base cone} kH= 400; {Height of cone} {RECTANGLE SURFACE PARAMETER} kLu= 130; {Rectangle Length } kAlt=80; {Rectangle Height} kRot= 25; {Rectangle rotation. O degree one side is complanar to the cone base} {Point affination} kn=64; {segment per curve} knRip=10; {number of curves} {Other constant} kPi=3.14159; {Costante PiGreco} VAR DistG,DistPV,DeltaL,Ckr,CrG,rP:REAL; {DistG=lunghezza generatrice cono/DistGx=distanza di pX da V} p,O3d,A3d,B3d,C3d :Point3D; {pX= punto generico del perimetro del rettangolo} AngG,AngP,AngP3D :REAL;{AngG=angolo di sviluppo/AngP=angolo} i,ii,PSize :INTEGER; {i=indice per i cicli FOR} OO,O,A,B,C :POINT; hLn,hNurbs,HGroupCurves,HNurbsSurf :Handle; red,green,blue :LONGINT; BEGIN {Set view in Top/Plan mode } DoMenuTextByName('Standard Views',1); PSize:=FPenSize; FFillFore(red,green,blue); {Disegna il CONO in 3D} {} PenSize(5); BeginMXtrd(0,kH); Oval(-kr,kr,kr,-kr); Locus(0,0); EndMXtrd; {} DSelectAll; {} {Calcoli preliminari: lunghezza della generatrice, circonf base cono, circonf.con raggio=generatrice, angolo di sviluppo della superficie conica} DistG:=sqrt(kr^2+kH^2); Ckr:=2*kPi*kr; CrG:=2*kPi*DistG; AngG:=(Ckr/CrG)*360; {Impostazioni preliminari} ANGLEVAR; O.x:=0; O.y:=-DistG; MoveTo(O.x,O.y); LineTo((kLu/kn),#(-kRot)); GetSegPt2(LNewObj,O.x,O.y); DelObject(LNewObj); NOANGLEVAR; {Calcola le coordinate dei vertici del rettangolo cio? i punti 0,A,B,C disegnando i quattro lati 0A, 0B, AC e BC} AngleVar; MoveTo(O.x,O.y);Lineto(kLu,#(180-kRot)); GetSegPt2(LNewObj,A.x,A.y);DelObject(LNewObj); MoveTo(O.x,O.y);Lineto(kAlt,#(90-kRot)); GetSegPt2(LNewObj,B.x,B.y);DelObject(LNewObj); MoveTo(A.x,A.y);Lineto(kAlt,#(90-kRot)); GetSegPt2(LNewObj,C.x,C.y);DelObject(LNewObj); MoveTo(B.x,B.y);Lineto(C.x,C.y);DelObject(LNewObj); NoAngleVar; {INIZIO PROCEDURE PER DISEGNARE I LATI DEL RETTANGOLO SULLA SUPERFICIE CONICA} PenSize(10); {Disegna il segmento OA in 3D calcolando i punti in base al numero indicato in kn e tante parallele ad OA quante indicate da knrip} {} AngleVar; OpenPoly; OO.x:=O.x; OO.y:=O.y; FillFore(100,100,100); For ii:=1 TO knrip DO BEGIN BeginPoly3D; For i:=1 to kN+1 DO BEGIN MoveTo(OO.x,OO.y); LineTo((kLu/kn)*i,#(180-kRot)); GetSegPt2(LNewObj,P.x,P.y); DelObject(LNewObj); DistPV:=Distance(P.x,P.y,0,0); P.z:=kH*(1-(DistPV/DistG)); AngP:=Rad2Deg(Arcsin(P.x/DistPV)); AngP3D:=(AngP/AngG)*360; rP:=(DistPV/DistG)*kr; MoveTo(0,0); LineTo(rP,#(270+AngP3D)); GetSegPt2(LNewObj,P.x,P.y); DelObject(LNewObj); IF (ii=1) & (i=0) then Add3DPt(0,-kr,0) ELSE Add3DPt(P.x,P.y,P.z); END; EndPoly3D; hNurbs := ConvertToNURBS(LNewObj, false); MoveTo(O.x,O.y); LineTo((kAlt/knrip)*ii,#(180-kRot-90)); GetSegPt2(LNewObj,OO.x,OO.y); DelObject(LNewObj); End; DoMenuTextByName('Group Chunk',1); NoAngleVar; {NURBS procedure} HGroupCurves:=LSActLayer; HNurbsSurf:=CreateLoftSurfaces(HGroupCurves,False,False,False); {DelObject(HGroupCurves);} SetFillFore(LSActLayer,200,100,100); {Reset} PenSize(PSize); FillFore(red,green,blue); END; RUN(RectSurfOverConicSurface); {END OF THE SCRIPT} Quote Link to comment
Ziska Posted August 24, 2004 Share Posted August 24, 2004 Ha! got it....changed browsers....and then copied. Lamberto- this is very very nice.... mille grazie! Unfortunately I am now experiencing a problem lofting two of the nurbs curves together- it seems to be in an infinity loop- I doubt this has anything to do with the script...but I thought I would mention it? Ziska Quote Link to comment
lamberto previati Posted August 24, 2004 Share Posted August 24, 2004 Hi to all. Here a new evolutione of my script. This one now create a smoothed surface without face effect. Please try and comment. Thank. Ciao Lamberto {copy from all this line to all.........} {Arch. Lamberto Previati ?2004/08 La procedura consente di disegnare un rettangolo dato in termini di Lunghezza/Larghezza/AngoloDiRotazione, sulla superficie conica data in termini di RaggioDiBase/Altezza. 2004-08-24 News: insert two new option in "Other constant" parameter: 1- kDelCone: if equal to 'Y' then procedure kill cone; 2- kDelCurvGpr: if equal to 'Y' then procedure kill Nurbs curves that generate the surface; Implemented: procedure CreateNurbsCurve(0,0,0,True,2); insteed BeginPoly3D, killed; procedure AddVertex3D(hNurbs,P.x,P.y,P.z);insteed Add3DPt(P.x,P.y,P.z); procedure NurbsDelVertex(hNurbs,0,0); for first point correction; } PROCEDURE RectSurfOverConicSurface; CONST {ATTENZIONE le unit? di misure assunte sono quelle impostate} {CONE PARAMETER} kr= 45; {radius of base cone} kH= 2002; {Height of cone} {RECTANGLE SURFACE PARAMETER} kLu= 330; {Rectangle Length } kAlt=80; {Rectangle Height} kRot= 20; {Rectangle rotation. O degree one side is complanar to the cone base} {Point affination} kn=62; {segment for curve} knRip=10; {number of curves} {Other constant} kPi=3.14159; {Costante PiGreco} kDelCone=' '; {Type Y for killing Cone} kDelCurvGrp='Y'; {Type Y for killing curves group} VAR DistG,DistPV,DeltaL,Ckr,CrG,rP:REAL; {DistG=lunghezza generatrice cono/DistGx=distanza di pX da V} p,O3d,A3d,B3d,C3d :Point3D; {pX= punto generico del perimetro del rettangolo} AngG,AngP,AngP3D :REAL;{AngG=angolo di sviluppo/AngP=angolo} i,ii,PSize :INTEGER; {i=indice per i cicli FOR} OO,O,A,B,C :POINT; hLn,hNurbs,HGroupCurves,HNurbsSurf :Handle; red,green,blue :LONGINT; BEGIN {Set view in Top/Plan mode } PopATTRS; DoMenuTextByName('Standard Views',1); {Disegna il CONO in 3D} {} IF kDelCone<>'Y' THEN BEGIN PenSize(5); BeginMXtrd(0,kH); Oval(-kr,kr,kr,-kr); Locus(0,0); EndMXtrd; END; {} DSelectAll; {} {Calcoli preliminari: lunghezza della generatrice, circonf base cono, circonf.con raggio=generatrice, angolo di sviluppo della superficie conica} DistG:=sqrt(kr^2+kH^2); Ckr:=2*kPi*kr; CrG:=2*kPi*DistG; AngG:=(Ckr/CrG)*360; {Impostazioni preliminari} ANGLEVAR; O.x:=0; O.y:=-DistG; MoveTo(O.x,O.y); LineTo((kLu/kn),#(-kRot)); GetSegPt2(LNewObj,O.x,O.y); DelObject(LNewObj); NOANGLEVAR; {Calcola le coordinate dei vertici del rettangolo cio? i punti 0,A,B,C disegnando i quattro lati 0A, 0B, AC e BC} AngleVar; MoveTo(O.x,O.y);Lineto(kLu,#(180-kRot)); GetSegPt2(LNewObj,A.x,A.y);DelObject(LNewObj); MoveTo(O.x,O.y);Lineto(kAlt,#(90-kRot)); GetSegPt2(LNewObj,B.x,B.y);DelObject(LNewObj); MoveTo(A.x,A.y);Lineto(kAlt,#(90-kRot)); GetSegPt2(LNewObj,C.x,C.y);DelObject(LNewObj); MoveTo(B.x,B.y);Lineto(C.x,C.y);DelObject(LNewObj); NoAngleVar; {INIZIO PROCEDURE PER DISEGNARE I LATI DEL RETTANGOLO SULLA SUPERFICIE CONICA} PenSize(10); {Disegna il segmento OA in 3D calcolando i punti in base al numero indicato in kn e tante parallele ad OA quante indicate da knrip} {} AngleVar; OpenPoly; OO.x:=O.x; OO.y:=O.y; FillFore(100,100,100); For ii:=1 TO knrip DO BEGIN hNurbs:=CreateNurbsCurve(0,0,0,True,2); For i:=1 to kN+1 DO BEGIN MoveTo(OO.x,OO.y); LineTo((kLu/kn)*i,#(180-kRot)); GetSegPt2(LNewObj,P.x,P.y); DelObject(LNewObj); DistPV:=Distance(P.x,P.y,0,0); P.z:=kH*(1-(DistPV/DistG)); AngP:=Rad2Deg(Arcsin(P.x/DistPV)); AngP3D:=(AngP/AngG)*360; rP:=(DistPV/DistG)*kr; MoveTo(0,0); LineTo(rP,#(270+AngP3D)); GetSegPt2(LNewObj,P.x,P.y); DelObject(LNewObj); {Add3DPt(P.x,P.y,P.z);} AddVertex3D(hNurbs,P.x,P.y,P.z); END; NurbsDelVertex(hNurbs,0,0); MoveTo(O.x,O.y); LineTo((kAlt/knrip)*ii,#(180-kRot-90)); GetSegPt2(LNewObj,OO.x,OO.y); DelObject(LNewObj); End; DoMenuTextByName('Group Chunk',1); NoAngleVar; {NURBS procedure} HGroupCurves:=LSActLayer; HNurbsSurf:=CreateLoftSurfaces(HGroupCurves,False,False,False); IF kDelCurvGrp='Y' THEN DelObject(HGroupCurves); SetPenFore(LSActLayer,200,100,100); SetFillFore(LSActLayer,200,100,100); {Reset} PushATTRS; END; RUN(RectSurfOverConicSurface); {... this one} Quote Link to comment
lamberto previati Posted August 24, 2004 Share Posted August 24, 2004 Hi Ziska, the script haven't control for its validation field of existence and i think that some or more values can return non-expected result. I haven't explored the limit of script, sorry. Ciao Lamberto. Quote Link to comment
Ziska Posted August 25, 2004 Share Posted August 25, 2004 Lamberto, Let's blame it on the browser realigning the script. Here is a quick example of your second script. Quote Link to comment
Ziska Posted August 25, 2004 Share Posted August 25, 2004 Okay- let's try that again... Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.