How to fill a surface of a mesh with other mesh?

I am looking for a way to fill a surface of a mesh with other mesh.
Something like this screenshot (the surface of the cube filled by spheres).


Any help would be appreciated!

If you really need them to form a correct grid, you’ll probably have to do it manually. Use an InstancedStaticMesh Component and add a lot of instances in a double For Loop, but you’ll have to do some math to calculate exact locations.

P.S. By “manually” I mean write code that will automatically place spheres, not place them manually =)

Thanks for the idea, but the problem is this solution will only work for a cube. I need it to work on any mesh/model. (Unreal’s mannequin, chair, sphere, etc)

I was thinking about using the vertices of the mesh somehow, but I’m still stuck on how I would go with this idea.

1 Like

My first thought was a particle system, but I don’t know if it’s possible to make particles spawn uniformly without overlapping each other =(