Le 09/06/2012 21:05, Adrien Prokopowicz a écrit :
> Le samedi 9 juin 2012 20:45:49 Benoît Minisini a écrit :
>> Le 09/06/2012 19:41, Adrien Prokopowicz a écrit :
>>> Hi all,
>>>
>>> in my project I have a cached DrawArea that I need to redraw each time it
>>> is resized. My code is like this :
>>>
>>> Public Sub RefershDrawArea()
>>>
>>>     Draw.Begin($drawArea)
>>>
>>>     'Drawing methods here ...
>>>
>>>     Draw.End
>>>
>>> End
>>>
>>> That works perfectly, but when I launch the profiler, he tells me that the
>>> Draw.Begin() method takes a lot of time (around 20 ms).
>>>
>>> Is there a way to make this call faster ? Or maybe a way to do only one
>>> call to Begin() when the user starts resizing and to End() when it stops
>>> ?
>>>
>>> Regards,
>>> Adrien.
>>
>> Please provide a project that shows that!
>
> Here is a little test project.
>
> And I just noticed that there isn't this problem with gb.gtk. So for me it's a
> bug in gb.qt4.
>

On my machine, Draw.Begin with gb.gtk takes about 120 micro-seconds the 
first time it is called, 50 us the next times. With gb.qt4, it takes 
about 300 us each time.

So I don't understand how it could take 20 ms on your machine: it means 
that my PC is 66x faster than yours!

-- 
Benoît Minisini

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to