×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

make a edge from a curve based on the start and end parameter

make a edge from a curve based on the start and end parameter

make a edge from a curve based on the start and end parameter

(OP)
Hi all
Does anyone know which command should I use to make an edge on the curve between parameters p1 (start) and p2 (end), using OpenNX API? I want to add several trimmed edges to form a polygon.
Many Thanks!

RE: make a edge from a curve based on the start and end parameter

(OP)
Basically, this will be a trimming operation.

Thanks!

RE: make a edge from a curve based on the start and end parameter

(OP)
can anyone help?

RE: make a edge from a curve based on the start and end parameter

I'm not clear on what your end goal is.
Do you want to create a planar sheet body polygon? If so, create the curves to form the perimeter of the polygon and extrude them with a zero thickness.

www.nxjournaling.com

RE: make a edge from a curve based on the start and end parameter

(OP)
I am actually using the NX C++ API to do our own project. The goal is to use the primitives provided by NX to write our program so as to create our own product. The NX GUI is merely used for visualization purpose. We will start with the 2D level, such as, polygon boolean operation to form the 2D sketches of the product, and then extrude/revolve the 2D sketches into 3D. For the 2D operations, the operations, such as, polygon Boolean operation, curve trim and curve intersection, will be used.

Now suppose I have a curve being created. I want to trim the curve by adjusting the curve starting and ending points, parametrically, and do it through c++ programming. For example, I have a line, line1, starts from (0., 0., 0) and ends at (2., 0., 0). If I want to trim it by starting from its 1/4 position and ending at its 3/4 position, (in programming, the favorable function would be: trim(&line, 1/4, 3/4)), the newly created line would be starting from p0(0.25, 0., 0) and ending at (0.75, 0., 0). Is there a function in NX can implement it?

Many thanks!

RE: make a edge from a curve based on the start and end parameter

Do you have access to the NX help files? The "programming guide" section is a handy reference.

One approach would be by using the CreatePoint method; it has an option to create a point at a certain percentage along an existing curve's length. You could create 2 of these points at the desired locations then use them to either create a new line or redefine your existing line.

p.s. NX does not support 2D boolean operations.

www.nxjournaling.com

RE: make a edge from a curve based on the start and end parameter

(OP)
Thank you cowski for your responds. I think the function you mean is UF_POINT_create_on_curve, right?
Yes, I think this certainly can do the work. Steps may be:
1. find the desired point on the curve based on the parameter;
2. based on the point create a line or plane as the reference object for trimming;
3. and use the line/plane to trim the curve using UF_create_trim function.


Apart from that, I also found another way to do that, using the 'UF_CURVE_edit_length' function. It can adjust the total length of the curve, and can be used as trim/extend function. Basically, it solves the problem.

Yes, I am aware that the 2D Boolean operations are not viable in NX.

Many thanks!

RE: make a edge from a curve based on the start and end parameter

Quote (lugan2)

I think the function you mean is UF_POINT_create_on_curve, right?

I use the .NET version of the API, so for me it is the CreatePoint method (one of the overloaded versions), but I'm glad you were able to translate that over to what you needed.

You might even be able to use the point directly in the curve trim operation (it works in interactive NX, anyway).

www.nxjournaling.com

RE: make a edge from a curve based on the start and end parameter

(OP)
Oh, yes. I remember that I can use the point as the suggested point for the bounding condition to trim.

Thanks for you help!

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources