Feature Tip: Add private address tag to any address under My Name Tag !
Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
Latest 1 internal transaction
Advanced mode:
Parent Transaction Hash | Block |
From
|
To
|
|||
---|---|---|---|---|---|---|
18203645 | 503 days ago | Contract Creation | 0 ETH |
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
ColormapRegistry
Compiler Version
v0.8.21+commit.d9974bed
Optimization Enabled:
Yes with 1000000 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: MIT pragma solidity ^0.8.21; import "@/contracts/utils/Constants.sol"; import { IColormapRegistry } from "@/contracts/interfaces/IColormapRegistry.sol"; import { IPaletteGenerator } from "@/contracts/interfaces/IPaletteGenerator.sol"; /// @title An on-chain registry for colormaps. /// @author fiveoutofnine contract ColormapRegistry is IColormapRegistry { // ------------------------------------------------------------------------- // Storage // ------------------------------------------------------------------------- /// @inheritdoc IColormapRegistry mapping(bytes8 => SegmentData) public override segments; /// @inheritdoc IColormapRegistry mapping(bytes8 => IPaletteGenerator) public override paletteGenerators; // ------------------------------------------------------------------------- // Modifiers // ------------------------------------------------------------------------- /// @dev Reverts a function if a colormap does not exist. /// @param _hash Hash of the colormap's definition. modifier colormapExists(bytes8 _hash) { SegmentData memory segmentData = segments[_hash]; // Revert if a colormap corresponding to `_hash` has never been set. if ( segmentData.r // Segment data is uninitialized. We don't need to check `g` // and `b` because the segment data would've never been // initialized if any of `r`, `g`, or `b` were 0. == 0 // Palette generator is uninitialized. && address(paletteGenerators[_hash]) == address(0) ) { revert ColormapDoesNotExist(_hash); } _; } // ------------------------------------------------------------------------- // Actions // ------------------------------------------------------------------------- /// @inheritdoc IColormapRegistry function batchRegister(IPaletteGenerator[] memory _paletteGenerators) external { uint256 length = _paletteGenerators.length; // Loop through `_paletteGenerators` and register each one. for (uint256 i; i < length;) { _register(_paletteGenerators[i]); unchecked { ++i; } } } /// @inheritdoc IColormapRegistry function batchRegister(SegmentData[] memory _segmentDataArray) external { uint256 length = _segmentDataArray.length; // Loop through `_segmentDataArray` and register each one. for (uint256 i; i < length;) { _register(_segmentDataArray[i]); unchecked { ++i; } } } /// @inheritdoc IColormapRegistry function register(IPaletteGenerator _paletteGenerator) external { _register(_paletteGenerator); } /// @inheritdoc IColormapRegistry function register(SegmentData memory _segmentData) external { _register(_segmentData); } // ------------------------------------------------------------------------- // View // ------------------------------------------------------------------------- /// @inheritdoc IColormapRegistry function getValue(bytes8 _hash, uint256 _position) external view colormapExists(_hash) returns (uint256, uint256, uint256) { IPaletteGenerator paletteGenerator = paletteGenerators[_hash]; // Compute using the palette generator, if there exists one. if (address(paletteGenerator) != address(0)) { return ( paletteGenerator.r(_position), paletteGenerator.g(_position), paletteGenerator.b(_position) ); } // Compute the value with a piece-wise interpolation on the segments // given by the segment data. SegmentData memory segmentData = segments[_hash]; return ( _computeLinearInterpolationFPM(segmentData.r, _position), _computeLinearInterpolationFPM(segmentData.g, _position), _computeLinearInterpolationFPM(segmentData.b, _position) ); } /// @inheritdoc IColormapRegistry function getValueAsHexString(bytes8 _hash, uint8 _position) external view returns (string memory) { (uint8 r, uint8 g, uint8 b) = getValueAsUint8(_hash, _position); return string( abi.encodePacked( HEXADECIMAL_DIGITS[r >> 4], HEXADECIMAL_DIGITS[r & 0xF], HEXADECIMAL_DIGITS[g >> 4], HEXADECIMAL_DIGITS[g & 0xF], HEXADECIMAL_DIGITS[b >> 4], HEXADECIMAL_DIGITS[b & 0xF] ) ); } /// @inheritdoc IColormapRegistry function getValueAsUint8(bytes8 _hash, uint8 _position) public view colormapExists(_hash) returns (uint8, uint8, uint8) { IPaletteGenerator paletteGenerator = paletteGenerators[_hash]; // Compute using the palette generator, if there exists one. if (address(paletteGenerator) != address(0)) { unchecked { // All functions in {IPaletteGenerator} represent a position in // the colormap as a 18 decimal fixed point number in [0, 1], so // we must convert it. uint256 positionAsFixedPointDecimal = FIXED_POINT_COLOR_VALUE_SCALAR * _position; // This function returns `uint8` for each of the R, G, and B's // values, while all functions in {IPaletteGenerator} use the // 18 decimal fixed point representation, so we must convert it // back. return ( uint8( paletteGenerator.r(positionAsFixedPointDecimal) / FIXED_POINT_COLOR_VALUE_SCALAR ), uint8( paletteGenerator.g(positionAsFixedPointDecimal) / FIXED_POINT_COLOR_VALUE_SCALAR ), uint8( paletteGenerator.b(positionAsFixedPointDecimal) / FIXED_POINT_COLOR_VALUE_SCALAR ) ); } } // Compute the value with a piece-wise interpolation on the segments // given by the segment data. SegmentData memory segmentData = segments[_hash]; return ( _computeLinearInterpolation(segmentData.r, _position), _computeLinearInterpolation(segmentData.g, _position), _computeLinearInterpolation(segmentData.b, _position) ); } // ------------------------------------------------------------------------- // Internal functions // ------------------------------------------------------------------------- /// @dev See {ColormapRegistry.register(IPaletteGenerator)} for more /// information. function _register(IPaletteGenerator _paletteGenerator) internal { bytes8 hash = _computeColormapHash(_paletteGenerator); // Store palette generator. paletteGenerators[hash] = _paletteGenerator; // Emit event. emit RegisterColormap(hash, _paletteGenerator); } /// @dev See {ColormapRegistry.register(SegmentData)} for more information. function _register(SegmentData memory _segmentData) internal { bytes8 hash = _computeColormapHash(_segmentData); // Check if `_segmentData` is valid. _checkSegmentDataValidity(_segmentData.r); _checkSegmentDataValidity(_segmentData.g); _checkSegmentDataValidity(_segmentData.b); // Store segment data. segments[hash] = _segmentData; // Emit event. emit RegisterColormap(hash, _segmentData); } // ------------------------------------------------------------------------- // Helper functions // ------------------------------------------------------------------------- /// @notice Checks if a colormap exists. /// @dev The function reverts if the colormap corresponding to `_hash` was /// never registered. /// @param _hash Hash of the colormap's definition. function _checkColormapDoesNotExist(bytes8 _hash) internal view { SegmentData memory segmentData = segments[_hash]; // Revert if a colormap corresponding to `hash` has already been set. if ( // Segment data is initialized. We don't need to check `g` and `b` // because the segment data would've never been initialized if any // of `r`, `g`, or `b` were 0. (segmentData.r > 0) // Palette generator is initialized. || address(paletteGenerators[_hash]) != address(0) ) { revert ColormapAlreadyExists(_hash); } } /// @notice Checks if a `uint256` corresponds to a valid segment data. /// @dev The function reverts if `_segmentData` is not a valid /// representation for a colormap. /// @param _segmentData Segment data for 1 of R, G, or B. See /// {IColormapRegistry} for its representation. function _checkSegmentDataValidity(uint256 _segmentData) internal pure { uint256 prevPosition = (_segmentData >> 16) & 0xFF; // Revert if the colormap isn't defined from the start. if (prevPosition > 0) { revert SegmentDataInvalid(_segmentData); } for ( // We shift `_segmentData` right by 24 because the first segment was // read already. uint256 partialSegmentData = _segmentData >> 24; partialSegmentData > 0; partialSegmentData >>= 24 ) { uint256 position = (partialSegmentData >> 16) & 0xFF; // Revert if the position did not increase. if (position <= prevPosition) { revert SegmentDataInvalid(_segmentData); } prevPosition = (partialSegmentData >> 16) & 0xFF; } // Revert if the colormap isn't defined til the end. if (prevPosition < 0xFF) { revert SegmentDataInvalid(_segmentData); } } /// @notice Computes the hash of a colormap defined via a palette generator. /// @dev The function reverts if the colormap already exists. /// @param _paletteGenerator Palette generator for the colormap. /// @return bytes8 Hash of `_paletteGenerator`. function _computeColormapHash(IPaletteGenerator _paletteGenerator) internal view returns (bytes8) { // Compute hash. bytes8 hash = bytes8(keccak256(abi.encodePacked(_paletteGenerator))); // Revert if colormap does not exist. _checkColormapDoesNotExist(hash); return hash; } /// @notice Computes the hash of a colormap defined via segment data. /// @dev The function reverts if the colormap already exists. /// @param _segmentData Segment data for the colormap. See /// {IColormapRegistry} for its representation. /// @return bytes8 Hash of the contents of `_segmentData`. function _computeColormapHash(SegmentData memory _segmentData) internal view returns (bytes8) { // Compute hash. bytes8 hash = bytes8(keccak256(abi.encodePacked(_segmentData.r, _segmentData.g, _segmentData.b))); // Revert if colormap does not exist. _checkColormapDoesNotExist(hash); return hash; } /// @notice Computes the value at the position `_position` along some /// segment data defined by `_segmentData`. /// @param _segmentData Segment data for 1 of R, G, or B. See /// {IColormapRegistry} for its representation. /// @param _position Position along the colormap. /// @return uint8 Intensity of the color at the position in the colormap. function _computeLinearInterpolation(uint256 _segmentData, uint8 _position) internal pure returns (uint8) { // We loop until we find the segment with the greatest position less // than `_position`. while ((_segmentData >> 40) & 0xFF < _position) { _segmentData >>= 24; } // Retrieve the start and end of the identified segment. uint256 segmentStart = _segmentData & 0xFFFFFF; uint256 segmentEnd = (_segmentData >> 24) & 0xFFFFFF; // Retrieve start/end position w.r.t. the entire colormap. uint256 startPosition = (segmentStart >> 16) & 0xFF; uint256 endPosition = (segmentEnd >> 16) & 0xFF; // Retrieve start/end intensities. uint256 startIntensity = segmentStart & 0xFF; uint256 endIntensity = (segmentEnd >> 8) & 0xFF; // Compute the value with a piece-wise linear interpolation on the // segments. unchecked { // This will never underflow because we ensure the start segment's // position is less than or equal to `_position`. uint256 positionChange = _position - startPosition; // This will never be 0 because we ensure each segment must increase // in {ColormapRegistry.register} via // {ColormapRegistry._checkSegmentDataValidity}. uint256 segmentLength = endPosition - startPosition; // Check if end intensity is larger to prevent under/overflowing (as // well as to compute the correct value). if (endIntensity >= startIntensity) { return uint8( startIntensity + ((endIntensity - startIntensity) * positionChange) / segmentLength ); } return uint8( startIntensity - ((startIntensity - endIntensity) * positionChange) / segmentLength ); } } /// @notice Computes the value at the position `_position` along some /// segment data defined by `_segmentData`. /// @param _segmentData Segment data for 1 of R, G, or B. See /// {IColormapRegistry} for its representation. /// @param _position 18 decimal fixed-point number in [0, 1] representing /// the position along the colormap. /// @return uint256 Intensity of the color at the position in the colormap. function _computeLinearInterpolationFPM(uint256 _segmentData, uint256 _position) internal pure returns (uint256) { unchecked { // We need to truncate `_position` to be in [0, 0xFF] pre-scaling. _position = _position > 0xFF * FIXED_POINT_COLOR_VALUE_SCALAR ? 0xFF * FIXED_POINT_COLOR_VALUE_SCALAR : _position; // We look until we find the segment with the greatest position less // than `_position`. while (((_segmentData >> 40) & 0xFF) * FIXED_POINT_COLOR_VALUE_SCALAR < _position) { _segmentData >>= 24; } // Retrieve the start and end of the identified segment. uint256 segmentStart = _segmentData & 0xFFFFFF; uint256 segmentEnd = (_segmentData >> 24) & 0xFFFFFF; // Retrieve start/end position w.r.t. the entire colormap and // convert them to the 18 decimal fixed point number representation. uint256 startPosition = ((segmentStart >> 16) & 0xFF) * FIXED_POINT_COLOR_VALUE_SCALAR; uint256 endPosition = ((segmentEnd >> 16) & 0xFF) * FIXED_POINT_COLOR_VALUE_SCALAR; // Retrieve start/end intensities and convert them to the 18 decimal // fixed point number representation. uint256 startIntensity = (segmentStart & 0xFF) * FIXED_POINT_COLOR_VALUE_SCALAR; uint256 endIntensity = ((segmentEnd >> 8) & 0xFF) * FIXED_POINT_COLOR_VALUE_SCALAR; // This will never underflow because we ensure the start segment's // position is less than or equal to `_position`. uint256 positionChange = _position - startPosition; // This will never be 0 because we ensure each segment must increase // in {ColormapRegistry.register} via // {ColormapRegistry._checkSegmentDataValidity}. uint256 segmentLength = endPosition - startPosition; // Check if end intensity is larger to prevent under/overflowing (as // well as to compute the correct value). if (endIntensity >= startIntensity) { return startIntensity + ((endIntensity - startIntensity) * positionChange) / segmentLength; } return startIntensity - ((startIntensity - endIntensity) * positionChange) / segmentLength; } } }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.21; // ----------------------------------------------------------------------------- // Scalars // ----------------------------------------------------------------------------- // A scalar to convert a number from [0, 255] to an 18 decimal fixed-point // number in [0, 1] (i.e. 1e18 / 255). uint256 constant FIXED_POINT_COLOR_VALUE_SCALAR = 3_921_568_627_450_980; // ----------------------------------------------------------------------------- // Miscellaneous // ----------------------------------------------------------------------------- // A look-up table to simplify the conversion from number to hexstring. bytes32 constant HEXADECIMAL_DIGITS = "0123456789ABCDEF";
// SPDX-License-Identifier: MIT pragma solidity ^0.8.21; import { IPaletteGenerator } from "@/contracts/interfaces/IPaletteGenerator.sol"; /// @title The interface for the colormap registry. /// @author fiveoutofnine /// @dev A colormap may be defined in 2 ways: (1) via segment data and (2) via a /// ``palette generator.'' /// 1. via segment data /// 2. or via a palette generator ({IPaletteGenerator}). /// Segment data contains 1 `uint256` each for red, green, and blue describing /// their intensity values along the colormap. Each `uint256` contains 24-bit /// words bitpacked together with the following structure (bits are /// right-indexed): /// | Bits | Meaning | /// | --------- | ---------------------------------------------------- | /// | `23 - 16` | Position in the colormap the segment begins from | /// | `15 - 08` | Intensity of R, G, or B the previous segment ends at | /// | `07 - 00` | Intensity of R, G, or B the next segment starts at | /// Given some position, the output will be computed via linear interpolations /// on the segment data for R, G, and B. A maximum of 10 of these segments fit /// within 256 bits, so up to 9 segments can be defined. If you need more /// granularity or a nonlinear palette function, you may implement /// {IPaletteGenerator} and define a colormap with that. interface IColormapRegistry { // ------------------------------------------------------------------------- // Errors // ------------------------------------------------------------------------- /// @notice Emitted when a colormap already exists. /// @param _hash Hash of the colormap's definition. error ColormapAlreadyExists(bytes8 _hash); /// @notice Emitted when a colormap does not exist. /// @param _hash Hash of the colormap's definition. error ColormapDoesNotExist(bytes8 _hash); /// @notice Emitted when a segment data used to define a colormap does not /// follow the representation outlined in {IColormapRegistry}. /// @param _segmentData Segment data for 1 of R, G, or B. See /// {IColormapRegistry} for its representation. error SegmentDataInvalid(uint256 _segmentData); // ------------------------------------------------------------------------- // Structs // ------------------------------------------------------------------------- /// @notice Segment data that defines a colormap when read via piece-wise /// linear interpolation. /// @dev Each param contains 24-bit words, so each one may contain at most /// 9 (24*10 - 1) segments. See {IColormapRegistry} for how the segment data /// should be structured. /// @param r Segment data for red's color value along the colormap. /// @param g Segment data for green's color value along the colormap. /// @param b Segment data for blue's color value along the colormap. struct SegmentData { uint256 r; uint256 g; uint256 b; } // ------------------------------------------------------------------------- // Events // ------------------------------------------------------------------------- /// @notice Emitted when a colormap is registered via a palette generator /// function. /// @param _hash Hash of `_paletteGenerator`. /// @param _paletteGenerator Instance of {IPaletteGenerator} for the /// colormap. event RegisterColormap(bytes8 _hash, IPaletteGenerator _paletteGenerator); /// @notice Emitted when a colormap is registered via segment data. /// @param _hash Hash of `_segmentData`. /// @param _segmentData Segment data defining the colormap. event RegisterColormap(bytes8 _hash, SegmentData _segmentData); // ------------------------------------------------------------------------- // Storage // ------------------------------------------------------------------------- /// @param _hash Hash of the colormap's definition (palette generator). /// @return IPaletteGenerator Instance of {IPaletteGenerator} for the /// colormap. function paletteGenerators(bytes8 _hash) external view returns (IPaletteGenerator); /// @param _hash Hash of the colormap's definition (segment data). /// @return uint256 Segment data for red's color value along the colormap. /// @return uint256 Segment data for green's color value along the colormap. /// @return uint256 Segment data for blue's color value along the colormap. function segments(bytes8 _hash) external view returns (uint256, uint256, uint256); // ------------------------------------------------------------------------- // Actions // ------------------------------------------------------------------------- /// @notice Batch register colormaps with palette generators. /// @param _paletteGenerators Array of {IPaletteGenerator} instances for the /// colormap. function batchRegister(IPaletteGenerator[] memory _paletteGenerators) external; /// @notice Batch register colormaps with segment data that will be read /// via piece-wise linear interpolation. /// @dev See {IColormapRegistry} for how the segment data should be /// structured. /// @param _segmentDataArray Array of segment data tuples defining the /// colormap. function batchRegister(SegmentData[] memory _segmentDataArray) external; /// @notice Register a colormap with a palette generator. /// @param _paletteGenerator Instance of {IPaletteGenerator} for the /// colormap. function register(IPaletteGenerator _paletteGenerator) external; /// @notice Register a colormap with segment data that will be read via /// piece-wise linear interpolation. /// @dev See {IColormapRegistry} for how the segment data should be /// structured. /// @param _segmentData Segment data defining the colormap. function register(SegmentData memory _segmentData) external; // ------------------------------------------------------------------------- // View // ------------------------------------------------------------------------- /// @notice Get the red, green, and blue color values of a color in a /// colormap at some position. /// @dev Each color value will be returned as a 18 decimal fixed-point /// number in [0, 1]. Note that the function *will not* revert if /// `_position` is an invalid input (i.e. greater than 1e18). This /// responsibility is left to the implementation of {IPaletteGenerator}s. /// @param _hash Hash of the colormap's definition. /// @param _position 18 decimal fixed-point number in [0, 1] representing /// the position in the colormap (i.e. 0 being min, and 1 being max). /// @return uint256 Intensity of red in that color at the position /// `_position`. /// @return uint256 Intensity of green in that color at the position /// `_position`. /// @return uint256 Intensity of blue in that color at the position /// `_position`. function getValue(bytes8 _hash, uint256 _position) external view returns (uint256, uint256, uint256); /// @notice Get the hexstring for a color in a colormap at some position. /// @param _hash Hash of the colormap's definition. /// @param _position Position in the colormap (i.e. 0 being min, and 255 /// being max). /// @return string Hexstring excluding ``#'' (e.g. `007CFF`) of the color /// at the position `_position`. function getValueAsHexString(bytes8 _hash, uint8 _position) external view returns (string memory); /// @notice Get the red, green, and blue color values of a color in a /// colormap at some position. /// @dev Each color value will be returned as a `uint8` number in [0, 255]. /// @param _hash Hash of the colormap's definition. /// @param _position Position in the colormap (i.e. 0 being min, and 255 /// being max). /// @return uint8 Intensity of red in that color at the position /// `_position`. /// @return uint8 Intensity of green in that color at the position /// `_position`. /// @return uint8 Intensity of blue in that color at the position /// `_position`. function getValueAsUint8(bytes8 _hash, uint8 _position) external view returns (uint8, uint8, uint8); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.21; /// @title The interface for a palette generator. /// @author fiveoutofnine /// @dev `IPaletteGenerator` contains generator functions for a color's red, /// green, and blue color values. Each of these functions is intended to take in /// a 18 decimal fixed-point number in [0, 1] representing the position in the /// colormap and return the corresponding 18 decimal fixed-point number in /// [0, 1] representing the value of each respective color. interface IPaletteGenerator { // ------------------------------------------------------------------------- // Errors // ------------------------------------------------------------------------- /// @notice Reverts if the position is not a valid input. /// @dev The position is not a valid input if it is greater than 1e18. /// @param _position Position in the colormap. error InvalidPosition(uint256 _position); // ------------------------------------------------------------------------- // Generators // ------------------------------------------------------------------------- /// @notice Computes the intensity of red of the palette at some position. /// @dev The function should revert if `_position` is not a valid input /// (i.e. greater than 1e18). Also, the return value for all inputs must be /// a 18 decimal. /// @param _position Position in the colormap. /// @return uint256 Intensity of red in that color at the position /// `_position`. function r(uint256 _position) external pure returns (uint256); /// @notice Computes the intensity of green of the palette at some position. /// @dev The function should revert if `_position` is not a valid input /// (i.e. greater than 1e18). Also, the return value for all inputs must be /// a 18 decimal. /// @param _position Position in the colormap. /// @return uint256 Intensity of green in that color at the position /// `_position`. function g(uint256 _position) external pure returns (uint256); /// @notice Computes the intensity of blue of the palette at some position. /// @dev The function should revert if `_position` is not a valid input /// (i.e. greater than 1e18). Also, the return value for all inputs must be /// a 18 decimal. /// @param _position Position in the colormap. /// @return uint256 Intensity of blue in that color at the position /// `_position`. function b(uint256 _position) external pure returns (uint256); }
{ "remappings": [ "forge-std/=lib/forge-std/src/", "solmate/=lib/solmate/src/", "trig/=lib/solidity-trigonometry/src/", "@/script/=script/", "@/contracts/=src/", "@/test/=test/", "@prb/test/=lib/solidity-trigonometry/lib/prb-math/lib/prb-test/src/", "ds-test/=lib/forge-std/lib/ds-test/src/", "prb-math/=lib/solidity-trigonometry/lib/prb-math/src/", "prb-test/=lib/solidity-trigonometry/lib/prb-math/lib/prb-test/src/", "solidity-trigonometry/=lib/solidity-trigonometry/src/" ], "optimizer": { "enabled": true, "runs": 1000000 }, "metadata": { "useLiteralContent": false, "bytecodeHash": "none", "appendCBOR": true }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "evmVersion": "paris", "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"bytes8","name":"_hash","type":"bytes8"}],"name":"ColormapAlreadyExists","type":"error"},{"inputs":[{"internalType":"bytes8","name":"_hash","type":"bytes8"}],"name":"ColormapDoesNotExist","type":"error"},{"inputs":[{"internalType":"uint256","name":"_segmentData","type":"uint256"}],"name":"SegmentDataInvalid","type":"error"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes8","name":"_hash","type":"bytes8"},{"indexed":false,"internalType":"contract IPaletteGenerator","name":"_paletteGenerator","type":"address"}],"name":"RegisterColormap","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes8","name":"_hash","type":"bytes8"},{"components":[{"internalType":"uint256","name":"r","type":"uint256"},{"internalType":"uint256","name":"g","type":"uint256"},{"internalType":"uint256","name":"b","type":"uint256"}],"indexed":false,"internalType":"struct IColormapRegistry.SegmentData","name":"_segmentData","type":"tuple"}],"name":"RegisterColormap","type":"event"},{"inputs":[{"components":[{"internalType":"uint256","name":"r","type":"uint256"},{"internalType":"uint256","name":"g","type":"uint256"},{"internalType":"uint256","name":"b","type":"uint256"}],"internalType":"struct IColormapRegistry.SegmentData[]","name":"_segmentDataArray","type":"tuple[]"}],"name":"batchRegister","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract IPaletteGenerator[]","name":"_paletteGenerators","type":"address[]"}],"name":"batchRegister","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes8","name":"_hash","type":"bytes8"},{"internalType":"uint256","name":"_position","type":"uint256"}],"name":"getValue","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes8","name":"_hash","type":"bytes8"},{"internalType":"uint8","name":"_position","type":"uint8"}],"name":"getValueAsHexString","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes8","name":"_hash","type":"bytes8"},{"internalType":"uint8","name":"_position","type":"uint8"}],"name":"getValueAsUint8","outputs":[{"internalType":"uint8","name":"","type":"uint8"},{"internalType":"uint8","name":"","type":"uint8"},{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes8","name":"","type":"bytes8"}],"name":"paletteGenerators","outputs":[{"internalType":"contract IPaletteGenerator","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract IPaletteGenerator","name":"_paletteGenerator","type":"address"}],"name":"register","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"r","type":"uint256"},{"internalType":"uint256","name":"g","type":"uint256"},{"internalType":"uint256","name":"b","type":"uint256"}],"internalType":"struct IColormapRegistry.SegmentData","name":"_segmentData","type":"tuple"}],"name":"register","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes8","name":"","type":"bytes8"}],"name":"segments","outputs":[{"internalType":"uint256","name":"r","type":"uint256"},{"internalType":"uint256","name":"g","type":"uint256"},{"internalType":"uint256","name":"b","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b50611563806100206000396000f3fe608060405234801561001057600080fd5b50600436106100a25760003560e01c80639295f0be11610076578063b5e5d89b1161005b578063b5e5d89b1461018c578063f14b4f3f1461019f578063f5022487146101b257600080fd5b80639295f0be1461014a57806394ab4f431461015d57600080fd5b80623a371d146100a75780633a4a8388146100d05780634420e486146101075780637ed155da1461011c575b600080fd5b6100ba6100b536600461115a565b61020d565b6040516100c79190611197565b60405180910390f35b6100e36100de36600461115a565b6103f9565b6040805160ff948516815292841660208401529216918101919091526060016100c7565b61011a610115366004611227565b6107c5565b005b61012f61012a366004611249565b6107d1565b604080519384526020840192909252908201526060016100c7565b61011a610158366004611371565b610b62565b61012f61016b366004611410565b60006020819052908152604090208054600182015460029092015490919083565b61011a61019a36600461142b565b610b9e565b61011a6101ad3660046114c3565b610bd5565b6101e86101c0366004611410565b60016020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100c7565b6060600080600061021e86866103f9565b919450925090507f3031323334353637383941424344454600000000000000000000000000000000600f600485901c166020811061025e5761025e6114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f851660208110610297576102976114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f600486901c16602081106102d4576102d46114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f86166020811061030d5761030d6114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f600487901c166020811061034a5761034a6114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f871660208110610383576103836114df565b6040517fff00000000000000000000000000000000000000000000000000000000000000978816602082015295871660218701529386166022860152918516602385015284166024840152901a60f81b909116602582015260260160405160208183030381529060405293505050505b92915050565b7fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526020818152604080832081516060810183528154808252600183015494820194909452600290910154918101919091528291829186911580156104a957507fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff16155b15610509576040517f5cc91f7e0000000000000000000000000000000000000000000000000000000081527fffffffffffffffff000000000000000000000000000000000000000000000000831660048201526024015b60405180910390fd5b7fffffffffffffffff000000000000000000000000000000000000000000000000871660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff168015610734576040517ff471d7ac000000000000000000000000000000000000000000000000000000008152660deea55900646460ff89168102600483018190529173ffffffffffffffffffffffffffffffffffffffff84169063f471d7ac90602401602060405180830381865afa1580156105d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105f5919061150e565b8161060257610602611527565b04660deea5590064648373ffffffffffffffffffffffffffffffffffffffff1663e420264a846040518263ffffffff1660e01b815260040161064691815260200190565b602060405180830381865afa158015610663573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610687919061150e565b8161069457610694611527565b04660deea5590064648473ffffffffffffffffffffffffffffffffffffffff1663cd580ff3856040518263ffffffff1660e01b81526004016106d891815260200190565b602060405180830381865afa1580156106f5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610719919061150e565b8161072657610726611527565b0496509650965050506107bc565b7fffffffffffffffff00000000000000000000000000000000000000000000000088166000908152602081815260409182902082516060810184528154808252600183015493820193909352600290910154928101929092526107979089610bde565b6107a582602001518a610bde565b6107b383604001518b610bde565b96509650965050505b50509250925092565b6107ce81610c84565b50565b7fffffffffffffffff0000000000000000000000000000000000000000000000008216600090815260208181526040808320815160608101835281548082526001830154948201949094526002909101549181019190915282918291869115801561088157507fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff16155b156108dc576040517f5cc91f7e0000000000000000000000000000000000000000000000000000000081527fffffffffffffffff00000000000000000000000000000000000000000000000083166004820152602401610500565b7fffffffffffffffff000000000000000000000000000000000000000000000000871660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff168015610ae3576040517ff471d7ac0000000000000000000000000000000000000000000000000000000081526004810188905273ffffffffffffffffffffffffffffffffffffffff82169063f471d7ac90602401602060405180830381865afa158015610995573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b9919061150e565b6040517fe420264a0000000000000000000000000000000000000000000000000000000081526004810189905273ffffffffffffffffffffffffffffffffffffffff83169063e420264a90602401602060405180830381865afa158015610a24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a48919061150e565b6040517fcd580ff3000000000000000000000000000000000000000000000000000000008152600481018a905273ffffffffffffffffffffffffffffffffffffffff84169063cd580ff390602401602060405180830381865afa158015610ab3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ad7919061150e565b955095509550506107bc565b7fffffffffffffffff0000000000000000000000000000000000000000000000008816600090815260208181526040918290208251606081018452815480825260018301549382019390935260029091015492810192909252610b469089610d41565b610b5482602001518a610d41565b6107b383604001518b610d41565b805160005b81811015610b9957610b91838281518110610b8457610b846114df565b6020026020010151610de3565b600101610b67565b505050565b805160005b81811015610b9957610bcd838281518110610bc057610bc06114df565b6020026020010151610c84565b600101610ba3565b6107ce81610de3565b60005b8160ff16602884901c60ff161015610bff57601883901c9250610be1565b62ffffff80841690601885901c1660ff601086901c811690602887901c81169080881690602089901c8116908816849003848403838310610c5f5780828585030281610c4d57610c4d611527565b048401985050505050505050506103f3565b80828486030281610c7257610c72611527565b049093039a9950505050505050505050565b6000610c8f82610ead565b7fffffffffffffffff000000000000000000000000000000000000000000000000811660008181526001602090815260409182902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff88169081179091558251938452908301529192507f51ab537ce60b5d5811824fe7db687b6ec835ba55ec37a2eadfd81c894154983b91015b60405180910390a15050565b6000670de0b6b3a763ff9c8211610d585781610d62565b670de0b6b3a763ff9c5b91505b81660deea559006464602885901c60ff16021015610d8957601883901c9250610d65565b62ffffff80841690601885901c1660ff601086901c8116660deea55900646490810291602888901c811682029181891681029160208a901c1602838803848403838310610c5f5780828585030281610c4d57610c4d611527565b6000610dee82610f06565b9050610dfd8260000151610f35565b610e0a8260200151610f35565b610e178260400151610f35565b7fffffffffffffffff0000000000000000000000000000000000000000000000008116600081815260208181526040918290208551815585820180516001830155868401805160029093019290925583519485528651928501929092529051918301919091525160608201527ff5665410b696554012166bb4b875c112e43a1e873201a48c6e194010272ee23390608001610d35565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606083901b16602082015260009081906034015b6040516020818303038152906040528051906020012090506103f38161101e565b805160208083015160408085015181519384019490945282015260608101919091526000908190608001610ee5565b60ff601082901c168015610f78576040517f524661ea00000000000000000000000000000000000000000000000000000000815260048101839052602401610500565b601882901c5b8015610fdb5760ff601082901c16828111610fc8576040517f524661ea00000000000000000000000000000000000000000000000000000000815260048101859052602401610500565b5060ff601082901c16915060181c610f7e565b5060ff81101561101a576040517f524661ea00000000000000000000000000000000000000000000000000000000815260048101839052602401610500565b5050565b7fffffffffffffffff00000000000000000000000000000000000000000000000081166000908152602081815260409182902082516060810184528154808252600183015493820193909352600290910154928101929092521515806110ca57507fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff1615155b1561101a576040517f2996eda90000000000000000000000000000000000000000000000000000000081527fffffffffffffffff00000000000000000000000000000000000000000000000083166004820152602401610500565b80357fffffffffffffffff0000000000000000000000000000000000000000000000008116811461115557600080fd5b919050565b6000806040838503121561116d57600080fd5b61117683611125565b9150602083013560ff8116811461118c57600080fd5b809150509250929050565b600060208083528351808285015260005b818110156111c4578581018301518582016040015282016111a8565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461115557600080fd5b60006020828403121561123957600080fd5b61124282611203565b9392505050565b6000806040838503121561125c57600080fd5b61126583611125565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156112e9576112e9611273565b604052919050565b600067ffffffffffffffff82111561130b5761130b611273565b5060051b60200190565b60006060828403121561132757600080fd5b6040516060810181811067ffffffffffffffff8211171561134a5761134a611273565b80604052508091508235815260208301356020820152604083013560408201525092915050565b6000602080838503121561138457600080fd5b823567ffffffffffffffff81111561139b57600080fd5b8301601f810185136113ac57600080fd5b80356113bf6113ba826112f1565b6112a2565b818152606091820283018401918482019190888411156113de57600080fd5b938501935b83851015611404576113f58986611315565b835293840193918501916113e3565b50979650505050505050565b60006020828403121561142257600080fd5b61124282611125565b6000602080838503121561143e57600080fd5b823567ffffffffffffffff81111561145557600080fd5b8301601f8101851361146657600080fd5b80356114746113ba826112f1565b81815260059190911b8201830190838101908783111561149357600080fd5b928401925b828410156114b8576114a984611203565b82529284019290840190611498565b979650505050505050565b6000606082840312156114d557600080fd5b6112428383611315565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561152057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c6343000815000a
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100a25760003560e01c80639295f0be11610076578063b5e5d89b1161005b578063b5e5d89b1461018c578063f14b4f3f1461019f578063f5022487146101b257600080fd5b80639295f0be1461014a57806394ab4f431461015d57600080fd5b80623a371d146100a75780633a4a8388146100d05780634420e486146101075780637ed155da1461011c575b600080fd5b6100ba6100b536600461115a565b61020d565b6040516100c79190611197565b60405180910390f35b6100e36100de36600461115a565b6103f9565b6040805160ff948516815292841660208401529216918101919091526060016100c7565b61011a610115366004611227565b6107c5565b005b61012f61012a366004611249565b6107d1565b604080519384526020840192909252908201526060016100c7565b61011a610158366004611371565b610b62565b61012f61016b366004611410565b60006020819052908152604090208054600182015460029092015490919083565b61011a61019a36600461142b565b610b9e565b61011a6101ad3660046114c3565b610bd5565b6101e86101c0366004611410565b60016020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100c7565b6060600080600061021e86866103f9565b919450925090507f3031323334353637383941424344454600000000000000000000000000000000600f600485901c166020811061025e5761025e6114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f851660208110610297576102976114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f600486901c16602081106102d4576102d46114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f86166020811061030d5761030d6114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f600487901c166020811061034a5761034a6114df565b1a60f81b7f3031323334353637383941424344454600000000000000000000000000000000600f871660208110610383576103836114df565b6040517fff00000000000000000000000000000000000000000000000000000000000000978816602082015295871660218701529386166022860152918516602385015284166024840152901a60f81b909116602582015260260160405160208183030381529060405293505050505b92915050565b7fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526020818152604080832081516060810183528154808252600183015494820194909452600290910154918101919091528291829186911580156104a957507fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff16155b15610509576040517f5cc91f7e0000000000000000000000000000000000000000000000000000000081527fffffffffffffffff000000000000000000000000000000000000000000000000831660048201526024015b60405180910390fd5b7fffffffffffffffff000000000000000000000000000000000000000000000000871660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff168015610734576040517ff471d7ac000000000000000000000000000000000000000000000000000000008152660deea55900646460ff89168102600483018190529173ffffffffffffffffffffffffffffffffffffffff84169063f471d7ac90602401602060405180830381865afa1580156105d1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105f5919061150e565b8161060257610602611527565b04660deea5590064648373ffffffffffffffffffffffffffffffffffffffff1663e420264a846040518263ffffffff1660e01b815260040161064691815260200190565b602060405180830381865afa158015610663573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610687919061150e565b8161069457610694611527565b04660deea5590064648473ffffffffffffffffffffffffffffffffffffffff1663cd580ff3856040518263ffffffff1660e01b81526004016106d891815260200190565b602060405180830381865afa1580156106f5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610719919061150e565b8161072657610726611527565b0496509650965050506107bc565b7fffffffffffffffff00000000000000000000000000000000000000000000000088166000908152602081815260409182902082516060810184528154808252600183015493820193909352600290910154928101929092526107979089610bde565b6107a582602001518a610bde565b6107b383604001518b610bde565b96509650965050505b50509250925092565b6107ce81610c84565b50565b7fffffffffffffffff0000000000000000000000000000000000000000000000008216600090815260208181526040808320815160608101835281548082526001830154948201949094526002909101549181019190915282918291869115801561088157507fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff16155b156108dc576040517f5cc91f7e0000000000000000000000000000000000000000000000000000000081527fffffffffffffffff00000000000000000000000000000000000000000000000083166004820152602401610500565b7fffffffffffffffff000000000000000000000000000000000000000000000000871660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff168015610ae3576040517ff471d7ac0000000000000000000000000000000000000000000000000000000081526004810188905273ffffffffffffffffffffffffffffffffffffffff82169063f471d7ac90602401602060405180830381865afa158015610995573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109b9919061150e565b6040517fe420264a0000000000000000000000000000000000000000000000000000000081526004810189905273ffffffffffffffffffffffffffffffffffffffff83169063e420264a90602401602060405180830381865afa158015610a24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a48919061150e565b6040517fcd580ff3000000000000000000000000000000000000000000000000000000008152600481018a905273ffffffffffffffffffffffffffffffffffffffff84169063cd580ff390602401602060405180830381865afa158015610ab3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ad7919061150e565b955095509550506107bc565b7fffffffffffffffff0000000000000000000000000000000000000000000000008816600090815260208181526040918290208251606081018452815480825260018301549382019390935260029091015492810192909252610b469089610d41565b610b5482602001518a610d41565b6107b383604001518b610d41565b805160005b81811015610b9957610b91838281518110610b8457610b846114df565b6020026020010151610de3565b600101610b67565b505050565b805160005b81811015610b9957610bcd838281518110610bc057610bc06114df565b6020026020010151610c84565b600101610ba3565b6107ce81610de3565b60005b8160ff16602884901c60ff161015610bff57601883901c9250610be1565b62ffffff80841690601885901c1660ff601086901c811690602887901c81169080881690602089901c8116908816849003848403838310610c5f5780828585030281610c4d57610c4d611527565b048401985050505050505050506103f3565b80828486030281610c7257610c72611527565b049093039a9950505050505050505050565b6000610c8f82610ead565b7fffffffffffffffff000000000000000000000000000000000000000000000000811660008181526001602090815260409182902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff88169081179091558251938452908301529192507f51ab537ce60b5d5811824fe7db687b6ec835ba55ec37a2eadfd81c894154983b91015b60405180910390a15050565b6000670de0b6b3a763ff9c8211610d585781610d62565b670de0b6b3a763ff9c5b91505b81660deea559006464602885901c60ff16021015610d8957601883901c9250610d65565b62ffffff80841690601885901c1660ff601086901c8116660deea55900646490810291602888901c811682029181891681029160208a901c1602838803848403838310610c5f5780828585030281610c4d57610c4d611527565b6000610dee82610f06565b9050610dfd8260000151610f35565b610e0a8260200151610f35565b610e178260400151610f35565b7fffffffffffffffff0000000000000000000000000000000000000000000000008116600081815260208181526040918290208551815585820180516001830155868401805160029093019290925583519485528651928501929092529051918301919091525160608201527ff5665410b696554012166bb4b875c112e43a1e873201a48c6e194010272ee23390608001610d35565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606083901b16602082015260009081906034015b6040516020818303038152906040528051906020012090506103f38161101e565b805160208083015160408085015181519384019490945282015260608101919091526000908190608001610ee5565b60ff601082901c168015610f78576040517f524661ea00000000000000000000000000000000000000000000000000000000815260048101839052602401610500565b601882901c5b8015610fdb5760ff601082901c16828111610fc8576040517f524661ea00000000000000000000000000000000000000000000000000000000815260048101859052602401610500565b5060ff601082901c16915060181c610f7e565b5060ff81101561101a576040517f524661ea00000000000000000000000000000000000000000000000000000000815260048101839052602401610500565b5050565b7fffffffffffffffff00000000000000000000000000000000000000000000000081166000908152602081815260409182902082516060810184528154808252600183015493820193909352600290910154928101929092521515806110ca57507fffffffffffffffff000000000000000000000000000000000000000000000000821660009081526001602052604090205473ffffffffffffffffffffffffffffffffffffffff1615155b1561101a576040517f2996eda90000000000000000000000000000000000000000000000000000000081527fffffffffffffffff00000000000000000000000000000000000000000000000083166004820152602401610500565b80357fffffffffffffffff0000000000000000000000000000000000000000000000008116811461115557600080fd5b919050565b6000806040838503121561116d57600080fd5b61117683611125565b9150602083013560ff8116811461118c57600080fd5b809150509250929050565b600060208083528351808285015260005b818110156111c4578581018301518582016040015282016111a8565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461115557600080fd5b60006020828403121561123957600080fd5b61124282611203565b9392505050565b6000806040838503121561125c57600080fd5b61126583611125565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156112e9576112e9611273565b604052919050565b600067ffffffffffffffff82111561130b5761130b611273565b5060051b60200190565b60006060828403121561132757600080fd5b6040516060810181811067ffffffffffffffff8211171561134a5761134a611273565b80604052508091508235815260208301356020820152604083013560408201525092915050565b6000602080838503121561138457600080fd5b823567ffffffffffffffff81111561139b57600080fd5b8301601f810185136113ac57600080fd5b80356113bf6113ba826112f1565b6112a2565b818152606091820283018401918482019190888411156113de57600080fd5b938501935b83851015611404576113f58986611315565b835293840193918501916113e3565b50979650505050505050565b60006020828403121561142257600080fd5b61124282611125565b6000602080838503121561143e57600080fd5b823567ffffffffffffffff81111561145557600080fd5b8301601f8101851361146657600080fd5b80356114746113ba826112f1565b81815260059190911b8201830190838101908783111561149357600080fd5b928401925b828410156114b8576114a984611203565b82529284019290840190611498565b979650505050505050565b6000606082840312156114d557600080fd5b6112428383611315565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561152057600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fdfea164736f6c6343000815000a
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
[ Download: CSV Export ]
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.