# Vertices and triangles count

**URL:** <https://discourse.threejs.org/t/vertices-and-triangles-count/19792>\
**Category:** Questions\
**Tags:** geometry\
**Created:** [October 15, 2020, 4:54pm UTC](https://discourse.threejs.org/t/vertices-and-triangles-count/19792 "2020-10-15T16:54:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![lluull](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/lluull/32/11116_2.png) [@lluull](https://discourse.threejs.org/u/lluull)\
**Post date:** [October 15, 2020, 4:54pm UTC](https://discourse.threejs.org/t/vertices-and-triangles-count/19792/1 "2020-10-15T16:54:26Z")

</div>

Hi,

i display the vertices and triangles count on model selected.

When is a Geometry is simple as using vertices.length and faces.length.

But when is a BufferGeometry.  
The vertices = attributes.position.count.  
There is no faces attribute, so just divide this by 3 for the triangles and it seem ok  
And when is index.  
The index.count can be much higher and even divided by 3 the triangles is greater than the vertices count.  
What is the real good value to use as vertices count when is index ?  
The attributes.position.count or the index.count ?

thx.

---

<div class="post-metadata">

**Author:** ![Mugen87](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/mugen87/32/5645_2.png) [@Mugen87](https://discourse.threejs.org/u/Mugen87)\
**Post date:** [October 15, 2020, 4:56pm UTC](https://discourse.threejs.org/t/vertices-and-triangles-count/19792/2 "2020-10-15T16:56:22Z")

</div>

> [@lluull](#):
>
> What is the real good value to use as vertices count when is index ?

The vertex count is always `position.count`. The number of rendered triangles depends on whether the geometry is indexed or non-indexed. If there is an index, it’s `index.count / 3`. Otherwise it’s `position.count / 3`.

---

<div class="post-metadata">

**Author:** ![lluull](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.threejs.org/lluull/32/11116_2.png) [@lluull](https://discourse.threejs.org/u/lluull)\
**Post date:** [October 15, 2020, 5:07pm UTC](https://discourse.threejs.org/t/vertices-and-triangles-count/19792/3 "2020-10-15T17:07:44Z")

</div>

Thx for the super quick answer

Yep, is what i was doing, and is why i ask about.  
Because this make me feel strange to have a possible triangles count superior to the vertices count.
