Intel® Integrated Performance Primitives (Intel® IPP) Developer Guide and Reference

ID 790148
Date 6/24/2024
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

Trilinear Interpolation

The trilinear interpolation is slower but more accurate than the 3D neighbor interpolation. It is also faster but less accurate than the tricubic interpolation. The trilinear interpolation algorithm uses source image intensities at the eight pixels: (xs0, ys0, zs0), (xs0, ys0, zs1), (xs0, ys1, zs0), (xs0, ys1, zs1), (xs1, ys0, zs0), (xs1, ys0, zs1), (xs1, ys1, zs0), (xs1, ys1, zs1) that are the closest to (xs, ys, zs) in the source image:

also with the conditions:

First, the intensity values are interpolated along the x-axis to produce four intermediate results I0, I1, I2, I3 :

Second, the intensity values are interpolated along the y-axis using  the intermediate value I0, I1, I2, I3:

Then, the sought-for intensity D(xD, yD, zD) = T0 (zs1-zs) + T1(zs-zs0)

To use the linear interpolation, set theinterpolation parameter to IPPI_INTER_LINEARor use the functions with the Linear suffix (passinterpolation = ippLinear to GetSize  functions).

To visualize the operation of the algorithm, look at the Linear interpolation page .