I'm working with an argb matrix, and would like to convert it into a single plane matrix, mapping rgb to xyz. I am attempting to fill a jitter matrix with 3D voronoi (similar to jit.bfg), but on the GPU.
I have gone down a few different paths in working on this:
First of all, I imagine that I could take a [jit.matrix 4 char 512 512] and remap RGB->XYZ, into a [jit.matrix 1 char 64 64 64]. Both should have an equivalent amount of data, but so far I have not found a way to remap the planes to match the new dimensions.
Next, and something I know far less about, I am finding information about 3D textures in OpenGL. I imagine something like this:
[jit.matrix 1 char 64 64 64] -> [jit.slab @file 3dVoronoi.jxs] -> [jit.matrix 1 char 64 64 64]
So far, I have not figured out how to utilize 3D texture coordinates, and even then, I can't seem to send a 3D matrix to a slab, and then read back into a 3D matrix.
Does anybody have some guidance on this, or some references that I could be pointed towards?