Counter Strike : Global Offensive Source Code
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.

95 lines
2.4 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //
  7. //=============================================================================//
  8. #if !defined(AFX_TORUSDLG_H__C146AA5D_38FE_11D1_AFC9_0060979D2F4E__INCLUDED_)
  9. #define AFX_TORUSDLG_H__C146AA5D_38FE_11D1_AFC9_0060979D2F4E__INCLUDED_
  10. #if _MSC_VER >= 1000
  11. #pragma once
  12. #endif // _MSC_VER >= 1000
  13. // TorusDlg.h : header file
  14. //
  15. /////////////////////////////////////////////////////////////////////////////
  16. // CTorusDlg dialog
  17. #define ARC_MAX_POINTS 4096
  18. class CTorusDlg : public CDialog
  19. {
  20. // Construction
  21. public:
  22. CTorusDlg(Vector& bmins, Vector& bmaxs, CWnd* pParent = NULL); // standard constructor
  23. ~CTorusDlg(); // standard constructor
  24. void DrawTorusTopView( CDC *pDC );
  25. void DrawTorusCrossSection( CDC *pDC );
  26. float GetTorusCrossSectionRadius() const;
  27. BOOL bInitialized;
  28. float fOuterPoints[ARC_MAX_POINTS][2];
  29. float fInnerPoints[ARC_MAX_POINTS][2];
  30. Vector bmins, bmaxs;
  31. // Dialog Data
  32. //{{AFX_DATA(CTorusDlg)
  33. enum { IDD = IDD_TORUS };
  34. CSpinButtonCtrl m_cStartAngleSpin;
  35. CSpinButtonCtrl m_cWallWidthSpin;
  36. CEdit m_cWallWidth;
  37. CSpinButtonCtrl m_cSidesSpin;
  38. CEdit m_cSides;
  39. CSpinButtonCtrl m_cArcSpin;
  40. CEdit m_cArc;
  41. CStatic m_cPreview;
  42. CStatic m_cTopViewPreview;
  43. int m_iSides;
  44. int m_iWallWidth;
  45. float m_fArc;
  46. float m_fAngle;
  47. float m_fRotationArc;
  48. float m_fRotationAngle;
  49. int m_iRotationSides;
  50. int m_iAddHeight;
  51. float m_fCrossSectionRadius;
  52. //}}AFX_DATA
  53. void SetMaxWallWidth(int iMaxWallWidth) { m_iMaxWallWidth = iMaxWallWidth; }
  54. void SaveValues();
  55. // Overrides
  56. // ClassWizard generated virtual function overrides
  57. //{{AFX_VIRTUAL(CTorusDlg)
  58. protected:
  59. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  60. //}}AFX_VIRTUAL
  61. // Implementation
  62. protected:
  63. float MaxTorusCrossSectionRadius() const;
  64. int m_iMaxWallWidth;
  65. // Generated message map functions
  66. //{{AFX_MSG(CTorusDlg)
  67. afx_msg void OnChangeArc();
  68. afx_msg void OnChangeTorusArc();
  69. afx_msg void OnCircle();
  70. afx_msg void OnComputeRadius();
  71. afx_msg void OnUpdateSides();
  72. afx_msg void OnUpdateWallwidth();
  73. virtual BOOL OnInitDialog();
  74. afx_msg void OnPaint();
  75. afx_msg void OnTorusPreview();
  76. //}}AFX_MSG
  77. DECLARE_MESSAGE_MAP()
  78. };
  79. //{{AFX_INSERT_LOCATION}}
  80. // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
  81. #endif // !defined(AFX_TORUSDLG_H__C146AA5D_38FE_11D1_AFC9_0060979D2F4E__INCLUDED_)