# How to make the contours of the electric potential colorful

**URL:** <https://root-forum.cern.ch/t/how-to-make-the-contours-of-the-electric-potential-colorful/48029>\
**Category:** Garfield++\
**Created:** [December 11, 2021, 5:59am UTC](https://root-forum.cern.ch/t/how-to-make-the-contours-of-the-electric-potential-colorful/48029 "2021-12-11T05:59:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![XiCheng](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/x/aca169/32.png) [@XiCheng](https://root-forum.cern.ch/u/XiCheng)\
**Post date:** [December 11, 2021, 5:59am UTC](https://root-forum.cern.ch/t/how-to-make-the-contours-of-the-electric-potential-colorful/48029/1 "2021-12-11T05:59:46Z")

</div>

I want to set the contours of the electric potential different colors, the color can change with the different value of electric potential.

 ![field contour](https://root-forum.cern.ch/uploads/default/original/3X/4/d/4d6bd4d4dc06698f3cf05667be261292cd0be09f.png)

---

<div class="post-metadata">

**Author:** ![XiCheng](https://root-forum.cern.ch/letter_avatar_proxy/v4/letter/x/aca169/32.png) [@XiCheng](https://root-forum.cern.ch/u/XiCheng)\
**Post date:** [December 11, 2021, 6:27am UTC](https://root-forum.cern.ch/t/how-to-make-the-contours-of-the-electric-potential-colorful/48029/2 "2021-12-11T06:27:18Z")

</div>

I have solved the problem now, it’s a trivial problem, just use the SetColor function.

---

<div class="post-metadata">

**Author:** ![system](https://root-forum.cern.ch/uploads/default/original/3X/e/f/efe4f24398fd8ffeb76bccb6ecc46d9d9c003376.png) [@system](https://root-forum.cern.ch/u/system)\
**Post date:** [December 25, 2021, 6:28am UTC](https://root-forum.cern.ch/t/how-to-make-the-contours-of-the-electric-potential-colorful/48029/3 "2021-12-25T06:28:04Z")

</div>

Closed on December 25, 2021, 6:28am UTC

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
