Filters and selections

Michael Thaler michael.thaler at ph.tum.de
Fri Jan 7 10:05:21 CET 2005


Hi,

right now, if a part of an image is selected, the filters still work on the 
whole image (I actually only tried it with the gaussian blur and the invert 
filter). I suppose, the filters should only be applied to the selected 
region.

If I have some time tonight, I would like to change one of the filters (maybe 
the invert, it is probably the easiest one), so that it does respect 
selections. The easiest solution would probably to use the  
iteratorPixelSelectionBegin iterators. Do they actually work? Or is there 
another way to do this?

Another thing comes to mind: for non-rectangular selections, applying filters 
might not work because you often need the neighbour pixels. So it would be 
fine if there would be a method to get the smallest rectangular region 
covered by a selection, apply the filter to that and then replace the 
selected area. Or is there a better way?

Michael


More information about the kimageshop mailing list