libretro/RetroArch — pull request #674 by TroggleMonkey (2014-05-08 19:29:18+00:00)
Title: LUT texture filtering improvements, etc.

Hey Squarepusher,
This is the mipmapping support we talked about on IRC. The first commit message is pretty self-explanatory, but there are two things you might want to glance at just in case I screwed something up:

First, check out line 58 of shader_common.c. The original LUT loading code for GLSL only generated a single texture handle, whereas the code for Cg generated one for each LUT as expected. I'm assuming that was just a bug in the GLSL code, so I fixed it in the refactored code, but if there was a good reason for it, the new function will have to be tweaked accordingly.

Second, I eliminated the MAX_LUT_TEXTURES macro from shader_cg.c and used GFX_MAX_TEXTURES in its place, which is what shader_glsl.c used. I'm assuming MAX_LUT_TEXTURES was just an unnecessary duplicate macro for the same conceptual value, but I wanted to bring it to your attention in case I'm mistaken.