OptionsDialog.h 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. /*
  2. ** Command & Conquer Renegade(tm)
  3. ** Copyright 2025 Electronic Arts Inc.
  4. **
  5. ** This program is free software: you can redistribute it and/or modify
  6. ** it under the terms of the GNU General Public License as published by
  7. ** the Free Software Foundation, either version 3 of the License, or
  8. ** (at your option) any later version.
  9. **
  10. ** This program is distributed in the hope that it will be useful,
  11. ** but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. ** GNU General Public License for more details.
  14. **
  15. ** You should have received a copy of the GNU General Public License
  16. ** along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. */
  18. /***********************************************************************************************
  19. *** Confidential - Westwood Studios ***
  20. ***********************************************************************************************
  21. * *
  22. * Project Name : LightMap *
  23. * *
  24. * $Archive:: /Commando/Code/Tool $*
  25. * *
  26. * $Author:: Ian_l $*
  27. * *
  28. * $Modtime:: 9/08/00 6:44p $*
  29. * *
  30. * $Revision:: 8 $*
  31. * *
  32. *---------------------------------------------------------------------------------------------*
  33. * Functions: *
  34. * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
  35. #if !defined(AFX_OPTIONSDIALOG_H__23794761_9166_11D3_A321_009027447394__INCLUDED_)
  36. #define AFX_OPTIONSDIALOG_H__23794761_9166_11D3_A321_009027447394__INCLUDED_
  37. #if _MSC_VER > 1000
  38. #pragma once
  39. #endif // _MSC_VER > 1000
  40. // Includes.
  41. #include "w3d_file.h"
  42. class OptionsDialog : public CDialog
  43. {
  44. // Construction
  45. public:
  46. OptionsDialog (CWnd *parent = NULL);
  47. float Get_Spatial_Tolerance() {return (SpatialTolerance * 0.0001f);} // x 0.0001 metres.
  48. unsigned Get_Smoothing_Angle() {return (SmoothingAngle);}
  49. unsigned Get_Filter_Sharpness() {return (FilterSharpness);}
  50. W3dRGBStruct Get_Fill_Color() {return (FillColor);}
  51. float Get_Sample_Rate() {return (SampleRate / 10.0f);}
  52. unsigned Get_Filter_Error() {return (FilterError);}
  53. unsigned Get_Bit_Depth() {return (BitDepth);}
  54. bool Get_Light_Export_Selective() {return (LightExportSelective);}
  55. const char *Get_Light_Exclusion_String() {return (LPCTSTR (LightExclusionString));}
  56. // Dialog Data
  57. //{{AFX_DATA(OptionsDialog)
  58. enum { IDD = IDD_OPTIONS };
  59. // NOTE: the ClassWizard will add data members here
  60. //}}AFX_DATA
  61. // Overrides
  62. // ClassWizard generated virtual function overrides
  63. //{{AFX_VIRTUAL(OptionsDialog)
  64. public:
  65. virtual int DoModal();
  66. protected:
  67. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  68. //}}AFX_VIRTUAL
  69. // Implementation
  70. protected:
  71. // Generated message map functions
  72. //{{AFX_MSG(OptionsDialog)
  73. virtual BOOL OnInitDialog();
  74. afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
  75. afx_msg void OnChangeSpatialTolerance();
  76. afx_msg void OnUpdateSpatialTolerance();
  77. afx_msg void OnChangeFillColorRed();
  78. afx_msg void OnChangeFillColorGreen();
  79. afx_msg void OnChangeFillColorBlue();
  80. afx_msg void OnUpdateFillColorRed();
  81. afx_msg void OnUpdateFillColorGreen();
  82. afx_msg void OnUpdateFillColorBlue();
  83. afx_msg void On16BitsPerPixel();
  84. afx_msg void On24BitsPerPixel();
  85. afx_msg void OnVScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
  86. afx_msg void OnLightExportSelective();
  87. afx_msg void OnChangeLightExclusionString();
  88. //}}AFX_MSG
  89. DECLARE_MESSAGE_MAP()
  90. private:
  91. void Initialize_Slider (int sliderid, int start, int end, int value);
  92. void Initialize_Spinner (int spinnerid, int start, int end, int value);
  93. void Set_Text (int textid, const char *controlstring, int value);
  94. void Set_Text (int textid, const char *controlstring, float value);
  95. unsigned SpatialTolerance; // Vertex smoothing spatial tolerance.
  96. unsigned SmoothingAngle; // Vertex smoothing angle (in degrees).
  97. unsigned FilterSharpness; // Filter sharpness (or tightness).
  98. unsigned BitDepth; // Lightmap bit depth (pixel format).
  99. W3dRGBStruct FillColor; // Color used to pad unused texels in lightmaps.
  100. unsigned SampleRate;
  101. unsigned FilterError; // Scale lightmaps to maximum filter error.
  102. bool LightExportSelective;
  103. CString LightExclusionString;
  104. };
  105. //{{AFX_INSERT_LOCATION}}
  106. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  107. #endif // !defined(AFX_OPTIONSDIALOG_H__23794761_9166_11D3_A321_009027447394__INCLUDED_)