On 28 March 2013 14:28, Tristan Bourgois <tristan.bourg...@gmail.com> wrote: > 2013/3/28 Igor Stasenko <siguc...@gmail.com>: >> On 28 March 2013 12:05, Tristan Bourgois <tristan.bourg...@gmail.com> wrote: >>> Hi! >>> >>> I try to optimize the graphic framework I'm porting. >>> I have good performance but I have some problem to reDraw the morph of my >>> view. >>> >>> When I reDraw my morph I use 'invalidRect:' with the bound of the part >>> I want to reDraw but every step my morph is entirely reDraw. >>> >>> Does I have to use another method? Or someone can explain me how pharo >>> manage the repaint of morph? >>> >> The thing you looking for called clipping. >> Usually (and if possible) morph should try and detect what parts of his >> drawing >> needs to be updated and update only minimum part covered by clipping region. >> But that implies some internal knowledge about morph's geometry etc.. >> and that's why a default implementation simply (re)draws everything. >> > Ok I simulate the clip in updating my canvas with 'copyClipRect: myClip' > This is functional and improve a LOT the performance :) > > I juste have to make some refactoring with some event and animation > which have some bad behavior for the redrawing > and I have to see if copyClipRect: is not a bad method to use. > >>> Thanks :) >>> >>> I will ask today if I can make a video of my work because is very >>> impressive of what we can do on Pharo with the framework! >>> >> Please do. >> >>> And if the reDraw is functional we certainly have the same performance >>> with Pharo! >>> >> Come to see me and we will look how we can optimize it :) > > For the moment it's a bit difficult to ask help for the framework > because it's a Thalès license...
i just offering my help. you (or your boss) are free to reject it , of course.. for whatever reason :) > I work with my tutor to make a part of the framework as open-source > and add it to Pharo but I need to show that Pharo it's so cool and > performant and actually it's work ;) > > I'm optimist :) > > -- Best regards, Igor Stasenko.