Function lsst::afw::math::makeWarpingKernel

Function Documentation

std::shared_ptr<SeparableKernel> lsst::afw::math::makeWarpingKernel(std::string name)

Return a warping kernel given its name.

Intended for use with warpImage() and warpExposure().

Allowed names are:

A warping kernel is a subclass of SeparableKernel with the following properties (though for the sake of speed few, if any, of these are enforced):

  • Width and height are even. This is unusual for a kernel, but it is more efficient because if the extra pixel was included it would always have value 0.

  • The center pixels should be adjacent to the kernel center. Again, this avoids extra pixels that are sure to have value 0.

  • It has two parameters: fractional x and fractional row position on the source image. The fractional position is the offset of the pixel position on the source from the center of a nearby source pixel:

    • The pixel whose center is just below or to the left of the source position: 0 <= fractional x and y < 0 and the kernel center is the default (size-1)/2.

    • The pixel whose center is just above or to the right of the source position: -1.0 < fractional x and y <= 0 and the kernel center must be set to (size+1)/2.