<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">
</div>I am. The merger shouldn't process empty rects. Unless you want to argue that the merger never should get empty rects in the first place: but even then, the merger should stop processing if it gets an empty rect.<br>
</blockquote><div><br>Well, KisBaseRectsWalker checks for the emptiness of the rect and removes empty jobs. But this case is not covered by this check, because applyRect in KisUpdateOriginalVisitor is a calculated value and is not available during preparational stage in KisBaseRectsWalker.<br>
<br>So, of course, we should check for the emptiness somewhere. And, currently, we check this in filters. I don't think we should check this twice.<br><br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
It would be good to try and fix all filters so they handle empty rects by returning without doing anything. However, that is something completely separate from making sure the merger doesn't try to merge empty rects.<br clear="all">
</blockquote></div><br>Well, currently, all the filters should work with empty areas fine, because all of them use (or should use) iterators. If they don't, they are broken. Async merger relies on the guarantee, that the filter (at least) will not crash when the area is empty. I don't see any reason in moving the guarantee to the level of the caller, because in such a case we will have to fix all the code calling filters to make our system consistent.<br>
<br>-- <br>Dmitry Kazakov<br>