Hi everyone,
currently I’m working on a project that uses a 3D texture as voxel storage. Everything’s working fine so far, but I’d love to optimze my memory usage and since I’m working with GL4.4 anyway I thought I’d give the GL_TEXTURE_SPARSE_ARB extension a try. The extension has been promoted by Cass Everitt (p.34) and Graham Sellers (p.43) multiple times lately, so I hoped I could get it to work too.
Unfortunately I get no result when querying for the virtual page sizes as described in the presentations.
While
glGetIntegerv(GL_MAX_SPARSE_3D_TEXTURE_SIZE_ARB, &maxSize)
returns the expected 2048.
I don’t get any number of indices from these…
glGetInternalformativ(GL_TEXTURE_3D, GL_NUM_VIRTUAL_PAGE_SIZES_ARB, GL_RGBA8, sizeof(GLint), &numSizes);
glGetInternalformativ(GL_TEXTURE_3D, GL_VIRTUAL_PAGE_SIZE_X_ARB, GL_RGBA8, numSizes*sizeof(GLint), pageSizesX);
I also tried GL_TEXTURE_2D instead, as used in the slides - the result is no different.
Cass Everitt writes
Note: numIndexes can be 0, so have a plan
Iterate, select suitable pageSizeIndex
so, question is…what to do? This sounds like the extension could still work on my HW and drivers, but I’d need to guess the proper virtual page size index I’d want to use.
Has anybody worked with this yet and knows the page sizes (for Nvidia)? I hope it’s just a driver issue on windows…
Thanks in advance on any input on this issue
PS: GPU is a GTX780, driver is the latest 335.23, OS win8.1