Source code of Windows XP (NT5)
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.

74 lines
1.9 KiB

  1. /******************************Module*Header*******************************\
  2. * Module Name: objects.h
  3. *
  4. * Copyright (c) 1994 Microsoft Corporation
  5. *
  6. \**************************************************************************/
  7. #ifndef __objects_h__
  8. #define __objects_h__
  9. #include "sspipes.h"
  10. #include "state.h"
  11. class OBJECT_BUILD_INFO {
  12. public:
  13. float radius;
  14. float divSize;
  15. int nSlices;
  16. BOOL bTexture;
  17. IPOINT2D *texRep;
  18. };
  19. /**************************************************************************\
  20. *
  21. * OBJECT classes
  22. *
  23. * - Display list objects
  24. *
  25. \**************************************************************************/
  26. class OBJECT {
  27. protected:
  28. int listNum;
  29. int nSlices;
  30. public:
  31. void Draw();
  32. OBJECT();
  33. ~OBJECT();
  34. };
  35. class PIPE_OBJECT : public OBJECT {
  36. private:
  37. void Build( OBJECT_BUILD_INFO *state, float length, float start_s, float s_end );
  38. public:
  39. PIPE_OBJECT( OBJECT_BUILD_INFO *state, float length );
  40. PIPE_OBJECT( OBJECT_BUILD_INFO *state, float length, float start_s, float end_s );
  41. };
  42. class ELBOW_OBJECT : public OBJECT {
  43. private:
  44. void Build( OBJECT_BUILD_INFO *state, int notch, float start_s, float end_s );
  45. public:
  46. ELBOW_OBJECT( OBJECT_BUILD_INFO *state, int notch );
  47. ELBOW_OBJECT( OBJECT_BUILD_INFO *state, int notch, float start_s, float end_s );
  48. };
  49. class BALLJOINT_OBJECT : public OBJECT {
  50. private:
  51. void Build( OBJECT_BUILD_INFO *state, int notch, float start_s, float end_s );
  52. public:
  53. // texturing version only
  54. BALLJOINT_OBJECT( OBJECT_BUILD_INFO *state, int notch, float start_s, float end_s );
  55. };
  56. class SPHERE_OBJECT : public OBJECT {
  57. private:
  58. void Build( OBJECT_BUILD_INFO *state, float radius, float start_s, float end_s );
  59. public:
  60. SPHERE_OBJECT( OBJECT_BUILD_INFO *state, float radius, float start_s, float end_s );
  61. SPHERE_OBJECT( OBJECT_BUILD_INFO *state, float radius );
  62. };
  63. #endif // __objects_h__