// File generated by CPPExt (Transient)
//
//
//                     Copyright (C) 1991 - 2000 by  
//                      Matra Datavision SA.  All rights reserved.
//  
//                     Copyright (C) 2001 - 2004 by
//                     Open CASCADE SA.  All rights reserved.
// 
// This file is part of the Open CASCADE Technology software.
//
// This software may be distributed and/or modified under the terms and
// conditions of the Open CASCADE Public License as defined by Open CASCADE SA
// and appearing in the file LICENSE included in the packaging of this file.
//  
// This software is distributed on an "AS IS" basis, without warranty of any
// kind, and Open CASCADE SA hereby disclaims all such warranties,
// including without limitation, any warranties of merchantability, fitness
// for a particular purpose or non-infringement. Please see the License for
// the specific terms and conditions governing rights and limitations under the
// License.

#ifndef _DrawTrSurf_BSplineSurface_HeaderFile
#define _DrawTrSurf_BSplineSurface_HeaderFile

#ifndef _Standard_HeaderFile
#include <Standard.hxx>
#endif
#ifndef _Handle_DrawTrSurf_BSplineSurface_HeaderFile
#include <Handle_DrawTrSurf_BSplineSurface.hxx>
#endif

#ifndef _Standard_Boolean_HeaderFile
#include <Standard_Boolean.hxx>
#endif
#ifndef _Draw_MarkerShape_HeaderFile
#include <Draw_MarkerShape.hxx>
#endif
#ifndef _Draw_Color_HeaderFile
#include <Draw_Color.hxx>
#endif
#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
#ifndef _DrawTrSurf_Surface_HeaderFile
#include <DrawTrSurf_Surface.hxx>
#endif
#ifndef _Handle_Geom_BSplineSurface_HeaderFile
#include <Handle_Geom_BSplineSurface.hxx>
#endif
#ifndef _Standard_Real_HeaderFile
#include <Standard_Real.hxx>
#endif
#ifndef _Handle_Draw_Drawable3D_HeaderFile
#include <Handle_Draw_Drawable3D.hxx>
#endif
class Geom_BSplineSurface;
class Draw_Color;
class Draw_Display;
class Draw_Drawable3D;



//!  This class defines a drawable BSplineSurface. <br>
//!  With this class you can draw the control points and the knots <br>
//!  of the surface. <br>
//!  You can use the general class Surface from DrawTrSurf too, <br>
//!  if you just want to sea boundaries and isoparametric curves. <br>
class DrawTrSurf_BSplineSurface : public DrawTrSurf_Surface {

public:
 // Methods PUBLIC
 // 

//! default drawing mode. <br>
//!  The isoparametric curves corresponding to the knots values are <br>
//!  drawn. <br>
//!  The control points and the knots points are drawn. <br>
//!  The boundaries are yellow, the isoparametric curves are blues. <br>
//!  For the discretisation 50 points are computed in each parametric <br>
//!  direction. <br>
Standard_EXPORT DrawTrSurf_BSplineSurface(const Handle(Geom_BSplineSurface)& S);


//!  The isoparametric curves corresponding to the knots values are <br>
//!  drawn. <br>
Standard_EXPORT DrawTrSurf_BSplineSurface(const Handle(Geom_BSplineSurface)& S,const Draw_Color& BoundsColor,const Draw_Color& IsosColor,const Draw_Color& PolesColor,const Draw_Color& KnotsColor,const Draw_MarkerShape KnotsShape,const Standard_Integer KnotsSize,const Standard_Boolean ShowPoles,const Standard_Boolean ShowKnots,const Standard_Integer Discret,const Standard_Real Deflection,const Standard_Integer DrawMode);

//! Parametric equidistant iso curves are drawn. <br>
Standard_EXPORT DrawTrSurf_BSplineSurface(const Handle(Geom_BSplineSurface)& S,const Standard_Integer NbUIsos,const Standard_Integer NbVIsos,const Draw_Color& BoundsColor,const Draw_Color& IsosColor,const Draw_Color& PolesColor,const Draw_Color& KnotsColor,const Draw_MarkerShape KnotsShape,const Standard_Integer KnotsSize,const Standard_Boolean ShowPoles,const Standard_Boolean ShowKnots,const Standard_Integer Discret,const Standard_Real Deflection,const Standard_Integer DrawMode);


Standard_EXPORT   void DrawOn(Draw_Display& dis) const;


Standard_EXPORT   void ShowPoles() ;


Standard_EXPORT   void ShowKnots() ;

//! change the number of isoparametric curves to be drawn. <br>
Standard_EXPORT virtual  void ShowIsos(const Standard_Integer Nu,const Standard_Integer Nv) ;

//! change the number of isoparametric curves to be drawn. <br>
Standard_EXPORT   void ShowKnotsIsos() ;

//! rub out all the isoparametric curves. <br>
Standard_EXPORT virtual  void ClearIsos() ;


Standard_EXPORT   void ClearPoles() ;


Standard_EXPORT   void ClearKnots() ;


Standard_EXPORT   void FindPole(const Standard_Real X,const Standard_Real Y,const Draw_Display& D,const Standard_Real Prec,Standard_Integer& UIndex,Standard_Integer& VIndex) const;


Standard_EXPORT   void FindUKnot(const Standard_Real X,const Standard_Real Y,const Draw_Display& D,const Standard_Real Prec,Standard_Integer& UIndex) const;


Standard_EXPORT   void FindVKnot(const Standard_Real X,const Standard_Real Y,const Draw_Display& D,const Standard_Real Prec,Standard_Integer& VIndex) const;

  void SetPolesColor(const Draw_Color& aColor) ;

  void SetKnotsColor(const Draw_Color& aColor) ;

  void SetKnotsShape(const Draw_MarkerShape Shape) ;

  Draw_MarkerShape KnotsShape() const;

  Draw_Color KnotsColor() const;

  Draw_Color PolesColor() const;

//! For variable copy. <br>
Standard_EXPORT virtual  Handle_Draw_Drawable3D Copy() const;
//Standard_EXPORT ~DrawTrSurf_BSplineSurface();




 // Type management
 //
 Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
 //Standard_EXPORT Standard_Boolean	       IsKind(const Handle(Standard_Type)&) const;

protected:

 // Methods PROTECTED
 // 


 // Fields PROTECTED
 //


private: 

 // Methods PRIVATE
 // 


 // Fields PRIVATE
 //
Standard_Boolean drawPoles;
Standard_Boolean drawKnots;
Standard_Boolean knotsIsos;
Draw_MarkerShape knotsForm;
Draw_Color knotsLook;
Standard_Integer knotsDim;
Draw_Color polesLook;


};


#include <DrawTrSurf_BSplineSurface.lxx>



// other Inline functions and methods (like "C++: function call" methods)
//


#endif
