|
VMD Extension Functions
|
Functions | |
| asel args | |
| ssel str | |
| asel_free | |
The asel and asel_free functions provide a replacement for VMD's atomselect which behave like VMD's usual atomselect, but keeps a list of selections created in the scope of the calling function (it is called _asel_list, but you should not need it). Such atomselections can be deleted all at once when the function is exited via the asel_free function.
proc anyway (unless they are declared global).In short, just use asel instead of atomselect, and call asel_free at the end of your function.
The ssel function allows one to write function which accept either selection strings or existing atomselections.
| asel | args | ||
Auto-cleanup version of atomselect.
| ssel | str | ||
Auto-cleanup version of atomselect. If str is an atomselection, just return it as it is. Otherwise, make a selection of it with the top molecule, record it like asel, and return it.
| str | An atom selection string or an existing atomselection |