utils.h File Reference

#include <hugin_shared.h>
#include <string.h>
#include <stdlib.h>
#include <string>
#include <vector>
#include <iostream>
#include <sstream>
#include <cassert>
#include <hugin_utils/platform.h>

Include dependency graph for utils.h:

Include dependency graph

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Namespaces

namespace  hugin_utils

Defines

#define DEBUG_HEADER   hugin_utils::GetCurrentTimeString() <<" (" << __FILE__ << ":" << __LINE__ << ") " << __func__ << "(): "
#define DEBUG_TRACE(msg)
#define DEBUG_DEBUG(msg)
#define DEBUG_INFO(msg)
#define DEBUG_NOTICE(msg)
#define DEBUG_WARN(msg)   { std::cerr << "WARN: " << DEBUG_HEADER << msg << std::endl; }
#define DEBUG_ERROR(msg)   { std::cerr << "ERROR: " << DEBUG_HEADER << msg << std::endl; }
#define DEBUG_FATAL(msg)   { std::cerr << "FATAL: " << DEBUG_HEADER << "(): " << msg << std::endl; }
#define DEBUG_ASSERT(cond)   assert(cond)
#define UTILS_THROW(class, msg)   { std::stringstream o; o << msg; throw(class(o.str().c_str())); };

Functions

template<typename STR>
bool stringToDouble (const STR &str_, double &dest)
 convert a string to a double, ignore localisation.
template<typename Target, typename Source>
Target lexical_cast (Source arg)
template<class str>
str QuoteStringInternal (const str &arg, const str &quotechar, const str &replacements)
template<class str>
str replaceAll (const str &arg, const str &target, const str &replacement)


Detailed Description

Author:
Pablo d'Angelo <pablo.dangelo@web.de>
$Id$

This is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU General Public License along with this software; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

Definition in file utils.h.


Define Documentation

#define DEBUG_ASSERT cond   )     assert(cond)
 

Definition at line 98 of file utils.h.

Referenced by PreviewIdentifyTool::AfterDrawImagesEvent(), vigra_ext::applyRect(), AutoPanoSiftPreAlign::automatch(), AutoPanoSift::automatch(), PreviewIdentifyTool::BeforeDrawImageEvent(), TextureManager::BindTexture(), HuginBase::MaskPolygon::clipPolygon(), MeshManager::MeshInfo::CompileList(), PanoPanel::Create(), OptimizePhotometricPanel::Create(), OptimizePanel::Create(), MaskEditorPanel::Create(), ImagesPanel::Create(), CPEditorPanel::Create(), vigra_ext::createTiffDirectory(), TextureManager::DrawImage(), GreatCircles::drawLineFromSpherical(), HuginBase::Nona::estimateBlendingOrder(), EVT_BUTTON(), CPEditorPanel::FineTuneSelectedPoint(), MainFrame::Get(), huginApp::Get(), HuginBase::ConstStandardImageVariableGroups::getLens(), HuginBase::ConstImageVariableGroup::getPartNumber(), HuginBase::PTScriptParsing::getPTDoubleParam(), TextureManager::GetTextureName(), GLPreviewFrame::GLPreviewFrame(), PreviewIdentifyTool::HighlightColour(), ImagesTreeCtrl::Init(), ImagesList::Init(), vigra_ext::ROIImage< RemapImage, AlphaImage >::lowerRight(), MainFrame::MainFrame(), vigra_ext::ROIImage< RemapImage, AlphaImage >::maskLowerRight(), vigra_ext::ROIImage< RemapImage, AlphaImage >::maskUpperLeft(), CPEditorPanel::NewPointChange(), NonaOptionsDialog::NonaOptionsDialog(), PreviewFrame::OnShowAll(), GLPreviewFrame::OnShowAll(), PreviewFrame::OnShowNone(), GLPreviewFrame::OnShowNone(), HuginBase::Nona::TiffMultiLayerRemapper< ImageType, AlphaImageType >::prepareOutputFile(), PreviewFrame::PreviewFrame(), HuginBase::PTScriptParsing::readVar(), CPListFrame::SetCPItem(), PreviewIdentifyTool::ShowImageNumber(), HuginBase::ImageCache::softFlush(), HuginBase::Nona::MultiImageRemapper< ImageType, AlphaImageType >::stitch(), HuginBase::Nona::stitchPanorama(), PreviewIdentifyTool::StopUpdating(), TextureManager::TextureInfo::TextureInfo(), vigra_ext::transformImageDist(), HuginBase::PanoCommand< std::string >::undo(), HuginBase::Panorama::updateLineCtrlPoints(), PreviewIdentifyTool::UpdateWithNewImageSet(), and vigra_ext::ROIImage< RemapImage, AlphaImage >::upperLeft().

#define DEBUG_DEBUG msg   ) 
 

Definition at line 86 of file utils.h.

Referenced by HuginBase::Panorama::activateImage(), PanosphereOverviewProjectionGridTool::AfterDrawImagesBackEvent(), PreviewProjectionGridTool::AfterDrawImagesEvent(), PanosphereOverviewProjectionGridTool::AfterDrawImagesFrontEvent(), HuginBase::PTOptEstimator::agree(), AutoPanoKolor::automatch(), AutoPanoSift::automatch(), vigra_ext::blend(), PanoPanel::BlenderChanged(), MaskImageCtrl::calcAutoScaleFactor(), CPImageCtrl::calcAutoScaleFactor(), HuginBase::StraightenPanorama::calcStraighteningRotation(), MeshManager::CheckUpdate(), AutoCtrlPointCreator::Cleanup(), MeshManager::MeshInfo::CompileList(), correctImage(), vigra_ext::correlateImageFast(), PreviewPanel::Create(), ImagesList::Create(), createCtrlPoints(), createCtrlPointsOld(), GLwxAuiManager::CreateFloatingFrame(), ImagesList::CreateItem(), PanosphereOverviewProjectionGridTool::createMesh(), TextureManager::TextureInfo::CreateTexture(), CPListFrame::DeleteSelected(), HuginBase::AutoOptimise::OptimiseVisitor::discover_vertex(), PanoPanel::DoStitch(), VisualizationState::DoUpdates(), ViewState::DoUpdates(), PreviewPanel::DrawPreview(), HuginBase::Nona::estimateBlendingOrder(), HuginBase::estimateImageAlpha(), CPEditorPanel::EstimatePoint(), vigra_ext::extractRandomPoints(), PanoPanel::FileFormatChanged(), HuginBase::RANSACOptimizer::findInliers(), vigra_ext::findInterestPointsOnGrid(), CPEditorPanel::FineTuneSelectedPoint(), VisualizationState::FinishedDraw(), PanoPanel::FusionChanged(), HuginBase::PTScriptParsing::getPTDoubleParam(), HuginBase::SmallRemappedImageCache::getRemapped(), HuginBase::ImageCache::getSmallImage(), LocalizedFileTipProvider::GetTip(), HuginPipedProcess::HasInput(), PanoPanel::HDRFileFormatChanged(), PanoPanel::HDRMergeChanged(), HuginBase::Nona::SpaceTransform::InitRadialCorrect(), NonaOptionsDialog::InterpolatorChanged(), HuginBase::SmallRemappedImageCache::invalidate(), MyExecPanel::KillProcess(), HuginBase::PTOptEstimator::leastSquaresEstimate(), HuginBase::ImageCache::loadImageSafely(), LoadLensParametersChoose(), MainFrame::LoadProjectFile(), vigra_ext::ROIImage< RemapImage, AlphaImage >::lowerRight(), main(), vigra_ext::ROIImage< RemapImage, AlphaImage >::maskLowerRight(), vigra_ext::ROIImage< RemapImage, AlphaImage >::maskUpperLeft(), CPImageCtrl::mouseMoveEvent(), PreviewPanel::mousePressLMBEvent(), CPImageCtrl::mousePressLMBEvent(), CPImageCtrl::mousePressMMBEvent(), PreviewPanel::mousePressRMBEvent(), CPImageCtrl::mouseReleaseLMBEvent(), CPImageCtrl::mouseReleaseMMBEvent(), CPImageCtrl::mouseReleaseRMBEvent(), vigra_ext::multithreadOperation(), NonaOptionsDialog::NonaOptionsDialog(), GLwxAuiFloatingFrame::OnActivate(), PreviewFrame::OnChangeDisplayedImgs(), PreviewFrame::OnChangeFOV(), GLPreviewFrame::OnChangeFOV(), PreviewFrame::OnClose(), OptimizePhotometricPanel::OnClose(), OptimizePanel::OnClose(), GLPreviewFrame::OnClose(), CPListFrame::OnClose(), CPEditorPanel::OnCPEvent(), CPListFrame::OnCPListSelectionChanged(), HFOVDialog::OnCropFactorChanged(), CPImageCtrl::OnDraw(), MainFrame::OnFineTuneAll(), HFOVDialog::OnFocalLengthChanged(), HFOVDialog::OnHFOVChanged(), huginApp::OnInit(), PanoPanel::OnJPEGQualityText(), CPEditorPanel::OnKey(), CPImageCtrl::OnKeyDown(), TextKillFocusHandler::OnKillFocus(), MaskImageCtrl::OnLeftMouseDown(), MaskImageCtrl::OnLeftMouseUp(), GLwxAuiFloatingFrame::OnMoveFinished(), PreviewFrame::OnNumTransform(), MyExecDialog::OnProcessTerminate(), PreviewFrame::OnProjectionChoice(), GLPreviewFrame::OnProjectionChoice(), MainFrame::OnSaveProject(), CPListFrame::OnSelectButton(), ImagesPanel::OnSelectionChanged(), GLPreviewFrame::OnShowEvent(), MyPipedProcess::OnTerminate(), TextKillFocusHandler::OnTextChange(), HFOVDialog::OnTypeChanged(), vigra_ext::TransformImageAlphaIntern< SrcImageIterator, SrcAccessor, SrcAlphaIterator, SrcAlphaAccessor, DestImageIterator, DestAccessor, TRANSFORM, PixelTransform, AlphaImageIterator, AlphaAccessor, Interpolator >::operator()(), vigra_ext::TransformImageIntern< SrcImageIterator, SrcAccessor, DestImageIterator, DestAccessor, TRANSFORM, PixelTransform, AlphaImageIterator, AlphaAccessor, Interpolator >::operator()(), HuginBase::Nona::DifferenceBlender::operator()(), HuginBase::Nona::SeamBlender::operator()(), HuginBase::Nona::StackingBlender::operator()(), PT::PanoramaObserver::panoramaChanged(), ViewState::panoramaChanged(), PreviewPanel::panoramaChanged(), PreviewFrame::panoramaChanged(), GLPreviewFrame::panoramaChanged(), CPEditorPanel::panoramaChanged(), PT::PanoramaObserver::panoramaImagesChanged(), ImagesPanel::panoramaImagesChanged(), ImagesList::panoramaImagesChanged(), CPEditorPanel::panoramaImagesChanged(), GLPreviewFrame::PauseResize(), HuginBase::PhotometricOptimizer::photometricError(), vigra_ext::PointFineTune(), PointFineTune2(), vigra_ext::PointFineTuneRotSearch(), HuginBase::Nona::TiffMultiLayerRemapper< ImageType, AlphaImageType >::prepareOutputFile(), PT::wxApplyTemplateCmd::processPanorama(), PT::wxLoadPTProjectCmd::processPanorama(), PT::wxAddCtrlPointGridCmd::processPanorama(), PanoPanel::ProjectionChanged(), HuginBase::PTOptEstimator::PTOptEstimator(), HuginBase::PTScriptParsing::readVar(), CommandHistory::redo(), VisualizationState::Redraw(), GLViewer::RedrawE(), reduceFilesToHDR(), GLViewer::RefreshWrapper(), HuginBase::Nona::remapImage(), HuginBase::Nona::RemappedPanoImage< RemapImage, AlphaImage >::remapImage(), PanoPanel::RemapperChanged(), HuginBase::Panorama::removeDuplicateCtrlPoints(), CPImageCtrl::rescaleImage(), GLViewer::Resized(), HuginBase::RotatePanorama::rotatePano(), OptimizePhotometricPanel::runOptimizer(), OptimizePanel::runOptimizer(), HuginBase::Nona::TiffMultiLayerRemapper< ImageType, AlphaImageType >::saveRemapped(), CPEditorPanel::SelectGlobalPoint(), CPEditorPanel::SelectLocalPoint(), CPImageCtrl::selectPoint(), HuginBase::PTools::setDestImage(), HuginBase::PanoramaOptions::setHeight(), CPImageCtrl::setNewPoint(), HuginBase::Nona::RemappedPanoImage< RemapImage, AlphaImage >::setPanoImage(), MaskImageCtrl::setScale(), CPImageCtrl::setScale(), GLOverview::setUp(), GLPreview::setUp(), HuginBase::PanoramaOptions::setVFOV(), HuginBase::PanoramaOptions::setWidth(), MainFrame::ShowCtrlPoint(), CPImageCtrl::showPosition(), CPImageCtrl::showSearchArea(), HuginBase::SmartOptimise::smartOptimize(), HuginBase::ImageCache::softFlush(), CPListFrame::SortList(), HuginBase::ImageCache::spawnAsyncThread(), PanoPanel::StackCheck(), HuginBase::Nona::SimpleStitcher< ImageType, AlphaType >::stitch(), HuginBase::Nona::ReduceStitcher< ImageType, AlphaType >::stitch(), HuginBase::Nona::WeightedStitcher< ImageType, AlphaType >::stitch(), HuginBase::Nona::stitchPanorama(), RunStitchPanel::StitchProject(), hugin_utils::stringToDouble(), vigra_ext::subpixelMaxima(), AppBase::ProgressDisplay::subtaskFinished(), AppBase::ProgressDisplay::subtaskStarted(), HuginBase::Panorama::swapImages(), vigra_ext::transformImage(), vigra_ext::transformImageAlpha(), vigra_ext::transformImageAlphaGPU(), vigra_ext::transformImageAlphaInternMT(), vigra_ext::transformImageGPU(), vigra_ext::transformImageInternMT(), hugin_utils::traverseEdges(), CommandHistory::undo(), VertexCoordRemapper::UpdateAndResetIndex(), CPEditorPanel::UpdateDisplay(), PreferencesDialog::UpdateDisplayData(), PreviewPanel::updatePreview(), vigra_ext::ROIImage< RemapImage, AlphaImage >::upperLeft(), CPListFrame::~CPListFrame(), MainFrame::~MainFrame(), and TextureManager::TextureInfo::~TextureInfo().

#define DEBUG_ERROR msg   )     { std::cerr << "ERROR: " << DEBUG_HEADER << msg << std::endl; }
 

Definition at line 94 of file utils.h.

Referenced by AutoPanoKolor::automatch(), AutoPanoSift::automatch(), AutoCtrlPointCreator::automatch(), ProjectionGridTool::createTexture(), TextureManager::TextureInfo::DefineLevels(), PanoPanel::DoStitch(), HuginBase::PanoramaOptions::getFormatFromName(), HuginBase::ConstStandardImageVariableGroups::getLens(), TextureManager::GetMaxTextureSizePower(), hugin_utils::lexical_cast(), HuginBase::ImageCache::loadImageSafely(), MainFrame::LoadProjectFile(), HuginBase::ImageCache::loadSafely(), main(), CPImageCtrl::mousePressLMBEvent(), PreviewFrame::OnChangeDisplayedImgs(), CPEditorPanel::OnCPEvent(), huginApp::OnInit(), MaskEditorPanel::OnZoom(), CPEditorPanel::OnZoom(), vigra_ext::PointFineTuneRotSearch(), PT::LoadPTProjectCmd::processPanorama(), PT::wxLoadPTProjectCmd::processPanorama(), AutoCtrlPointCreator::readUpdatedControlPoints(), CommandHistory::redo(), HuginBase::Panorama::removeDuplicateCtrlPoints(), CPEditorPanel::SelectGlobalPoint(), TextureManager::TextureInfo::SetMaxLevel(), TextureManager::TextureInfo::SetParameters(), GLViewer::SetUpContext(), CPListFrame::SortList(), HuginBase::Nona::WeightedStitcher< ImageType, AlphaType >::stitch(), HuginBase::Nona::stitchPanoIntern(), HuginBase::Nona::stitchPanorama(), vigra_ext::subpixelMaxima(), CommandHistory::undo(), HuginBase::Panorama::updateLineCtrlPoints(), PreviewPanel::updatePreview(), and HuginBase::Panorama::updateVariable().

#define DEBUG_FATAL msg   )     { std::cerr << "FATAL: " << DEBUG_HEADER << "(): " << msg << std::endl; }
 

Definition at line 96 of file utils.h.

Referenced by CommandHistory::addCommand(), MainFrame::Get(), huginApp::Get(), HuginBase::Nona::SpaceTransform::Init(), HuginBase::Nona::SpaceTransform::InitInv(), HuginBase::ImageCache::loadImageSafely(), CPEditorPanel::OnCPEvent(), and HuginBase::PTools::setFullImage().

#define DEBUG_HEADER   hugin_utils::GetCurrentTimeString() <<" (" << __FILE__ << ":" << __LINE__ << ") " << __func__ << "(): "
 

Definition at line 71 of file utils.h.

#define DEBUG_INFO msg   ) 
 

Definition at line 87 of file utils.h.

Referenced by TextureManager::CheckUpdate(), MeshManager::CheckUpdate(), TextureManager::CleanTextures(), MeshManager::MeshInfo::CompileList(), ProjectionGridTool::createTexture(), TextureManager::TextureInfo::DefineLevels(), MainFrame::DisplayHelp(), PanoPanel::DoCalcFOV(), PanoPanel::DoCalcOptimalROI(), PanoPanel::DoCalcOptimalWidth(), EVT_NOTEBOOK_PAGE_CHANGED(), PanoOperation::AddImagesSeriesOperation::GetInternalCommand(), TextureManager::GetMaxTextureSizePower(), HuginBase::ImageCache::getSmallImage(), PanoPanel::HeightChanged(), PanoPanel::HFOVChanged(), HuginBase::ImageVariable< Type >::linkWith(), LensCalFrame::OnAddImage(), GLPreviewFrame::OnAutocrop(), BatchFrame::OnButtonHelp(), GLPreviewFrame::OnCropFactorChanged(), GLPreviewFrame::OnExposureChanged(), PreviewFrame::OnFitPano(), GLPreviewFrame::OnFitPano(), GLPreviewFrame::OnFocalLengthChanged(), GLPreviewFrame::OnHFOVChanged(), GLPreviewFrame::OnProjParameterChanged(), ImagesPanel::OnSize(), GLPreviewFrame::OnStackAutocrop(), PreviewFrame::OnTextCtrlChanged(), GLPreviewFrame::OnVFOVChanged(), PT::PanoramaObserver::panoramaChanged(), PT::PanoramaObserver::panoramaImagesChanged(), PreviewFrame::panoramaImagesChanged(), GLPreviewFrame::panoramaImagesChanged(), PT::wxApplyTemplateCmd::processPanorama(), PT::wxLoadPTProjectCmd::processPanorama(), PT::wxAddImagesCmd::processPanorama(), AppBase::ProgressDisplay::propagateProgress(), GLViewer::Redraw(), HuginBase::RandomPointSampler::sampleRandomPanoPoints(), CPListFrame::SetCPItem(), TextureManager::TextureInfo::SetParameters(), GLViewer::SetUpContext(), PreferencesDialog::UpdateConfigData(), PreviewPanel::updatePreview(), AppBase::MultiProgressDisplayAdaptor::updateProgressDisplay(), AppBase::ProgressDisplay::updateSubtaskProgress(), PanoPanel::VFOVChanged(), and PanoPanel::WidthChanged().

#define DEBUG_NOTICE msg   ) 
 

Definition at line 88 of file utils.h.

Referenced by HuginBase::PanoramaOptions::setHFOV(), and vigra_ext::subpixelMaxima().

#define DEBUG_TRACE msg   ) 
 

Definition at line 85 of file utils.h.

Referenced by MyProgressDialog::abortOperation(), MyExecPanel::AddToOutput(), RunStitchPanel::CancelStitch(), CPEditorPanel::changeState(), CPImageCtrl::clearNewPoint(), PreviewPanel::Create(), PanoPanel::Create(), OptimizePhotometricPanel::Create(), OptimizePanel::Create(), MaskEditorPanel::Create(), ImagesTreeCtrl::Create(), ImagesPanel::Create(), ImagesListMask::Create(), ImagesList::Create(), CPEditorPanel::Create(), CPEditorPanel::CreateNewPoint(), CPImageCtrl::deselect(), MainFrame::DisplayHelp(), PanoPanel::DoCalcFOV(), PreviewPanel::DrawPreview(), HuginBase::ImageCache::Entry::Entry(), EVT_BUTTON(), EVT_NOTEBOOK_PAGE_CHANGED(), EVT_TEXT(), vigra_ext::findInterestPointsOnGrid(), CPImageCtrl::generateMagBitmap(), PanoOperation::CelesteOperation::GetInternalCommand(), PanoOperation::AddImagesSeriesOperation::GetInternalCommand(), GLPreviewFrame::GLPreviewFrame(), huginApp::huginApp(), OptimizePanel::Init(), LensCalFrame::LensCalFrame(), MainFrame::LoadProjectFile(), MainFrame::MainFrame(), CPEditorPanel::NewPointChange(), MainFrame::OnAddImages(), BatchFrame::OnButtonHelp(), CPEditorPanel::OnCelesteButton(), PreviewFrame::OnChangeFOV(), GLPreviewFrame::OnChangeFOV(), PreviewFrame::OnClose(), OptimizePhotometricPanel::OnClose(), OptimizePanel::OnClose(), GLPreviewFrame::OnClose(), CPEditorPanel::OnCPEvent(), CPEditorPanel::OnCPListSelect(), CPListFrame::OnCPListSelectionChanged(), CPEditorPanel::OnDeleteButton(), MainFrame::OnDoStitch(), PanoDropTarget::OnDropFiles(), FileDropTarget::OnDropFiles(), stitchApp::OnExit(), MainFrame::OnExit(), huginApp::OnExit(), MainFrame::OnFineTuneAll(), PreviewFrame::OnFitPano(), GLPreviewFrame::OnFitPano(), huginApp::OnInit(), LensCalApp::OnInit(), ImagesList::OnItemDeselected(), ImagesList::OnItemSelected(), CPImageCtrl::OnKey(), CPImageCtrl::OnKeyDown(), TextKillFocusHandler::OnKillFocus(), CPEditorPanel::OnLeftChoiceChange(), MainFrame::OnLoadProject(), CPImageCtrl::OnMouseEnter(), CPImageCtrl::OnMouseLeave(), MainFrame::OnOptimize(), OptimizePhotometricPanel::OnOptimizeButton(), OptimizePanel::OnOptimizeButton(), GLPreviewFrame::OnOverviewToggle(), RunStitchFrame::OnProcessTerminate(), RunStitchPanel::OnProcessTerminate(), MyExecPanel::OnProcessTerminated(), MainFrame::OnRedo(), PreviewPanel::OnResize(), PreferencesDialog::OnRestoreDefaults(), CPEditorPanel::OnRightChoiceChange(), MainFrame::OnSaveProject(), MainFrame::OnSaveProjectAs(), MainFrame::OnSavePTStitcherAs(), MainFrame::OnShowCPFrame(), GLPreviewFrame::OnShowEvent(), MainFrame::OnShowPrefs(), MaskImageCtrl::OnSize(), MainFrame::OnSize(), CPImageCtrl::OnSize(), MyProcess::OnTerminate(), TextKillFocusHandler::OnTextChange(), TextKillFocusHandler::OnTextEnter(), CPEditorPanel::OnTextPointChange(), MainFrame::OnTogglePreviewFrame(), GLPreviewFrame::OnTrackChangeFOV(), MainFrame::OnUndo(), OptimizePanel::OptimizePanel(), PanoPanel::panoramaChanged(), NonaOptionsDialog::panoramaChanged(), CPEditorPanel::panoramaChanged(), PreviewPanel::panoramaImagesChanged(), PreviewFrame::panoramaImagesChanged(), MainFrame::panoramaImagesChanged(), ImagesTreeCtrl::panoramaImagesChanged(), ImagesPanel::panoramaImagesChanged(), ImagesList::panoramaImagesChanged(), GLPreviewFrame::panoramaImagesChanged(), CPListFrame::panoramaImagesChanged(), CPEditorPanel::panoramaImagesChanged(), CPEditorPanel::PointFineTune(), vigra_ext::PointFineTuneRotSearch(), PreviewFrame::PreviewFrame(), PT::wxLoadPTProjectCmd::processPanorama(), vigra_ext::reduceToNextLevelOld(), RestoreFramePosition(), OptimizePhotometricPanel::runOptimizer(), OptimizePanel::runOptimizer(), CPEditorPanel::SelectLocalPoint(), CPImageCtrl::selectPoint(), MaskImageCtrl::setImage(), MaskEditorPanel::setImage(), CPImageCtrl::setImage(), CPEditorPanel::setLeftImage(), CPEditorPanel::setRightImage(), CPListFrame::SortList(), PanoPanel::StackCheck(), stitchApp::stitchApp(), RunStitchPanel::StitchProject(), StoreFramePosition(), CPImageCtrl::update(), PreferencesDialog::UpdateConfigData(), MaskEditorPanel::UpdateCropDisplay(), PreviewPanel::updatePreview(), MainFrame::updateProgressDisplay(), LensCalFrame::updateProgressDisplay(), CPEditorPanel::~CPEditorPanel(), CPImageCtrl::~CPImageCtrl(), CPListFrame::~CPListFrame(), HuginBase::ImageCache::Entry::~Entry(), GLPreviewFrame::~GLPreviewFrame(), huginApp::~huginApp(), ImagesList::~ImagesList(), ImagesPanel::~ImagesPanel(), ImagesTreeCtrl::~ImagesTreeCtrl(), LensCalFrame::~LensCalFrame(), MainFrame::~MainFrame(), MaskEditorPanel::~MaskEditorPanel(), NonaOptionsDialog::~NonaOptionsDialog(), OptimizePanel::~OptimizePanel(), OptimizePhotometricPanel::~OptimizePhotometricPanel(), PanoPanel::~PanoPanel(), HuginBase::Panorama::~Panorama(), PreferencesDialog::~PreferencesDialog(), PreviewFrame::~PreviewFrame(), PreviewPanel::~PreviewPanel(), and stitchApp::~stitchApp().

#define DEBUG_WARN msg   )     { std::cerr << "WARN: " << DEBUG_HEADER << msg << std::endl; }
 

Definition at line 92 of file utils.h.

Referenced by const_map_get(), CPEditorPanel::EstimatePoint(), map_get(), PreviewFrame::OnBlendChoice(), CPListFrame::OnFineTuneButton(), PreviewFrame::OnOutputChoice(), PreviewFrame::OnProjectionChoice(), PT::PanoramaObserver::panoramaChanged(), PT::PanoramaObserver::panoramaImagesChanged(), HuginBase::PTScriptParsing::ImgInfo::parse(), HuginBase::Panorama::swapImages(), GLPreviewFrame::updateBlendMode(), and PreferencesDialog::UpdateDisplayData().

#define UTILS_THROW class,
msg   )     { std::stringstream o; o << msg; throw(class(o.str().c_str())); };
 

Definition at line 146 of file utils.h.

Referenced by HuginBase::Nona::stitchPanoGray_32_float(), HuginBase::Nona::stitchPanoGray_8_16(), HuginBase::Nona::stitchPanorama(), HuginBase::Nona::stitchPanoRGB_32_float(), and HuginBase::Nona::stitchPanoRGB_8_16().


Function Documentation

template<typename Target, typename Source>
Target lexical_cast Source  arg  ) 
 

Definition at line 228 of file utils.h.

References DEBUG_ERROR.

template<class str>
str QuoteStringInternal const str &  arg,
const str &  quotechar,
const str &  replacements
 

Definition at line 249 of file utils.h.

template<class str>
str replaceAll const str &  arg,
const str &  target,
const str &  replacement
 

Definition at line 273 of file utils.h.

template<typename STR>
bool stringToDouble const STR &  str_,
double &  dest
 

convert a string to a double, ignore localisation.

always accept both.

sets dest to the new value, and returns true if it could be read.

it the conversion fails, returns false and does not modify dest.

Returns:
success

Definition at line 177 of file utils.h.

References DEBUG_DEBUG.

Referenced by HuginBase::PTScriptParsing::getDoubleParam(), HuginBase::PTScriptParsing::getPTDoubleParam(), GLPreviewFrame::OnNumTransform(), HuginBase::PTScriptParsing::readVar(), str2double(), and PreferencesDialog::UpdateConfigData().


Generated on Fri Aug 29 01:25:46 2014 for Hugintrunk by  doxygen 1.3.9.1