I'm trying to write a jit.gen patch to resample an input matrix based upon cell addresses contained within a plane of the matrix itself. For example, the matrix has two planes, the first is data, the second is a target cell address. Cell 0 contains value 65 and a target address of 10. The gen patch should look at the second plane and move the data value to this cell address in the output matrix.
It seems the 'sample' object can only select cells from an incoming matrix. Is there a way to do a 'reverse sample' and select a cell in the output matrix to be written to rather than processing them in order?