MASK
- v14
mask {ON | OFF } {,X = <index_name>}
Function
It implements a filter mechanism that will be used by the selection commands.
Command introduced in Eagle V12.5.4.
Parameters
on|off |
Define whether MASKing filter is switch on or off. |
|
|
x=<text> |
Where text is the name of the user-defined index. |
Examples
MASK on,x=Selectable
Notes
This command can be used in conjunction with the standard INDEX command to drive all selection commands (select, include, exclude, nearest, identify, latch, clump and conflict) to analyze only items belonging to the specified index. This functionality has the advantage of consistently reducing the response time of selections, especially on big drawings, and also to "ring fence" the selection command operation by only searching through required items.
The developer should aim to ensure that the Eagle application is focused on keeping the requested index up-to-date. The application can ultimately handle many different indices, and selectively activate the appropriate one for the current required selections.
The following is an example of use of the functionality:
…
INDEX SELECTABLE,kill
INDEX SELECTABLE,a7=#* # This add the requested items on the
index, emptying the index first
INDEX SELECTABLE,+f=(40,42,43,49,73,79),a7=a?#*
INDEX SELECTABLE,-f=(20,23,30),a1=*db*
…
MASK ON,X=SELECTABLE
NBB: from
this point onwards selection commands will only analyze items belonging
to SELECTABLE index
…
MASK OFF
from this
point onwards the selection commands will again analyze the full workspace
If and when the Eagle application needs to load other items into the workspace, and accordingly update the relevant index, the following programming outline can be implemented:
…
BACKGROUND ON
<load new items>
…
INDEX SELECTABLE,+a7=#* # This add items to the index
INDEX SELECTABLE,+f=(40,42,43,49,73,79),a7=a?#*
INDEX SELECTABLE,-f=(20,23,30),a1=*db*
…
This can be achieved due to the fact that when the background is active then the next specified INDEX commands operate only on the items that are in the foreground, thereby speeding up their performance when restructuring the new items in the already defined index.
See also
index, select, include, exclude, nearest, identify, latch, clump, conflict