
Definition in file ShapeOps.C.
#include "Image/ShapeOps.H"
#include "Image/CutPaste.H"
#include "Image/FilterOps.H"
#include "Image/Image.H"
#include "Image/Pixels.H"
#include "Util/Assert.H"
#include "Util/StringUtil.H"
#include "Util/log.H"
#include "Util/safecopy.H"
#include "rutz/trace.h"
#include <algorithm>
#include <cmath>
#include <limits>
#include <vector>
#include "inst/Image/ShapeOps.I"
Include dependency graph for ShapeOps.C:

Go to the source code of this file.
Defines | |
| #define | ADD_RGB(buf, Weight, bWeight, in) |
| #define | RGB_BILINEAR_INTERP(EL) |
| #define | B (1.0 / 3.0) |
| #define | C (1.0 / 3.0) |
Functions | |
| template<class T> | |
| Image< T > | quickLocalAvg (const Image< T > &array, const int scale) |
| template<class T> | |
| Image< T > | quickLocalAvg2x2 (const Image< T > &src) |
| template<class T> | |
| T | element_wise_max (const T &t1, const T &t2) |
| template<class T> | |
| PixRGB< T > | element_wise_max (const PixRGB< T > &t1, const PixRGB< T > &t2) |
| template<class T> | |
| Image< T > | quickLocalMax (const Image< T > &array, const int scale) |
| template<class T> | |
| T | element_wise_min (const T &t1, const T &t2) |
| template<class T> | |
| PixRGB< T > | element_wise_min (const PixRGB< T > &t1, const PixRGB< T > &t2) |
| template<class T> | |
| Image< T > | quickLocalMin (const Image< T > &array, const int scale) |
| template<class T> | |
| Image< T > | quickInterpolate (const Image< T > &src, const int sfactor) |
| template<class T> | |
| Image< T > | interpolate (const Image< T > &src) |
| template<class T> | |
| Image< T > | rescaleBilinear (const Image< T > &src, const Dims &dims) |
| template<class T> | |
| Image< T > | rescaleBilinear (const Image< T > &src, const int new_w, const int new_h) |
| template<> | |
| Image< PixRGB< byte > > | rescaleBilinear (const Image< PixRGB< byte > > &src, const int new_w, const int new_h) |
| template<class T> | |
| Image< T > | rescaleNI (const Image< T > &src, const Dims &dims) |
| template<class T> | |
| Image< T > | rescaleNI (const Image< T > &src, const int new_w, const int new_h) |
| RescaleType | getRescaleTypeFromChar (char ftype) |
| Convert a character mnemonic into a RescaleType;. | |
| std::string | convertToString (RescaleType ftype) |
| Convert RescaleType -> string. | |
| void | convertFromString (const std::string &str1, RescaleType &ftype) |
| Convert string -> RescaleType. | |
| double | sinc (double x) |
| template<class F> | |
| void | calc_x_contrib (CLIST *contribX, double xscale, int dstwidth, int srcwidth, int i) |
| template<class F, class T> | |
| Image< T > | genericRescale (const Image< T > &src, const Dims &newdims) |
| template<class T> | |
| Image< T > | rescale (const Image< T > &src, const Dims &newdims, RescaleType ftype) |
| template<class T> | |
| Image< T > | rescale (const Image< T > &src, const int width, const int height, RescaleType ftype) |
| template<class T> | |
| Image< T > | rescaleOpt (const Image< T > &src, const Dims &dims, const bool interp) |
| template<class T> | |
| Image< T > | rescaleOpt (const Image< T > &src, const int new_w, const int new_h, const bool interp) |
| template<class T> | |
| Image< PixRGB< T > > | downscaleFancy (const Image< PixRGB< T > > &src, int width, int height, int weighting_slope, bool no_weight_black) |
| downscale an image using fancy widgets like anti-aliasing, resampling | |
| template<class T> | |
| Image< T > | downSize (const Image< T > &src, const Dims &dims, const int filterWidth) |
| Downsize using alternating lowpass/decimate operations. | |
| template<class T> | |
| Image< T > | downSize (const Image< T > &src, const int new_w, const int new_h, const int filterWidth) |
| Downsize using alternating lowpass/decimate operations. | |
| Image< float > | downSizeClean (const Image< float > &src, const Dims &new_dims, const int filterWidth) |
| template<class T> | |
| Image< T > | concatArray (const Image< T > arr[], const int nbarr, const int Nx, const int destX, const int destY) |
| template<class T> | |
| Image< T > | decXY (const Image< T > &src, const int xfactor, const int yfactor_raw) |
| template<class T> | |
| Image< T > | decX (const Image< T > &src, const int factor) |
| template<class T> | |
| Image< T > | decY (const Image< T > &src, const int factor) |
| template<class T> | |
| Image< T > | blurAndDecY (const Image< T > &src, const int factor) |
| Blur and then decimate in Y. Equivalent to decY(sepFilter(src)). | |
| template<class T> | |
| Image< T > | intXY (const Image< T > &src, const bool dupli) |
| template<class T> | |
| Image< T > | intX (const Image< T > &src, const bool dupli) |
| template<class T> | |
| Image< T > | intY (const Image< T > &src, const bool dupli) |
| template<class T> | |
| Image< T > | zoomXY (const Image< T > &src, int xzoom, int yzoom) |
| template<class T> | |
| Image< T > | rotate (const Image< T > &srcImg, const int x, const int y, const float ang) |
| template Image< double > | quickLocalAvg2x2 (const Image< double > &) |
| template Image< int > | decX (const Image< int > &, int) |
| template Image< int > | decY (const Image< int > &, int) |
| template Image< int > | decXY (const Image< int > &, int, int) |
| template Image< double > | intXY (const Image< double > &, bool) |
|
template Image< PixH2SV2< float > > | decXY (const Image< PixH2SV2< float > > &, int, int) |
|
template Image< PixH2SV2< float > > | rescaleBilinear (const Image< PixH2SV2< float > > &src, int, int) |
|
|
Value: Definition at line 63 of file ShapeOps.C. Referenced by downscaleFancy(). |
|
|
Value: |
|
||||||||||||||||
|
Blur and then decimate in Y. Equivalent to decY(sepFilter(src)). This is logically equivalent to constructing a boxcar filter of size factor, then doing decY(sepFilter(src, [], filter)). However, this implementation is optimized to be much faster, especially if factor is large, since we avoid computing the filter results that would just be thrown away by the subsequent decimation. Definition at line 1390 of file ShapeOps.C. References ASSERT, Image< T >::begin(), Image< T >::beginw(), Image< T >::getHeight(), Image< T >::getWidth(), GVX_TRACE, i, w, and ZEROS. Referenced by Image_xx_blurAndDecY_xx_1(), and TrainingSet::load(). |
|
||||||||||||
|
Convert string -> RescaleType.
Definition at line 585 of file ShapeOps.C. |
|
|
Convert RescaleType -> string.
Definition at line 566 of file ShapeOps.C. |
|
||||||||||||||||||||||||||||
|
downscale an image using fancy widgets like anti-aliasing, resampling Adapted from PhotoPNMtools by Boris Van Schooten boris@13thmonkey.org Definition at line 998 of file ShapeOps.C. References ADD_RGB, Image< T >::beginw(), PixRGB< T >::blue(), lobot::cos(), Image< T >::getVal(), Image< T >::getWidth(), PixRGB< T >::green(), GVX_TRACE, LERROR, LINFO, out, pix, PixRGB< T >::red(), Image< T >::resize(), Image< T >::setVal(), src, and weight. Referenced by featureClusterVision< FLOAT >::fCVgetImageComplexStats(). |
|
||||||||||||||||||||||||
|
Downsize using alternating lowpass/decimate operations. The width used internally in the lowpass filters is given by filterWidth (default = 9). Definition at line 1143 of file ShapeOps.C. References ASSERT, decX(), decY(), Image< T >::getHeight(), Image< T >::getWidth(), GVX_TRACE, i, LFATAL, log(), lowPassX(), and lowPassY(). |
|
||||||||||||||||||||
|
Downsize using alternating lowpass/decimate operations. The width used internally in the lowpass filters is given by filterWidth (default = 9). Definition at line 1135 of file ShapeOps.C. Referenced by BiasValImage::BiasValImage(), InferoTemporalSalBayes::buildRawDV(), DescriptorVec::buildRawDV(), SubmapAlgorithmBiased::compute(), computeCMAP(), BeoSubSaliency::computeCMAP(), SaliencyMT::computeCMAP(), downSize(), GetSaliency::getSubMaps(), TaskRelevanceMapKillStatic::inputFrame(), insertLocalAvg(), TaskRelevanceMapKillN::integrate(), main(), maxNormalizeFancy(), RegSaliency::postChannel(), SingleChannel::postProcessMap(), and BiasValImage::updateValues(). |
|
|
Convert a character mnemonic into a RescaleType;.
Definition at line 547 of file ShapeOps.C. |
1.4.4