by Always_Anon · 3y ago · 0 comments
The way which they are mapped to images vary from NFT to NFT.
But let's look at Bored Ape Yacht Club specifically.
Collection https://opensea.io/collection/boredapeyachtclub
Pick a random bored ape. For example #1337.
https://opensea.io/assets/ethereum/0xbc4ca0eda7647a8ab7c2061...
From there we can see the bored ape Ethereum "smart contract"
https://etherscan.io/address/0xbc4ca0eda7647a8ab7c2061c2e118...
This contract is responsible for minting all of the original Bored Ape NFTs
Click on "contract". And then click "read contract".
Scroll down. There is a method named "tokenURI". It takes an integer as parameter. Let's query it with value "1337" (the id of the bored ape we are interested in knowing about).
Result:
ipfs://QmeSjSinHpPnmXmspMjwiXyN6zS4E9zccariGR3jxcaWtq/1337
Let's visit that URL via an IPFS gateway.
https://cloudflare-ipfs.com/ipfs/QmeSjSinHpPnmXmspMjwiXyN6zS...
It contains JSON data.
{"image":"ipfs://QmWjXFUVNjavM4hDzXeQYGXGCXjV86mP7kPEaTeP5bohae","attributes":[{"trait_type":"Background","value":"Yellow"},{"trait_type":"Fur","value":"Dark Brown"},{"trait_type":"Clothes","value":"Bone Necklace"},{"trait_type":"Mouth","value":"Bored Unshaven"},{"trait_type":"Hat","value":"Horns"},{"trait_type":"Eyes","value":"Bloodshot"}]}
We make note of the IPFS URL for the image from here.ipfs://QmWjXFUVNjavM4hDzXeQYGXGCXjV86mP7kPEaTeP5bohae
And visit that one via our chosen IPFS gateway.
https://cloudflare-ipfs.com/ipfs/QmWjXFUVNjavM4hDzXeQYGXGCXj...
So there you have it. Via the Bored Ape smart contract we retrieved the JSON data and image file for Bored Ape #1337 from IPFS.
We knew NFTs were stupid... we just couldn't comprehend how incredibly stupid they actually are.
In reality though it is an implementation detail. An NFT is just a coloured coin, and derives it's value from someone else thinking they can buy it and sell it on to someone else / OR some kind of bragging rights value, i.e. I can afford $100k on X useless thing (e.g. watch, gold plated iPhone etc.) so therefore I am rich.
Pretty sure the X useless thing was $44 billion.
Ultimately, the chain is meant to be a ledger of transactions (like a decentralized Christie’s auction house maintaining provenance), not a storage layer.
The big difference between git and a blockchain like Bitcoin and Ethereum is how you do "pull requests". On git, usually, there is a designated central repository that is controlled by project maintainers, and when you submit a pull request, they check it, merge it to central, and others get it back from here.
With blockchains, there is no designated central repository, to merge a pull request, you have to win a sort of lottery, commonly by reversing a crypto hash (mining). The more invested you are into the system, the higher the odds. If you win, you show it to the the world, do the merge, and everyone pulls from you. By randomly selecting who does the pull among the most invested limits the chance of one bad actor ruining the system for everyone. In case of a conflict, the branch with the most commits wins, because that's the one with the most "lottery winners" and therefore the most likely to be the right one. To encourage others to merge that pull request, there is usually a reward for those who do (transaction fees).
Technically, it is very sound, just like git is, in a sense. The "proof-of-work" lottery is wasteful in electricity though, and of course, what you do with it is another matter. Just like git can be used for good (ex: linux) or for bad (ex: developing malware).
So basically ipfs won?! or lost?!
there are a lot of NFTs that are better implementations, the primary improvement being that there is no external hosting and they build the visual data into the smart contract function for a renderer to interpret
Ive done a lot with SVGs that way. others upload dependendies like three.js on the blockchain in other smart contracts, so when called they can return into yours and you have more sophisticated renders
I think artblocks does something like that, not sure
Most of the financial sector NFTs have an onchain svg too, like all the Uniswap liquidity pools
first movers are often poorer implementations of the technology, its up to the consumers to discern and if they dont then there is no incentive to act differently