0

How can change GLCapabilities of an existing GLCanvas?

I want to do this so that I can change FSAA (antialias) samples without recreating the GLCanvas.

Jire
  • 9,680
  • 14
  • 52
  • 87

1 Answers1

4

You cannot. The nature of the default framebuffer is defined at context-creation time. It cannot be changed without destroying and re-creating the context.

Your best bet is to use FBOs and do your rendering to user-created images, then blit to the default framebuffer. That way, if you want to change your anti-aliasing techniques, you can do so without rebuilding the context.

Nicol Bolas
  • 449,505
  • 63
  • 781
  • 982
  • You're right and I confirm that JOGL doesn't allow to use another GLCapabilities instance with a GLAutoDrawable. – gouessej Oct 13 '17 at 11:48