Hugin trunk 0.1
Loading...
Searching...
No Matches
Classes | Macros | Functions | Variables
BrowseDialog.cpp File Reference

implementation of dialog to browse directory with pto files More...

#include "hugin/BrowseDialog.h"
#include "hugin/huginApp.h"
#include "wx/dir.h"
#include "wx/busyinfo.h"
#include "hugin/GenerateThumbnail.h"
#include "hugin/MainFrame.h"
#include "base_wx/wxcms.h"
#include "base_wx/LensTools.h"
#include "base_wx/platform.h"
#include "base_wx/wxutils.h"
Include dependency graph for BrowseDialog.cpp:

Go to the source code of this file.

Classes

class  ThreadImage
 helper class to transfer thumbnail data from worker thread to GUI thread More...
 
class  ThumbnailThread
 background thread to generate thumbnails of all pto files More...
 

Macros

#define THUMBNAIL_SIZE   128
 
#define SORTASCENDING(functionName, var)
 
#define SORTDESCENDING(functionName, var)
 
#define SORTASCENDING(functionName, var)
 
#define SORTDESCENDING(functionName, var)
 

Functions

 wxDECLARE_EVENT (wxEVT_COMMAND_THUMBNAILTHREAD_UPDATE, wxCommandEvent)
 
 wxDEFINE_EVENT (wxEVT_COMMAND_THUMBNAILTHREAD_UPDATE, wxCommandEvent)
 
template<class Type >
int GreaterComparisonOperator (const Type &a, const Type &b)
 
template<class Type >
int SmallerComparisonOperator (const Type &a, const Type &b)
 
 SORTASCENDING (SortCanvasSizeAcending, options.getSize().area()) SORTDESCENDING(SortCanvasSizeDescending
 
options getSize ().area()) int wxCALLBACK SortFieldOfViewAscending(wxIntPtr item1
 
return GreaterComparisonOperator (fieldOfView1, fieldOfView2)
 
int wxCALLBACK SortFieldOfViewDescending (wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
 
int wxCALLBACK SortDateAscending (wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
 
int wxCALLBACK SortDateDesending (wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
 
int wxCALLBACK SortDurationAscending (wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
 
int wxCALLBACK SortDurationDesending (wxIntPtr item1, wxIntPtr item2, wxIntPtr sortData)
 

Variables

options wxIntPtr item2
 
options wxIntPtr wxIntPtr sortData
 
const float fieldOfView1 = data->at(item1).options.getHFOV() * 1000 + data->at(item1).options.getVFOV()
 
const float fieldOfView2 = data->at(item2).options.getHFOV() * 1000 + data->at(item2).options.getVFOV()
 

Detailed Description

implementation of dialog to browse directory with pto files

Author
T. Modes

Definition in file BrowseDialog.cpp.

Macro Definition Documentation

◆ SORTASCENDING [1/2]

#define SORTASCENDING (   functionName,
  var 
)
Value:
{\
std::vector<PanoInfo>* data = (std::vector<PanoInfo>*)(sortData);\
return GreaterComparisonOperator(data->at(item1).var, data->at(item2).var);\
}
int GreaterComparisonOperator(const Type &a, const Type &b)
options wxIntPtr wxIntPtr sortData
options wxIntPtr item2
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.
Definition threshold.h:41

Definition at line 657 of file BrowseDialog.cpp.

◆ SORTASCENDING [2/2]

#define SORTASCENDING (   functionName,
  var 
)
Value:
{\
std::vector<PanoInfo>* data = (std::vector<PanoInfo>*)(sortData);\
return data->at(item1).var.CmpNoCase(data->at(item2).var);\
}

Definition at line 657 of file BrowseDialog.cpp.

◆ SORTDESCENDING [1/2]

#define SORTDESCENDING (   functionName,
  var 
)
Value:
{\
std::vector<PanoInfo>* data = (std::vector<PanoInfo>*)(sortData);\
return SmallerComparisonOperator(data->at(item1).var, data->at(item2).var);\
}
int SmallerComparisonOperator(const Type &a, const Type &b)

Definition at line 663 of file BrowseDialog.cpp.

◆ SORTDESCENDING [2/2]

#define SORTDESCENDING (   functionName,
  var 
)
Value:
{\
std::vector<PanoInfo>* data = (std::vector<PanoInfo>*)(sortData);\
return -(data->at(item1).var.CmpNoCase(data->at(item2).var));\
}

Definition at line 663 of file BrowseDialog.cpp.

◆ THUMBNAIL_SIZE

#define THUMBNAIL_SIZE   128

Definition at line 152 of file BrowseDialog.cpp.

Function Documentation

◆ getSize()

options getSize ( )

◆ GreaterComparisonOperator() [1/2]

template<class Type >
int GreaterComparisonOperator ( const Type &  a,
const Type &  b 
)

Definition at line 620 of file BrowseDialog.cpp.

◆ GreaterComparisonOperator() [2/2]

return GreaterComparisonOperator ( fieldOfView1  ,
fieldOfView2   
)

◆ SmallerComparisonOperator()

template<class Type >
int SmallerComparisonOperator ( const Type &  a,
const Type &  b 
)

Definition at line 639 of file BrowseDialog.cpp.

Referenced by SortFieldOfViewDescending().

◆ SORTASCENDING()

SORTASCENDING ( SortCanvasSizeAcending  ,
options.  getSize).area( 
)

◆ SortDateAscending()

int wxCALLBACK SortDateAscending ( wxIntPtr  item1,
wxIntPtr  item2,
wxIntPtr  sortData 
)

Definition at line 725 of file BrowseDialog.cpp.

References item2, sortData, and threshold().

Referenced by BrowsePTOFilesDialog::SortItems().

◆ SortDateDesending()

int wxCALLBACK SortDateDesending ( wxIntPtr  item1,
wxIntPtr  item2,
wxIntPtr  sortData 
)

Definition at line 739 of file BrowseDialog.cpp.

References item2, sortData, and threshold().

Referenced by BrowsePTOFilesDialog::SortItems().

◆ SortDurationAscending()

int wxCALLBACK SortDurationAscending ( wxIntPtr  item1,
wxIntPtr  item2,
wxIntPtr  sortData 
)

Definition at line 754 of file BrowseDialog.cpp.

References item2, sortData, and threshold().

Referenced by BrowsePTOFilesDialog::SortItems().

◆ SortDurationDesending()

int wxCALLBACK SortDurationDesending ( wxIntPtr  item1,
wxIntPtr  item2,
wxIntPtr  sortData 
)

Definition at line 768 of file BrowseDialog.cpp.

References item2, sortData, and threshold().

Referenced by BrowsePTOFilesDialog::SortItems().

◆ SortFieldOfViewDescending()

int wxCALLBACK SortFieldOfViewDescending ( wxIntPtr  item1,
wxIntPtr  item2,
wxIntPtr  sortData 
)

◆ wxDECLARE_EVENT()

wxDECLARE_EVENT ( wxEVT_COMMAND_THUMBNAILTHREAD_UPDATE  ,
wxCommandEvent   
)

◆ wxDEFINE_EVENT()

wxDEFINE_EVENT ( wxEVT_COMMAND_THUMBNAILTHREAD_UPDATE  ,
wxCommandEvent   
)

Variable Documentation

◆ fieldOfView1

const float fieldOfView1 = data->at(item1).options.getHFOV() * 1000 + data->at(item1).options.getVFOV()

Definition at line 711 of file BrowseDialog.cpp.

Referenced by SortFieldOfViewDescending().

◆ fieldOfView2

const float fieldOfView2 = data->at(item2).options.getHFOV() * 1000 + data->at(item2).options.getVFOV()

Definition at line 712 of file BrowseDialog.cpp.

Referenced by SortFieldOfViewDescending().

◆ item2

options wxIntPtr item2

◆ sortData

options wxIntPtr wxIntPtr sortData
Initial value:
{
std::vector<PanoInfo>* data = (std::vector<PanoInfo>*)(sortData)

Definition at line 708 of file BrowseDialog.cpp.

Referenced by SortDateAscending(), SortDateDesending(), SortDurationAscending(), SortDurationDesending(), and SortFieldOfViewDescending().