As you probably realized by now, a layer in Lightact is a very flexible concept. It can do many different things and rendering video or playing sound is just one of them. Therefore, in this article, we’ve assembled some of the best practices that will make it easier for you to be efficient while working with them.

Use lots of variables

Variables are containers that can hold many things and they can be set or read from any layer. Use them to hold information about the status of your programming or its current stage. And give them descriptive names. They will allow you to avoid long connection lines, which can become very hard to read.

Let each layer do one thing

Don’t try to save on the number of layers. Instead, organize your programming into separate blocks and put each block into one layer. The layers can then communicate between themselves with variables. This way your programming is going to be easier to read or to modify. And, give descriptive names to layers, so you’ll know what they do just by glancing at them.

Use node comments

node comments example

You can insert node comments for every node. Use this feature to write what a node (or a section of a layout) does, so it will be easier to understand it later. You can write comments in node’s properties on the right-hand side.

Avoid performing actions on every frame if possible

Some nodes need to be executed every frame (for example Render to canvas), but some don’t (for example, Print to log or UDP Sender). Use Run once or Delay nodes whenever possible to lower the performance cost.

 

print

Login to leave your feedback!

Comments are closed.