I'm trying to solve the following problem. I got a "low frequency" input 2D signal over a square region. I'll collect a few samples, somewhere around 10-30 maybe, the exact sample count will be dynamic. Then I want to compress this to much less data and later reconstruct the square representation. The compression will only occur once but the decompression multiple times. Performance is essential. So I need a method that compress fast, but decompress faster and to a compact format so the data transfer won't become the bottleneck.
The actual application: It's for real-time computer graphics processed on a GPU. I compute samples of lighting in a vertex shader. Then the data transfers to a pixel shader where it gets reconstructed. I will accept a certain amount of error as long as the result is "blurry", i.e. no sharp artifacts. Also transcendental functions are somewhat slow on a GPU (even though a slim transcendental representation will beat any verbose solution ofc)
I've been thinking about several methods. Maybe something fourier based. I could use a standard fourier series in its power series form, e^i(mx+ny) but that would require n^2-1 params to be handled right? Does it exist some basis function that's less verbose in 2D? Or in general more suited for this kind of thing?
Maybe I could do something related to curve fitting (plane fitting). Or maybe something completely different altogether. Anyone with a suggestion?