# Advice to improve performance of a 3D model composed of many blocks

**URL:** <https://discourse.processing.org/t/advice-to-improve-performance-of-a-3d-model-composed-of-many-blocks/38446>\
**Category:** Development\
**Created:** [August 21, 2022, 6:38pm UTC](https://discourse.processing.org/t/advice-to-improve-performance-of-a-3d-model-composed-of-many-blocks/38446 "2022-08-21T18:38:19Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![ramith](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/ramith/32/16833_2.png) [@ramith](https://discourse.processing.org/u/ramith)\
**Post date:** [August 23, 2022, 7:19pm UTC](https://discourse.processing.org/t/advice-to-improve-performance-of-a-3d-model-composed-of-many-blocks/38446/10 "2022-08-23T19:19:18Z")

</div>

Thank you !! @scudly & @sableraph

Starting from @scudly 's code, I was able to extend it to my need without performance issues. Will explore more!

I actually didn’t have any idea about creating it using a single mesh, quite fascinating!

Edit : There was another discussion on p5.geometry I will add that link here, i think there is an example with texture in it

> [@What does p5.Geometry do and how to use it?](https://discourse.processing.org/t/what-does-p5-geometry-do-and-how-to-use-it/29919/2):
>
> p5.Geometry is used to represent 3d objects. It is returned by the [loadModel() function](https://p5js.org/reference/#/p5/loadModel), and also used internally by the 3d primitive drawing functions. 3d objects are commonly described as a list of vertices, a list of vertex normals, a list of triangles which reference the vertexes, and a list of texture coordinates for each vertex. Vertex normals are a vector describing the direction of the surface of the object at that point which is used to affect how light will illuminate a surface based o…

 ![Screenshot 2022-08-23 at 15.16.44](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/d/1/d1da7a7fd3e272e13b4ba2e08b7993e69ff46056.jpeg)

---

_[View the full topic](https://discourse.processing.org/t/advice-to-improve-performance-of-a-3d-model-composed-of-many-blocks/38446)._
