propstuff Posted January 1, 2010 Share Posted January 1, 2010 I have received a model consisting of a bazillion linear (2 vertex) 3D polys. I want to find the length of some of them, but none of the Engineering or 3D properties tools will yield their length. Would anyone have a script which would return the true length of a 3D poly? TIA, N. Quote Link to comment
MullinRJ Posted January 1, 2010 Share Posted January 1, 2010 Nicholas, ???Here is a short script that will return the length of one 2-vertex 3D Poly. Of course, a favorite program of mine will do the same and a whole lot more. ;-) ???If you are looking for the length of all selected Polys, that's easy, too. PROCEDURE Length3DLine; VAR P0, P1 :Vector; BEGIN GetPolyPt3D(FSActLayer, 0, P0.x, P0.y, P0.z); GetPolyPt3D(FSActLayer, 1, P1.x, P1.y, P1.z); Message(Norm(P1-P0)); { Length of vector between 2 points } END; Run(Length3DLine); Happy New Year, Raymond Quote Link to comment
propstuff Posted January 1, 2010 Author Share Posted January 1, 2010 Nicholas, ? Of course, a favorite program of mine will do the same and a whole lot more. ;-) Would that program start with "Re" and end with "er"? :-) Thanks Raymond, thats a big help. cheers, N. Quote Link to comment
MullinRJ Posted January 1, 2010 Share Posted January 1, 2010 Would that program start with "Re" and end with "er"? :-)It might. :whistle: You're welcome. Raymond Quote Link to comment
Kool Aid Posted January 2, 2010 Share Posted January 2, 2010 Reconnoitre (Br, Aus, NZ) or reconnoiter (US, Can)? Sorry, could not resist?? Quote Link to comment
Kool Aid Posted January 2, 2010 Share Posted January 2, 2010 Very elegant, Raymond! Ahh, the ?easy?: One has to have a REAL variable to store the accumulated lengths, adding each to it. 3D-polys with 3 or more vertices are easy, too? Now pay attention, single-oh-integer: the vertex index starts from zero. 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.