LWJGL Forum

Programming => Lightweight Java Gaming Library => Topic started by: rainforest on October 17, 2005, 17:44:04

Title: Extral Panel
Post by: rainforest on October 17, 2005, 17:44:04
Dear LWJGL programmers

Is there any way that we could make extra panel in the lwjgl window. I ve tried to find a frame to split it into more panels but there seem to be no frame on that the lwjgl is drawing. Any suggestions will be helpful.

Thank you.
rainforest.
Title: Extral Panel
Post by: princec on October 17, 2005, 18:36:17
What do you mean, an extra panel?

Cas :)
Title: Extral Panel
Post by: tomb on October 17, 2005, 21:10:10
LWJGL don't use AWT (on windows), so there is no java.awt.Frame.
Title: I mean
Post by: rainforest on October 18, 2005, 00:52:26
I mean I want to split the frame say in two equal portion. In one portion I 'll render my drawing (models, billboards, terrain etc) and in other portion I'll display links or images relevant to the display content like html.

Is that possbile in lwjgl?

rainforest.
Title: hmmmm...
Post by: Fool Running on October 18, 2005, 01:50:03
I think you want to use a normal JFrame and use AWTGLCanvas to do the rendering. Thats what I did to make a split view and it worked fine (after you get over the heavy weight component thing :lol: )
Title: confucious
Post by: rainforest on October 18, 2005, 16:24:16
Dear Fool Running

I wonder if u please give me some example of splitting the panel that u've described. It would be better for me to understand if u please mention some code with it?  :)

thank you.''

rainforest.
Title: In addition
Post by: rainforest on October 18, 2005, 16:30:03
Dear programmers

In my program it always stays in windowed mode. But in that case I've to see the title bar also. Is there any way to remove the title bar from the window and I'm still in the windowed mode?  :shock:

My english is really not good. Sorry for that.


rainforest.
Title: Extral Panel
Post by: Matzon on October 18, 2005, 17:31:56
pass -Dorg.lwjgl.opengl.Window.undecorated=true on the commandline
Title: Extral Panel
Post by: Evil-Devil on October 18, 2005, 17:45:58
When using AWTGLCanvas and a (J)Frame, then just use a propriate Layout like BoxLayout to split your Frame. Or take a Slider...but that will result in some extra code work for reacting on the resize stuff.
Title: Extral Panel
Post by: princec on October 18, 2005, 18:05:02
Furthermore, if using AWTGLCanvas inside a Frame you can turn off the native window decorations, I believe.

Cas :)
Title: texture blinking
Post by: rainforest on October 18, 2005, 18:26:39
Dear Matzon

Im so thankful for ur wonderful java argument. It worked just the way I want it to except one problem. The textures that I used in 3d models are flickering or blinking (I don't know exactly which word to use) in this state.
But I don't have the problem in windowed mode with title bar.

Please suggest me something.

rainforest.
Title: I need some example
Post by: rainforest on October 18, 2005, 18:31:04
Dear Cas

Obviously the suggestions are excellent. But as Im a new LWJGL programmer even the suggestions seems difficult to me. Can u please give me some example of using the CANVAS to split up the (J)Frame?

Any code will be helpful for me. :D

rainforest.
Title: Extral Panel
Post by: Evil-Devil on October 20, 2005, 11:51:11
Take a look at the Examples in the LWJGL Source Distribution. They explain the usage very well :)

And if you want to display other SWing Elements above the Canvas, just set the Swing Element to Heavyweight. Than the Swing Element will be shown up on top of the Canvas.