1 // -*- c-basic-offset: 4 -*- 2 /** @file PanoOutputDialog.h 3 * 4 * @brief Definition of PanoOutputDialog class 5 * 6 * @author T. Modes 7 * 8 */ 9 10 /* This is free software; you can redistribute it and/or 11 * modify it under the terms of the GNU General Public 12 * License as published by the Free Software Foundation; either 13 * version 2 of the License, or (at your option) any later version. 14 * 15 * This software is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 18 * Lesser General Public License for more details. 19 * 20 * You should have received a copy of the GNU General Public 21 * License along with this software. If not, see 22 * <http://www.gnu.org/licenses/>. 23 * 24 */ 25 26 #ifndef _PANOOUTPUTDIALOG_H 27 #define _PANOOUTPUTDIALOG_H 28 29 #include "panoinc_WX.h" 30 #include "panoinc.h" 31 #include "GuiLevel.h" 32 33 /** Dialog for setting output parameters for simple user interface */ 34 class PanoOutputDialog : public wxDialog 35 { 36 public: 37 /** Constructor, read from xrc ressource; restore last uses settings, size and position */ 38 PanoOutputDialog(wxWindow *parent, HuginBase::Panorama& pano, GuiLevel guiLevel); 39 /** destructor, save position */ 40 ~PanoOutputDialog(); GetNewPanoramaOptions()41 HuginBase::PanoramaOptions GetNewPanoramaOptions() {return m_newOpt; } ; 42 protected: 43 /** Saves current state of all checkboxes when closing dialog with Ok */ 44 void OnOk(wxCommandEvent & e); 45 /** enabled Ok button and LDR/HDR format settings depeding on selected output settings */ 46 void OnOutputChanged(wxCommandEvent & e); 47 /** LDR format changed */ 48 void OnLDRFormatChanged(wxCommandEvent & e); 49 /** HDR format changed */ 50 void OnHDRFormatChanged(wxCommandEvent & e); 51 /** width changed */ 52 void OnWidthChanged(wxSpinEvent & e); 53 /** height changed */ 54 void OnHeightChanged(wxSpinEvent & e); 55 56 private: 57 void EnableOutputOptions(); 58 59 HuginBase::PanoramaOptions m_newOpt; 60 HuginBase::Panorama& m_pano; 61 double m_initalWidth; 62 double m_initalROIWidth; 63 double m_aspect; 64 GuiLevel m_guiLevel; 65 66 wxSpinCtrl* m_edit_width; 67 wxSpinCtrl* m_edit_height; 68 69 std::vector<HuginBase::UIntSet> m_stacks; 70 std::vector<HuginBase::UIntSet> m_exposureLayers; 71 72 DECLARE_EVENT_TABLE() 73 }; 74 75 #endif //_PANOOUTPUTDIALOG_H 76