I’m a little confused about how you work with multiple texture objects.
If I create several texture objects using;
URL url = c1.getResource( “com/thinkastronomy/galaxyin3d/star.gif” );
starTexture = TextureIO.newTexture( url, false, “gif” );
url = c1.getResource( “com/thinkastronomy/galaxyin3d/Spitzer_Color_Texture.jpg” );
galaxyTexture = TextureIO.newTexture( url, false, “jpg” );
url = c1.getResource( “com/thinkastronomy/galaxyin3d/particle.png” );
particleTexture = TextureIO.newTexture( url, false, “png” );
What I don’t understand is when to call texture.bind() and texture.enable() or texture.disable() when using these.
I’ve tried binding them right before use, but this sometimes gives the wrong texture being used. If I call enable() after the bind() I sometimes get nothing at all drawn. Can someone give me the rules for how to intersperse different textures when drawing?
url = c1.getResource( "com/thinkastronomy/galaxyin3d/GalacticCore-2.png" );
coreTexture = TextureIO.newTexture( url, false, "png" );