Hugin trunk
0.1
Loading...
Searching...
No Matches
hugin_base
hugin_math
hugin_math.cpp
Go to the documentation of this file.
1
// -*- c-basic-offset: 4 -*-
23
#include "
hugin_math.h
"
24
#include "
hugin_utils/utils.h
"
25
27
namespace
hugin_utils
28
{
29
int
_gcd
(
int
a,
int
b)
30
{
31
// calculate greated common divisor using Euclidean algorithm
32
return
b == 0 ? a :
_gcd
(b, a % b);
33
}
34
35
int
gcd
(
int
a,
int
b)
36
{
37
// enforce that both arguments are positive
38
return
_gcd
(
abs
(a),
abs
(b));
39
}
40
41
}
// namespace
hugin_math.h
misc math function & classes used by other parts of the program
utils.h
hugin_utils
namespace for various utils
Definition
wxPlatform.cpp:30
hugin_utils::_gcd
int _gcd(int a, int b)
Definition
hugin_math.cpp:29
hugin_utils::gcd
int gcd(int a, int b)
function to calculate greated common divisor using Euclidean algorithm both arguments should be >=0
Definition
hugin_math.cpp:35
threshold
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
Generated on Sun Sep 6 2026 02:43:01 for Hugin trunk by
1.9.8