Hugintrunk  0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GenerateSequenceDialog.h
Go to the documentation of this file.
1 // -*- c-basic-offset: 4 -*-
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 _GENERATESEQUENCEDIALOG_H
27 #define _GENERATESEQUENCEDIALOG_H
28 
29 #include <vector>
30 #include "panoinc_WX.h"
31 #include "panoinc.h"
32 #include "BatchFrame.h"
33 
34 extern "C"
35 {
36 #include "tiff.h"
37 #include "tiffio.h"
38 }
39 
43 class GenerateSequenceDialog : public wxDialog
44 {
45 public:
47  GenerateSequenceDialog(BatchFrame* batchframe, wxString xrcPrefix, wxString ptoFilename);
51  bool IsValidPanorama() const;
52 
53 protected:
55  void OnSelectBasePath(wxCommandEvent& e);
57  void OnSelectSubDir(wxCommandEvent& e);
59  void OnImageListSelected(wxListEvent& e);
61  void OnUpdateImageTemplate(wxCommandEvent& e);
63  void OnUpdateAllImagesTemplate(wxCommandEvent& e);
65  void OnUpdateCounters(wxSpinEvent& e);
67  void OnGeneratePreview(wxCommandEvent& e);
69  void OnGenerateStitchingPanorama(wxCommandEvent& e);
71  void OnGenerateAssistantPanorama(wxCommandEvent& e);
72 
73 private:
75  void ReadPTOFile();
77  void FillImagesList();
79  void UpdateCounters();
81  void GenerateFileList(wxArrayString& panoSubDirs, std::vector<wxArrayString>& fileList);
83  void DoGeneratePanorama(const Project::Target target);
84 
86  wxString m_filename;
88  bool m_validPTO{ false };
89  wxTextCtrl* m_basepath;
90  wxChoice* m_choiceSubDir;
91  wxTextCtrl* m_subDirTextCtrl;
96  wxArrayString m_orignalFilenames;
97  wxArrayString m_mappedFilenames;
98  wxListCtrl* m_imagesListCtrl;
99  wxStaticText* m_originalImage;
100  wxTextCtrl* m_imageTemplate;
103 
104  DECLARE_EVENT_TABLE()
105 };
106 
107 
108 #endif //_GENERATESEQUENCEDIALOG_H
void OnGenerateAssistantPanorama(wxCommandEvent &e)
generate assistant sequence button
HuginBase::Panorama m_pano
void OnUpdateImageTemplate(wxCommandEvent &e)
update image filename template on selected image
Dialog for generate panoramas from a sequence of images.
void OnGenerateStitchingPanorama(wxCommandEvent &e)
generate stitching sequence button
include file for the hugin project
Model for a panorama.
Definition: Panorama.h:152
void OnSelectBasePath(wxCommandEvent &e)
show select directory dialog
void OnUpdateAllImagesTemplate(wxCommandEvent &e)
update images filename template for all images
void FillImagesList()
fill the images list with current values
void GenerateFileList(wxArrayString &panoSubDirs, std::vector< wxArrayString > &fileList)
generate a list of all panorama and images in panoramas
void OnImageListSelected(wxListEvent &e)
image in list ctrl selected
void OnUpdateCounters(wxSpinEvent &e)
update all spin controls with current numbers
Batch processor for Hugin with GUI.
void DoGeneratePanorama(const Project::Target target)
generates all panoramas and add them to the batch queue with given queue target
void OnSelectSubDir(wxCommandEvent &e)
select which sub-directory should be used
void UpdateCounters()
update all counters, enable/disable end value and calculate end values
include file for the hugin project
~GenerateSequenceDialog()
destructor, saves size and position
void OnGeneratePreview(wxCommandEvent &e)
generate preview
void ReadPTOFile()
read pto template from file
bool IsValidPanorama() const
return true if given template is a valid pto file, if not the dialog should not be used ...
GenerateSequenceDialog(BatchFrame *batchframe, wxString xrcPrefix, wxString ptoFilename)
Constructor, read from xrc ressource; restore last uses settings, size and position.