digiKam
Digikam::LensDistortionPixelAccess Class Reference

Public Member Functions

 LensDistortionPixelAccess (DImg *srcImage)
 
void pixelAccessGetCubic (double srcX, double srcY, double brighten, uchar *dst)
 
 ~LensDistortionPixelAccess ()
 

Protected Member Functions

void cubicInterpolate (uchar *src, int rowStride, uchar *dst, bool sixteenBit, double dx, double dy, double brighten)
 
uchar * pixelAccessAddress (int i, int j)
 
void pixelAccessDoEdge (int i, int j)
 
void pixelAccessReposition (int xInt, int yInt)
 
void pixelAccessSelectRegion (int n)
 

Detailed Description

LensDistortionPixelAccess class: solving the eternal problem: random, cubic-interpolated, sub-pixel coordinate access to an image. Assuming that accesses are at least slightly coherent, LensDistortionPixelAccess keeps LensDistortionPixelAccessRegions buffers, each containing a LensDistortionPixelAccessWidth x LensDistortionPixelAccessHeight region of pixels. Buffer[0] is always checked first, so move the last accessed region into that position. When a request arrives which is outside all the regions, get a new region. The new region is placed so that the requested pixel is positioned at [LensDistortionPixelAccessXOffset, LensDistortionPixelAccessYOffset] in the region.

Constructor & Destructor Documentation

◆ LensDistortionPixelAccess()

Digikam::LensDistortionPixelAccess::LensDistortionPixelAccess ( DImg srcImage)
explicit

◆ ~LensDistortionPixelAccess()

Digikam::LensDistortionPixelAccess::~LensDistortionPixelAccess ( )

Member Function Documentation

◆ cubicInterpolate()

void Digikam::LensDistortionPixelAccess::cubicInterpolate ( uchar *  src,
int  rowStride,
uchar *  dst,
bool  sixteenBit,
double  dx,
double  dy,
double  brighten 
)
protected

Referenced by pixelAccessGetCubic().

◆ pixelAccessAddress()

uchar * Digikam::LensDistortionPixelAccess::pixelAccessAddress ( int  i,
int  j 
)
inlineprotected

◆ pixelAccessDoEdge()

void Digikam::LensDistortionPixelAccess::pixelAccessDoEdge ( int  i,
int  j 
)
protected

◆ pixelAccessGetCubic()

void Digikam::LensDistortionPixelAccess::pixelAccessGetCubic ( double  srcX,
double  srcY,
double  brighten,
uchar *  dst 
)

◆ pixelAccessReposition()

void Digikam::LensDistortionPixelAccess::pixelAccessReposition ( int  xInt,
int  yInt 
)
protected

◆ pixelAccessSelectRegion()

void Digikam::LensDistortionPixelAccess::pixelAccessSelectRegion ( int  n)
protected

Referenced by pixelAccessGetCubic().


The documentation for this class was generated from the following files: