Jump to content

vlax-curve-getClosestPointToProjection returns inconsistent results


Recommended Posts

Posted

Hi,

How can I ensure that vlax-curve-getClosestPointToProjection returns the closest point in every case? I suspect that the curve is merging in the projected plane and therefore it does not always return the closest point in the desired direction.

Alternatively, I could probably use vla-IntersectWith method with a line object and find the closest point, but I'm using grread where vlax-curve-getClosestPointToProjection will be more appropriate, I don't have to create and delete line objects in while loop.

Animation.apng

Drawing1.dwg sline2_dev_v2.lsp

Posted (edited)

I Really need to start using grread and grdraw more. seen some really nice things the past few week on here. what happens if you take out LM:rounddown function call?

 

-edit

i haven't run the code but might be something in the (if (< dst dse) that isn't updateing the cpt point correctly. that is making "outside" the other line.

Edited by mhupp

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...