How to control which part to trim?

Hi guys,

Now i am trying write code to convert data from NX to Rhino, When i want to trim a brep, what i really need is like this.

image

But now result is

image

I want to know which parameter should I change to optimize this?

And one other thing, When i want to create a trimmed cone/cylinder, top of which is a ellipse, like this

But i get a invalid Brep, and i was told that ON_Brep.m_T[1] 2d curve is not inside surface domain.

Your help will be appreciated. Thx.

Hi @zcstkhk,

With what little you’ve provided, I’m not sure how to assist.

If the goal is import NX file into Rhino, then you might consider these to resouces:

Rhino plug-ins to convert, import and export files

https://cadexchanger.com/rhino/nx-to-rhino/

NX will also write STEP files, which Rhino will import.

– Dale

1 Like

Here is the rhino file, which contains a brep created by my tool,

And a brep import from STEP file by Rhino, which is correct.

brep_trim_issue.3dm (114.0 KB)

Hope you can give some advice. Thx.

Hi

FWIW:
With my limited knowledge I would suggest the direction of the trim curve should be reversed.

-Willem

Hi @zcstkhk,

I suggest using Visusl Studio’s debugger to example the differences between the two. Rhino’s List command can also be helpful in determining the differences.

– Dale