Sacra Logo

How is generative art stored on the blockchain, what parameters are stored on the blockchain, and why is it important for buyers and sellers?

Erick Calderon

Founder & CEO at Art Blocks

If you take a highly dynamic unit of output, like any Art Blocks piece, some of them are over four megabytes. They have such incredible complexity and detail in them. In the traditional world of NFTs, if that even exists, you would take that four-megabyte file, and you would have to host it on what's called decentralized storage. It's not fully decentralized when it's IPFS, but IPFS is a brilliant, genius concept for decentralized storage. That's not actually stored on-chain. The concept of Art Blocks is that the value of on-chain generative art is that the information necessary to create that four-megabyte image that cannot live on-chain is stored on-chain. This is the algorithm.

In some cases, the entirety of the algorithm lives on the blockchain, but an external library is allowed—the most common one being p5js, then there's another one called 3js. Ideally, with anything that's stored on-chain, you would be able to reproduce it just following the logic of what the artist wrote. 

What's really important to note is that IPFS, if you store one image on-chain, you have one single image that belongs to one out of billions of NFTs or millions of NFTs that needs to be kept track of. With Art Blocks, these external dependencies are not kept on-chain, for example, p5js being the most prominent one.

Number one, 100 or 200 projects on Art Blocks are using that dependency, so it's not like an IPFS image where one NFT needs that one thing, but hundreds of people and projects depend on that. 

Number two, the distribution of that dependency is—I'm 99% sure—significantly more distributed than Ethereum itself. In other words, more computers and servers and GitHub repos and whatever are hosting p5js right now, internalized on all sorts of backups and systems, than there are people actually hosting Ethereum nodes. 

If what we're trying to do is have our art be internalized, then that feels very decentralized, and it feels very secure that you cannot reproduce your output when that dependency is gone.

The beauty of an Art Block piece is that storage on the blockchain is incredibly expensive. You cannot store a four-megabyte image. If I had to guess, it would cost two or three million bucks to store four megabytes on the blockchain. I'm just totally throwing a number out there. 

Then, imagine we have additions of a thousand, so multiply that by a thousand. Take all of that and then just sum it up to the fact that there's one algorithm that's usually 50 kilobytes, let's say it's 1% of the size of one image, and that one algorithm has the instructions to produce a seemingly unlimited number of four-megabyte files that are all 100% unique using the technology that Art Blocks has created. The NFT stores only a variable, a hash string that contains the variability of the art, and the blockchain stores the script for the art one time.

What Art Blocks is doing is combining the algorithm that the artist created with the variability that's minted onto the token into a single output, so the algorithm is actually useless without the mint. The mint is also useless without the algorithm, but when combined, you get what we call a deterministic output, which means anytime that you combine those two same things, they produce the exact same output no matter what browser, no matter what. Obviously, we're going to face some struggles in the future as there's breaking changes in browsers, and we can have an entire conversation based around that.

The other point about putting something on-chain that’s like that four-megabyte file is that if it was created on a screen that was 10 times bigger, it would now generate a 40-megabyte or 160-megabyte file. The point being that the resolution of the file, being that it's generated algorithmically, is 100% independent of the algorithm. Let’s say in 10 years, screens have four times the resolution—that same output would either have to be upsampled, or it would have to be smaller than the screen, one or the other, because it's a static image. If you're generating an Art Blocks output in 10 years, it will look exactly the same on that higher resolution screen than it looks on your screen today.

Find this answer in Erick Calderon, CEO of Art Blocks, on the evolution of NFT marketplaces
lightningbolt_icon Unlocked Report