DXTC Compression and OpenGL3

Has anything with compressed texture formats changed since OpenGL 2.1? I am getting funny results with my DDS loader. I can load uncompressed DDS files, but DXTC 1, 3, and 5 format are not loading correctly. Yes, I am using glCompressedImage2D() for those formats. The DDS files are power-of-two sized.

My code is something like this:

internalformat = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT;

No OpenGL errors are produced.

Here is a demo:

I am testing on an NVidia GEForce 9800 on Windows 7 64-bit with driver 258.96, using OpenGL 3.1. GL 3.3 produces the same results.

Ha, the error was caused by an offset in the data. I’m surprised I didn’t think of that. Everything works perfectly now.