/*****************************************************************************
* Conversion routines from curvesand surfaces to polygons and polylines.     *
*									     *
* Written by:  Gershon Elber				Ver 1.0, Apr 1992    *
*****************************************************************************/

#ifndef IP_CONVRT_H
#define IP_CONVRT_H

#include "iritprsr.h"
#include "attribut.h"

IPPolygonStruct *IritCurve2Polylines(CagdCrvStruct *Crv, int SamplesPerCurve);
IPPolygonStruct *IritCurve2CtlPoly(CagdCrvStruct *Crv);
IPPolygonStruct *IritSurface2Polylines(CagdSrfStruct *Srf, int NumOfIsolines[2],
				       int SamplesPerCurve);
IPPolygonStruct *IritSurface2CtlMesh(CagdSrfStruct *Srf);
IPPolygonStruct *IritSurface2Polygons(CagdSrfStruct *Srf, int FourPerFlat,
				      int FineNess, int ComputeUV);
void IritSetCurvesToCubicBzrTol(RealType Tolerance);
CagdCrvStruct *IritCurvesToCubicBzrCrvs(CagdCrvStruct *Crvs,
					IPPolygonStruct **CtlPolys,
					CagdBType DrawCurve,
					CagdBType DrawCtlPoly,
					CagdRType MaxArcLen);
CagdCrvStruct *IritSurfacesToCubicBzrCrvs(CagdSrfStruct *Srfs,
					  IPPolygonStruct **CtlMeshes,
					  CagdBType DrawSurface,
					  CagdBType DrawMesh,
					  int NumOfIsolines[2],
					  CagdRType MaxArcLen);

#endif /* IP_CONVRT_H */
