Login  Register

When switching the tab of toolwindow, the GLCanvas in Swing JPanel flickers

classic Classic list List threaded Threaded
4 messages Options Options
Embed post
Permalink
Reply | Threaded
Open this post in threaded view
| More
Print post
Permalink

When switching the tab of toolwindow, the GLCanvas in Swing JPanel flickers

wiuyouke
2 posts
Hello,

When switching the tab of toolwindow, the canvas flickers.

I’m trying to build a GLCanvas in Swing JPanel, but I have a problem to switch toolwindow tab, the CLCanvas is flickering(the content of the entire screen is displayed on the canvas, and it disappears quickly)

The development scenario is to use IDEA(Intellij) for development under the window platform.

we try to inserting the following line into your main() method:

System.setProperty("sun.awt.noerasebackground", "true");

But it didn't take effect.

Please help us, Thanks.

        wuyouke
Reply | Threaded
Open this post in threaded view
| More
Print post
Permalink

Re: When switching the tab of toolwindow, the GLCanvas in Swing JPanel flickers

gouessej
Administrator
6038 posts
Hello

Have you tried with a GLJPanel instead of a GLCanvas?
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
| More
Print post
Permalink

Re: When switching the tab of toolwindow, the GLCanvas in Swing JPanel flickers

wiuyouke
2 posts
yes,  we use GLJpanel to solve this problem on windows, but not on Linux. And GLJPanel will report errors, draws slower in Linux.
Reply | Threaded
Open this post in threaded view
| More
Print post
Permalink

Re: When switching the tab of toolwindow, the GLCanvas in Swing JPanel flickers

gouessej
Administrator
6038 posts
Which errors? Maybe I have a possible workaround for that.
Julien Gouesse | Personal blog | Website