Axel Etzold wrote: > Dear all, > > I have a number of black-and-white scanned pages. To prepare them for OCR, > I have to split them in columns and rows. Additionally, somewhere in between, there > are pictures, which also need to be separated. > > So, in a page that might look like this: > > Text1 Text4 Text6 > > Text2 Pict1 Text7 > > Text3 Text5 Pict2 > > I'd like to find the largest blocks of white which separate the texts and pictures, both horizontally > and vertically. Anthony, one of the IM team, has a suggestion you can read here: http://www.imagemagick.org/discourse-server/viewtopic.php?f=1&t=11980&p=39232#p39232. If this is something you want to pursue let me know and we can work on converting his shell script to Ruby. -- RMagick: http://rmagick.rubyforge.org/