User Documentation
Centre for Vision, Speech & Signal Processing
DEVELOP IN NAMESPACE AMMA TREE ROOT AMMA SEARCH AMMA HOME
 

  PUBLIC
ByteImgDensity2dC::ByteImgDensity2dC(void)
ByteImgDensity2dC::ByteImgDensity2dC(const ByteImageC &)
ByteImgDensity2dC::ByteImgDensity2dC(const ByteImgDensity2dC &)
ByteImgDensity2dC::operator=(const ByteImageC &)
ByteImgDensity2dC::GetRandomPix(ImageRectangleC,BooleanT) const
ByteImgDensity2dC::GetRandomBinPix(ImageRectangleC,BooleanT) const
ByteImgDensity2dC::GetRandomPix(void) const
ByteImageC::Copy(void) const
ByteImageC::Copy(const ByteImageC &)
ByteImageC::Copy(const ImageRectangleC &,const PixelC &)
ByteImageC::ACopy(void) const
ByteImageC::AnotherImage(void) const
ByteImageC::operator=(const ByteImageC &)
ByteImageC::operator=(const ImageC &)
ByteImageC::SaveAs(ImageOStreamC &,ImageFileFormatT)
ByteImageC::SaveAs(const FilenameC &,ImageFileFormatT)
ByteImageC::SaveBoundariesAsGF(char *,LongIntT)
ByteImageC::SaveBoundariesCompressed(char *,LongIntT)
ByteImageC::ByteImage(void) const
ByteImageC::ByteImage(void)
ByteImageC::operator+=(const ByteImageC &)
ByteImageC::operator+(const ByteImageC &) const
ByteImageC::operator-(const ByteImageC &) const
ByteImageC::Mul(const PolynomialC &,const ImageRectangleC &)
ByteImageC::Div(const PolynomialC &,const ImageRectangleC &)
ByteImageC::Palette(void)
ByteImageC::Fill(ByteGreyValueT)
ByteImageC::Frame(ByteGreyValueT)
ByteImageC::Frame(ByteGreyValueT,const ImageRectangleC &)
ByteImageC::GenerateBall(const PixelC,const RealT,const RealT,const RealT,const RealT)
ByteImageC::GenerateBall(const PixelC,const RealT)
ByteImageC::Negative(void)
ByteImageC::Max(const ByteImageC &)
ByteImageC::Min(const ByteImageC &)
ByteImageC::GreyLevelTransformation(const IntSArray1dC &)
ByteImageC::Rotate90(void) const
ByteImageC::Rotate180(void) const
ByteImageC::Rotate270(void) const
ByteImageC::Rotate(const Point2dC &,RealT,ByteGreyValueT) const
ByteImageC::Rotate(ByteImageC &,const Point2dC &,RealT,ByteGreyValueT) const
ByteImageC::Threshold(const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT)
ByteImageC::LowThreshold(const ByteGreyValueT,const ByteGreyValueT)
ByteImageC::DetectLevel(const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT)
ByteImageC::DetectLInterval(const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT)
ByteImageC::HysteresisThresholding(const RealT,const RealT)
ByteImageC::Threshold4(const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT,const ByteGreyValueT)
ByteImageC::CompLabel8(IntImageC &,SizeT &) const
ByteImageC::Erode(MorphoStructuringElementT)
ByteImageC::Dilate(MorphoStructuringElementT)
ByteImageC::LabelErode(const IndexNeigh2dC &)
ByteImageC::DistanceMap(void)
ByteImageC::SpreadRegions(int)
ByteImageC::SpreadRegions(ByteImageC &,int)
ByteImageC::HorConvolution(const RealArray1dC &)
ByteImageC::VerConvolution(const RealArray1dC &)
ByteImageC::BoundaryMedian3x3(const ByteImageC &)
ByteImageC::MaxPixel(void) const
ByteImageC::MinPixel(void) const
ByteImageC::MaxPixel4(const PixelC &) const
ByteImageC::MinPixel4(const PixelC &) const
ByteImageC::MaxPixel8(const PixelC &) const
ByteImageC::MinPixel8(const PixelC &) const
ByteImageC::Count(GreyValueT) const
ByteImageC::BasicStatistics(GreyValueT &,GreyValueT &,RealT &,RealT &)
ByteImageC::Mean(void) const
ByteImageC::IntensitySums(void) const
ByteImageC::LineKind(const IntT)
ByteImageC::LabelContour(PixelC)
ByteImageC::LinkEdges(void)
ByteImageC::Reflectance(const RealT,const RealT,const RealT) const
ByteImageC::IllDirectionPentland(void) const
ByteImageC::TsaiShahShapeFromShading(DoubleImageC &,DoubleImageC &,const Vector3dC &,IndexT)
ByteImageC::GlobalColumnCompensation(void)
ByteImageC::ADLocalColumnCompensation(void)
ByteImageC::LFLocalColumnCompensation(void)
ByteImageC::WindowMeanCompensation(SizeT)
IntDensity2dC::operator=(const IntDensity2dC &)
IntDensity2dC::operator=(const ByteImageC &)
IntDensity2dC::Build(const ByteImageC &)
IntDensity2dC::Sum(ImageRectangleC) const
IntDensity2dC::Density(ImageRectangleC) const
IntDensity2dC::GetRandomRect(ImageRectangleC,IntT) const
IntDensity2dC::GetRandomPix(ImageRectangleC) const
ImageC::Copy(void) const
ImageC::Copy(const ImageC &)
ImageC::Copy(const ImageRectangleC &,const PixelC &)
ImageC::ACopy(void) const
ImageC::AnotherImage(void) const
ImageC::operator=(const ImageC &)
ImageC::ReflectUp(const ImageRectangleC &)
ImageC::ReflectDown(const ImageRectangleC &)
ImageC::ReflectLeft(const ImageRectangleC &)
ImageC::ReflectRight(const ImageRectangleC &)
ImageC::ReflectFrom(const ImageRectangleC &)
ImageC::Rotate90(const ImageC &)
ImageC::Rotate180(const ImageC &)
ImageC::Rotate270(const ImageC &)
ImageC::Rotate(const Point2dC &,RealT,PValueT) const
ImageC::Rotate(const ImageC &,const Point2dC &,RealT,PValueT)
ImageC::ShiftRowIndexes(const IndexT)
ImageC::ShiftColIndexes(const IndexT)
ImageC::Subsample(IntT) const
ImageC::SetOrigin(const PixelC &)
ImageC::Fill(PValueT)
ImageC::Frame(PValueT)
ImageC::Frame(PValueT,const ImageRectangleC &)
ImageC::Pad(const ImageRectangleC &) const
ImageC::IsValid(void) const
ImageC::operator[](IndexT) const
ImageC::operator[](IndexT)
ImageC::operator[](const Index2dC &)
ImageC::operator[](const Index2dC &) const
ImageC::operator[](const PixelC &)
ImageC::operator[](const PixelC &) const
ImageC::CRow(PixelIndexT) const
ImageC::Row(PixelIndexT)
ImageC::Save(ostream &,BooleanT) const
ImageC::Load(istream &,BooleanT)
ImageC::StartAddress(void) const
ImageC::Buffer(void)
ImageC::Buffer(void) const
BaseImageC::Rectangle(void) const
BaseImageC::Origin(void) const
BaseImageC::End(void) const
BaseImageC::ImageFileInfo(void) const
BaseImageC::BaseImage(void) const
BaseImageC::BaseImage(void)
BaseImageC::SetRowSubRange(const IndexT,const IndexT)
BaseImageC::SetColSubRange(const IndexT,const IndexT)
BaseImageC::SetSubRange(const ImageRectangleC &)
BaseImageC::SetFullRectangle(void)
BaseImageC::SetImageFileInfo(ImageFileInfoC *)
BaseImageC::IsEmpty(void) const
BaseImageC::ErrDifferentSize(const BaseImageC &,char *) const
BaseImageC::Rnum(void) const
BaseImageC::Cnum(void) const
BaseImageC::TRow(void) const
BaseImageC::LCol(void) const
BaseImageC::BRow(void) const
BaseImageC::RCol(void) const
BaseImageC::Area(void) const
BaseImageC::Count(void) const
BaseImageC::AllocatedRect(void) const
BaseImageC::IsBlock(void) const
ImageAC::ACopy(void) const
ImageAC::AnotherImage(void) const
ImageAC::Rectangle(void) const
ImageAC::ShiftRowIndexes(const IndexT)
ImageAC::ShiftColIndexes(const IndexT)
ImageAC::SetRowSubRange(const IndexT,const IndexT)
ImageAC::SetColSubRange(const IndexT,const IndexT)
ImageAC::ImageFileInfo(void) const
ByteImgDensity2dC
 
Combined Byte and Density image.
 
include "amma/IBDens2d.hh"
User Level:Default
Library:Density
Example:exImgSeq.cc
Section:Image.Image Processing.Operators
In Scope:std

Parent Classes:

Methods:
ByteImgDensity2dC()
Default constructor.

ByteImgDensity2dC(const ByteImageC & Img)
construct from a byte image.

ByteImgDensity2dC(const ByteImgDensity2dC & Oth)
construct from a byte image.

const ByteImgDensity2dC & operator=(const ByteImageC & Oth)
Assign to an ordinary byte image.

PixelC GetRandomPix(ImageRectangleC Rect,BooleanT InvalidOk = FALSE) const
Pick a pixel a probablity equal to its value.

PixelC GetRandomBinPix(ImageRectangleC Rect,BooleanT InvalidOk = FALSE) const
Pick a pixel with value 1 from a binary image.

PixelC GetRandomPix() const
Pick pixel from whole image.

#include "amma/ByteImag.hh"
ByteImageC Copy() const
a physical copy of image

void Copy(const ByteImageC & img)
Copyies the values of image 'img' into this image.

void Copy(const ImageRectangleC & rect,const PixelC & newOrigin)
Copies the rectangle domain 'rect' of the image into the position 'newOrigin'.

ImageAC * ACopy() const
A physical copy of this image.

ImageAC * AnotherImage() const
Creates a new empty image of the same type and size as this image is.

const ByteImageC & operator=(const ByteImageC & im)
Assigment.

const ByteImageC & operator=(const ImageC<ByteGreyValueT> & im)

void SaveAs(ImageOStreamC & outS,ImageFileFormatT format = DEFAULT_FORMAT)
Saves the image into the output stream 'outS' using format.

void SaveAs(const FilenameC & name,ImageFileFormatT format = DEFAULT_FORMAT)
Saves the image into the file with the 'name' in the format.

void SaveBoundariesAsGF(char * gfName,LongIntT minArea)
Only binary image can be processed. The function traces WHITE blobs in the image and saves them in *.gf file. Only blobs which area is bigger than 'minArea' are saved.

void SaveBoundariesCompressed(char * filename,LongIntT minArea)
Only binary image can be processed. The function traces WHITE blobs in the image and saves them in the file in compressed format. Only blobs which area is bigger than 'minArea' are saved. Conversions between color images. ---------------------------------

const ByteImageC & ByteImage() const
access to the constant object

ByteImageC & ByteImage()
access to the object Arithmetical operations. ------------------------

const ByteImageC & operator+=(const ByteImageC & img)
Adds the values of image 'img' to the values of this image.

ByteImageC operator+(const ByteImageC & img) const
Sums values of related pixels of this image and image 'img'. The results are saved into the new image. The values over WHITE are cut.

ByteImageC operator-(const ByteImageC & img) const
Subtracts values of related pixels of image 'img' from this image. The results are saved into the new image shifted by the value (WHITE+BLACK)/2. The values under BLACK or over WHITE are cut.

const ByteImageC & Mul(const PolynomialC & pol,const ImageRectangleC & polRect)
Each image value is multiplied by the value of the 2d polynomial 'pol' which <-1,1>x<-1,1> range is related to the image rectangle 'polRect'. The values of the image are truncated.

const ByteImageC & Div(const PolynomialC & pol,const ImageRectangleC & polRect)
Each image value is divided by the value of the 2d polynomial 'pol' which <-1,1>x<-1,1> range is related to the image rectangle 'polRect'. The values of the image are truncated. Generating of synthetic images. -------------------------------

void Palette()
Generates a grey level palette image.

ByteImageC & Fill(ByteGreyValueT v)
Fills the image by value 'v'.

ByteImageC & Frame(ByteGreyValueT v)
Creates the frame of the image. The frame has the value 'v'.

ByteImageC & Frame(ByteGreyValueT v,const ImageRectangleC & rect)
Generates the frame of the image rectangle 'rect' into this image. The value 'v' is used for setting of the pixel values.

void GenerateBall(const PixelC center,const RealT radius,const RealT azimut,const RealT elevation,const RealT albedo)
Generates the ball with around the pixel 'center' with the 'radius'. The illumination direction is determined by the angles 'azimut' [rad] and 'elevation' [rad]. The surface of the ball is Lambertian with 'albedo' in the range <0,1>.

void GenerateBall(const PixelC center,const RealT radius)
Generates the ball with around the pixel 'center' with the 'radius'. Grey level modifications. -------------------------

ByteImageC & Negative()
invert the image pixel value

ByteImageC & Max(const ByteImageC & im)
Take the bigger value from the both images

ByteImageC & Min(const ByteImageC & im)
Take the smaller value from the both images

ByteImageC & GreyLevelTransformation(const IntSArray1dC & newLevel)
Changes grey levels according to the table 'newLevel'. Geometrical transformations. ----------------------------

ByteImageC Rotate90() const
Rotate the image about PI/2 rad.

ByteImageC Rotate180() const
Rotate the image about PI rad.

ByteImageC Rotate270() const
Rotate the image about 3/2PI rad.

ByteImageC Rotate(const Point2dC & center,RealT angle,ByteGreyValueT background) const
rotate the image around the center about the angle. Return the result.

ByteImageC & Rotate(ByteImageC & rotImage,const Point2dC & center,RealT angle,ByteGreyValueT background) const
rotate the image around the center about the angle save the result in rotImage. Return the result. Thresholding. -------------

ByteImageC & Threshold(const ByteGreyValueT thr,const ByteGreyValueT lowLabel = BLACK,const ByteGreyValueT upLabel = WHITE)
The image is thresholded. If an input image value >= thr, the output value is upLabel, otherwise lowLabel.

ByteImageC & LowThreshold(const ByteGreyValueT thr,const ByteGreyValueT lowLabel)
The image is thresholded. If an input image value < 'thr', the output value is set lowLabel, otherwise the output value has the same value as the input one.

ByteImageC & DetectLevel(const ByteGreyValueT level,const ByteGreyValueT levelLabel,const ByteGreyValueT backgroundLabel)
If an input image value == 'level', then the output value is 'levelLabel', otherwise 'backgroundLabel'

ByteImageC & DetectLInterval(const ByteGreyValueT lowThr,const ByteGreyValueT highThr,const ByteGreyValueT lowLabel,const ByteGreyValueT centerLabel,const ByteGreyValueT highLabel)
If an input image value is below the threshold 'lowThr', the output value is 'lowLabel'. If an input image value is higher than 'highThr', the output value is 'highLabel'. Otherwise the output value is 'centerValue'.

ByteImageC HysteresisThresholding(const RealT mjuSmall,const RealT mjuBig)
This subroutine detects spots. The spot peaks are extracted from the enhanced image by means of hysteresis thresholding.

void Threshold4(const ByteGreyValueT veryLow,const ByteGreyValueT low,const ByteGreyValueT high,const ByteGreyValueT veryHigh,const ByteGreyValueT aLabel,const ByteGreyValueT bLabel,const ByteGreyValueT cLabel,const ByteGreyValueT dLabel,const ByteGreyValueT eLabel)
Performs thresholding with 4 thresholds 'veryLow' < 'low' < 'high' < 'veryHigh'. The intervals of grey levels created by these thresholds are labelled with the labels 'aLabel', 'bLabel', 'cLabel', 'dLabel', 'eLabel'. If a function g(label) generates all possible grey levels corresponding to the interval labelled 'label', the following relationship is valid: g('aLabel') < g('bLabel') < g('cLabel') < g('dLabel') < g('eLabel'). Connected component labelling -----------------------------

void CompLabel8(IntImageC & jp,SizeT & maxLabel) const
Connected component labelling using 8-neighborhood of pixel provided that this input image contains regions determined by sets of 4-connected WHITE pixels on the BLACK background. At input the value 'maxLabel' is taken as an assumed maximum label value, at output the value 'maxLabel' is the number of connected components already found in this image. The result is saved in the image 'jp'. Morphological operations. -------------------------

ByteImageC & Erode(MorphoStructuringElementT elType = SQUARE3x3)
Calculates binary erosion for the structuring element 'elType'. The image size is reduced by 1 along each border
BUG: The image is also shifted to the top left by 1 pixel. IPMorphErodeC is now the preferred method

ByteImageC & Dilate(MorphoStructuringElementT elType = SQUARE3x3)
Calculates binary dilation for the structuring element 'elType'. The image size is reduced by 1 along each border
BUG: The image is also shifted to the top left by 1 pixel. IPMorphDilateC is now the preferred method

ByteImageC & LabelErode(const IndexNeigh2dC & structElement)
Label erosion. If the whole 'structElement' is not covered by one label, the pixel is relabeled to be BLACK. The first index of the 'structElement' must be the most upper-left one, the last one must be the most bottom-right one. Distance mapping. -----------------

ByteImageC & DistanceMap()
Calculates distance map for each pixel which value is different from BLACK. The pixel value will be the block-city distance from the nearest BLACK pixel. The outside of the image is taken BLACK.

ByteImageC & SpreadRegions(int maxDist = 255)
Spreads regions defined by non-zero values of pixels into the image area of zero value pixels. Each zero value pixel closer (<=) than 'maxDist' (block-city metric used) to a reagion is assigned value of the nearest non-zero pixel. The 'maxDist' must not be bigger than 255. The outside of the image is taken zero.

ByteImageC & SpreadRegions(ByteImageC & measure,int maxDist = 255)
Spreads regions defined by non-zero values of pixels into the image area of zero value pixels. Each zero value pixel closer (<=) than 'maxDist' (block-city metric used) to a reagion is assigned value of the nearest non-zero pixel. The 'maxDist' must not be bigger than 255. The outside of the image is taken zero. Together with expanding of region boundary pixels their measure value in the image 'measure' is propagated. Convolutions. -------------

ByteImageC & HorConvolution(const RealArray1dC & mask)
convolves an image horizontally with a given mask

ByteImageC & VerConvolution(const RealArray1dC & mask)
convolves an image vertically with a given mask Smoothing. ----------

ByteImageC & BoundaryMedian3x3(const ByteImageC & objectMask)
The boundary pixel values are replaced by the median from the neighborhood 3 x 3 pixels of an object. The boundary pixel is any pixel having the BLACK 4-connected neighbouring pixel. The object pixel is any pixel which value is different from BLACK. Statistics. -----------

PixelC MaxPixel() const
Returns the first pixel with the maximum value.

PixelC MinPixel() const
Returns the first pixel with the minimum value.

PixelC MaxPixel4(const PixelC & p) const
Returns the first pixel with the maximum value 4-connected with the pixel 'p'. "The first one takes everything" search method is used.

PixelC MinPixel4(const PixelC & p) const
Returns the first pixel with the minimum value 4-connected with the pixel 'p'. "The first one takes everything" search method is used.

PixelC MaxPixel8(const PixelC & p) const
Returns the first pixel with the maximum value 8-connected with the pixel 'p'. "The first one takes everything" search method is used.

PixelC MinPixel8(const PixelC & p) const
Returns the first pixel with the minimum value 8-connected with the pixel 'p'. "The first one takes everything" search method is used.

LongIntT Count(GreyValueT level) const
Returns the number of pixels at 'level' in the image.

ByteImageC & BasicStatistics(GreyValueT & minValue,GreyValueT & maxValue,RealT & meanValue,RealT & var)
Estimates the image statistics, i.e. mean, variance, and extrems.

RealT Mean() const
Returns the mean of intensities of all pixel values.

LinearSums1dC IntensitySums() const
Returns the sums of intensities of all pixel values.

RealT LineKind(const IntT frameWidth)
Decides about the dominant orientation of lines which can be detected in the image 'im'. The image sides of the width 'frameWidth' are not involved into the decision making. It returns positive value, if lines are horizontal, or it returns negative value, if lines are vertical.

void LabelContour(PixelC pxl)
Works with an image of pixel whose values contain state. The function changes the status of the 8-connected pixels which state is UNPROC_PXL and the whole string of pixels contains the pixel 'pxl'.

PixelStringListC LinkEdges()
Transformation of the image containing pixels with states into the list of pixel strings. Shape from shading. -------------------

DoubleImageC Reflectance(const RealT azimut,const RealT elevation,const RealT albedo) const
Returns the reflectance map of the image taken as a depth map. The reflectance map is generated for the illumination direction determined by the angles 'azimuth' and 'elevation' [rad]. The surface is supposed to be Lambertian with the 'albedo'.

IllDirectionC IllDirectionPentland() const
Returns the estimation of illumination direction according to Pentland's method.

void TsaiShahShapeFromShading(DoubleImageC & snIm,DoubleImageC & znIm,const Vector3dC & illDirection,IndexT iterNumber)
A Simple Shape From Shading Algorithm by P.Tsai and M. Shah: CS-TR-92-24, Department of Computer Science, Technical Report, University of Central Florida, Orlando, FL 32816 Variaty of compensations. -------------------------

GreyValueT GlobalColumnCompensation()
Compensates the regular global offset between even and odd columns of the image. The value offset is returned.

void ADLocalColumnCompensation()
Compensates the local offset between even and odd columns of the image. All even columns are compensated using the average difference (AD) between the given column and its both neighbohrs.

void LFLocalColumnCompensation()
Compensates the pixel response non-uniformity using filtering method.

void WindowMeanCompensation(SizeT wsize)
Compensates the local mean in each window of the size 'wsize' to be the image intensity mean.

#include "amma/IDens2d.hh"
const IntDensity2dC & operator=(const IntDensity2dC & oth)
Assignment.

const IntDensity2dC & operator=(const ByteImageC & Img)
Assign to a byte image.

void Build(const ByteImageC & Img)
Build a new map from Image ByteImageC,

IntT Sum(ImageRectangleC Rect) const
Get sum of pixel in Rect. Rect is clipped to lie within Map.

RealT Density(ImageRectangleC Rect) const
Get the density of points within the rectangle. Any part of the rectangle outside the image is considered to contain nothing.

ImageRectangleC GetRandomRect(ImageRectangleC Rect,IntT MinArea = 12) const
Pick a Rectangle inside 'Rect' with a probality propoportional the magnatude the sum of the pixels in that area. This is for making a more efficent 'GetRandomPix' when dealing with binary images. When the area drops below MinArea it is more efficent to scan the image an pick from the pixels found. NB. - The returned rectangle isn't random in posision !! - The returned rectangle may not be entirly inside the map if the original rectangle wasn't.

PixelC GetRandomPix(ImageRectangleC Rect) const
Pick a pixel inside 'Rect' with a probality propoportional the magnatude of the pixel.

#include "amma/Image.hh"
ImageC<ByteGreyValueT> Copy() const
Creates another physical copy of this image.

void Copy(const ImageC<ByteGreyValueT> & image)
Copies the contents of image "img" into this image.

void Copy(const ImageRectangleC & rect,const PixelC & newOrigin)
Copies the region of the image defined by rectangle "rect" into the region whose origin is "newOrigin".

ImageAC * ACopy() const
A physical copy of this image.

ImageAC * AnotherImage() const
Creates a new empty image of the same type and size as this image is.

const ImageC<ByteGreyValueT> & operator=(const ImageC<ByteGreyValueT> & image)
Assigment of a big object.

void ReflectUp(const ImageRectangleC & rect)
Mirrors the image rectangle along its top edge.

void ReflectDown(const ImageRectangleC & rect)
Mirrors the image rectangle along its bottom edge.

void ReflectLeft(const ImageRectangleC & rect)
Mirrors the image rectangle along its left edge.

void ReflectRight(const ImageRectangleC & rect)
Mirrors the image rectangle along its right edge.

void ReflectFrom(const ImageRectangleC & rect)
Mirrors the image rectangle "rect" along its sides to fill the whole image.

void Rotate90(const ImageC<ByteGreyValueT> & originalImage)
The values of image "originalImage" rotated about PI/2 rad and shifted to have the original upper-left corner and are saved into this image.

void Rotate180(const ImageC<ByteGreyValueT> & originalImage)
The values of image "originalImage" rotated about PI rad and shifted to have the original upper-left corner and are saved into this image.

void Rotate270(const ImageC<ByteGreyValueT> & originalImage)
The values of image "originalImage" rotated about 3/2*PI rad and shifted to have the original upper-left corner and are saved into this image.

ImageC<ByteGreyValueT> Rotate(const Point2dC & center,RealT angle,ByteGreyValueT background) const
The values of this image are rotated about "angle" (in rad) and saved to the result image.
Note the AMMA convention that the 1st or "x" coordinate of Point2dC is associated with the image row no., and the 2nd or "y" coordinate with the image column no.

void Rotate(const ImageC<ByteGreyValueT> & originalImage,const Point2dC & center,RealT angle,ByteGreyValueT background)
The values of image "originalImage" rotated about "angle" rad are saved into this image.
Note the AMMA convention that the 1st or "x" coordinate of Point2dC is associated with the image row no., and the 2nd or "y" coordinate with the image column no.

void ShiftRowIndexes(const IndexT offset)
Row indices of the items will be shifted by "offset".
There must be only one reference to this image.
For +ve "offset", the image is shifted down, or the coordinate system is shifted up.

void ShiftColIndexes(const IndexT offset)
Column indices of the items will be shifted by "offset".
There must be only one reference to this image.
For +ve "offset", the image is shifted down, or the coordinate system is shifted up.

ImageC<ByteGreyValueT> Subsample(IntT factor = 2) const
returns an image subsampled by a factor of "factor"

void SetOrigin(const PixelC & newOrigin)
The image coordinates are changed so that the top left pixel will have coordinates of "newOrigin".
There must be only one reference to this image.

Grey level operations.


ImageC<ByteGreyValueT> & Fill(ByteGreyValueT value)
Fills the image with "value"

ImageC<ByteGreyValueT> & Frame(ByteGreyValueT value)
Fills a 1-pixel-wide border around the image with "value"

ImageC<ByteGreyValueT> & Frame(ByteGreyValueT v,const ImageRectangleC & rect)
Fills a 1-pixel-wide rectangle with "v";
the rectangle is the intersection of "this" with "rect".

ImageC<ByteGreyValueT> Pad(const ImageRectangleC & rect) const
Creates a new image whose frame is from "rect", with pixels copied from "this".
Where the new image lies outside "this", it is padded out with the nearest value from "this".

Logical conditions.


BooleanT IsValid() const
Returns FALSE if the image does not have a valid data area allocated

Access to pixels values.


const RangeBufferAccessC<ByteGreyValueT> operator[](IndexT r) const
Access to the row of the row of pixels.

RangeBufferAccessC<ByteGreyValueT> operator[](IndexT r)
Access to the row of the row of pixels.

ByteGreyValueT & operator[](const Index2dC & pxl)
Returns the content of the pixel.

const ByteGreyValueT & operator[](const Index2dC & pxl) const
Returns the content of the pixel.

ByteGreyValueT & operator[](const PixelC & pxl)
Returns the content of the pixel.

const ByteGreyValueT & operator[](const PixelC & pxl) const
Returns the content of the pixel.

const ByteGreyValueT * CRow(PixelIndexT row) const
Access to the beginning of the row, eg. t
The returned pointer points to the first pixel of the "row".

ByteGreyValueT * Row(PixelIndexT row)
Access to the beginning of the constant "row"
I.e. the returned pointer points to the first pixel of "row".

void Save(ostream & outS,BooleanT useHeader = TRUE) const
Saves templated image to stream.
For byte images it will save them in either PGM or PPM binary format. For other types it will save them in ascii if a suitable stream operator has been written for the templated class. NB. These treat images of ByteGreyValueT specialy, the image values are read as numbers not as charactors.

void Load(istream & outS,BooleanT useHeader = TRUE)
Loads templated image type from ascii stream.
Should not be used for binary PGM/PPM files, but should work on most templated types. NB. These treat images of ByteGreyValueT specialy, the image values are written as numbers not as charactors.

ByteGreyValueT ** StartAddress() const
Returns the pointer to the table of pointers to image.
This being public is really only a hack! EXPERTS ONLY!

BufferRC<ByteGreyValueT> & Buffer()
Access buffer where data is stored.

const BufferRC<ByteGreyValueT> & Buffer() const
Access buffer where data is stored.

#include "amma/BasImage.hh"
const ImageRectangleC & Rectangle() const
Returns the image rectangle.

const Index2dC & Origin() const
Returns the upper-left pixel coordinates of the image rectangle.

const Index2dC & End() const
Returns the lower right pixel coordinates of the image rectangle.

const ImageFileInfoC & ImageFileInfo() const
Access to the origin.

const BaseImageC & BaseImage() const
access to the constant object

BaseImageC & BaseImage()
access to the object
Modification of the object --------------------------

void SetRowSubRange(const IndexT newMin,const IndexT newMax)
The range of indexes of the array will be constrained

void SetColSubRange(const IndexT newMin,const IndexT newMax)
The range of indexes of the array will be constrained.

void SetSubRange(const ImageRectangleC & range)
Constrains the domain of the image.

void SetFullRectangle()
Sets the working rectangle to be allocated rectangle of the image.

void SetImageFileInfo(ImageFileInfoC * newInfo)
Sets a new image file information respecting the current size of the image.

BooleanT IsEmpty() const
Returns TRUE if the image has zero size

void ErrDifferentSize(const BaseImageC & image,char * functionName) const
Triggers an error event if this image has different size from `image'.
The functionName should be the name of the function that triggers the error event.

SizeT Rnum() const
Returns number of rows.

SizeT Cnum() const
Returns number of columns.

IndexT TRow() const
Returns the top row index.

IndexT LCol() const
Returns the left side column index.

IndexT BRow() const
Returns the bottom row index.

IndexT RCol() const
Returns the right side column index.

LongIntT Area() const
Returns the area of the image rectangle expressed in number of indexs.

UIntT Count() const
Returns the number of refrences to this object.
NB. The following definition is now obsolete, The value 0 means there is no other reference to this object.

const ImageRectangleC & AllocatedRect() const
Access allocated rectangle.

BooleanT IsBlock() const
Returns TRUE if the image is allocated as one block of memory.

#include "amma/ImageA.hh"
ImageAC * ACopy() const
A physical copy of the image.

ImageAC * AnotherImage() const
Creates a new empty image of the same type and size as this image is.

const ImageRectangleC & Rectangle() const
Returns the working image rectangle.

void ShiftRowIndexes(const IndexT offset)
all indexes of the items will be shift by 'offset'

void ShiftColIndexes(const IndexT offset)
all indexes of the items will be shift by 'offset'

void SetRowSubRange(const IndexT newMin,const IndexT newMax)
the range of indexes of the array will be constrained

void SetColSubRange(const IndexT newMin,const IndexT newMax)
the range of indexes of the array will be constrained

const ImageFileInfoC & ImageFileInfo() const
access to the const origin


Programmer:Charles Galambos, Documentation by CxxDoc: Tue Mar 20 10:48:08 2001