# How to create a new colormap

**URL:** <https://vapor.discourse.group/t/how-to-create-a-new-colormap/272>\
**Category:** Uncategorized\
**Created:** [February 10, 2023, 8:04am UTC](https://vapor.discourse.group/t/how-to-create-a-new-colormap/272 "2023-02-10T08:04:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mingyu](https://avatars.discourse-cdn.com/v4/letter/m/77aa72/32.png) [@Mingyu](https://vapor.discourse.group/u/Mingyu)\
**Post date:** [February 10, 2023, 8:04am UTC](https://vapor.discourse.group/t/how-to-create-a-new-colormap/272/1 "2023-02-10T08:04:05Z")

</div>

Hi,  
I installed the VAPOR 3.8.  
I want to draw a figure using the palette via modifying the colormap file.  
While the file downloaded is totally beyond understanding.  
The colormap file reads as follows:  
  
  
0  
  
  
-0.004999999888241291 0.009999999776482582  
  
  
1  
  
  
  
4  
  
  
1  
  
  
0.644444465637207 0.6949999928474426 0.7570000290870667 0.1362799257040024 0.0643620565533638 0.0801708921790123 0.8944974541664124 0.3093922734260559 0.05888497084379196 0.1599867194890976 0.923209011554718 0.3609576523303986 0.9729180335998535 0.9273130297660828 0.7137835025787354 0.530386745929718 0.9666666666666667 0.977 0.706 0.99

I want to know how I can create my own colormap.  
Your help is highly appreciated!

Mingyu

---

<div class="post-metadata">

**Author:** ![pearse](https://yyz2.discourse-cdn.com/free1/user_avatar/vapor.discourse.group/pearse/32/177_2.png) [@pearse](https://vapor.discourse.group/u/pearse)\
**Post date:** [February 10, 2023, 7:00pm UTC](https://vapor.discourse.group/t/how-to-create-a-new-colormap/272/2 "2023-02-10T19:00:23Z")

</div>

I’m guessing that you’re looking at the .tf3 files located in Vapor’s share directory, or elsewhere. I’ve copied BlackBody.tf3’s ColorMapControlPoints section from the .xml file below.

BlackBody contains five color control points that are described by Hue, Saturation, Value, and Position values that range between 0 and 1. You can create your own custom HSVP values in this manner, as well as edit other parameters for your colormap in the .xml file.

If you’re not familiar with the HSV color space, [this website](http://colormine.org/color-converter) can help you convert RGB values into HSV. Hope that helps.

```auto
<ColorMapControlPoints Type="Double">
-0.002785515272989869 0 0 0
 0 0.8117647171020508 0.6980392336845398 0.3912840485572815
 0.07520891726016998 0.9803921580314636 0.8901960849761963 0.5801073312759399
 0.1448467969894409 0.9176470637321472 0.9333333373069763 0.8404544591903687
-0.002785515272989869 0 1 0.9900000095367432
</ColorMapControlPoints>

```

---

<div class="post-metadata">

**Author:** ![Mingyu](https://avatars.discourse-cdn.com/v4/letter/m/77aa72/32.png) [@Mingyu](https://vapor.discourse.group/u/Mingyu)\
**Post date:** [February 11, 2023, 8:58am UTC](https://vapor.discourse.group/t/how-to-create-a-new-colormap/272/3 "2023-02-11T08:58:47Z")

</div>

Thank your very much!  
That really help a lot!
