glvis icon indicating copy to clipboard operation
glvis copied to clipboard

Additional color palettes?

Open tzanio opened this issue 1 year ago • 5 comments

Consider adding support for additional color palettes such as the colour-vision deficiency friendly and perceptually-uniform colour maps at https://zenodo.org/records/8409685

+ScientificColourMaps8-FabioCrameri

See also https://github.com/GLVis/glvis/tree/colormap_dev

tzanio avatar Jan 27 '24 21:01 tzanio

I can work on this.

justinlaughlin avatar Feb 05 '24 22:02 justinlaughlin

I think I've tried every one of the colormaps from Fabio Crameri in grad school :'). A couple quick thoughts... colormap designers often emphasize linear luminosity (one of the main criticisms of jet is that its luminosity is nonlinear and non-monotonic) which is a feature that makes perfect sense for 2d data. However in 3d it can start to lose significance because there is almost always some kind of lighting applied to the scene. It is still a good thing to have, but IMO span of luminosity+color is more important in a scene with lighting. I like batlow and lipari from this set, as they are perceptually uniform, span many colors, and look good. I'm not a huge fan of colormaps like buda and nuuk as their range of color/luminosity is small, so scene lighting will more dramatically influence perception.

Lmk if you have any thoughts on which colormaps we should add.

justinlaughlin avatar Feb 05 '24 23:02 justinlaughlin

I'm also wondering if we need more colormaps, but if we decide to add them, I do like batlow and lipari myself.

We already have some perceptually uniform maps in https://github.com/GLVis/glvis/blob/master/lib/palettes.cpp from https://github.com/1313e/CMasher and https://bids.github.io/colormap/.

tzanio avatar Feb 06 '24 00:02 tzanio

If there is too many options we might need a different interface to choose a colormap besides "cycling". Maybe the most common colormaps can be cycled through, and for those who want more options, a separate hotkey could let you input a name to a specific colormap. That way we could add in as many colormaps as we want without cluttering the colormap cycle.

justinlaughlin avatar Feb 07 '24 20:02 justinlaughlin

You can always "jump" to a particular color palette with F6, but I agree that cycling through a lot of palettes has its downsides.

Another option could be to enable extra palettes with a build options.

tzanio avatar Feb 07 '24 23:02 tzanio