I'm working on new update which expected to bring us the ability to create Multicam like camo pattern. On the last success i was be able to create organic shape without the need for hand drawing.
For how it work. The pattern generator system work by using the base fractal noise as we known are really good at create organic shape, so i put a controllable mask on it and add some parameter to have more control. The result is a controllable organic shape generattor
This camouflage pattern generator is based on fractal noise.
The first step is extract main colors from an input image.
You can customize the number of colors to extract by modifying the num_colors parameter. For example:
color_palette = cp.extract_palette("demo_input/k20r.jpg", num_colors=4) # Extract 4 main colorsIn this step, fractals are randomly generated within a given frame size and filled with the extracted colors. You can control the parameters to customize the final camouflage pattern.
generate_pattern(color_palette, "gencamo.png", size=(500, 500), c=3)Pycamo can generate 3 types of digital camo: Fractal, Pixel, Multicam-like(mimic multicam style).
Follow these steps to use the Camouflage Pattern Generator:
git clone https://github.com/Minhtrna/Pycamo.git
Install library
pip install -r requirements.txt
Then you can run Pycamo in scr folder
python Pycamo.py
Or
Use Pycamo in other Py program by
import Pycamo
You can edit parameter here
| Parameter | Description |
|---|---|
color_palette |
A list of colors extracted from an image or defined manually. |
num_colors |
The number of colors to extract from the image using the extract_palette function. |
ratios |
A list of percentages defining how much each color should contribute to the pattern. |
size |
The dimensions of the generated camouflage pattern in pixels (width, height). |
c |
A parameter that controls the complexity of the fractal noise. |
ratios=[] |
Passes the predefined ratios for each color to the generate_pattern function. |
pixelize=True/False |
Set True to pixelize camo, False for normal fractal. |
pixel_size |
Set pixel size for pixelize function. |
"demo_input/teste3.png" |
The input image file used to extract colors. |
"gencamo.png" |
The output file name where the generated pattern will be saved. |
To use GUI instead of command.
go to GUI folder
then
python GUI.py
ENJOY!




