Shift register: Difference between revisions
Appearance
m made internal links to singluar (instead of plural) |
m got link and display text backwards |
||
| Line 4: | Line 4: | ||
* on subsequent calls, is equal to the value that flowed into the right terminal of the shift register, on the previous call of the loop. | * on subsequent calls, is equal to the value that flowed into the right terminal of the shift register, on the previous call of the loop. | ||
This behavior means that the shift register can be used to store some data that will be remembered from one call of the loop to the next. This technique is used for creating [[functional | This behavior means that the shift register can be used to store some data that will be remembered from one call of the loop to the next. This technique is used for creating [[functional global|functional globals]] (a.k.a. [[LV2-style global|LV2-style globals]]). | ||
Revision as of 15:49, 7 April 2007
An uninitialized shift register is a shift register of either a While Loop or For Loop that has no input data wired to the shift register's left terminal from the outside of the loop. Since the shift register is not initialized, the data that flows out of the shift register:
- on the first time the loop is called, is equal to the default value of the shift register's data type, and
- on subsequent calls, is equal to the value that flowed into the right terminal of the shift register, on the previous call of the loop.
This behavior means that the shift register can be used to store some data that will be remembered from one call of the loop to the next. This technique is used for creating functional globals (a.k.a. LV2-style globals).