Jump to content

Zhang-Suen thinning algorithm: Difference between revisions

m
→‎{{header|Java}}: small change
(→‎{{header|Java}}: added Java)
m (→‎{{header|Java}}: small change)
Line 819:
=={{header|Java}}==
{{works with|Java|7}}
<lang java>import java.utilawt.*Point;
import java.util.*;
 
public class ZhangSuen {
Line 849 ⟶ 850:
{0, 4, 6}}};
 
static List<Integer[]Point> toWhite = new ArrayList<>();
static char[][] grid;
 
Line 884 ⟶ 885:
continue;
 
toWhite.add(new Integer[]{Point(r, c}));
hasChanged = true;
}
}
 
for (Integer[]Point coordsp : toWhite)
grid[coords[0]p.x][coords[1]p.y] = ' ';
toWhite.clear();
 
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.