# Number of points in a Mesh3D

**URL:** <https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212>\
**Category:** 📊 Plotly Python\
**Created:** [August 26, 2020, 12:30pm UTC](https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212 "2020-08-26T12:30:15Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Raudcu](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/raudcu/32/11615_2.png) [@Raudcu](https://community.plotly.com/u/Raudcu)\
**Post date:** [August 26, 2020, 12:30pm UTC](https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212/1 "2020-08-26T12:30:15Z")

</div>

Hi there! I wanted to know if it’s possibly to control the number (density actually) of points in a Mesh3D.

I developed a Dash App to draw an specific crystallographic structure (made of Tetrahedra) and the user it’s able to add elements to it.

The thing is that I want to improve performance because it takes a while to render the plot with all the thing that have in it, and that affects the dynamic of the app a little bit.

So, does anyone know if it’s possible to have less points in a Mesh3D in order to achieve a faster renderization?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![empet](https://avatars.discourse-cdn.com/v4/letter/e/977dab/32.png) [@empet](https://community.plotly.com/u/empet)\
**Post date:** [August 26, 2020, 5:13pm UTC](https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212/2 "2020-08-26T17:13:09Z")

</div>

@Raudcu

Plottiing only boundary faces reduces drastically the number of points. Here is such a solution given as answer to a similar question: [https://chart-studio.plotly.com/~empet/15549](https://chart-studio.plotly.com/~empet/15549)

---

<div class="post-metadata">

**Author:** ![Raudcu](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/raudcu/32/11615_2.png) [@Raudcu](https://community.plotly.com/u/Raudcu)\
**Post date:** [August 26, 2020, 6:08pm UTC](https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212/3 "2020-08-26T18:08:17Z")

</div>

@empet thank you for the quick answer! So, what you mean is that in order to have less point (ans thus have a faster renderization) what I should do is use Scatter3D with the option to color the surface. Did I get it right?

---

<div class="post-metadata">

**Author:** ![empet](https://avatars.discourse-cdn.com/v4/letter/e/977dab/32.png) [@empet](https://community.plotly.com/u/empet)\
**Post date:** [August 26, 2020, 6:16pm UTC](https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212/4 "2020-08-26T18:16:35Z")

</div>

@Raudcu

No, What I suggest is not to plot the entire structure, but only its boundary that is seen by a user. The Scatter3d was added as an auxilliary trace, to point out the vertices of the boundary faces.

---

<div class="post-metadata">

**Author:** ![Raudcu](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/raudcu/32/11615_2.png) [@Raudcu](https://community.plotly.com/u/Raudcu)\
**Post date:** [August 26, 2020, 6:33pm UTC](https://community.plotly.com/t/number-of-points-in-a-mesh3d/44212/5 "2020-08-26T18:33:36Z")

</div>

Ah! I understand. The problem is that the majority of the structure (if not all) is seen all the time. I attached a typical view:

![pyrodash_figure](https://us1.discourse-cdn.com/flex024/uploads/plot/original/2X/d/d72f2ad1c14e968f5459709cc2d0e9d90cf6bce3.png)

Also, if you want to, you can see a demo of the app here:

[https://pyrodash.azurewebsites.net/](https://pyrodash.azurewebsites.net/)

(it may take a while to load the first time because it’s deployed with a free plan)
