Home
Reply
New Visitor
sharc
Posts: 1

Changing Faceter Settings in ACIS

Hi

 

I am new here so please bear with me if I am in the wrong group.

 

I am using the ACIS faceter to convert a CATIA V5 file into a faceted format.

I can get this to work pretty well, but want to know how to turn on some

of the options like adaptive faceting. I cannot see how to do this in a c++ code.

 

Any advice would be most helpful.

 

Thanks

Spatial Employee
gweedo
Posts: 14

Re: Changing Faceter Settings in ACIS

Try something like the following...

 

    option_header * adaptive_triangles_option = find_option( "adaptive_triangles" );
    if ( adaptive_triangles_option != NULL )
        adaptive_triangles_option->push( TRUE );

    outcome res = api_facet_entity( body );

    if ( adaptive_triangles_option != NULL )
        adaptive_triangles_option->pop();

 

This works immensely faster in ACIS R19.

Contributor
pranveer
Posts: 5

Re: Changing Faceter Settings in ACIS

Hey there, 

 

I am using R15 and tried using the above method for enabling "adaptive_triangles" option in my faceting application. The code compiled well but when I ran the code it threw an exception at "pMesh->get_next_polygon(mesh_polygon);" and ended abruptly.

 

Is it the R15 version problem or I am doing something wrong ??

 

Any help would really be great. 

Spatial Employee
asdf
Posts: 93

Re: Changing Faceter Settings in ACIS

[ Edited ]

If you used the code gweedo suggested, I think you are doing things correctly.  Without looking at it, I cannot tell if it is a bug specific to R15. 

 

You may want to look at the setup of your application.  Acis APIs do not throw exceptions -- exceptions are trapped by the api block and the information is in the result.  A failing API won't cause your application to crash, but if you rethrow exceptions and don't catch them, then your application will crash.

 

As mentioned above, the adaptive faceting algorithm was largely improved for R19.  You might also consider updating to R21 when it comes out, becuase the default faceting accuracy has been substantially improved for it.  It is as accurate as adaptive triangles ever was, but with sensible settings it is similar in speed to default faceting.  If you contact support services, they may be able to get you a prerelease of r21.