-
Essay / Straightening using binary and grayscale images - 2166
1.6.3 Straightening using binary and grayscale imagesMethod 1This first algorithm uses information from binary and level images of gray to estimate the tilt angle. It is based on Binary Image Filtering Algorithm 1.2.1, Sobel edge detection filter and classical Hough transform. As we are looking for angles between -25 and 25 degrees, the window length is set to 3 and the threshold to 2 for the filtering algorithm. If a white pixel satisfies the conditions of the filtering algorithm, then we apply the Sobel edge detection filter to the considered point on the grayscale image. If the gradient magnitude is greater than 255, votes are taken in all directions in the ac. -accumulator.The peaks in the accumulator are located using the method proposed in 1.5.2.Method 2This method only differs from the previous one in the voting scheme. In fact, instead of voting in all directions, the gradient directory is used to calculate the estimated inclination angle at the considered point using (1.12). In order to maintain precision, votes are carried out between θ − 2◦ and θ + 2. ◦ .In order to increase the precision of the algorithm for poorly cropped images, it may be interesting to vote in more directions than - 2 to 2 degrees. However, this implies a greater calculation time for perhaps not greater precision.1.7 ResultsFor the experiment, 25 documents from magazines, business letters, annual reports were considered. Documents are tested at predefined angles between 0 and 25 degrees. The following table gives the mean (M), standard deviation (SD) and calculation time (T) in seconds for the different methods proposed. These tests were carried out on a Pentium computer. 4 ...... middle of paper ...... were carried out on 12 words or groups of words chosen at random. Finally, boldness could be estimated by examining the variation in estimated boldness between words on the same line. . It is also mandatory to note that the estimated boldness varies depending on the word fonts. 2.4 Scaling Algorithms 2.4.1 Scale2xScale2x is a real-time graphics effect capable of increasing the size of small bitmaps by guessing missing pixels without interpolating pixels or blurring images. was originally developed for the AdvanceMAME project in 2001 to improve the quality of older games with low video resolution. The Scale3x and Scale4x derivative effects which scale the image by 3x and 4x are also available (8). Image upsampling is calculated by applying certain rules to each pixel of the input image. Consider first the following 3 × 3 matrix.: