27#include "hugin_config.h"
30#include <wx/stdpaths.h>
31#include <wx/wfstream.h>
39#include "vigra/imageinfo.hxx"
105#if defined(__WXMSW__) || defined(__WXMAC__)
107#elif defined(__WXGTK20__)
123 if (!
mf)
return false;
125 if (!m_imageOnly &&
filenames.GetCount() == 1) {
127 if (file.GetExt().CmpNoCase(
"pto") == 0 ||
128 file.GetExt().CmpNoCase(
"ptp") == 0 ||
129 file.GetExt().CmpNoCase(
"pts") == 0 )
134 mf->LoadProjectFile(file.GetFullPath());
143 std::vector<std::string>
filesv;
188 if(pano.getNrOfCtrlPoints()>0)
194 std::vector<PanoCommand::PanoCommand*>
cmds;
207 message->SetOKLabel(
_(
"Convert anyway."));
215 if (
dlg.CheckRawFiles())
235 : cp_frame(0), pano(pano)
244 wxXmlResource::Get()->LoadDialog(&
dlg,
NULL,
"disable_opengl_dlg");
245 long noOpenGL=wxConfigBase::Get()->Read(
"DisableOpenGL", 0l);
254 wxConfigBase::Get()->Write(
"DisableOpenGL", 1l);
258 wxConfigBase::Get()->Write(
"DisableOpenGL", 0l);
264 wxConfigBase::Get()->Write(
"DisableOpenGL", 0l);
269 long noOpenGL=wxConfigBase::Get()->Read(
"DisableOpenGL", 0l);
282 dc.SelectObject(bitmap);
296 dc.DrawText(
version, bitmap.GetWidth() -
tw - 3, bitmap.GetHeight() -
th - 3);
313 wxXmlResource::Get()->LoadFrame(
this,
parent,
"main_frame");
318 wxApp::s_macAboutMenuItemId =
XRCID(
"action_show_about");
319 wxApp::s_macPreferencesMenuItemId =
XRCID(
"action_show_prefs");
320 wxApp::s_macExitMenuItemId =
XRCID(
"action_exit_hugin");
321 wxApp::s_macHelpMenuTitleName =
_(
"&Help");
349 if (
item.IsAPIValid())
358 for (PluginItems::const_iterator
it =
items.begin();
it !=
items.end(); ++
it)
460 if (!files.IsEmpty())
469 for (
auto file : files)
490 help = wxString::Format(
_(
"User defined sequence: %s"), file);
527 if (!files.IsEmpty())
536 for (
auto file : files)
557 help = wxString::Format(
_(
"User defined assistant: %s"), file);
614#if defined __WXMAC__ || defined __WXMSW__
623 ImageCache::getInstance().setProgressDisplay(
this);
676 for (
int i = 0;
i < 9; ++
i)
692 Bind(
wxEVT_MENU, &MainFrame::OnPythonScript,
this,
XRCID(
"action_python_script"));
742 ImageCache::getInstance().setProgressDisplay(
NULL);
743 delete & ImageCache::getInstance();
855 messageString =
_(
"Save changes to the project file before opening another project?");
858 messageString =
_(
"Save changes to the project file before starting a new project?");
862 messageString =
_(
"Save changes to the project file before closing?");
869 message->SetExtendedMessage(
_(
"If you load another project without saving, your changes since last save will be discarded."));
872 message->SetExtendedMessage(
_(
"If you start a new project without saving, your changes since last save will be discarded."));
876 message->SetExtendedMessage(
_(
"If you close without saving, your changes since your last save will be discarded."));
879 #if defined __WXMAC__ || defined __WXMSW__
891 wxCommandEvent
dummy;
945 ImageCache::getInstance().flush();
960 DEBUG_DEBUG(
"stripping " << path <<
" from image filenames");
980 }
catch (std::exception & e) {
1001 _(
"Save project file"),
1003 _(
"Project files (*.pto)|*.pto|All files (*)|*"),
1006 wxConfig::Get()->Write(
"/actualPath",
dlg.GetDirectory());
1008 if (
fn.Right(4).CmpNoCase(
".pto")!=0)
1011 if (wxFile::Exists(
fn)) {
1034 _(
"Save PTmender script file"),
1036 _(
"PTmender files (*.txt)|*.txt"),
1103 SetTitle(
fname.GetName() +
"." +
fname.GetExt() +
" - " +
_(
"Hugin - Panorama Stitcher"));
1120 SetTitle(
_(
"Hugin - Panorama Stitcher"));
1123 if (! (
fname.GetExt() ==
"pto")) {
1131 config->Write(
"/actualPath", path);
1139 wxCommandEvent
dummy;
1149void MainFrame::MacOnOpenFile(
const wxString & filename)
1153 ImageCache::getInstance().flush();
1169 _(
"Open project file"),
1171 _(
"Project files (*.pto)|*.pto|All files (*)|*"),
1179 if (
hugin_utils::HuginMessageBox(wxString::Format(
_(
"File %s is an image file and not a project file.\nThis file can't be open with File, Open.\nDo you want to add this image file to the current project?"), filename.c_str()),
1191 ImageCache::getInstance().flush();
1209 ImageCache::getInstance().flush();
1219 config->Write(
"/actualPath",
dialog.GetSelectedPath());
1232 ImageCache::getInstance().flush();
1243 SetTitle(
_(
"Hugin - Panorama Stitcher"));
1246 wxCommandEvent
dummy;
1284 std::vector<std::string>
filesv;
1314 if(e.GetId()==
XRCID(
"ID_SHOW_PANEL_MASK"))
1317 if(e.GetId()==
XRCID(
"ID_SHOW_PANEL_CP_EDITOR"))
1320 if(e.GetId()==
XRCID(
"ID_SHOW_PANEL_OPTIMIZER"))
1323 if(e.GetId()==
XRCID(
"ID_SHOW_PANEL_OPTIMIZER_PHOTOMETRIC"))
1335 if(e.GetId()==
XRCID(
"ID_SHOW_PANEL_PANORAMA"))
1363 hugin_utils::HuginMessageBox(wxString::Format(
_(
"Could not load image \"%s\".\nThis file is not a valid image.\nThis file will be removed from the project."), e.GetString()),
1369 hugin_utils::HuginMessageBox(wxString::Format(
_(
"Could not load image \"%s\".\nThis file was renamed, deleted or is on a non-accessible drive.\nThis file will be removed from the project."), e.GetString()),
1508 wxCommandEvent
dummy;
1518#if defined __WXMSW__ || defined __WXMAC__
1525#if defined __WXMSW__
1532#elif defined __WXGTK__
1561 wxCommandEvent
dummy;
1616 wxCommandEvent
dummy;
1653 _(
"Open project file"),
1655 _(
"Project files (*.pto)|*.pto|All files (*)|*"),
1680 wxCommandEvent
dummy;
1701 wxConfigBase::Get()->Write(
"/actualPath",
dlg.GetDirectory());
1712 _(
"Choose template project"),
1714 _(
"Project files (*.pto)|*.pto|All files (*)|*"),
1716 dlg.SetDirectory(wxConfigBase::Get()->Read(
"/templatePath",
wxEmptyString));
1719 wxConfig::Get()->Write(
"/templatePath",
dlg.GetDirectory());
1731#if defined __WXMAC__ && defined MAC_SELF_CONTAINED_BUNDLE
1742 CFSTR(
"net.sourceforge.hugin.PTBatcherGUI"),
1750 wxExecute(
_T(
"open -b net.sourceforge.hugin.PTBatcherGUI"));
1753 wxExecute(
_T(
"open -b net.sourceforge.hugin.PTBatcherGUI"));
1770 for (
unsigned int i=0;
i < cps.size();
i++) {
1775 unsigned int nGood=0;
1776 unsigned int nBad=0;
1802 if (!
progress.updateDisplayValue())
1834 if (res.
maxi >= corrThresh) {
1837 cps[*
it].error = res.
maxi;
1846 cps[*
it].error = res.
maxi;
1852 cps[*
it].error = 1.0;
1854 unsigned int rm = *
it;
1865 result.Printf(
_(
"%d points fine-tuned, %d points not updated due to low correlation\n\nHint: The errors of the fine-tuned points have been set to the correlation coefficient\nProblematic points can be spotted (just after fine-tune, before optimizing)\nby an error <= %.3f.\nThe error of points without a well defined peak (typically in regions with uniform color)\nwill be set to 0\n\nUse the Control Point list (F3) to see all points of the current project\n"),
1890void MainFrame::OnPythonScript(wxCommandEvent & e)
1894 _(
"Select python script"),
1896 _(
"Python script (*.py)|*.py|All files (*.*)|*.*"),
1898 dlg.SetDirectory(wxConfigBase::Get()->Read(
"/pythonScriptPath",
wxEmptyString));
1903 wxConfig::Get()->Write(
"/pythonScriptPath",
dlg.GetDirectory());
1911void MainFrame::OnPlugin(wxCommandEvent & e)
1914 if(file.FileExists())
2060 " client: "<<
csz.x <<
"," <<
csz.y <<
2061 " virtual: "<<
vsz.x <<
"," <<
vsz.y);
2127 if (
fn.FileExists())
2133 ImageCache::getInstance().flush();
2256 wxCommandEvent
dummy;
2282 SetTitle(
_(
"Hugin - Panorama Stitcher"));
2307 hugin_utils::HuginMessageBox(
_(
"Can't switch to simple interface. The project is using stacks and/or vignetting center shift.\nThese features are not supported in simple interface."),
2312 hugin_utils::HuginMessageBox(
_(
"Can't switch to simple interface. The project is using translation or shear parameters.\nThese parameters are not supported in simple interface."),
2328 hugin_utils::HuginMessageBox(
_(
"Can't switch to advanced interface. The project is using translation or shear parameters.\nThese parameters are not supported in advanced interface."),
2352 if(
tempDir.Last()!=wxFileName::GetPathSeparator())
2354 tempDir.Append(wxFileName::GetPathSeparator());
2371 std::stringstream
errors;
2373 if (commands->empty())
2413 hugin_utils::HuginMessageBox(
_(
"The assistant could not find vertical lines. Please add vertical lines in the panorama editor and optimize project manually."),
2421 if (
comps.size() > 1)
2424 unsigned i1 = *(
comps[0].rbegin());
2425 unsigned i2 = *(
comps[1].begin());
2429 +
_(
"Please create control points between unconnected images using the Control Points tab in the panorama editor.\n\nAfter adding the points, press the \"Align\" button again"),
_(
"Error"),
wxOK,
mainWin);
2464 wxCommandEvent
dummy;
2469#if defined __WXMAC__ && defined MAC_SELF_CONTAINED_BUNDLE
2480 CFSTR(
"net.sourceforge.hugin.PTBatcherGUI"),
Definition of dialog for numeric transforms.
create a CommandQueue for running the assistant using CLI tools
Definition of dialog to browse directory with pto files.
vigra_ext::CorrelationResult PointFineTuneProjectionAware(const HuginBase::SrcPanoImage &templ, const vigra::UInt8RGBImage &templImg, vigra::Diff2D templPos, int templSize, const HuginBase::SrcPanoImage &search, const vigra::UInt8RGBImage &searchImg, vigra::Diff2D searchPos, int sWidth)
function for fine-tune with remapping to stereographic projection
algorithms for remove control points by statistic method
GuiLevel GetMinimumGuiLevel(HuginBase::PanoramaData &pano)
returns the requiered GuiLevel for the given panorama to work correctly
int MyExecuteCommandQueue(HuginQueue::CommandQueue *queue, wxWindow *parent, const wxString &title, const wxString &comment)
execute all commands in queue with redirection of output to frame and allow canceling the queue will ...
void registerPTWXDlgFcn()
void deregisterPTWXDlgFcn()
Definition of PanoOperation class.
read settings from papywizard xml file
bool comparePluginItem(PluginItem item1, PluginItem item2)
compares 2 plugin with category and name
Reading python plugins metadata.
std::list< PluginItem > PluginItems
Definition of dialog and functions to import RAW images to project file.
Dialog for browsing pto files.
class, which stores all settings of one cp detector
control point editor panel.
void setRightImage(unsigned int imgNr)
set right image
void Init(HuginBase::Panorama *pano)
void setLeftImage(unsigned int imgNr)
set left image
void ShowControlPoint(unsigned int cpNr)
show a control point
The OpenGL preview frame.
void InitPreviews()
init previews
void OnShowEvent(wxShowEvent &e)
void SetGuiLevel(GuiLevel newLevel)
sets the gui level
void LoadOpenGLLayout()
loads the layout of the OpenGL windows and restores it
void StorePositionAndSize()
store position and size of window in wxConfig
void AddUserDefinedSequence(int id, const wxString &desc, const wxString &help)
adds the given user defined output sequence to SplitButton menu
void AddUserDefinedAssistant(int id, const wxString &desc, const wxString &help)
adds the given user defined assistant to SplitButton menu
void ResetPreviewZoom()
reset zoom level for preview window
void SetShowProjectionHints(bool new_value)
set status if projection hints should be shown or not
This is a cache for all the images we use.
static ImageCache & getInstance()
get the global ImageCache object
void flush()
release all images in the cache.
Memento class for a Panorama object.
bool loadPTScript(std::istream &i, int &ptoVersion, const std::string &prefix="")
load a Hugin file
void changeFinished(bool keepDirty)
notify observers about changes in this class
const SrcPanoImage & getImage(std::size_t nr) const
get a panorama image, counting starts with 0
const PanoramaOptions & getOptions() const
returns the options for this panorama
virtual void clearDirty()
clear dirty flag.
bool isDirty() const
true if there are unsaved changes
void setMemento(const PanoramaMemento &memento)
set the internal state
void addObserver(PanoramaObserver *o)
add a panorama observer.
const int getPhotometricOptimizerSwitch() const
return the photometric optimizer master switch
const CPVector & getCtrlPoints() const
get all control point of this Panorama
bool removeObserver(PanoramaObserver *observer)
remove a panorama observer.
const OptimizeVector & getOptimizeVector() const
return the optimize settings stored inside panorama
bool WritePTOFile(const std::string &filename, const std::string &prefix="")
write data to given pto file
void printStitcherScript(std::ostream &o, const PanoramaOptions &target, const UIntSet &imgs) const
create the stitcher script
const int getOptimizerSwitch() const
returns optimizer master switch
std::size_t getNrOfImages() const
number of images.
class to work with images graphs created from a HuginBase::Panorama class it creates a graph based on...
std::vector< HuginBase::UIntSet > Components
stores the components of the graph
class for showing splash screen the class wxSplashScreen from wxWidgets does not work correctly for o...
HuginSplashScreen(wxWindow *parent, wxBitmap bitmap)
wxString GetCurrentOptimizerString()
return the currently selected optimizer setting as string from the drop down list box
void RunCPGenerator(CPDetectorSetting &setting, const HuginBase::UIntSet &img)
run the cp generator with the given setting on selected images
void SetGuiLevel(GuiLevel newGuiLevel)
sets the GuiLevel for all controls on this panel
void ReloadCPDetectorSettings()
Reloads the cp detector settings from config, necessary after edit preferences.
const wxString GetSelectedCPGenerator()
return the currently selected cp generator description
void Init(HuginBase::Panorama *pano)
CPDetectorSetting & GetDefaultSetting()
returns the default cp detector settings
A tip file provider that uses gettext to translate the tips.
void OnTogglePreviewFrame(wxCommandEvent &e)
void ShowCtrlPoint(unsigned int cpNr)
void OnFAQ(wxCommandEvent &e)
void OnLoadingFailed(wxCommandEvent &e)
event handler called when loading of image file failed
void OnMRUFiles(wxCommandEvent &e)
event handler for recently used files
static MainFrame * Get()
hack.. kind of a pseudo singleton...
void OnSaveProject(wxCommandEvent &e)
virtual ~MainFrame()
dtor.
void AddImages(wxArrayString &filenameArray)
adds the given files to the projects, with checking for invalid filenames
void SetGuiLevel(GuiLevel newLevel)
bool m_optOnlyActiveImages
bool m_show_opt_photo_panel
void updateProgressDisplay()
receive notification about progress.
void OnShowPrefs(wxCommandEvent &e)
void LoadProjectFile(const wxString &filename)
void OnTipOfDay(wxCommandEvent &e)
void OnDoStitch(wxCommandEvent &e)
void OnRunAssistantUserdefined(wxCommandEvent &e)
void OnShowCPFrame(wxCommandEvent &e)
std::map< int, wxString > m_userOutput
void DisableOpenGLTools()
disables all OpenGL related menu items and toobar buttons
void ShowCtrlPointEditor(unsigned int img1, unsigned int img2)
opens the control points tab with the both images selected
void OnKeyboardHelp(wxCommandEvent &e)
GLPreviewFrame * gl_preview_frame
const wxString & GetXRCPath()
get the path to the xrc directory
HuginBase::Panorama & pano
void OnPhotometricOptimize(wxCommandEvent &e)
void OnOpenPTBatcher(wxCommandEvent &e)
void OnSendToAssistantQueue(wxCommandEvent &e)
PreviewFrame * preview_frame
void OnAbout(wxCommandEvent &e)
void OnAddImages(wxCommandEvent &e)
struct celeste::svm_model * svmModel
void OnToggleGLPreviewFrame(wxCommandEvent &e)
wxMenu * m_menu_file_simple
void OnRemoveCPinMasks(wxCommandEvent &e)
std::map< int, wxString > m_userAssistant
void OnHelp(wxCommandEvent &e)
wxHelpController & GetHelpController()
void OnUserQuit(wxCommandEvent &e)
void RunCPGenerator(CPDetectorSetting &setting, const HuginBase::UIntSet &img)
run the cp generator with the given setting on selected images
void OnOnlyActiveImages(wxCommandEvent &e)
void OnSetGuiSimple(wxCommandEvent &e)
void RunAssistant(wxWindow *mainWin, const wxString &userdefinedAssistant=wxEmptyString)
void ShowMaskEditor(size_t imgNr, bool switchToCropMode=false)
opens the mask/crop editor with the given image selected
void OnSetGuiAdvanced(wxCommandEvent &e)
wxString getProjectName()
void OnNewProject(wxCommandEvent &e)
static MainFrame * m_this
void OnMergeProject(wxCommandEvent &e)
void OnReadPapywizard(wxCommandEvent &e)
void OnOptimize(wxCommandEvent &e)
const bool GetOptimizeIgnoreLineCp() const
wxMenuItem * m_assistantUserMenu
OptimizePanel * opt_panel
wxMenuItem * m_outputUserMenu
bool IsShowingCorrelation() const
void OnFullScreen(wxCommandEvent &e)
event handler for full screen
MaskEditorPanel * mask_panel
void OnLoadProject(wxCommandEvent &e)
virtual void panoramaChanged(HuginBase::Panorama &pano)
Enable or disable undo and redo.
wxString GetCurrentOptimizerString()
returns the string which describes the current selected optimizer setting
void DisplayHelp(wxString section=wxEmptyString)
call help browser with given file
void OnRunAssistant(wxCommandEvent &e)
void OnCPListFrameClosed()
void OnUndo(wxCommandEvent &e)
bool CloseProject(bool cancelable, CloseReason reason)
void enableTools(bool option)
const wxString GetSelectedCPGenerator()
return the currently selected cp generator description
void OnFineTuneAll(wxCommandEvent &e)
void OnUserDefinedStitch(wxCommandEvent &e)
void SetOptimizeIgnoreLineCp(const bool ignoreLineCP)
sets the status of the "ignore line cp" menu item
void OnRedo(wxCommandEvent &e)
const wxString & GetDataPath()
get the path to data directory
void OnIgnoreLineCp(wxCommandEvent &e)
struct celeste::svm_model * GetSVMModel()
MainFrame(wxWindow *parent, HuginBase::Panorama &pano)
ctor.
void OnSavePTStitcherAs(wxCommandEvent &e)
void panoramaImagesChanged(HuginBase::Panorama &pano, const HuginBase::UIntSet &imgNr)
notifies about changes to images
GLPreviewFrame * getGLPreview()
void OnSetGuiExpert(wxCommandEvent &e)
void OnAddTimeImages(wxCommandEvent &e)
ImagesPanel * images_panel
const bool GetOptimizeOnlyActiveImages() const
void OnSize(wxSizeEvent &e)
OptimizePhotometricPanel * opt_photo_panel
void OnBrowseProjects(wxCommandEvent &e)
void OnShowPanel(wxCommandEvent &e)
CPDetectorSetting & GetDefaultSetting()
returns default cp detector setting
void ShowStitcherTab()
opens the stitcher tab
void OnUserDefinedStitchSaved(wxCommandEvent &e)
void OnApplyTemplate(wxCommandEvent &e)
void SetOptimizeOnlyActiveImages(const bool onlyActive)
sets the status of the "optimize only active images" menu item
void OnExit(wxCloseEvent &e)
wxMenu * m_menu_file_advanced
void OnSaveProjectAs(wxCommandEvent &e)
void Init(HuginBase::Panorama *pano)
void SwitchToCropMode()
switches the controls to crop mode
void setImage(unsigned int imgNr, bool updateListSelection=false)
sets the image, which is currently edited
void SetGuiLevel(GuiLevel newGuiLevel)
void SetOnlyActiveImages(const bool onlyActive)
for external setting of "only active image" checkbox
void OnOptimizeButton(wxCommandEvent &e)
run the optimizer
void Init(HuginBase::Panorama *pano)
void SetIgnoreLineCP(const bool noLineCp)
for external setting of "ignore line cp" checkbox
void Init(HuginBase::Panorama *pano)
void SetGuiLevel(GuiLevel newGuiLevel)
void SetOnlyActiveImages(const bool onlyActive)
for external setting of "only active image" checkbox
void OnOptimizeButton(wxCommandEvent &e)
run the optimizer
center panorama horizontically
PanoCommand to combine other PanoCommands.
bool canRedo() const
Return true iff there is a command to redo.
std::string getLastCommandName() const
returns the name of the last command
void clearRedoQueue()
clear all commands in the redo queue
virtual void redo()
Redoes the last undone action.
void addCommand(PanoCommand *command, bool execute=true)
Adds a command to the history.
virtual void undo()
Undoes the last action.
void clear()
Erases all the undo/redo history.
bool canUndo() const
Return true iff there is a command to undo.
distributes all images above the sphere, for the assistant
static GlobalCmdHist & getInstance()
Base class for all panorama commands.
remove several control points
remove multiple images from a panorama
update all control points
updates the optimize vector, aka all variables which should be optimized
add image(s) to a panorama
apply a template to a panorama object
dump the current project and load a new one.
start a new project, reset options to values in preferences
simple class that forward the drop to the mainframe
PanoOperation to add several user selected images to the panorama.
PanoOperation to add all image in a defined timeinterval to the panorama.
virtual PanoCommand::PanoCommand * GetCommand(wxWindow *parent, HuginBase::Panorama &pano, HuginBase::UIntSet images, GuiLevel guiLevel)
returns the appropriate PanoCommand::PanoCommand to be inserted into GlobalCmdHistory,...
Define the pano edit panel.
virtual void panoramaChanged(HuginBase::Panorama &pano)
this is called whenever the panorama has changed.
wxButton * GetStitchButton() const
void Init(HuginBase::Panorama *pano)
void SetGuiLevel(GuiLevel newGuiLevel)
void DoUserDefinedStitch(const wxString &settings=wxString())
stitching with user defined file
class for generating plugin menu items
void OnUpdate(wxCommandEvent &event)
const wxString & GetDataPath()
return the current data path
const wxString & GetXRCPath()
return the current xrc path
static huginApp * Get()
hack.. kind of a pseudo singleton...
#define HUGIN_FT_TEMPLATE_SIZE
#define HUGIN_CELESTE_MODEL
#define HUGIN_FT_CURV_THRESHOLD
#define HUGIN_FT_LOCAL_SEARCH_WIDTH
#define HUGIN_SHOW_PROJECTION_HINTS
#define HUGIN_FT_CORR_THRESHOLD
wxString Components2Str(const HuginGraph::ImageGraph::Components &comp)
wxString getDefaultProjectName(const HuginBase::Panorama &pano, const wxString filenameTemplate)
gets the default project name, as defined in the preferences
functions for interaction with the hugin configuration file
#define DEBUG_ASSERT(cond)
std::vector< ControlPoint > CPVector
std::vector< std::set< std::string > > OptimizeVector
std::set< unsigned int > UIntSet
CommandQueue * GetAssistantCommandQueueUserDefined(const HuginBase::Panorama &pano, const wxString &ExePath, const wxString &project, const wxString &assistantSetting, wxArrayString &tempFilesDelete, std::ostream &errStream)
generates the command queue for running the assistant
std::vector< NormalCommand * > CommandQueue
const wxString GetSettingStringTranslated(wxConfigBase *setting, const wxString &name, const wxString defaultValue)
read a translated string from settings and remove all whitespaces
CommandQueue * GetAssistantCommandQueue(const HuginBase::Panorama &pano, const wxString &ExePath, const wxString &project)
generates the command queue for running the assistant
void GeneratePanoOperationVector()
generates the PanoOperationVector for context menu
void CleanPanoOperationVector()
clears the PanoOperationVector
bool ImportPapywizardFile(const wxString &filename, HuginBase::Panorama &pano)
import the settings from given filename into pano
void destroySVMmodel(struct svm_model *&model)
frees the resource of model
bool loadSVMmodel(struct svm_model *&model, std::string &model_file)
loads the SVM model from file
str wxQuoteFilename(const str &arg)
Quote a filename, so that it is surrounded by "".
bool AskUserOverwrite(const wxString &filename, const wxString &caption, wxWindow *parent)
ask user if the given file should be overwritten, return true if the user confirmed the overwritting
int HuginMessageBox(const wxString &message, const wxString &caption, int style, wxWindow *parent)
std::unique_ptr< wxMessageDialogBase > MessageDialog
std::string GetUserAppDataDir()
returns the directory for user specific Hugin settings, e.g.
std::string GetHuginVersion()
return a string with version numbers
void StoreFramePosition(wxTopLevelWindow *frame, const wxString &basename, const bool ignoreMaximize)
std::string getPathPrefix(const std::string &filename)
Get the path to a filename.
MessageDialog GetMessageDialog(const wxString &message, const wxString &caption, int style, wxWindow *parent)
IMPLEMENT_DYNAMIC_CLASS(wxTreeListHeaderWindow, wxWindow)
include file for the hugin project
include file for the hugin project
void fill_set(_Container &c, typename _Container::key_type begin, typename _Container::key_type end)
Maximum of correlation, position and value.
hugin_utils::FDiff2D corrPos
hugin_utils::FDiff2D curv
hugin_utils::FDiff2D maxpos
std::vector< deghosting::BImagePtr > threshold(const std::vector< deghosting::FImagePtr > &inputImages, const double threshold, const uint16_t flags)
Threshold function used for creating alpha masks for images.
void UpdateImageCacheSize()
update the image cache size from the settings in wxConfig
wxwindows specific panorama commands