An Approach to Modification of Water Flow Algorithm for Segmentation and Text Parameters Extraction