Long Nguyen / Pixel Arts with Java
Created 2020-07-27 Modified 2020-07-27

152 Words

Some results of my attempt to implement some fancy algorithms with Java’s BufferedImage interface.

For better user interaction I also implemented a CLI to ease the image making process with Picocli, which is currently my favorite tool to make a CLI.

Simple Triangulation

Randomly generating points inside the images, creating the triangulation and sample mean RGB color of each triangle.

Advanced Triangulation

Filter the input image with a mean filter which blurrs the sharp conture. After that filter the image again with an sobel filter, the output of the sobel filter will be sampled and be the sources for generating random points. With this approach, the triangles have a higher probability of landing near a feature edge. The triangulation therefore will be better.


Generating random points as center in the two dimensional image. The points will be iteratively moved around until the distances of each center to its neighbors are equal.