Dear all,
I have been doing tutorials from NeHe and I am able to render/load a texture on
a JFrame. Problem is, I am unable to load 2 textures on a JFrame to make them
look "layered". Below is a small portion of my codes:
JFrame frame = new JFrame("VVI Control Panel");
GLCapabilities caps = new GLCapabilities();
caps.setAlphaBits(8);
GLCanvas canvas = new GLCanvas(caps);
canvas.addGLEventListener(new panel());
canvas.addGLEventListener(new CompassFrame());
frame.add(canvas);
frame.setSize(800, 600);
frame.show();
final Animator animator = new Animator(canvas);
//...
The first GLEventListener is set to a size of 800,600 and should appear at the
bottom of both texture.
The second GLEventListener is set to a size of 200,200 and should appear at the
top of both texture to achieve a layered effect.
Yet, the second GLEventListener will always take the size of 800,600 (even
though I've set it to 200,200 in the class file) and appears on the top of both
textures.
Any help will be appreciated as I am stuck at this bottle neck for the past
week...
[Message sent by forum member 'raven_hex' (raven_hex)]
http://forums.java.net/jive/thread.jspa?messageID=325886
===========================================================================
To unsubscribe, send email to [email protected] and include in the body
of the message "signoff JAVA2D-INTEREST". For general help, send email to
[email protected] and include in the body of the message "help".