Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.4 KiB

  1. #ifndef __gluknotvector_h_
  2. #define __gluknotvector_h_
  3. /**************************************************************************
  4. * *
  5. * Copyright (C) 1992, Silicon Graphics, Inc. *
  6. * *
  7. * These coded instructions, statements, and computer programs contain *
  8. * unpublished proprietary information of Silicon Graphics, Inc., and *
  9. * are protected by Federal copyright law. They may not be disclosed *
  10. * to third parties or copied or duplicated in any form, in whole or *
  11. * in part, without the prior written consent of Silicon Graphics, Inc. *
  12. * *
  13. **************************************************************************/
  14. /*
  15. * knotvector.h - $Revision: 1.1 $
  16. */
  17. #include "types.h"
  18. #ifdef NT
  19. class Knotvector { /* a knot vector */
  20. public:
  21. #else
  22. struct Knotvector { /* a knot vector */
  23. #endif
  24. Knotvector( void );
  25. ~Knotvector( void );
  26. void init( long, long, long, INREAL * );
  27. int validate( void );
  28. void show( char * );
  29. long order; /* order of spline */
  30. long knotcount; /* number of knots */
  31. long stride; /* bytes between points */
  32. Knot * knotlist; /* global knot vector */
  33. };
  34. /* tolerance to test knot coincidence */
  35. #define TOLERANCE 10.0e-5
  36. inline int
  37. identical( Knot x, Knot y )
  38. {
  39. return ((x-y) < TOLERANCE) ? 1 : 0;
  40. }
  41. #endif /* __gluknotvector_h_ */