home *** CD-ROM | disk | FTP | other *** search
- /*
- Company: Sensaura Ltd
- Copyright: (C) 2000
-
- File Name: buffrdlg.h
- File Description: Header file for declaration of BufferDlg class which creates a
- DirectSound3D buffer with ZoomFX support controlled by a dialog box
- interface
- Author: Adam Philp
- Last Update: 04-JAN-00
-
- Target Compiler: Microsoft Visual C++ Version 5.0
- */
-
- #ifndef __buffrdlg_h // Sentry, use file only if it's not already included
- #define __buffrdlg_h
-
- /////////////////////// Included files ////////////////////////////////////////////////////////////
-
- #include "applicat.h"
- #include "buffer.h"
-
- /////////////////////// Class definition //////////////////////////////////////////////////////////
-
- /*
- Class: BufferDlg
- Description: Dialog class for a DirectSound3D buffer
- */
-
- class BufferDlg : public Buffer
- {
- friend BOOL CALLBACK BufferDlgProc(HWND, UINT, WPARAM, LPARAM);
-
- public: // Public constructor and destructor
- BufferDlg();
- ~BufferDlg();
-
- public: // Public data members
- HWND m_hWnd;
-
- public: // Public member functions
- bool Create(Application*, const char*, LPDIRECTSOUND);
- virtual void Destroy();
- bool Update();
-
- protected: // Protected member functions
- BOOL OnInitDialog(HWND, WPARAM, LPARAM);
- BOOL OnCommand(WPARAM, LPARAM);
- BOOL OnHScroll(WORD, LONG, HWND);
- void OnDestroy();
-
- BOOL InitControlRanges(LPDIRECTSOUND);
- bool InitControls();
- void EnableZoomFXControls();
-
- bool UpdateFrequency();
- bool UpdateVolume();
- bool RestoreDefaults();
- bool EnableZoomFX(bool);
- bool UpdateMode(WORD);
- bool UpdateMinDistance();
- bool UpdateMaxDistance();
- bool UpdatePosition();
- bool UpdateVelocity();
- bool UpdateInnerConeAngle();
- bool UpdateOuterConeAngle();
- bool UpdateOuterVolume();
- bool UpdateZoomFXExtent();
- bool UpdateZoomFXExtentSymmetrical(bool);
- void UpdateZoomFXOrientation();
- bool CommitZoomFXOrientation();
-
- void UpdateDistanceStatics(D3DVALUE, D3DVALUE);
- void UpdatePositionStatics(LPD3DVECTOR);
- void UpdateVelocityStatics(LPD3DVECTOR);
- void UpdateConeAngleStatics(DWORD, DWORD);
-
- protected: // Protected data members
- MainWnd* m_pParent;
- bool m_bZoomFXEnabled;
- bool m_bZoomFXSymmetrical;
- ZOOMFX_BOX m_Extent;
- ZOOMFX_ORIENTATION m_Orientation;
-
- HWND m_hPlayBtn, m_hLoopedBtn;
- HWND m_hDefaultBtn, m_hEnableZoomFXBtn;
- HWND m_hFormatStatic, m_hPlayCursorStatic, m_hWriteCursorStatic;
- HWND m_hFrequencySlider, m_hVolumeSlider;
- HWND m_hFrequencyStatic, m_hVolumeStatic;
- HWND m_hNormalBtn, m_hHeadRelativeBtn, m_hDisabledBtn;
- HWND m_hMinDistanceSlider, m_hMaxDistanceSlider;
- HWND m_hMinDistanceStatic, m_hMaxDistanceStatic;
- HWND m_hPositionXSlider, m_hPositionYSlider, m_hPositionZSlider;
- HWND m_hPositionXStatic, m_hPositionYStatic, m_hPositionZStatic;
- HWND m_hVelocityXSlider, m_hVelocityYSlider, m_hVelocityZSlider;
- HWND m_hVelocityXStatic, m_hVelocityYStatic, m_hVelocityZStatic;
- HWND m_hInnerConeAngleSlider, m_hOuterConeAngleSlider;
- HWND m_hInnerConeAngleStatic, m_hOuterConeAngleStatic;
- HWND m_hOuterVolumeSlider, m_hOuterVolumeStatic;
- HWND m_hZoomFXMaxXSlider, m_hZoomFXMaxYSlider, m_hZoomFXMaxZSlider;
- HWND m_hZoomFXMaxXStatic, m_hZoomFXMaxYStatic, m_hZoomFXMaxZStatic;
- HWND m_hZoomFXMinXSlider, m_hZoomFXMinYSlider, m_hZoomFXMinZSlider;
- HWND m_hZoomFXMinXStatic, m_hZoomFXMinYStatic, m_hZoomFXMinZStatic;
- HWND m_hZoomFXSymmetricalBtn;
- HWND m_hZoomFXFrontXSlider, m_hZoomFXFrontYSlider, m_hZoomFXFrontZSlider;
- HWND m_hZoomFXFrontXStatic, m_hZoomFXFrontYStatic, m_hZoomFXFrontZStatic;
- HWND m_hZoomFXTopXSlider, m_hZoomFXTopYSlider, m_hZoomFXTopZSlider;
- HWND m_hZoomFXTopXStatic, m_hZoomFXTopYStatic, m_hZoomFXTopZStatic;
- HWND m_hZoomFXCommitOrientationBtn;
- };
-
- #endif // End of sentry __buffrdlg_h