For trilinear filtering, we need to implement another lerp function across two level of detail.The final D should be (ceil(D)−D)∗floor(D)+(D−floor(D))∗(ceil(D))(ceil(D)-D)*floor(D)+(D-floor(D))*(ceil(D))(ceil(D)−D)∗floor(D)+(D−floor(D))∗(ceil(D))
For trilinear filtering, we need to implement another lerp function across two level of detail.The final D should be (ceil(D)−D)∗floor(D)+(D−floor(D))∗(ceil(D))