|
Hugin trunk 0.1
|
panel for stacker GUI More...
#include <StackerPanel.h>

Classes | |
| struct | FileInfo |
Public Types | |
| typedef std::vector< FileInfo > | FileInfoVector |
Public Member Functions | |
| ~StackerPanel () | |
| destructor, save state and settings | |
| bool | Create (wxWindow *parent, MyExecPanel *logPanel) |
| creates the control and populates all controls with their settings | |
| void | AddFile (const wxString &filename) |
| adds the given file to the list | |
| void | OnProcessFinished (wxCommandEvent &e) |
| call at the end of the enfuse command, to load result back and enable buttons again | |
Protected Member Functions | |
| void | OnAddFiles (wxCommandEvent &e) |
| event handler | |
| void | OnAddDirectory (wxCommandEvent &e) |
| void | OnRemoveFile (wxCommandEvent &e) |
| void | OnFileListChar (wxKeyEvent &e) |
| void | OnFileSelectionChanged (wxCommandEvent &e) |
| void | OnFileCheckStateChanged (wxListEvent &e) |
| void | OnFileColumnHeaderClick (wxListEvent &e) |
| void | OnModeChanged (wxCommandEvent &e) |
| void | OnGeneratePreview (wxCommandEvent &e) |
| void | OnGenerateOutput (wxCommandEvent &e) |
| void | OnZoom (wxCommandEvent &e) |
| void | OnImageLoaded (HuginBase::ImageCache::EntryPtr entry, std::string filename) |
| called when is image is fully loaded to display image in wxStaticBitmap | |
Private Member Functions | |
| void | ExecuteStacker () |
| build the command line and execute enfuse command | |
| void | ExecuteStackerExiftool () |
| build the command line and execute enfuse and exiftool afterwards | |
| wxString | GetStackerOptions () |
| build string with all stacker options from values in wxPropertyGrid this are the mainly the fusion options without the filesnames | |
| wxString | GetStackerCommandLine () |
| get the full commandline for enfuse without program, but with files and output options, the output filename is read from m_outputFilename | |
| void | EnableFileButtons () |
| enable/disable the file(s) remove and create buttons depending on selection of wxListCtrl | |
| long | GetCheckedItemCount () const |
| return the number of check images | |
| void | EnableOutputButtons (bool enable) |
| enable/disable output buttons | |
| void | CleanUpTempFiles () |
| delete all temporary files, to be called mainly at end | |
| void | SortList () |
| sort filename list | |
| void | FillFileList () |
| fill the list from internal file list | |
| void | AddFileInfo (const long fileIndex) |
Private Attributes | |
| wxListCtrl * | m_fileListCtrl { nullptr } |
| wxChoice * | m_modeChoice { nullptr } |
| wxSpinCtrlDouble * | m_winsorTrim { nullptr } |
| wxSpinCtrlDouble * | m_sigma { nullptr } |
| wxSpinCtrl * | m_sigmaMaxIter { nullptr } |
| wxStaticBitmap * | m_smallImagePreview { nullptr } |
| FileInfoVector | m_files |
| PreviewWindow * | m_preview { nullptr } |
| MyExecPanel * | m_logWindow { nullptr } |
| HuginBase::ImageCache::RequestPtr | m_imgRequest |
| std::string | m_selectedImage |
| wxArrayString | m_outputFilenames |
| wxArrayString | m_tempFiles |
| bool | m_cleanupOutput = false |
| long | m_sortCol { -1 } |
| bool | m_sortAscending { true } |
panel for stacker GUI
Definition at line 38 of file StackerPanel.h.
| typedef std::vector<FileInfo> StackerPanel::FileInfoVector |
Definition at line 57 of file StackerPanel.h.
| StackerPanel::~StackerPanel | ( | ) |
destructor, save state and settings
Definition at line 192 of file StackerPanel.cpp.
References CleanUpTempFiles(), m_fileListCtrl, m_modeChoice, m_sigma, m_sigmaMaxIter, m_sortAscending, m_sortCol, m_winsorTrim, and threshold().
adds the given file to the list
Definition at line 296 of file StackerPanel.cpp.
References AddFileInfo(), EnableOutputButtons(), GetCheckedItemCount(), m_files, and threshold().
Referenced by OnAddDirectory(), OnAddFiles(), and StackerDropTarget::OnDropFiles().
Definition at line 858 of file StackerPanel.cpp.
References m_fileListCtrl, m_files, and threshold().
Referenced by AddFile(), and FillFileList().
|
private |
delete all temporary files, to be called mainly at end
Definition at line 838 of file StackerPanel.cpp.
References m_tempFiles, and threshold().
Referenced by OnProcessFinished(), and ~StackerPanel().
| bool StackerPanel::Create | ( | wxWindow * | parent, |
| MyExecPanel * | logPanel | ||
| ) |
creates the control and populates all controls with their settings
Definition at line 212 of file StackerPanel.cpp.
References PreviewWindow::Create(), EnableFileButtons(), EnableOutputButtons(), m_fileListCtrl, m_logWindow, m_modeChoice, m_preview, m_sigma, m_sigmaMaxIter, m_smallImagePreview, m_sortAscending, m_sortCol, m_winsorTrim, OnAddDirectory(), OnAddFiles(), OnFileCheckStateChanged(), OnFileColumnHeaderClick(), OnFileListChar(), OnFileSelectionChanged(), OnGenerateOutput(), OnGeneratePreview(), OnModeChanged(), OnRemoveFile(), OnZoom(), and threshold().
Referenced by ToolboxFrame::ToolboxFrame().
|
private |
enable/disable the file(s) remove and create buttons depending on selection of wxListCtrl
Definition at line 812 of file StackerPanel.cpp.
References m_fileListCtrl, and threshold().
Referenced by Create(), OnFileSelectionChanged(), and OnRemoveFile().
enable/disable output buttons
Definition at line 832 of file StackerPanel.cpp.
References threshold().
Referenced by AddFile(), Create(), ExecuteStacker(), ExecuteStackerExiftool(), OnFileCheckStateChanged(), OnProcessFinished(), and OnRemoveFile().
|
private |
build the command line and execute enfuse command
Definition at line 549 of file StackerPanel.cpp.
References MyExecPanel::AddString(), MyExecPanel::ClearOutput(), EnableOutputButtons(), MyExecPanel::ExecWithRedirect(), HuginQueue::GetInternalProgram(), GetStackerCommandLine(), m_logWindow, threshold(), and HuginQueue::wxEscapeFilename().
Referenced by OnGeneratePreview().
|
private |
build the command line and execute enfuse and exiftool afterwards
Definition at line 562 of file StackerPanel.cpp.
References MyExecPanel::ClearOutput(), EnableOutputButtons(), MyExecPanel::ExecQueue(), HuginQueue::GetExternalProgram(), HuginQueue::GetInternalProgram(), GetStackerCommandLine(), m_fileListCtrl, m_files, m_logWindow, m_outputFilenames, threshold(), and HuginQueue::wxEscapeFilename().
Referenced by OnGenerateOutput().
|
private |
fill the list from internal file list
Definition at line 847 of file StackerPanel.cpp.
References AddFileInfo(), m_fileListCtrl, m_files, SortList(), and threshold().
Referenced by OnRemoveFile().
|
private |
return the number of check images
Definition at line 818 of file StackerPanel.cpp.
References m_fileListCtrl, and threshold().
Referenced by AddFile(), OnFileCheckStateChanged(), and OnRemoveFile().
|
private |
get the full commandline for enfuse without program, but with files and output options, the output filename is read from m_outputFilename
Definition at line 742 of file StackerPanel.cpp.
References HuginQueue::GetConfigTempDir(), GetStackerOptions(), hugin_utils::HuginMessageBox(), m_fileListCtrl, m_files, m_outputFilenames, m_tempFiles, threshold(), and hugin_utils::wxQuoteFilename().
Referenced by ExecuteStacker(), and ExecuteStackerExiftool().
|
private |
build string with all stacker options from values in wxPropertyGrid this are the mainly the fusion options without the filesnames
Definition at line 707 of file StackerPanel.cpp.
References m_sigma, m_sigmaMaxIter, m_winsorTrim, and threshold().
Referenced by GetStackerCommandLine().
|
protected |
Definition at line 370 of file StackerPanel.cpp.
References AddFile(), m_fileListCtrl, SortList(), and threshold().
Referenced by Create().
|
protected |
event handler
Definition at line 312 of file StackerPanel.cpp.
References AddFile(), GetFileDialogImageFilters(), m_fileListCtrl, SortList(), and threshold().
Referenced by Create().
|
protected |
Definition at line 499 of file StackerPanel.cpp.
References EnableOutputButtons(), GetCheckedItemCount(), m_fileListCtrl, and m_files.
Referenced by Create().
|
protected |
Definition at line 506 of file StackerPanel.cpp.
References m_fileListCtrl, m_sortAscending, m_sortCol, SortList(), and threshold().
Referenced by Create().
|
protected |
Definition at line 419 of file StackerPanel.cpp.
References m_fileListCtrl, and threshold().
Referenced by Create().
|
protected |
Definition at line 452 of file StackerPanel.cpp.
References EnableFileButtons(), GeneratePreviewSelectedFile(), HuginBase::ImageCache::getInstance(), HuginBase::ImageCache::getSmallImageIfAvailable(), HUGIN_CONV_FILENAME, m_fileListCtrl, m_files, m_imgRequest, m_selectedImage, m_smallImagePreview, OnImageLoaded(), HuginBase::ImageCache::requestAsyncSmallImage(), and threshold().
Referenced by Create().
|
protected |
Definition at line 590 of file StackerPanel.cpp.
References ExecuteStackerExiftool(), GetMainImageFilters(), m_cleanupOutput, m_files, m_outputFilenames, and threshold().
Referenced by Create().
|
protected |
Definition at line 536 of file StackerPanel.cpp.
References ExecuteStacker(), HuginQueue::GetConfigTempDir(), m_cleanupOutput, m_outputFilenames, and threshold().
Referenced by Create().
|
protected |
called when is image is fully loaded to display image in wxStaticBitmap
Definition at line 489 of file StackerPanel.cpp.
References GeneratePreviewSelectedFile(), m_selectedImage, m_smallImagePreview, and threshold().
Referenced by OnFileSelectionChanged().
|
protected |
Definition at line 523 of file StackerPanel.cpp.
References m_modeChoice, m_sigma, m_sigmaMaxIter, m_winsorTrim, and threshold().
Referenced by Create().
| void StackerPanel::OnProcessFinished | ( | wxCommandEvent & | e | ) |
call at the end of the enfuse command, to load result back and enable buttons again
Definition at line 688 of file StackerPanel.cpp.
References CleanUpTempFiles(), EnableOutputButtons(), m_cleanupOutput, m_outputFilenames, m_preview, PreviewWindow::setImage(), and threshold().
Referenced by ToolboxFrame::OnQueueProgress().
|
protected |
Definition at line 387 of file StackerPanel.cpp.
References EnableFileButtons(), EnableOutputButtons(), FillFileList(), GetCheckedItemCount(), m_fileListCtrl, m_files, and threshold().
Referenced by Create().
|
protected |
Definition at line 654 of file StackerPanel.cpp.
References DEBUG_ERROR, m_preview, and PreviewWindow::setScale().
Referenced by Create().
|
private |
sort filename list
Definition at line 905 of file StackerPanel.cpp.
References m_fileListCtrl, m_files, m_sortAscending, m_sortCol, and threshold().
Referenced by FillFileList(), OnAddDirectory(), OnAddFiles(), and OnFileColumnHeaderClick().
Definition at line 120 of file StackerPanel.h.
Referenced by OnGenerateOutput(), OnGeneratePreview(), and OnProcessFinished().
|
private |
Definition at line 107 of file StackerPanel.h.
Referenced by AddFileInfo(), Create(), EnableFileButtons(), ExecuteStackerExiftool(), FillFileList(), GetCheckedItemCount(), GetStackerCommandLine(), OnAddDirectory(), OnAddFiles(), OnFileCheckStateChanged(), OnFileColumnHeaderClick(), OnFileListChar(), OnFileSelectionChanged(), OnRemoveFile(), SortList(), and ~StackerPanel().
|
private |
Definition at line 113 of file StackerPanel.h.
Referenced by AddFile(), AddFileInfo(), ExecuteStackerExiftool(), FillFileList(), GetStackerCommandLine(), OnFileCheckStateChanged(), OnFileSelectionChanged(), OnGenerateOutput(), OnRemoveFile(), and SortList().
|
private |
Definition at line 116 of file StackerPanel.h.
Referenced by OnFileSelectionChanged().
|
private |
Definition at line 115 of file StackerPanel.h.
Referenced by Create(), ExecuteStacker(), and ExecuteStackerExiftool().
Definition at line 108 of file StackerPanel.h.
Referenced by Create(), OnModeChanged(), and ~StackerPanel().
|
private |
Definition at line 118 of file StackerPanel.h.
Referenced by ExecuteStackerExiftool(), GetStackerCommandLine(), OnGenerateOutput(), OnGeneratePreview(), and OnProcessFinished().
|
private |
Definition at line 114 of file StackerPanel.h.
Referenced by Create(), OnProcessFinished(), and OnZoom().
|
private |
Definition at line 117 of file StackerPanel.h.
Referenced by OnFileSelectionChanged(), and OnImageLoaded().
|
private |
Definition at line 110 of file StackerPanel.h.
Referenced by Create(), GetStackerOptions(), OnModeChanged(), and ~StackerPanel().
|
private |
Definition at line 111 of file StackerPanel.h.
Referenced by Create(), GetStackerOptions(), OnModeChanged(), and ~StackerPanel().
|
private |
Definition at line 112 of file StackerPanel.h.
Referenced by Create(), OnFileSelectionChanged(), and OnImageLoaded().
Definition at line 123 of file StackerPanel.h.
Referenced by Create(), OnFileColumnHeaderClick(), SortList(), and ~StackerPanel().
|
private |
Definition at line 122 of file StackerPanel.h.
Referenced by Create(), OnFileColumnHeaderClick(), SortList(), and ~StackerPanel().
|
private |
Definition at line 119 of file StackerPanel.h.
Referenced by CleanUpTempFiles(), and GetStackerCommandLine().
|
private |
Definition at line 109 of file StackerPanel.h.
Referenced by Create(), GetStackerOptions(), OnModeChanged(), and ~StackerPanel().