Introduction to Rendering and Faceting   

<<< Attributes Chapters Parasolid View Matrices >>>

Contents

[back to top]


48.1 Introduction

Visual representation of parts modeled in Parasolid is provided by the rendering and faceting functionality, which generates wire frame and hidden line pictures of bodies, faces end edges in the session.

These processes are introduced in this chapter.

The following chapters cover some concepts which are generally applicable to rendering and faceting:

Specific information on the PK functions which perform rendering and faceting is contained in further chapters as indicated in the text below.

[back to top]


48.2 Introduction to rendering

Rendering is the process of asking the modeler to produce graphical data representing a particular entity or set of entities. There are two functions which produce the following types of graphical data when rendering geometric and topological entities:

 

PK_GEOM_render_line PK_TOPOL_render_line

View independent geometry

View independent topology

View dependent topology

Hidden line drawings

The differences in these types of output are explained in Chapter 52, "Rendering Functions".

In its simplest form, the graphical data consist of polyline, circular and elliptical line segments which approximate the surface boundaries and edge geometry of rendered entities. A user-supplied curve tolerance controls how closely the rendered data match the geometry of original model entities.

 

Note: Because the rendered data are calculated to curve tolerance accuracy and not to modeling accuracy, these data should not be used for modeling calculations.

[back to top]

48.2.1 Options

Options are available to generate additional geometric data such as face hatching, blend boundaries and silhouette lines.

There are other options which divide the rendered data into hidden and visible line segments and output additional data such as smoothness and regional classification values alongside the geometric GO data.

These options are described in general terms, using the categories listed in the above table, in Chapter 52, "Rendering Functions". Detailed descriptions of the option structures are in Chapter 53, "Rendering Option Settings".

[back to top]


48.3 Introduction to faceting

The term "faceting" describes the generation of an approximate representation of a part using a mesh of polygonal planar facets to represent its faces.

A user-supplied curve tolerance controls how closely the boundary of each face mesh matches the edge geometry of the face. A user-supplied surface tolerance controls how closely each face mesh matches the surface geometry of the face.

Further options are available which constrain the size and shape of facets in the mesh.

 

Figure 48-1 Faceted representations of a toroidal body

[back to top]

48.3.1 Outputting facet geometry through the GO

PK_TOPOL_render_facet outputs facet geometry through the Graphical Output (GO) interface, defining each facet as a closed polygon. It is passed an option structure, PK_TOPOL_render_facet_o_t, consisting of a pair of typedefs:

 

Option Structure Controls Described in

PK_TOPOL_facet_mesh_o_t

how the facet mesh is constructed

Chapter 54, "Facet Mesh Generation"

PK_TOPOL_render_facet_go_o_t

the type of data which is output through GO

Chapter 55, "Faceting Output Via GO"

[back to top]

48.3.2 Outputting facet information in tabular format

PK_TOPOL_facet returns a tabular representation of the part's topology and geometry, defining the facet mesh in terms of connected facet, fin and vertex indices. It is passed an options structure, PK_TOPOL_facet_o_t, consisting of a pair of typedefs:

 

Option Structure Controls Described in

PK_TOPOL_facet_mesh_o_t

how the facet mesh is constructed

Chapter 54, "Facet Mesh Generation"

PK_TOPOL_facet_choice_o_t

the output of the tabular data

Chapter 56, "Tabular Output of Faceting"

PK_TOPOL_facet_choice_o_t chooses which types of faceting data the application requires, defining totals for the number of facets, fins and vertices, and pointers to arrays of data which define facet topology, geometry and associated data.

In this case the faceting data is not output through the GO, but is returned to the application using the following structure:

 

Option Structure Controls Described in

PK_TOPOL_facet_r_t

contains the data returned to the application

Chapter 56, "Tabular Output of Faceting"

[back to top]


48.4 Graphical output (GO)

Graphical data are output when the PK rendering functions call registered "GO" functions (GOOPSG, GOSGMT and GOCLSG).

The application must capture this 3-dimensional data and use it to generate pictures on the screen or create hard copy output from it.

All GO data is defined in modeling coordinates. The application writer must implement a set of GO functions which first transform view dependent and hidden line data into the application's viewing coordinate system.

The transformed data can be passed to a 3-dimensional rendering package or projected onto the application viewing screen using homogenous matrix techniques.

The selection of rendering options is governed by whether the application's GO functions require such additional data. A minimal implementation of GO must be able to transform and display (or postprocess) basic rendering data such as polylines and arc segments.

The GO implementation should be written so that it discounts rendering data which it does not understand and behaves sensibly if it does not always receive the additional rendering data. This allows a minimal implementation of GO to be enhanced at a later date and new rendering options to be introduced.

The format of GO data is described in Chapter 4, "Graphical Output", of the Parasolid Downward Interfaces manual and in the GOOPSG, GOSGMT and GOCLSG function headers descriptions in Appendix B, "Graphical Output Functions". View dependent data and viewing matrix construction are described later.

 

[back to top]

<<< Attributes Chapters Parasolid View Matrices >>>