Main Page   Class Hierarchy   Compound List   File List   Compound Members  

PLib::NurbsSubSurface Class Template Reference

A class to represent a NURBS surface suitable for subdivision. More...

#include <nurbsSub.h>

List of all members.

Public Methods

 NurbsSubSurface (const NurbsSurface< T, 3 > &s)
 ~NurbsSubSurface ()
void drawSubdivisionPS (ostream &os, T tolerance)
void drawSubdivisionPS (const char *f, T tolerance)
void drawSubdivisionVRML (ostream &os, T tolerance, const Color &col=Color(0, 0, 255))
void drawSubdivisionVRML (const char *f, T tolerance, const Color &col=Color(0, 0, 255))
void drawSubdivisionVRML97 (ostream &os, T tolerance, const Color &col=Color(0, 0, 255))
void drawSubdivisionVRML97 (const char *f, T tolerance, const Color &col=Color(0, 0, 255))
void drawSubdivisionPoints (BasicArray< Point_nD< T, 3 > > &pnts, T tolerance)
void drawSubdivisionPoints (T tolerance)

Protected Methods

void drawSubdivision (T tolerance)
void initSurf ()

Protected Attributes

RenderMesh< T > * render
const NurbsSurface< T, 3 > & rsurf
NurbSurface< T > * surf


Detailed Description

template<class T>
class PLib::NurbsSubSurface< T >

A class to represent a NURBS surface suitable for subdivision.

This class adds the methods and the information necessary for performing subdivision on the surface.

Subdivision is mainly used to output the surface in diverse formats such as VRML, Post-Sript or a mesh file.

This class is based on code from the article "Tessellation of NURB Surfaces" by John W. Peterson, jp@blowfish.taligent.com in "Graphics Gems IV", Academic Press, 1994

Author:
Philippe Lavoie
Date:
20 January, 1999

Definition at line 110 of file nurbsSub.h.


Constructor & Destructor Documentation

template<class T>
PLib::NurbsSubSurface< T >::NurbsSubSurface const NurbsSurface< T, 3 > &    s
 

Constructor from a NurbsSurface.

Constructor from a NurbsSurface

Parameters:
s  the NurbsSurface to construct from
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 63 of file nurbsSub.cpp.

template<class T>
PLib::NurbsSubSurface< T >::~NurbsSubSurface  
 

Destructor.

Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 339 of file nurbsSub.cpp.


Member Function Documentation

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivision   tolerance [protected]
 

Draw the subdivision of the NURBS surface.

Draw the subdivision of the NURBS surface

Parameters:
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 136 of file nurbsSub.cpp.

References initSurf.

Referenced by drawSubdivisionPoints, drawSubdivisionPS, drawSubdivisionVRML, and drawSubdivisionVRML97.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionPoints BasicArray< Point_nD< T, 3 > > &    pnts,
  tolerance
 

perform the subdivision of the NURBS and write the result in a VRML file.

Parameters:
os  the ostream to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 271 of file nurbsSub.cpp.

References drawSubdivision.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionPS const char *    f,
  tolerance
 

perform the subdivision of the NURBS and write the result in a PS file.

Parameters:
f  the file name to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 153 of file nurbsSub.cpp.

References drawSubdivisionPS.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionPS ostream &    os,
  tolerance
 

perform the subdivision of the NURBS and write the result in a PS file.

Parameters:
os  the ostream to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 213 of file nurbsSub.cpp.

References drawSubdivision.

Referenced by drawSubdivisionPS.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionVRML const char *    f,
  tolerance,
const Color   col = Color(0,0,255)
 

perform the subdivision of the NURBS and write the result in a VRML file.

Parameters:
f  the file name to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 173 of file nurbsSub.cpp.

References drawSubdivisionVRML.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionVRML ostream &    os,
  tolerance,
const Color   col = Color(0,0,255)
 

perform the subdivision of the NURBS and write the result in a VRML file.

Parameters:
os  the ostream to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 232 of file nurbsSub.cpp.

References drawSubdivision.

Referenced by drawSubdivisionVRML.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionVRML97 const char *    f,
  tolerance,
const Color   col = Color(0,0,255)
 

perform the subdivision of the NURBS and write the result in a VRML file.

Parameters:
f  the file name to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
30 April 1999

Definition at line 193 of file nurbsSub.cpp.

References drawSubdivisionVRML97.

template<class T>
void PLib::NurbsSubSurface< T >::drawSubdivisionVRML97 ostream &    os,
  tolerance,
const Color   col = Color(0,0,255)
 

perform the subdivision of the NURBS and write the result in a VRML file.

Parameters:
os  the ostream to write to
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
30 April 1999

Definition at line 251 of file nurbsSub.cpp.

References drawSubdivision.

Referenced by drawSubdivisionVRML97.

template<class T>
void PLib::NurbsSubSurface< T >::initSurf   [protected]
 

initialise the subdivision surface.

Parameters:
tolerance  the accepted tolerance
Author:
Philippe Lavoie
Date:
20 January 1999

Definition at line 289 of file nurbsSub.cpp.

Referenced by drawSubdivision.


The documentation for this class was generated from the following files:
Generated on Tue Jun 24 13:27:00 2003 for NURBS++ by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002