Status of com.sun.opengl classes?

From what I have read ‘com.sun’ classes should be treated as classes which may have their API change at any time, without respect for backwards compatibility, and therefore should be avoid where possible. Does the same go for the ‘com.sun.opengl’ classes? Will these be migrated to javax at some point in time?

The rule about their API changing at any time holds; this is why these classes aren’t in the JSR-231 spec.

However, I disagree with the conventional wisdom that these classes should be avoided where possible. This advice holds true if you’re relying on implementation details of the underlying JDK, because different vendors release different JDKs and the com.sun.* APIs might not be present on one vendor’s JDK. However, JOGL is an extension which is deployed along with the application (via Java Web Start, for example) and so you can settle on one particular version of JOGL when deploying your app, and you’re guaranteed that it isn’t going to change out from under you. Therefore I don’t think that advice applies in this case. Plus, there is a lot of useful functionality in the com.sun.opengl.* classes like the Texture classes and TextRenderer. We aren’t ready to put these in the spec as they are still evolving; for example, an incompatible but necessary change to the TextRenderer’s RenderDelegate was just checked in last night.