Skip to main content
Log in

Generalized N-way iterative scanline fill algorithm for real-time applications

  • Original Research Paper
  • Published:
Journal of Real-Time Image Processing Aims and scope Submit manuscript

Abstract

A generalized iterative scanline fill algorithm intended for use in real-time applications and its highly optimized machine code implementation are presented in this paper. The algorithm uses the linear image representation in order to achieve the fast memory access to the pixel intensity values. The usage of the linear image representation is crucial for achieving the highly optimized low-level machine code implementation. A few generalization features are also proposed, and discussion about the possible real-time applications is given. The proposed efficient machine code implementation is tested on several PC machines, and a set of numerical results is provided. The machine routine is compared with standard and optimized implementations of the 4-way flood fill algorithm and scanline fill algorithm. The machine code implementation performs approximately 2 times faster than the optimized scanline fill algorithm implementation and 6 times faster than standard iterative scanline fill algorithm implementation on two-dimensional image data structure. Furthermore, the machine routine proved to perform even more than 15 times faster than the optimized flood fill algorithm implementations. Provided results prove the efficiency of the proposed generalized scanline fill algorithm and its advantage over the state-of-the-art algorithms, and clearly show that optimized machine routine is capable of performing the real-time tasks.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8

Similar content being viewed by others

References

  1. Albert, T.A., Slaaf, D.W.: A rapid regional filling technique for complex binary images. Comput. Graph. 19(4), 541–549 (1995)

    Article  Google Scholar 

  2. Arquè, D., Grange, O.: A fast scan-line algorithm for topological filling of well-nested objects in 2.5D digital pictures. Theor. Comput. Sci. 147(1–2), 211–248 (1995)

    Article  Google Scholar 

  3. Bhargava, N., Trivedi, P., Toshniwal, A., Swarnkar, H.: Iterative region merging and object retrieval method using mean shift segmentation and flood fill algorithm. In: 3rd International Conference on Advances in Computing and Communications (ICACC) (2013)

  4. Burger, W., Burge, M.J.: Principles of digital image processing: core algorithms, 1st edn. Springer, London (2009)

    Book  Google Scholar 

  5. Cai, Z., Ye, L., Yang, A.: FloodFill maze solving with expected toll of penetrating unknown walls for micromouse. In: IEEE 14th International Conference on High Performance Computing and Communication and 2012 IEEE 9th International Conference on Embedded Software and Systems (HPCC-ICESS) (2012)

  6. Dang, H., Song, J., Guo, Q.: An efficient algorithm for robot maze-solving. In: 2nd International Conference on Intelligent Human-Machine Systems and Cybernetics (IHMSC) (2010)

  7. Duo-le, F., Ming, Z.: A new fast region filling algorithm based on cross searching method. In: Zhou M., Tan H. (eds) Advances in Computer Science and Education Applications. Communications in Computer and Information Science, p. 202. Springer, Berlin, Heidelberg (2011)

    Google Scholar 

  8. Elshamarka, I., Saman, A.: Design and implementation of a robot for maze-solving using flood-fill algorithm. Int. J. Comput. Appl. 56(5), 8–13 (2012)

    Google Scholar 

  9. Fanfeng, Z., Wei, F.: Hole filling algorithm based on contours information. In: 2nd International Conference on Information Science and Engineering (ICISE) (2010)

  10. Fathi, M., Hiltner, J.: A new fuzzy based flood-fill algorithm for 3D NMR brain segmentation. In: IEEE International Conference on Systems, Man, and Cybernetics, IEEE SMC ‘99 Conference Proceedings (1999)

  11. Fellah, S.E., Rziza, M., Haziti, M.E.: An efficient approach for filling gaps in landsat 7 satellite images. IEEE Geosci. Remote Sens. Lett. 14(1), 62–66 (2016)

    Article  Google Scholar 

  12. Fukukawa, T., Maeda, Y., Sekiyama, K., Fukuda, T.: Road detection method corresponded to multi road types with flood fill and vehicle control. In: 2nd International Conference on Robot, Vision and Signal Processing (RVSP) (2013)

  13. Golda, A.F., Aridha, S., Elakkiya, D.: Algorithmic agent for effective mobile robot navigation in an unknown environment. In: International Conference on Intelligent Agent and Multi-Agent Systems, IAMA (2009)

  14. Henrich, D.: Space-efficient region filling in raster graphics. Vis. Comput. 10(4), 205–215 (1994)

    Article  Google Scholar 

  15. Hersch, R.D.: Descriptive contour fill of partly degenerated shapes. IEEE Comput. Graph. Appl. 6(7), 61–70 (1986)

    Article  Google Scholar 

  16. Jou, S., Tsai, M.: A fast 3D seed-filling algorithm. Vis. Comput. 19(4), 243–251 (2003)

    Article  Google Scholar 

  17. Ju, Z., Chen, Y.: New filling algorithm based on chain code. Comput. Eng. 17(33), 211–215 (2007)

    Google Scholar 

  18. Kang, H., Lee, S., Lee, J.: Image segmentation based on fuzzy flood fill mean shift algorithm. In: Annual Meeting of the North American Fuzzy Information Processing Society (NAFIPS) (2010)

  19. Khudeev, R.: A new flood-fill algorithm for closed contour. In: IEEE International Siberian Conference on Control and Communications, SIBCON ‘05 (2005)

  20. Law, G.: Quantitative comparison of flood fill and modified flood fill algorithms. Int. J. Comput. Theory Eng. 5(3), 503–508 (2013)

    Article  Google Scholar 

  21. Li, X., Huang, L.: New region filling algorithm based on chain codes description. In: 3rd International Congress on Image and Signal Processing (CISP) (2010)

  22. Li, X., Li, X.: Filling the holes of 3D body scan line point cloud. In: 2nd International Conference on Advanced Computer Control (ICACC) (2010)

  23. Liu, S., Ma, W.: Seed-growing segmentation of 3-D surface from CT-contour data. Comput. Aided Des. 31(8), 517–536 (1999)

    Article  Google Scholar 

  24. Mishra, S., Bande, P.: Maze solving algorithms for micro mouse. In: IEEE International Conference on Signal Image Technology and Internet Based Systems, SITIS ‘08 (2008)

  25. Mohammed, F.G.: Satellite image gap filling technique. Int. J. Adv. Res. Technol. 2(4), 348–351 (2013)

    MathSciNet  Google Scholar 

  26. Nosal, E.M.: Flood-fill algorithms used for passive acoustic detection and tracking. In: New Trends for Environmental Monitoring Using Passive Systems, pp. 1–5 (2008)

  27. Oikarinen, J.: Using 2- and 2½-dimensional seed filling in view lattice to accelerate volumetric rendering. Comput. Graph. 22(6), 745–757 (1998)

    Article  Google Scholar 

  28. Oikarinen, J.T., Jyrkinen, L.J.: Maximum intensity projection by 3-dimensional seed filling in view lattice. Comput. Netw. ISDN Syst. 30, 2003–2014 (1998)

    Article  Google Scholar 

  29. Patel, A., Dubey, A., Pandey, A., Choubey, S.D.: Vision guided shortest path estimation using floodfill algorithm for mobile robot applications. In: 2nd International Conference on Power, Control and Embedded Systems (ICPCES) (2012)

  30. Pavlidis, T.: Filling algorithms for raster graphics. Comput. Graph. Image Process. 10(2), 126–141 (1979)

    Article  MathSciNet  Google Scholar 

  31. Pavlidis, T.: Algorithms for Graphics and Image Processing. Computer Science Press, Rockville (1982)

    Book  Google Scholar 

  32. Ren, M., Yang, W., Yang, J.: A new and fast contour-filling algorithm. Pattern Recogn. 38(12), 2564–2577 (2005)

    Article  Google Scholar 

  33. Sarpate, G.K., Guru, S.K.: Image inpainting on satellite image using texture synthesis and region filling algorithm. In: International Conference on Advances in Communication and Computing Technologies (ICACACT) (2014)

  34. Tang, G.Y., Lien, B.: Region filing with the use of the discrete green theorem. Comput. Vis. Graph. Image Process. 42(3), 297–305 (1988)

    Article  Google Scholar 

  35. Thapaliya, K., Kwon, G.R.: Extraction of brain tumor based on morphological operations. In: 8th International Conference on Computing Technology and Information Management (ICCM) (2012)

  36. Torbert, S.: Applied Computer Science, 2nd edn, p. 158. Springer, Berlin (2016)

    Google Scholar 

  37. Vučković, V., Arizanović, B.: Efficient character segmentation approach for machine-typed documents. Expert Syst. Appl. 80, 210–231 (2017)

    Article  Google Scholar 

  38. Vučković, V., Arizanović, B.: Automatic document skew pre-processor for character segmentation algorithm. Facta Univ. Electron. Energ. 30(4), 611–625 (2017)

    Article  Google Scholar 

  39. Vučković, V., Arizanović, B., Le Blond, S.: Ultra-fast basic geometrical transformations on linear image data structure. Expert Syst. Appl. 91, 322–346 (2018)

    Article  Google Scholar 

  40. Wayalun, P., Chomphuwiset, P., Laopracha, N., Wanchanthuek, P.: Images enhancement of G-band chromosome using histogram equalization, OTSU thresholding, morphological dilation and flood fill techniques. In: 8th International Conference on Computing and Networking Technology (ICCNT) (2012)

  41. Yu, W., He, F., Xi, P.: A rapid 3D seed-filling algorithm based on scan slice. Comput. Graph. 34(4), 449–459 (2010)

    Article  Google Scholar 

  42. Yu, Y., Wang, J.: Image segmentation based on region growing and edge detection. In: IEEE International Conference on Systems, Man, and Cybernetics, 1999. IEEE SMC ’99 Conference Proceedings, vol. 6 (1999). doi:10.1109/ICSMC.1999.816653

  43. Zhu, H., Zhang, G., Liu, G., Sun, Q.: Flotation bubble seed image filling algorithm based on boundary point features. Int. J. Min. Sci. Technol. 22(3), 289–293 (2012)

    Article  Google Scholar 

Download references

Acknowledgements

This paper is supported by the Ministry of Education, Science and Technological Development of the Republic of Serbia (Project III44006-10) and Mathematical Institute of Serbian Academy of Science and Arts (SANU).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Vladan Vučković.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Vučković, V., Arizanović, B. & Le Blond, S. Generalized N-way iterative scanline fill algorithm for real-time applications. J Real-Time Image Proc 16, 2213–2231 (2019). https://doi.org/10.1007/s11554-017-0732-1

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s11554-017-0732-1

Keywords

Navigation