Skip to content

Chanmoey/replace-image-background-color

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

替换照片的背景色

学习Flood Fill算法时的一个小Deom,没有使用价值,但是新手用来练习Java基本语法和熟悉Flood Fill算法还是可以的。

因为我不是做图像相关的方向的,所以对于图像颜色的判断并不很准确,这个Demo还有很大改进的空间。

主要使用到的算法是Flood Fill。

思路是通过Flood Fill算法,不停的便利相同颜色的像素点(认为颜色相同的为背景色),然后将其背景色替换成其他颜色。

存在的两个难点:

  1. 色差如何判断。
  2. 图像边缘如何处理。

About

Try to change the background color of the picture.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages