Terrain Processor: Area: High-density Cluster: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(Created page with "Area__NOTOC__ {| style="background:#eee;" | '''Task name''': Area: Hight-density Cluster '''Dll plugin name''': BITasksPlugin.dll '''Ge...")
 
m (Text replacement - "[[Image:" to "[[File:")
 
(5 intermediate revisions by 3 users not shown)
Line 1: Line 1:
[[Category:Terrain Processor Manual|Area]]__NOTOC__
[[Category:Terrain Processor Manual|Area]]
{| style="background:#eee;"
{{TerrainProcessorManual|Area: Hight-density Cluster|BITasksPlugin.dll|Polygon, PolygonM, PolygonZ|No
| '''Task name''': Area: Hight-density Cluster
|DESCRIPTION=Random placement of multiple objects inside the polygons specified in the given shapefile. First step is to create lifegrid. Lifegrid is 2D table where every cell has information about its Object prototype. Algorithm puts some first seeds. Counts and types of seeds depends on input parameters. Ideal for high density areas like forest.


'''Dll plugin name''': BITasksPlugin.dll
==== Example ====
 
'''Geometry type''': Polygon, PolygonM, PolygonZ
 
'''Heightmap''': No
|}
 
== Description ==
Random placement of multiple objects inside the polygons specified in the given shapefile. First step is to create lifegrid. Lifegrid is 2D table where every cell has information about its Object prototype. Algorithm puts some first seeds. Counts and types of seeds depends on input parameters. Ideal for high density areas like forest.
 
'''Example :'''
* Spruce 85% PROB
* Spruce 85% PROB
* Pine 10% PROB
* Pine 10% PROB
* Larch 5% PROB
* Larch 5% PROB
See the bottom of the page for the data from the example.


{| class="bikitable sortable"  
|TASKPARAMETERS=* '''Random seed''' - number used to initialize pseudorandom number generator.
* '''Hectare density''' - density of the filling, in number of objects for hectare. For example 100 objects per hectare means an average distance of 10 meters between each object.
* '''Fraction''' - initial seeds count for smallest probability object prototype on hectare.
* '''Blend distance''' - distance to get object prototype.
|OBJECTPROTOTYPEPARAMETERS=* '''OBJECT''' - Object's prototype name
* '''PROB''' - Object's probability
* '''MINHEIGHT''' - Minimal size in %
* '''MAXHEIGHT''' - Maximal size in %
* '''MINDIST''' - Minimal distance in meters
|USAGE=Use for areas with high objects density, where particular object types tend to aggregate in groups, e.g. in mixed forests.
|ALGORITHM=For each shape (areal) do :
# Create and populate "lifegrid"
## Find shape bounding.
## Create empty "lifegrid" for this area.
## Generate base seeds (for each object prototype)
### seeds_count =  HECTARES * CDENSHA
### Randomly generate seeds_count in shape and set this grid item prototype.
# instances_count = HECTARES * DENSHA
# For instances_count try to find position :
## Random position in bounding box.
## If position is inside shape, continue to c. else a.
## Test with objects if minimal distance is ok, continue to d. else a.
## Find object prototype - random grid item in radius 50 meters. This grid item has information about object prototype.
If this loop a <-> d has no new output for last 100 attempts, area is full and iteration of this shape will end.
|SAMPLE=
}}
 
=== Example data ===
{| class="wikitable sortable"  
! Fragmentation
! Fragmentation
! Spruce seeds count
! Spruce seeds count
Line 29: Line 48:
| 2
| 2
| 1
| 1
| [[Image:TerrainProcessor_HightFrag1.png]]
| [[File:TerrainProcessor_HightFrag1.png]]
|- style="vertical-align:top;"
|- style="vertical-align:top;"
| 2
| 2
Line 35: Line 54:
| 4
| 4
| 2
| 2
| [[Image:TerrainProcessor_HightFrag2.png]]
| [[File:TerrainProcessor_HightFrag2.png]]
|- style="vertical-align:top;"
|- style="vertical-align:top;"
| 5
| 5
Line 41: Line 60:
| 10
| 10
| 5
| 5
| [[Image:TerrainProcessor_HightFrag3.png]]
| [[File:TerrainProcessor_HightFrag3.png]]
|}
|}
Legend: [[Image:TerrainProcessor_HightFragLegend.png]]
 
Legend: [[File:TerrainProcessor_HightFragLegend.png]]
=== Task parameters ===
* '''Random seed''' - number used to initialize pseudorandom number generator.
* '''Hectare''' - area size in hectares (individual for each shape)
* '''Hectare density''' - density of the filling in number of objects for hectare. For example 100 objects for hectare means an average distance of about 10 meters between objects.
* '''Fraction''' - initial seeds count for smallest probability object prototype on hectare.
* '''Blend distance''' - distance to get object prototype.
=== Object prototype parameters ===
* '''OBJECT''' - Object's prototype name
* '''PROB''' - Object's probability
* '''MINHEIGHT''' - Minimal size in %
* '''MAXHEIGHT''' - Maximal size in %
* '''MINDIST''' - Minimal distance in meters
=== Usage ===
Use for areas with high objects density, where particular object types tend to aggregate in groups, e.g. in mixed forests.
=== Algorithm ===
For each shape (areal) do :
# Create and populate "lifegrid"
## Find shape bounding.
## Create empty "lifegrid" for this area.
## Generate base seeds (for each object prototype)
### seeds_count =  HECTARES * CDENSHA
### Randomly generate seeds_count in shape and set this grid item prototype.
# instances_count = HECTARES * DENSHA
# For instances_count try to find position :
## Random position in bounding box.
## If position is inside shape, continue to c. else a.
## Test with objects if minimal distance is ok, continue to d. else a.
## Find object prototype - random grid item in radius 50 meters. This grid item has information about object prototype.
If this loop a <-> d has no new output for last 100 attempts, area is full and iteration of this shape will end.

Latest revision as of 00:11, 21 November 2023

Task details

Task name : Area: Hight-density Cluster

Dll plugin name : BITasksPlugin.dll

Geometry type : Polygon, PolygonM, PolygonZ

Heightmap : No


Description

Random placement of multiple objects inside the polygons specified in the given shapefile. First step is to create lifegrid. Lifegrid is 2D table where every cell has information about its Object prototype. Algorithm puts some first seeds. Counts and types of seeds depends on input parameters. Ideal for high density areas like forest.

Example

  • Spruce 85% PROB
  • Pine 10% PROB
  • Larch 5% PROB

See the bottom of the page for the data from the example.

Task parameters

  • Random seed - number used to initialize pseudorandom number generator.
  • Hectare density - density of the filling, in number of objects for hectare. For example 100 objects per hectare means an average distance of 10 meters between each object.
  • Fraction - initial seeds count for smallest probability object prototype on hectare.
  • Blend distance - distance to get object prototype.

Object prototype parameters

  • OBJECT - Object's prototype name
  • PROB - Object's probability
  • MINHEIGHT - Minimal size in %
  • MAXHEIGHT - Maximal size in %
  • MINDIST - Minimal distance in meters

Usage

Use for areas with high objects density, where particular object types tend to aggregate in groups, e.g. in mixed forests.

Algorithm

For each shape (areal) do :

  1. Create and populate "lifegrid"
    1. Find shape bounding.
    2. Create empty "lifegrid" for this area.
    3. Generate base seeds (for each object prototype)
      1. seeds_count = HECTARES * CDENSHA
      2. Randomly generate seeds_count in shape and set this grid item prototype.
  2. instances_count = HECTARES * DENSHA
  3. For instances_count try to find position :
    1. Random position in bounding box.
    2. If position is inside shape, continue to c. else a.
    3. Test with objects if minimal distance is ok, continue to d. else a.
    4. Find object prototype - random grid item in radius 50 meters. This grid item has information about object prototype.

If this loop a <-> d has no new output for last 100 attempts, area is full and iteration of this shape will end.


Example data

Fragmentation Spruce seeds count Pine seeds count Larch seeds count Preview
1 17 2 1 TerrainProcessor HightFrag1.png
2 34 4 2 TerrainProcessor HightFrag2.png
5 85 10 5 TerrainProcessor HightFrag3.png

Legend: TerrainProcessor HightFragLegend.png