Create Layers

simulation with layer simulation with layer

It is possible to define overlays (layers) of data that can be sensed everywhere in the environment. Layers can be used to model physical properties, such as pollution, light, temperature, and so on. As opposed to nodes’ contents, layers have no dependency optimization. This implies that reactions that read values from layers should have special care in defining their context appropriately.

Layers are created with the type/parameter syntax, as in this example:

Click to show / hide code

The following example shows the syntax for initializing multiple BidimensionalGaussianLayers:

Click to show / hide code

If the target layer is written in Kotlin, it can be loaded using named parameters, which arguably reads more clearly.

Click to show / hide code