Easily convert any image into low-poly art
Originaly created by: jaybosamiya
The tool creates a defined amount of random points and runs a Delaunay Triangulation on it. It then averages out the colours in the source image for each triangle in order to generate the low-poly image.
./triangulate-tool input_image output_image [total_points] [total_points_per_side]
total_points
(default:100
):int
of total random points in the imagetotal_points_per_side
(default:3
):int
total points on each edge of the image (does not count towardstotal_points
)
./build.sh
or manually
gcc triangulate-tool.cpp -o triangulate-tool $(pkg-config --cflags-only-I opencv4) -lopencv_core -lopencv_imgcodecs -lopencv_imgproc
- OpenCV 4.x (
sudo pacman -Sy opencv
) - A C++ compiler like
gcc
(sudo pacman -Sy gcc
)
This project is licensed under the GNU Lesser General Public License v3.0.