1. A method comprising: obtaining, by a computing system, (1) a reference image that was captured by a camera device and (2) a target array, wherein the reference image comprises a plurality of pixels that have respective pixel locations in the reference image and respective color variables, wherein the target array comprises target values, and wherein the target values respectively correspond to the pixels of the reference image; associating, by the computing system, the pixels of the reference image with respective vertices in a vertex space, wherein the vertex space comprises two spatial dimensions and a color-space dimension, wherein the association between the pixels of the reference image and the respective vertices is defined by an association matrix, wherein the association matrix comprises a plurality of values of which fewer than half are non-zero; associating, by the computing system, the target values with the respective vertices with which the pixels of the reference image corresponding to the target values are associated; determining, by the computing system, a vertex cost matrix based on: (1) the association between the pixels of the reference image and the respective vertices, and (2) a degree of similarity between pairs of pixels of the reference image, wherein the degree of similarity between a particular pair of pixels of the reference image is related to a distance between the pixel locations of the particular pair of pixels in the reference image and a distance in the color-space dimension between the color variables of the particular pair of pixels of the reference image; determining, by the computing system, respective vertex fit values for the vertices by solving a linear system defined by the vertex cost matrix and a vertex cost vector; and generating, by the computing system, a filtered output image, wherein the filtered output image comprises pixels that respectively correspond to the pixels of the reference image, wherein generating the filtered output image comprises using the determined vertex fit values of vertices that are associated with the pixels of the reference image as a basis to determine respective pixels of the filtered output image.