Hugintrunk  0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
PossiblePano Class Reference

#include <FindPanoDialog.h>

Public Types

enum  NamingConvention { NAMING_PANO =0, NAMING_FIRST_LAST =1, NAMING_FOLDER =2, NAMING_TEMPLATE =3 }
 enumeration for different naming conventions, must be match combobox in ressource More...
 

Public Member Functions

 PossiblePano ()
 constructor, init values More...
 
 ~PossiblePano ()
 destructor, cleans up used variables More...
 
bool BelongsTo (HuginBase::SrcPanoImage *img, const wxTimeSpan max_time_diff)
 return true, if the image could belong to the given PossiblePano, it checks camera maker and model, focal length, image size and date/time More...
 
void AddSrcPanoImage (HuginBase::SrcPanoImage *img)
 adds the given SrcPanoImage to this pano-group More...
 
const unsigned int GetImageCount () const
 returns number of images in this group More...
 
const wxString GetItemString (const wxString BasePath) const
 returns a string which contains description of this pano More...
 
const wxString GetFilestring (const wxString BasePath, const bool stripExtension=false) const
 returns a string with the filename of the first and last file More...
 
wxString GeneratePanorama (NamingConvention nc, bool createLinks, HuginBase::PanoramaOptions::BlendingMechanism defaultBlender)
 generates the panorama file from this set of images More...
 
wxString GetCameraName ()
 returns the camera name More...
 
wxString GetLensName ()
 returns the lens name More...
 
wxString GetFocalLength ()
 returns the focal length as string More...
 
wxString GetStartString ()
 return the start date/time as string More...
 
wxString GetDuration ()
 returns the duration as string More...
 
void PopulateListCtrl (wxListCtrl *list, wxImageList *thumbs, wxArrayString &tooltips)
 add all images to wxListCtrl More...
 
void RemoveImage (const unsigned int index)
 removes the image at given index More...
 
PossiblePanoSplitPano (const unsigned int index)
 split pano into 2 subpanos, index is used as first image of second pano More...
 

Private Member Functions

const wxDateTime GetDateTime (const HuginBase::SrcPanoImage *img)
 does some reformating date/time format More...
 
bool GetNewProjectFilename (NamingConvention nc, const wxString basePath, wxFileName &projectFile)
 returns a given filename, which does not already exists More...
 
void UpdateDateTimes ()
 updates the internal date/time representations More...
 

Private Attributes

std::string m_make
 
std::string m_camera
 
std::string m_lens
 
wxDateTime m_dt_start
 
wxDateTime m_dt_end
 
double m_focallength
 
double m_cropfactor
 
vigra::Size2D m_size
 
ImageSet m_images
 

Detailed Description

Definition at line 120 of file FindPanoDialog.h.

Member Enumeration Documentation

enumeration for different naming conventions, must be match combobox in ressource

Enumerator
NAMING_PANO 
NAMING_FIRST_LAST 
NAMING_FOLDER 
NAMING_TEMPLATE 

Definition at line 124 of file FindPanoDialog.h.

Constructor & Destructor Documentation

PossiblePano::PossiblePano ( )
inline

constructor, init values

Definition at line 132 of file FindPanoDialog.h.

Referenced by SplitPano().

PossiblePano::~PossiblePano ( )

destructor, cleans up used variables

Definition at line 608 of file FindPanoDialog.cpp.

References m_images.

Member Function Documentation

void PossiblePano::AddSrcPanoImage ( HuginBase::SrcPanoImage img)

adds the given SrcPanoImage to this pano-group

Definition at line 666 of file FindPanoDialog.cpp.

References GetDateTime(), m_camera, m_cropfactor, m_dt_end, m_dt_start, m_focallength, m_images, m_lens, m_make, and m_size.

Referenced by FindPanoDialog::SearchInDir(), and SplitPano().

bool PossiblePano::BelongsTo ( HuginBase::SrcPanoImage img,
const wxTimeSpan  max_time_diff 
)

return true, if the image could belong to the given PossiblePano, it checks camera maker and model, focal length, image size and date/time

Definition at line 619 of file FindPanoDialog.cpp.

References GetDateTime(), m_camera, m_cropfactor, m_dt_end, m_dt_start, m_focallength, m_lens, m_make, and m_size.

wxString PossiblePano::GeneratePanorama ( NamingConvention  nc,
bool  createLinks,
HuginBase::PanoramaOptions::BlendingMechanism  defaultBlender 
)

generates the panorama file from this set of images

Returns
the generated project file, or wxEmptyString if generation failed

Definition at line 791 of file FindPanoDialog.cpp.

References HuginBase::Panorama::addImage(), HuginBase::PanoramaOptions::blendMode, HuginBase::PanoramaOptions::enblendOptions, HuginBase::PanoramaOptions::enfuseOptions, HuginBase::Panorama::getImage(), HuginBase::StandardImageVariableGroups::getLenses(), GetNewProjectFilename(), HuginBase::Panorama::getNrOfImages(), HuginBase::Panorama::getOptions(), HuginBase::ConstImageVariableGroup::getPartNumber(), HuginBase::Panorama::hasPossibleStacks(), HuginBase::PanoramaOptions::HDRMERGE_AVERAGE, HuginBase::PanoramaOptions::hdrMergeMode, HuginBase::PanoramaOptions::hdrmergeOptions, HUGIN_CONV_FILENAME, HUGIN_ENBLEND_ARGS, HUGIN_ENFUSE_ARGS, HUGIN_HDRMERGE_ARGS, HUGIN_JPEG_QUALITY, HUGIN_LDR_OUTPUT_FORMAT, HUGIN_NONA_CROPPEDIMAGES, HUGIN_NONA_INTERPOLATOR, HUGIN_TIFF_COMPRESSION, HuginBase::PanoramaOptions::interpolator, HuginBase::Panorama::linkPossibleStacks(), m_images, HuginBase::OPT_EXPOSURE, HuginBase::OPT_POSITION, HuginBase::OPT_RESPONSE, HuginBase::OPT_VIGNETTING, HuginBase::PanoramaOptions::outputExposureValue, HuginBase::PanoramaOptions::outputFormat, HuginBase::PanoramaOptions::outputImageType, HuginBase::PanoramaOptions::outputImageTypeCompression, HuginBase::PanoramaOptions::quality, HuginBase::Panorama::setOptimizerSwitch(), HuginBase::Panorama::setOptions(), HuginBase::Panorama::setPhotometricOptimizerSwitch(), HuginBase::ImageVariableGroup::switchParts(), HuginBase::PanoramaOptions::TIFF_m, HuginBase::PanoramaOptions::tiff_saveROI, HuginBase::PanoramaOptions::tiffCompression, HuginBase::PanoramaOptions::verdandiOptions, and HuginBase::Panorama::WritePTOFile().

wxString PossiblePano::GetCameraName ( )

returns the camera name

Definition at line 904 of file FindPanoDialog.cpp.

References m_camera.

const wxDateTime PossiblePano::GetDateTime ( const HuginBase::SrcPanoImage img)
private

does some reformating date/time format

Definition at line 652 of file FindPanoDialog.cpp.

References HuginBase::SrcPanoImage::getExifDateTime(), and HUGIN_CONV_FILENAME.

Referenced by AddSrcPanoImage(), BelongsTo(), and UpdateDateTimes().

wxString PossiblePano::GetDuration ( )

returns the duration as string

Definition at line 928 of file FindPanoDialog.cpp.

References m_dt_end, and m_dt_start.

const wxString PossiblePano::GetFilestring ( const wxString  BasePath,
const bool  stripExtension = false 
) const

returns a string with the filename of the first and last file

Definition at line 695 of file FindPanoDialog.cpp.

References HUGIN_CONV_FILENAME, and m_images.

Referenced by GetItemString(), and GetNewProjectFilename().

wxString PossiblePano::GetFocalLength ( )

returns the focal length as string

Definition at line 914 of file FindPanoDialog.cpp.

References FormatString::GetFocalLength(), m_focallength, and m_images.

const unsigned int PossiblePano::GetImageCount ( ) const
inline

returns number of images in this group

Definition at line 141 of file FindPanoDialog.h.

References m_images.

Referenced by FindPanoDialog::OnSplitPanos().

const wxString PossiblePano::GetItemString ( const wxString  BasePath) const

returns a string which contains description of this pano

Definition at line 712 of file FindPanoDialog.cpp.

References GetFilestring(), and m_images.

wxString PossiblePano::GetLensName ( )

returns the lens name

Definition at line 909 of file FindPanoDialog.cpp.

References m_lens.

bool PossiblePano::GetNewProjectFilename ( NamingConvention  nc,
const wxString  basePath,
wxFileName &  projectFile 
)
private

returns a given filename, which does not already exists

Definition at line 717 of file FindPanoDialog.cpp.

References HuginBase::Panorama::addImage(), getDefaultProjectName(), GetFilestring(), m_images, NAMING_FIRST_LAST, NAMING_FOLDER, NAMING_PANO, and NAMING_TEMPLATE.

Referenced by GeneratePanorama().

wxString PossiblePano::GetStartString ( )

return the start date/time as string

Definition at line 923 of file FindPanoDialog.cpp.

References m_dt_start.

void PossiblePano::PopulateListCtrl ( wxListCtrl *  list,
wxImageList *  thumbs,
wxArrayString &  tooltips 
)
void PossiblePano::RemoveImage ( const unsigned int  index)

removes the image at given index

Definition at line 1057 of file FindPanoDialog.cpp.

References m_images, and UpdateDateTimes().

PossiblePano * PossiblePano::SplitPano ( const unsigned int  index)

split pano into 2 subpanos, index is used as first image of second pano

Returns
pointer to second subpano

Definition at line 1071 of file FindPanoDialog.cpp.

References AddSrcPanoImage(), m_images, PossiblePano(), and UpdateDateTimes().

void PossiblePano::UpdateDateTimes ( )
private

updates the internal date/time representations

Definition at line 1095 of file FindPanoDialog.cpp.

References GetDateTime(), m_dt_end, m_dt_start, and m_images.

Referenced by RemoveImage(), and SplitPano().

Member Data Documentation

std::string PossiblePano::m_camera
private

Definition at line 179 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), BelongsTo(), and GetCameraName().

double PossiblePano::m_cropfactor
private

Definition at line 184 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), and BelongsTo().

wxDateTime PossiblePano::m_dt_end
private

Definition at line 182 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), BelongsTo(), GetDuration(), and UpdateDateTimes().

wxDateTime PossiblePano::m_dt_start
private
double PossiblePano::m_focallength
private

Definition at line 183 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), BelongsTo(), and GetFocalLength().

ImageSet PossiblePano::m_images
private
std::string PossiblePano::m_lens
private

Definition at line 180 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), BelongsTo(), and GetLensName().

std::string PossiblePano::m_make
private

Definition at line 178 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), and BelongsTo().

vigra::Size2D PossiblePano::m_size
private

Definition at line 185 of file FindPanoDialog.h.

Referenced by AddSrcPanoImage(), and BelongsTo().


The documentation for this class was generated from the following files: