First of all, I am not a NFT expert, nor a buyer but i am curious. Curious to know how could be generated these images sold thousands (millions) of dollars.
First let me explain what is a NFT ?
«Non fungible token» is a “simple” way to have the property on a digital object. The objective is to generate Proof of Ownership thanks to the blockchain. This doesn’t mean people can’t use your item (image, music, videos, virtual land …) but it means that you are the owner of this item, this digital item.
This idea comes from a purely subjective observation, some NFT collections seem to be the superposition of layers.
In this illustration, we have 5 “Features” :
Each feature has a number of options, so the idea will be to combine all these options to generate the NFT.
For example, if I have 3 features :
- Hair : 3 options
- Face : 2 options
- Glasses : 2 options
I can generate 12 “unique” images.
- Python (+ pip install Pillow)
- Some transparent .png with the same size (several Features & Options)
The process is very simple, our images will be the superposition of an option from each feature. I create very (very very) simple images to build my “features library”.
First, import image from Pillow :
from PIL import Image
Then, I decide to create lists with all the file names :
HEADS = [“head_orange.png”,”head_creepy.png”,”head_white.png”]
HATS = [“hat_black.png”,”hat_blue.png”,”hat_red.png”,”casquette_kaki.png”,”casquette_blue.png”]
Now, let the magic happen.
img_id = 0
for head in HEADS:
for hat in HATS:
img_id += 1
hat_img = Image.open(hat)
head_img = Image.open(head)
For each “head”, I’ll paste a hat on it, then I save the result with an incremental ID called “img_id”. It’s a simple script for a nice result.
You can now create NFT Collection.