1 #ifndef _BG_BITMAP_DLG_H
2 #define _BG_BITMAP_DLG_H
3 /*
4  * Copyright (C) Volition, Inc. 1999.  All rights reserved.
5  *
6  * All source code herein is the property of Volition, Inc. You may not sell
7  * or otherwise commercially exploit the source or things you created based on the
8  * source.
9  *
10 */
11 
12 #include "resource.h"
13 
14 #include "../code/nebula/neb.h"
15 
16 /////////////////////////////////////////////////////////////////////////////
17 // bg_bitmap_dlg dialog
18 
19 class bg_bitmap_dlg : public CDialog
20 {
21 // Construction
22 public:
23 	void update_data(int update = 1);
24 	void create();
25 
26 	// sun data functions
27 	void sun_data_init();
28 	void sun_data_close();
29 	void sun_data_save_current();
30 
31 	// bitmap data functions
32 	void bitmap_data_init();
33 	void bitmap_data_close();
34 	void bitmap_data_save_current();
35 
36 	void get_data_spinner(NM_UPDOWN* pUD, int id, int *var, int min, int max);
37 	void get_data_int(int id, int *var, int min, int max);
38 	void get_data_float(int id, float *var, float max, float min);
39 
40 	afx_msg void OnClose();
41 
42 	bg_bitmap_dlg(CWnd* pParent = NULL);   // standard constructor
43 
44 // Dialog Data
45 	//{{AFX_DATA(bg_bitmap_dlg)
46 	enum { IDD = IDD_BG_BITMAP };
47 	CSliderCtrl	m_amb_blue;
48 	CSliderCtrl	m_amb_green;
49 	CSliderCtrl	m_amb_red;
50 	CString	m_neb_intensity;
51 	int		m_nebula_color;
52 	int		m_nebula_index;
53 	int		m_bank;
54 	int		m_heading;
55 	int		m_pitch;
56 	CSliderCtrl			m_slider;
57 	int		m_neb2_texture;
58 	BOOL		m_subspace;
59 	BOOL		m_fullneb;
60 	int		m_poofs[MAX_NEB2_POOFS];
61 	BOOL	m_toggle_trails;
62 	CString	m_storm_name;
63 	CString s_name;
64 	int s_pitch;
65 	int s_bank;
66 	int s_heading;
67 	float s_scale;
68 	int s_index;
69 	CString b_name;
70 	int b_pitch;
71 	int b_bank;
72 	int b_heading;
73 	float b_scale_x;
74 	float b_scale_y;
75 	int b_div_x;
76 	int b_div_y;
77 	int b_index;
78 	int m_sky_flag_1;
79 	int m_sky_flag_2;
80 	int m_sky_flag_3;
81 	int m_sky_flag_4;
82 	int m_sky_flag_5;
83 	int m_sky_flag_6;
84 	CString m_skybox_model;
85 	CString m_envmap;
86 	int m_skybox_pitch;
87 	int m_skybox_bank;
88 	int m_skybox_heading;
89 	float m_neb_near_multi;
90 	float m_neb_far_multi;
91 	//}}AFX_DATA
92 
93 // Overrides
94 	// ClassWizard generated virtual function overrides
95 	//{{AFX_VIRTUAL(bg_bitmap_dlg)
96 	protected:
97 	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
98 	//}}AFX_VIRTUAL
99 
100 // Implementation
101 protected:
102 	// clear and build the nebula filename list appropriately
103 	void build_nebfile_list();
104 
105 	int get_active_background();
106 	int get_swap_background();
107 	void reinitialize_lists();
108 
109 	void OnOrientationChange();
110 
111 	// Generated message map functions
112 	//{{AFX_MSG(bg_bitmap_dlg)
113 	afx_msg void OnCancel();
114 	afx_msg void OnOK();
115 	afx_msg void OnSelchangeNebcolor();
116 	afx_msg void OnSelchangeNebpattern();
117 	afx_msg void OnFullNeb();
118 	afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
119 	afx_msg void OnSunChange();
120 	afx_msg void OnAddSun();
121 	afx_msg void OnDelSun();
122 	afx_msg void OnSunDropdownChange();
123 	afx_msg void OnBitmapChange();
124 	afx_msg void OnAddBitmap();
125 	afx_msg void OnDelBitmap();
126 	afx_msg void OnBitmapDropdownChange();
127 	afx_msg void OnDeltaposSbitmapPSpin(NMHDR* pNMHDR, LRESULT* pResult);
128 	afx_msg void OnDeltaposSbitmapBSpin(NMHDR* pNMHDR, LRESULT* pResult);
129 	afx_msg void OnDeltaposSbitmapHSpin(NMHDR* pNMHDR, LRESULT* pResult);
130 	afx_msg void OnKillfocusSbitmapScaleX();
131 	afx_msg void OnKillfocusSbitmapScaleY();
132 	afx_msg void OnKillfocusSbitmapDivX();
133 	afx_msg void OnKillfocusSbitmapDivY();
134 	afx_msg void OnKillfocusSbitmapP();
135 	afx_msg void OnKillfocusSbitmapB();
136 	afx_msg void OnKillfocusSbitmapH();
137 	afx_msg void OnDeltaposSun1PSpin(NMHDR* pNMHDR, LRESULT* pResult);
138 	afx_msg void OnDeltaposSun1HSpin(NMHDR* pNMHDR, LRESULT* pResult);
139 	afx_msg void OnDeltaposSun1BSpin(NMHDR* pNMHDR, LRESULT* pResult);
140 	afx_msg void OnKillfocusSun1P();
141 	afx_msg void OnKillfocusSun1H();
142 	afx_msg void OnKillfocusSun1B();
143 	afx_msg void OnKillfocusSun1Scale();
144 	afx_msg void OnAddBackground();
145 	afx_msg void OnRemoveBackground();
146 	afx_msg void OnImportBackground();
147 	afx_msg void OnSwapBackground();
148 	afx_msg void OnBackgroundDropdownChange();
149 	afx_msg void OnSkyboxBrowse();
150 	afx_msg void OnDeltaposSkyboxPSpin(NMHDR* pNMHDR, LRESULT* pResult);
151 	afx_msg void OnDeltaposSkyboxBSpin(NMHDR* pNMHDR, LRESULT* pResult);
152 	afx_msg void OnDeltaposSkyboxHSpin(NMHDR* pNMHDR, LRESULT* pResult);
153 	afx_msg void OnKillfocusSkyboxP();
154 	afx_msg void OnKillfocusSkyboxB();
155 	afx_msg void OnKillfocusSkyboxH();
156 	afx_msg void OnEnvmapBrowse();
157 	//}}AFX_MSG
158 	DECLARE_MESSAGE_MAP()
159 
160 private:
161 };
162 
163 #endif
164