# SUBSYSTEM OVERVIEW

Parasolid Interface (PINT) Subsystem

The (PINT) subsystem is the top level subsystem in the PDElib Parasolid Interface. The PINT subsystem provides Parasolid schema specific functions for translating to and/or from Parasolid data structures. The reader should be familiar with the MDA subsystems before reading this man page. Additionally, the MAP, GDX, and DDF subsystems are applicable (see mda_intro, map_intro, gdx_intro, and ddf_intro man pages.

# GENERAL CONCEPTS

The Parasolid Interface to PDElib consists of the Parasolid EXPRESS model and several subsystems of functions, each beginning with the letter 'p'. The Parasolid Interface subsystems are as follows:

PINT

The top level Parasolid Interface subsystem

PPIR

The subsystem to read Parasolid data using the Parasolid API's

PPIW

The subsystem to write Parasolid data using the Parasolid API's

PGDX

The subsystem of functions to convert between Parasolid data (in the PDElib Parasolid EXPRESS model) and GDX data structures.

PMAP

The subsystem to allow the Parasolid Interface to be used within the PDElib map entity framework. (see map_intro)

PICR

The subsystem of functions to directly create Parasolid EXPRESS model entities.

Each subsystem has an intro man page which explains more detail about the functionality available in the subsystem.

The PPIR and PPIW subsystems are designed to read/write directly to a Parasolid file. At this time, they can not be called from an already open Parasolid session. Thus, at this time, a translator can not be linked in with a CAD application to directly read/write the Parasolid entities.

# Parasolid EXPRESS MODEL (pint.exp)

Parasolid data within PDElib is handled using the standard mda (model data access) entity structure (see mda_intro). The entities are defined using EXPRESS with data structures that are as close to Parasolid data structures as possible. Certain entities were merged together to reduce entity access overhead while preserving the data representation. There is no interpretation or conversion that takes places in terms of geometric content of the data.

To ensure that the PINT model is initialized properly, a call to pint_InitModelInfo must be made before allocating the model.

# CREATING A PINT MODEL

To create an PINT model, the following code sequence is used:

    #include "pint_Interface.h"
    #include "ppir_Interface.h"
    #include "ppiw_Interface.h"
    #include "pmap_Interface.h"
    #include "mda_Interface.h"
    MDA_MODEL_INFO model_info;
    int pint_model;
          .
    pdx_Initialize (PDX_NOOPT);
    pint_Initialize(PINT_NOOPT);
          .
    mda_GetModelDefaults(MDA_NOOPT, &model_info);
    pint_InitModelInfo(PINT_NOOPT, &model_info);
          .
    /* Other model_info fields set */
          .
    mda_AllocateModel(MDA_NOOPT, &model_info, &pint_model);

The model is now ready to have Parasolid entities added. The model can be populated with the contents of a Parasolid file by calling ppir_Read.

# TOLERANCES/PRECISIONS

The PINT model stores the session precisions in each body. The PPIR subsystem sets the PINT_BODY precisions from the session precisions in the Parasolid file. The PPIW subsystem always uses the default precisions when writing a new Parasolid file. The PPIW subsystem uses the precisions in the PINT body to perform body checking. The PGDX subsystem uses the precisions in the body to set the GDX model space point tolerance and GDX andle tolerance. Likewise, the inverse occurs when converting a GDX_SOLID to a PINT_BODY.

The PINT model stores the edge precisions and vertex precisions. PPIR and PPIW subsystems read/write these values directly to/from the Parasolid edge/vertex. Currently, GDX does not have edge or vertex tolerances, so the edge and vertex precisions are lost when PGDX converts a PINT edge/vertex entity to/from GDX.

# PARASOLIDS DATA REQUIREMENTS

Parasolids assumes a default unit of meters. The function gdx_ModelConvertUnits is to be used to convert the geometry to meters. The unit conversion is performed on the whole GDX model at once. It could not be an entity mapping. Thus, any program to create Parasolids data must programatically call this function. For more information on units in GDX, see gdx_ModelConvertUnits, gcr_ModelVar, gdx_model_var.

Parasolids does not have a face sense or a loop sense. Thus, all the faces senses and loop senses must be true in the GDX data prior to converting it into Parasolids (PINT). Parasolids also requires G1 continuous surfaces and curves. These constraints on Parasolid data can be taken care of by using the mapping "gdx_solid -> process gdx_solid" with the GMP_PREP_PS option, or the gdx_SolidProcessAll() with the GDX_PREP_PS option.

View the sample programs, ptog.c and gtop.c, to see how GDX and Parasolids interact with mappings.

# SPECIAL CONSIDERATIONS

In order to compile or link with the PINT subsystem, the following are required:

1)

Parasolid libraries and include files must be available.

2)

The appropriate C compilers must be available.