LWJGL and SWT

Started by DanDanger, July 27, 2006, 17:38:14

Previous topic - Next topic

DanDanger

Hellos,

Got a bit of a problem I was hoping i could get some help with:

I am building a 3d package using SWT + LWJGL.
The package has your standard 4 windows onto the world, each of which is a canvas using LWJGL. However... each canvas appears to have its own openGL context, so I cannot share display lists and textures between them.

Is is possible to have my 4 windows share the same openGL context? Or is there a better way of having the mutiple windows?

Any help would be appreacieated ^_^

Fool Running

There is a constructor for AWTGLCanvas (I assume this is what you are using):
AWTGLCanvas(java.awt.GraphicsDevice device, PixelFormat pixel_format, Drawable drawable)

Give the canvas with the context you want to share to this constructor as the last parameter (drawable).
I think that's how contexts are shared (someone correct me if I'm wrong :lol: )
Programmers will, one day, rule the world... and the world won't notice until its too late.Just testing the marquee option ;D

DanDanger

Im using SWT not AWT, so that wont work unfortunately.

Fool Running

Well then I have no idea, unfortunatly :cry:

anyone else can chime in here :lol:
Programmers will, one day, rule the world... and the world won't notice until its too late.Just testing the marquee option ;D