MPSImageGaussianPyramid(3) MetalPerformanceShaders.framework MPSImageGaussianPyramid(3)

MPSImageGaussianPyramid

#import <MPSImageConvolution.h>

Inherits MPSImagePyramid.

The Gaussian image pyramid is constructed as follows: First the zeroth level mipmap of the input image is filtered with the specified convolution kernel. The default the convolution filter kernel is

k = w w^T, where w = [ 1/16,  1/4,  3/8,  1/4,  1/16 ]^T,


but the user may also tweak this kernel with a centerWeight parameter: 'a':

k = w w^T, where w = [ (1/4 - a/2),  1/4,  a,  1/4,  (1/4 - a/2) ]^T


or the user can provide a completely custom kernel. After this the image is downsampled by removing all odd rows and columns, which defines the next level in the Gaussian image pyramid. This procedure is continued until every mipmap level present in the image texture are filled with the pyramid levels.

In case of the Gaussian pyramid the user must run the operation in-place using: inPlaceTexture:fallbackCopyAllocator:, where the fallback allocator is ignored.

Generated automatically by Doxygen for MetalPerformanceShaders.framework from the source code.

Mon Jul 9 2018 Version MetalPerformanceShaders-119.3