Flickering when screen sharing in web meeting

This forum can be used to talk about general design strategies, new ideas and questions in general related to wxWidgets. If you feel your questions doesn't fit anywhere, put it here.
Post Reply
giuse
Earned a small fee
Earned a small fee
Posts: 16
Joined: Wed Jul 29, 2020 9:11 pm

Flickering when screen sharing in web meeting

Post by giuse »

Hello everyone,

I have the following problem: I developed and app using wxWidgets and it works perfectly, however, when I share the app in some web meeting applications it starts flickering. Does anyone know the cause of this behaviour?

many thanks
User avatar
doublemax
Moderator
Moderator
Posts: 19115
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: Flickering when screen sharing in web meeting

Post by doublemax »

I've never heard about something like this.

Do you have this effect only with wxWidgets applications?
Does it also happen with all of the wxWidgets samples?
What does your application display? Standard controls or custom drawing with a paint event handler?
Use the source, Luke!
giuse
Earned a small fee
Earned a small fee
Posts: 16
Joined: Wed Jul 29, 2020 9:11 pm

Re: Flickering when screen sharing in web meeting

Post by giuse »

Hello,

thank you for the answer.
It seems that the strange flickering appears only with my custom application. Other applications behave as expected, no flickering.

My application is a sort of CAD application with a main frame which has a ribbon and a wxSplitterWindow with many controls inside. Morever, inside the splitter window there is a graphic area where geometrical elements are displayed. In my application there is no paint event handler.
I tried to make several tests but without effect, at each screen sharing, the application starts flickering.
I don't know how to solve...
The main frame has only an OnIdle and an OnSize functions (I could imagine that these could be related to flickering), but my tests on these functions had no positive results.

void MainFrame::OnSize(wxSizeEvent& evt)
{
evt.Skip();
}

void MainFrame::OnIdle(wxIdleEvent& event)
{
//event.Skip();
}

Do you have any suggestions or test I could do to try to solve this issue?

many thanks
User avatar
doublemax
Moderator
Moderator
Posts: 19115
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: Flickering when screen sharing in web meeting

Post by doublemax »

Morever, inside the splitter window there is a graphic area where geometrical elements are displayed. In my application there is no paint event handler.
If there is no paint event handler, how do these geometrical elements get displayed? If you use wxClientDC only, that could be the reason.

Is the graphic area the only one that flickers, or is it the whole frame?

When does it flicker? All the time, even if you're not doing anything, or only when the content changes, or only when you resize the window?
Use the source, Luke!
giuse
Earned a small fee
Earned a small fee
Posts: 16
Joined: Wed Jul 29, 2020 9:11 pm

Re: Flickering when screen sharing in web meeting

Post by giuse »

Hello,

well, in fact, I use a 3d geometric library to display the geometrical elements, I do not do that using wxwidgets. Such geometric library is linked to a wxPanel (that is inside the wxSplitterWindow) where the elements are displayed.

The flickering happens especially when I'm not doing nothing and it is not continuous (I mean it does not have always the same frequency). Moreover, the frequency of flickering increases when more controls are present (the left side of the wxsplitterwindow is popolated by differents controls depending on the action the user want to carry out: he presses a button and the controls related to the button function appear on the left side of the wxSplitterWindow). If I conitnuosly move the mouse the flickering seems to disappear. Even if I disable the graphic panel (i.e I create an empty panel with no link to the geometric library or any other control), the flickering od the controls on the left side of the wxSplitterWindow is still present.

The only thing that never gets flickering is the ribbon. The flickering elements are the controls inside the splitter window (both the controls on the left and the panel on the right of the wxSplitterWindow).
User avatar
doublemax
Moderator
Moderator
Posts: 19115
Joined: Fri Apr 21, 2006 8:03 pm
Location: $FCE2

Re: Flickering when screen sharing in web meeting

Post by doublemax »

This is a complete mystery to me, especially that the controls flicker if you're not doing anything. Can you try with some of the samples that come with wxWidgets, e.g. the "widgets" one?

BTW: What OS are you running?

As a desperate, wild guess i would try to call wxWindow::SetDoubleBuffered(true) on the mainframe or some of the background panels. Although i really don't expect that to make any difference.

Could you make a video of the flickering? Maybe seeing the effect triggers a new idea.
Use the source, Luke!
ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 7459
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: Flickering when screen sharing in web meeting

Post by ONEEYEMAN »

Hi,
Are you using OpenGL? Or something else?
Can you build and run opengl samples that provided by wxWidgets (all of them) and try them in your flickering environment?
What kind of screen sharing app you are using? Is it a latest version?
Is the other machine has a HiDPI display? Is you software is DPI-aware?

Thank you.
giuse
Earned a small fee
Earned a small fee
Posts: 16
Joined: Wed Jul 29, 2020 9:11 pm

Re: Flickering when screen sharing in web meeting

Post by giuse »

hello,

sorry for the long time, and thank you for your interest in my problem.

Well, I'll try to answer to all your questions in the best way:

- I'm using windows 10;
- my app is dpi aware;
- I tried to set wxWindow::SetDoubleBuffered(true) and some changes happened: in particular, putting it in the main frame seems to stop the flickering of the controls but not of the graphic area. However, setting wxWindow::SetDoubleBuffered(true) in the main frame or even in the raphic area freezes the graphic area itself that becomes slow and sticky (when you try to pan or rotate the object), but but the flickering still happens;
- The flickering happens especially when you share the precise window of the application and not the whole desktop. It seems that it happens with the most common web meeting applications. The flickering happens on my side (and the other persn sees it as well);
- I'm using Opencascade as graphic library which has its own opengl viewer.

I'll be more precise and give more info as soon as possible, I'll make some other tests; in the mean time I hope you can have some new ideas to try!
thank you again for your support
J21Jastreb
In need of some credit
In need of some credit
Posts: 2
Joined: Fri Sep 25, 2020 4:40 pm

Re: Flickering when screen sharing in web meeting

Post by J21Jastreb »

What's the configuration of your computer? I don't see what could be wrong with the program, so it could be a hardware issue.
ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 7459
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: Flickering when screen sharing in web meeting

Post by ONEEYEMAN »

Hi,
Please try to post on the wx-users ML.
This forum is for users of the library. Core wx development are not coming here.

Make sure you see the same thing with minimal sample.

Thank you.
Post Reply