# Howto increase Verts in a Procedural Cube

**URL:** <https://forums.unrealengine.com/t/howto-increase-verts-in-a-procedural-cube/431486>\
**Category:** World Creation\
**Tags:** Procedural-Generation, procedural-geometry, unreal-engine, CPP, question\
**Created:** [August 12, 2018, 11:10am UTC](https://forums.unrealengine.com/t/howto-increase-verts-in-a-procedural-cube/431486 "2018-08-12T11:10:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![HOUmmel](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/hoummel/32/1055696_2.png) [@HOUmmel](https://forums.unrealengine.com/u/HOUmmel)\
**Post date:** [August 12, 2018, 11:10am UTC](https://forums.unrealengine.com/t/howto-increase-verts-in-a-procedural-cube/431486/1 "2018-08-12T11:10:44Z")

</div>

Hello,

i try to create a Cube during Runtime with ProceduralMeshComponent. Creating a Cube with 24 Verts works fine.  
The thing is, i want to have more than 24 Verts so i can male a Sphere from it with adjustable detail.

I struggle to generate the Triangles Indices for the CreateMeshSection(…) function  
[UE4 - Sphere from Cube (Procedural Mesh Test) - YouTube](https://www.youtube.com/watch?v=jVi5GvDpB_o) like this

---

<div class="post-metadata">

**Author:** ![HOUmmel](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/hoummel/32/1055696_2.png) [@HOUmmel](https://forums.unrealengine.com/u/HOUmmel)\
**Post date:** [August 15, 2018, 11:36am UTC](https://forums.unrealengine.com/t/howto-increase-verts-in-a-procedural-cube/431486/2 "2018-08-15T11:36:53Z")

</div>

Found a Solution. I Create a Cube with 24 Verts. Than i use subdivision to get a Cube with more Verts.

```
	// For Cube
	v12 = (v1 + v2) / 2;
	v23 = (v2 + v3) / 2;
	v31 = (v3 + v1) / 2;
```
