Clarify colormap_name requirements and usage - #25
emmanuelmathot wants to merge 3 commits into
Conversation
We also have custom colormap names in titiler I'm starting to feel that it will be difficult to generalize renders for many backends/clients 🤷 |
|
Such an extension will be a compromise if we don't want this to be the "titiler" extension (which should then be the name), and never be supporting everything that a specific implementation might support. User could use colormap instead of pre-defined names for those additional cases. Coming up with a more interoperable compromise render extension is generally a good way forward IMHO. That could make it work for the "80%" of the cases for everyone instead of 100% only for titiler. |
Co-authored-by: Matthias Mohr <m.mohr@moregeo.it>
| | colormap | object | [Color map JSON definition](https://developmentseed.org/titiler/user_guide/rendering/#custom-colormaps) that must be applied for a raster band | | ||
| | color_formula | string | [Color formula](https://developmentseed.org/titiler/user_guide/rendering/#color-formula) that must be applied for a raster band | | ||
| | rescale | \[float] | 2 dimensions array of delimited Min,Max range per band. If not provided, the data will not be rescaled. | | | ||
| | colormap_name | string | Name of a standard [matplotlib colormap](https://matplotlib.org/stable/users/explain/colors/colormaps.html) (e.g. `viridis`, `YlGn`) to apply to a raster band. Third party colormaps are not supported, use `colormap` instead. | |
There was a problem hiding this comment.
| | colormap_name | string | Name of a standard [matplotlib colormap](https://matplotlib.org/stable/users/explain/colors/colormaps.html) (e.g. `viridis`, `YlGn`) to apply to a raster band. Third party colormaps are not supported, use `colormap` instead. | | |
| | colormap_name | string | Name of a standard [matplotlib colormap](https://matplotlib.org/3.11.2/users/explain/colors/colormaps.html) (e.g. `viridis`, `YlGn`) to apply to a raster band. Third party colormaps are not supported, use `colormap` instead. | |
Not 100% sure, but should this link to a specific version to ensure we are not implementing against a moving target?
Update the CHANGELOG and README to specify that
colormap_namemust be a standard matplotlib colormap name, ensuring a consistent naming convention for raster bands. Include additional details on how to use colormaps with titiler.fixes #14
This is a breaking change and will require a version bump