visual3d:documentation:pipeline:pipeline_commands:for_each_and_end_for_each
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
visual3d:documentation:pipeline:pipeline_commands:for_each_and_end_for_each [2024/07/16 19:31] – created sgranger | visual3d:documentation:pipeline:pipeline_commands:for_each_and_end_for_each [2024/09/03 13:57] (current) – [Command Syntax] wikisysop | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== | + | ====== |
Executes pipeline commands multiple times for each item in a list of items. It is not identical with a "for loop" or "do loop" in a programming language because the items must be explicitly defined as ITEMS in the command. This has some powerful consequences because it means that you can " | Executes pipeline commands multiple times for each item in a list of items. It is not identical with a "for loop" or "do loop" in a programming language because the items must be explicitly defined as ITEMS in the command. This has some powerful consequences because it means that you can " | ||
Line 5: | Line 5: | ||
==== Command Syntax ==== | ==== Command Syntax ==== | ||
- | **For_Each** | + | < |
+ | For_Each | ||
/ | / | ||
!/ | !/ | ||
/Items= ITEM1+ITEM2+ITEM3 | /Items= ITEM1+ITEM2+ITEM3 | ||
- | **;** | + | ; |
! Starting from the For_Each command and ending at the End_For_Each command | ! Starting from the For_Each command and ending at the End_For_Each command | ||
! the loop is repeated once for each item in the For_Each command at each | ! the loop is repeated once for each item in the For_Each command at each | ||
! loop INDEX is a pipeline command this is identified as ::INDEX in any other command | ! loop INDEX is a pipeline command this is identified as ::INDEX in any other command | ||
- | **End_For_Each** | + | |
+ | End_For_Each | ||
/ | / | ||
- | **;** | + | ; |
+ | </ | ||
As of version 5.02.17, a new parameter " | As of version 5.02.17, a new parameter " | ||
Line 56: | Line 61: | ||
Visual3D doesn' | Visual3D doesn' | ||
+ | < | ||
Variable blnContinue = true | Variable blnContinue = true | ||
- | **While** Continue = true | + | While Continue = true |
Prompt user for variable blnContinue (true or false) | Prompt user for variable blnContinue (true or false) | ||
FileCounter = FileCounter +1 | FileCounter = FileCounter +1 | ||
[load and process another file (e.g. filename_filecounter)] | [load and process another file (e.g. filename_filecounter)] | ||
- | **End while** | + | End while |
+ | </ | ||
==== Example: Processing many files ==== | ==== Example: Processing many files ==== | ||
visual3d/documentation/pipeline/pipeline_commands/for_each_and_end_for_each.1721158268.txt.gz · Last modified: 2024/07/16 19:31 by sgranger