How is Noun art encoded? #395
Answered
by
solimander
cdt-eth
asked this question in
Solidity / smart contracts
-
How is Noun art encoded? |
Beta Was this translation helpful? Give feedback.
Answered by
solimander
Mar 30, 2022
Replies: 1 comment
-
Noun parts are run-length encoded, which means repeating, same-color pixels in each row are grouped. The exact encoding for each noun part is: The bounds are the bounding box of the actual content within the 32x32 pixel grid. For more information, take a look the the on-chain art documentation. You can use the @nouns/sdk to run-length encode PNG images. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
solimander
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Noun parts are run-length encoded, which means repeating, same-color pixels in each row are grouped. The exact encoding for each noun part is:
palette_index, bounds (top, right, bottom, left), [pixel_length, color_index][]
The bounds are the bounding box of the actual content within the 32x32 pixel grid. For more information, take a look the the on-chain art documentation.
You can use the @nouns/sdk to run-length encode PNG images.