hugin_hdrmerge.cpp File Reference

merge images More...

#include <hugin_config.h>
#include <fstream>
#include <sstream>
#include <cmath>
#include <algorithm>
#include <memory>
#include <vigra/error.hxx>
#include <vigra/functorexpression.hxx>
#include <vigra/transformimage.hxx>
#include <hugin_utils/utils.h>
#include <vigra_ext/impexalpha.hxx>
#include <vigra_ext/HDRUtils.h>
#include <vigra_ext/ReduceOpenEXR.h>
#include <getopt.h>
#include "../deghosting/deghosting.h"
#include "../deghosting/khan.h"

Include dependency graph for hugin_hdrmerge.cpp:

Go to the source code of this file.


typedef vigra::FRGBImage ImageType
typedef std::shared_ptr< ImageTypeImagePtr


bool mergeWeightedAverage (std::vector< std::string > inputFiles, vigra::FRGBImage &output, vigra::BImage &alpha)
bool weightedAverageOfImageFiles (const std::vector< std::string > &inputFiles, const std::vector< deghosting::FImagePtr > &weights, vigra::FRGBImage &output, vigra::BImage &alpha)
 compute output image when given source images
static void usage (const char *name)
int main (int argc, char *argv[])


static int g_verbose = 0
const uint16_t OTHER_GRAY = 1

Detailed Description

merge images

Pablo d'Angelo <>

This program 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 General Public License for more details.

You should have received a copy of the GNU General Public License along with this software. If not, see <>.

Definition in file hugin_hdrmerge.cpp.

Typedef Documentation

typedef std::shared_ptr<ImageType> ImagePtr

Definition at line 56 of file hugin_hdrmerge.cpp.

typedef vigra::FRGBImage ImageType

Definition at line 53 of file hugin_hdrmerge.cpp.

Function Documentation

int main ( int  argc,
char *  argv[] 

Definition at line 213 of file hugin_hdrmerge.cpp.

References deghosting::ADV_GAMMA, deghosting::ADV_MULTIRES, cerr, cout, deghosting::Deghosting::createWeightMasks(), vigra::exportImageAlpha(), flags, g_verbose, iterations, mergeWeightedAverage(), OTHER_GRAY, otherFlags, reduceFilesToHDR(), sigma, vigra_ext::srcImage(), vigra_ext::srcImageRange(), hugin_utils::stripPath(), usage(), and weightedAverageOfImageFiles().

bool mergeWeightedAverage ( std::vector< std::string inputFiles,
vigra::FRGBImage &  output,
vigra::BImage &  alpha 

Definition at line 64 of file hugin_hdrmerge.cpp.

References cerr, cout, vigra_ext::destImage(), g_verbose, vigra::detail::importImageAlpha(), celeste::info(), and vigra_ext::ReduceToHDRFunctor< VALUETYPE >::reset().

Referenced by main().

static void usage ( const char *  name  )  [static]

Definition at line 186 of file hugin_hdrmerge.cpp.

References cout, and hugin_utils::GetHuginVersion().

bool weightedAverageOfImageFiles ( const std::vector< std::string > &  inputFiles,
const std::vector< deghosting::FImagePtr > &  weights,
vigra::FRGBImage &  output,
vigra::BImage &  alpha 

compute output image when given source images

Definition at line 142 of file hugin_hdrmerge.cpp.

References vigra::omp::combineThreeImages(), vigra::omp::combineTwoImages(), cout, vigra_ext::destImage(), g_verbose, vigra::importImageAlpha(), vigra_ext::srcImage(), vigra_ext::srcImageRange(), and vigra_ext::transformImage().

Referenced by main().

Variable Documentation

int g_verbose = 0 [static]

Definition at line 58 of file hugin_hdrmerge.cpp.

const uint16_t OTHER_GRAY = 1

Definition at line 60 of file hugin_hdrmerge.cpp.

Generated on 27 Jul 2017 for Hugintrunk by  doxygen 1.4.7