33 : m_variables (variables),
62 std::size_t
part)
const
82#define image_variable( name, type, default_value )\
84 for (std::size_t imageNr = 0; imageNr < m_pano.getNrOfImages(); imageNr++)\
86 if (m_image_part_numbers[imageNr] == part)\
91 if (m_pano.getImage(imageNr).name##isLinked())\
120#define image_variable( name, type, default_value )\
122 m_pano.unlinkImageVariable##name(i);\
133 unsigned int imageNr)
159#define image_variable( name, type, default_value )\
161 m_pano.linkImageVariable##name(first_image_number, i);\
172 unsigned int imageNr)
187 DEBUG_ERROR(
"Request to switch an image to a nonexistent part." );
201#define image_variable( name, type, default_value ) \
203 if(m_pano.getImage(part_image_index).name##isLinked())\
205 linked_variables.insert(IVE_##name);\
226#define image_variable( name, type, default_value ) \
228 m_pano.unlinkImageVariable##name(imageNr);\
244#define image_variable( name, type, default_value ) \
246 m_pano.linkImageVariable##name(part_image_index, imageNr);\
300 for (std::set<ImageVariableEnum>::const_iterator
k =
m_variables.begin();
308#define image_variable( name, type, default_value ) \
310 if (m_pano.getImage(i).name##isLinkedWith(m_pano.getImage(parts_first_image[j]))) \
Declare the ImageVariableGroup and ImageVariableGroupObserver classes.
virtual ~ConstImageVariableGroup()
destructor
std::size_t getNumberOfParts() const
get the number of parts.
void setPartNumbers()
Set the part numbers in m_image_part_numbers, and notify observers of changes.
void updatePartNumbers()
Update the part numbers, call this when the panorama changes.
bool getVarLinkedInPart(ImageVariableEnum variable, std::size_t part) const
Get the linked status of a particular variable for a given part number.
ConstImageVariableGroup(std::set< ImageVariableEnum > variables, const PanoramaData &pano)
constructor
unsigned int getPartNumber(unsigned int imageNr) const
Get a part number from an image number.
std::vector< unsigned int > m_image_part_numbers
The part numbers for each image.
UIntSetVector getPartsSet() const
return a vector which contains a HuginBase::UIntSet for each group with the corresponding images numb...
const PanoramaData & m_pano
The panorama this group works on.
std::set< ImageVariableEnum > m_variables
The set of variables which make up this group.
void switchParts(unsigned int ImageNr, unsigned int partNr)
switch a given image to a different part number.
void unlinkVariableImage(ImageVariableEnum variable, unsigned int imageNr)
unlink one the variables across the part containing a given image.
void unlinkVariablePart(ImageVariableEnum variable, unsigned int partNr)
unlink one of the variables across a given part.
void linkVariableImage(ImageVariableEnum variable, unsigned int imageNr)
link one of the variables across a part containing a given image
void linkVariablePart(ImageVariableEnum variable, unsigned int partNr)
link one of the variables across a given part
virtual void imageChanged(unsigned int imgNr)=0
mark image change for maintainance
virtual std::size_t getNrOfImages() const =0
number of images.
#define DEBUG_ASSERT(cond)
This file specifies what image variables SrcPanoImg should have.
mainly consists of wrapper around the pano tools library, to assist in ressource management and to pr...
std::vector< UIntSet > UIntSetVector
std::set< unsigned int > UIntSet
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.