Author Topic: getting the point within the line...  (Read 1434 times)

0 Members and 1 Guest are viewing this topic.

rainier

  • Guest
getting the point within the line...
« on: October 01, 2007, 01:12:17 AM »
what function to get the point (xyz) with the line???

like that --->  ____._______

ohh! i mean is i have a distance on the point but i dont have a location.. getting the (XYZ)
any idea guys?? please help.. thanks
« Last Edit: October 01, 2007, 01:16:58 AM by rainier »

FengK

  • Guest
Re: getting the point within the line...
« Reply #1 on: October 01, 2007, 01:52:17 AM »
if i understood you correctly, look up function polar.

from ref:

(polar pt ang dist)
Arguments

pt

A 2D or 3D point.

ang

An angle expressed in radians relative to the world X axis. Angles increase in the counterclockwise direction, independent of the current construction plane.

dist

Distance from the specified pt.

Return Values

A 2D or 3D point, depending on the type of point specified by pt.

« Last Edit: October 01, 2007, 01:55:11 AM by Kelie »

CAB

  • Global Moderator
  • Seagull
  • Posts: 10401
Re: getting the point within the line...
« Reply #2 on: October 01, 2007, 09:12:59 AM »
Polar requires the start point, angle and distance while vlax-curve-getPointAtDist requires the object and distance.
 
Code: [Select]
(setq p2 (polar p1 angle dist))
 
(setq p2 (vlax-curve-getPointAtDist ent dist))

 Note that the vlax-curve-getPointAtDist uses the start point of the object when created and may not be the point
 you think it is.
I've reached the age where the happy hour is a nap. (°¿°)
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

CADaver

  • Guest
Re: getting the point within the line...
« Reply #3 on: October 01, 2007, 11:42:13 AM »
hmmm... ???x2

Anyway, as Alan points out vlax-curve-getPointAtDist uses the start point so I still use the old CAL function.