I have some code that worked nicely with a JOGL from late 2012. Today I revisited the code and noticed that some simple textured quads had no textures but were rendering as black. Trigger an epic 10h bug hunt in my own code with a few curses and some rants.
The culprit seems to be that AWTTextureIO.newTexture() or TextureIO.newTexture() no longer create mipmaps automatically. The code that worked fine looked like:
The texture was loaded ok and nicely rendered. Today it was black. Note the "true" parameter to AWTTextureIO.newTexture() which according to the docs is supposed to automatically create mipmaps and did with the old JOGL. Now it doesn't and nothing worked before I added:
gl.glGenerateMipmap( GL.GL_TEXTURE_2D );
after loading the texture. If this is intended behaviour then the docs for the parameter could be improved a little bit and the general usefulness of TextureIO is reduced a bit compared to just loading an image and doing the low level OpenGL calls manually.
I didn't report this as a bug as Bugzilla requires registration and I'm not sure it's a real bug (but after my wasted 10h I'd be ready to call it a lot of things that are not safe for sensitive ears and eyes).
I'm such a n00b working with textures so making a test case that actually works (or not in this case) displays a texture would take me ages to do. I can see it in action in my own app by just commenting out the glGenerateMipmap() calls I added.
Re: AWTTextureIO.newTexture() not creating mipmaps
Administrator
In this case, don't start from scratch, reuse an existing testcase. In the worst case, write a bug report with no complete test case, it wouldn't be good :s but better than nothing at all.
Given that it used to work before. Try making your texture base of two and the height=width. For example 512x512, 128x128, but NOT 128x64 or 512x128. Let us know what happens.