# Problem Changing Point Colors in PointsCloudSystem Through Material

**URL:** <https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798>\
**Category:** Questions\
**Tags:** material, point-cloud\
**Created:** [December 29, 2023, 6:49am UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798 "2023-12-29T06:49:39Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ertugrulcetin](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/ertugrulcetin/32/33011_2.png) [@ertugrulcetin](https://forum.babylonjs.com/u/ertugrulcetin)\
**Post date:** [December 29, 2023, 6:49am UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/1 "2023-12-29T06:49:39Z")

</div>

I’m working with PointsCloudSystem and have encountered an issue where I cannot change the colors of the points through the material. I am aware that the color of each point can be set individually in the `particle.color` property within the `addPoints` method, but for my use case, I need to control the point colors through the material instead.

Here’s a link to my Playground where I’ve set up the PCS and material: [https://playground.babylonjs.com/#M1CA97#5](https://playground.babylonjs.com/#M1CA97#5).

Any advice on how to achieve color changes through the material for PCS points would be greatly appreciated!

---

<div class="post-metadata">

**Author:** ![carolhmj](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carolhmj/32/25918_2.png) [@carolhmj](https://forum.babylonjs.com/u/carolhmj)\
**Post date:** [January 2, 2024, 5:11pm UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/2 "2024-01-02T17:11:19Z")

</div>

> [@ertugrulcetin](#):
>
> but for my use case, I need to control the point colors through the material instead.

Just trying to understand your case better, why does it need to be through the material?

I experimented a bit and found one possibility is using Material Plugin: [Basic Point Cloud with Plugin Material | Babylon.js Playground (babylonjs.com)](https://playground.babylonjs.com/#I9YNNB#4)

---

<div class="post-metadata">

**Author:** ![carolhmj](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carolhmj/32/25918_2.png) [@carolhmj](https://forum.babylonjs.com/u/carolhmj)\
**Post date:** [January 2, 2024, 5:45pm UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/3 "2024-01-02T17:45:18Z")

</div>

Oh, thanks to @sebavan , now I know it is possible with a ShaderMaterial too, but it needs to set gl\_PointSize: [Basic Point Cloud | Babylon.js Playground (babylonjs.com)](https://playground.babylonjs.com/#I9YNNB#9)

---

<div class="post-metadata">

**Author:** ![ertugrulcetin](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/ertugrulcetin/32/33011_2.png) [@ertugrulcetin](https://forum.babylonjs.com/u/ertugrulcetin)\
**Post date:** [January 2, 2024, 10:00pm UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/4 "2024-01-02T22:00:39Z")

</div>

Thank you so much, that helped a lot! I used material because I wanted to use `emissiveColor` to use glow effect etc. Are there any options without using material?

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [January 2, 2024, 10:44pm UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/5 "2024-01-02T22:44:43Z")

</div>

> [@ertugrulcetin](#):
>
> Are there any options without using material?

Not sure to understand what you are asking as you need a material to render a mesh. This is representing the shader we are using under the hood.

---

<div class="post-metadata">

**Author:** ![ertugrulcetin](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/ertugrulcetin/32/33011_2.png) [@ertugrulcetin](https://forum.babylonjs.com/u/ertugrulcetin)\
**Post date:** [January 3, 2024, 12:53pm UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/6 "2024-01-03T12:53:28Z")

</div>

> [@carolhmj](#):
>
> Just trying to understand your case better, why does it need to be through the material?

She asked me why I need get it done through material, so I asked liked that

---

<div class="post-metadata">

**Author:** ![carolhmj](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/carolhmj/32/25918_2.png) [@carolhmj](https://forum.babylonjs.com/u/carolhmj)\
**Post date:** [January 3, 2024, 1:03pm UTC](https://forum.babylonjs.com/t/problem-changing-point-colors-in-pointscloudsystem-through-material/46798/7 "2024-01-03T13:03:30Z")

</div>

Oh, I was just asking because I was curious why `particle.color` couldn’t be used 😅
