The Parametric Pseudo-Manifold (PPS) Library 1.0
Defining geometry

To add more flexibility to the PPS library, we ask the user to provide a surface to be approximated by the surface defined by the PPS class. Why? We believe the main reason for using a surface defined by a PPS is its higher degree of continuity. It is a well-known fact that higher order of continuity surfaces obtained from other approaches (i.e., as subdivision surfaces or by the patch-stitching paradigm) have poor visual quality, as opposed to lower order of continuity surfaces. To avoid this kind of problem, we created a procedure that defines the geometry of a PPS by "mimicking" the geometry of a given surface defined over the input mesh. The given surface can have any degree of continuity (but it must be at least continuous). Our procedure ensures that the visual quality of a PPS is basically the same as the visual quality of the given surface. So, by providing a good visual quality, lower degree of continuity surface as input, the user can obtain a good visual quality, higher degree of continuity surface as output.

How can the user provide a surface defined over the mesh? The user can do that by implementing a pure virtual method of the PPS class, called pps::PPS::eval_surface.

The method

virtual void eval_surface( Face* face , double u , double v , double w , double& x , double& y , double& z ) const = 0 ;

is a pure virtual method that computes a point on the surface provided by the user. The method takes in a pointer to a face of the triangle mesh (i.e., a triangle) and the parameter barycentric coordinates, $(u,v,w)$, and then computes the coordinates $(x,y,z)$ of the point on the surface corresponding to the parameter point whose barycentric coordinates are $(u,v,w)$. These coordinates are given with respect to the affine frame (i.e., a triangle) that defines the parametric domain of the surface patch associated with the mesh face pointed by the parameter face. Once the user implements this method in a class that derives from the PPS class, the PPS class constructor can use it to compute an approximation to the surface defined by the user.