Saturday, September 11, 2010

Krita: Free Scrolling and Masks improvements

Hi, All!

Last week I was working on fixing one of the most reported bugs of Krita. Many users wanted to scroll the canvas in a way to see corners of the image in the center of the screen. Now it is easily possible. More than that, coupled with the ability to zoom and pan image with the wheel, Free Scrolling makes the workflow very smooth. I think people who ever used CAD systems would feel something like deja vu, when try it ;)

Another task of mine was to fix Masks updates, because they curiously broke after i activated multithreading. I've spent about 9 hours searching race conditions and all, but the problem appeared to be trivial. There was a legacy code that wasn't ported when move() feature of paint device appeared. It caused clear() operations clear wrong areas. Everything was fine in single-threaded environment, because those areas were overwritten immediately. But in multithreaded case, those operations broke usage-guarantees of the data manager (that is we must not access intersecting areas simultaneously, but must work with independent areas instead). Broken guarantees, in their turn, led to race conditions during update. You can see how trivial the fix was [1], but it was really tough to find :)

[1] - http://websvn.kde.org/?view=revision&revision=1174365

Photobucket

3 comments:

  1. THANKS a bunch for your work on Krita.

    Krita 2.3 is shaping up very well ;-)

    ReplyDelete
  2. I like that grenouille you painted.

    ReplyDelete

Followers