Justify more effective instanceCount value

Hmm, is there an effective way to instantiate instances based on the Terrain size so it’s entirely covered?

For example:

I guess I’m looking for a Math function which takes the Terrain scale and radius to justify a reasonable instanceCount value, or maybe even the heightmap from the terrain itself.

Usually for this purpose, your terrain is subdivided into some square areas. And as the camera moves, you generate instances only on the areas near the camera, and remove those further away - usually using some kind of fading out or similar to hide the pop.
Otherwise you end up rendering way too much.


I got ya, I also thought upon moving the matrices based on the player position yet this approach seems more ideal.