I have a block of memory on the device organized as several 10000-element arrays, arranged back to back in memory. You might visualize the arrangement as follows:
A0 A1 A2 … A10000
B0 B1 B2 … B10000
C0 C1 C2 … C10000
I would like to build a 1D texture on top of each array (A,B,C etc). I understand that the correct way to do this is to create a layered texture.
The trouble is that all the examples I have found in the Programming Guide, and in the SDK, start by creating a 3D Array on the host, then copying it to the device. The trouble is my data is already on the device. It is actually produced on the device. It would be wasteful to copy the data back to the host, build the texture, and then send it back to the device.
Is there any way to create a layered texture on data that already resides on the device? If so, can you please explain the process?