← Back to team overview

kicad-developers team mailing list archive

Re: 3D-Viewer - Request for merge evaluation

 

Le 21/06/2016 à 12:01, Mário Luzeiro a écrit :
> Interesting findings. I will try on my systems and see if that still works ok for me.
> 
> Still it puzzles me as you told it was when you switch between render targets, but the "entry
> point" of the render targets is the same, basically it just switch between OpenGL
> functions/implementation, so it should now be related with Paint events.. but. somehow..

In fact, it can be not really related.
It happens also when rotating the board from toolbar icons (but not every time).

What helped me to find something in OnPaint method which creates this issue is the fact the screen
was redrawn (after it freezes) when forcing some paint events (like iconize/uniconize the 3D frame)

> 
> Orson: Was that something that Orson could experienced before? I was checking the GAL, it still
> has a "wxPaintDC dc(this);" but don't has an "event.Skip( false );"
> 
> Mario
> 
> ________________________________________ From: jp charras [jp.charras@xxxxxxxxxx] Sent: 21 June
> 2016 10:40 To: Mário Luzeiro; kicad-developers@xxxxxxxxxxxxxxxxxxx Subject: Re:
> [Kicad-developers] 3D-Viewer - Request for merge evaluation
> 
> Le 21/06/2016 à 10:41, Mário Luzeiro a écrit :
>> Hi JP,
>> 
>> I was comparing your build with mine, the big differences are Windows 7 32vs64bits and
>> wxWidgets 3.0.2 vs 3.1
>> 
>> I tried to update wxWidgets on msys2 but it says they are updated. How do I update mine to
>> 3.1?
>> 
> 
> the 3.1 version is built by myself, from sources.
> 
> I am not sure it makes difference with 3.0.2.
> 
> I fixed the display freeze by slightly modify the EDA_3D_CANVAS::OnPaint( wxPaintEvent &event )
> method:
> 
> I removed: event.Skip( false ); (not useful) and wxPaintDC( this ); This is when deleting this
> line i do not have any freeze.
> 
> In OpenGL samples, you can see wxPaintDC pdc( this ) in paint events, but now I am thinking it
> is not needed and can (and perhaps must) be removed (I am thinking the associated comments are
> very old) at least in wxWdgets 3.0
> 
> Moreover, in wxWidgets compiled with GTK3, in the EDA_3D_CANVAS::OnPaint(), I have an assert
> error for wxPaintDC pdc( this ) (wxPaintDC not allowed in non native Paint events).
> 
> Therefore I think now wxGLCanvas::OnPaint() in a special case, and does not need a wxPaintDC 
> declaration.
> 



-- 
Jean-Pierre CHARRAS


References