Page 1 of 1

Drawing executed but not displayed ???

Posted: Mon Feb 14, 2022 9:50 am
by Joris
Hi,

I have a setup as simplified in the code below here.
The loop blocks, somewhat understandable, also the gadgets (no more mouse clicks possible)
but the drawing to be executed is not displayed even though the code is executed.
What or how should this be done under linux ?
The drawing works perfectly if the loop has been stopped and is again controlled by mouse actions.
(the same code works perfectly under windows) ?

Thanks

Code: Select all

While  maxcount>count
  status=0    
 
  While status<>-#EAGAIN
    status=snd_rawmidi_read(port, @buffer, 1)
    If  status=>0 
      Analyse_Input(buffer, count)
      Do_drawings(buffer)                              ;******** no drawing becomes visible ???
     count+1
    EndIf
   Wend
Wend            

Re: Drawing executed but not displayed ???

Posted: Mon Feb 14, 2022 10:37 am
by mk-soft
On macOS and Linux you can not drawing outside event loop.

Re: Drawing executed but not displayed ???

Posted: Mon Feb 14, 2022 11:29 am
by Joris
mk-soft wrote: Mon Feb 14, 2022 10:37 am On macOS and Linux you can not drawing outside event loop.
It is a separate loop, not the default EVENT loop.

I'll try to do something with the Eventtimer...

Re: Drawing executed but not displayed ???

Posted: Mon Feb 14, 2022 12:08 pm
by Joris
Joris wrote: Mon Feb 14, 2022 11:29 amI'll try to do something with the Eventtimer...
Good job Joris, that does it. :D