lasso (or "free-form selection") is an editing tool available, with little variation, in most digital image editing software. It is often accessed from the standard main menu (in Photoshop, SAI Paint Tool, and GIMP, as a common example), by clicking on the dashed line icon which is shaped like a lasso strap, from which the common name appears.
Video Lasso tool
Standard operation
The lasso tool operates on the active layer of the image, and is used by clicking and dragging to trace the edge of the selection. Most software supports multiple closed contours, which can be selected by traversing the edge path multiple times. It is also usually not necessary to close the form: releasing the mouse button triggers the software to close the open loop automatically. The area covered by the cursor path will remain selected and open to various transformation operators (shift, scale, cut, copy, and paste, for example) to elsewhere in the clicked image. At this point, the lassoed option will join the selected layer.
Maps Lasso tool
Characteristics
Unlike other image selection algorithms such as smart scissors, magic wands, or grabcuts, lassoing does not place requirements on images, because the user is free to create any closed path.
Technical description
From the image processing point of view, the lasso is basically a masking tool. The edges of the mask are determined by the user input, alias. the cursor path when the button is pressed. A new temporary active layer is created which contains the logical AND of the masking layer and the active image layer. Meanwhile, the original active layer is masked (logical AND) with the opposite of the lasso selection. This creates the impression that the tool has cut a piece of the original image for selective transformation and editing. Most of the operations available for full images can now be applied to the temporary active layer.
When the layers are merged, pixels in the active layer temporarily replace pixels in the coincide active layer (aka, the pixels by which they share the location (row, column) in the 2D field). The "Empty" pixels are handled in one of two ways depending on whether the imaging software supports alpha composing. They may take the value from the default "background" color, or they can continue to be defined as transparent with a zero alpha channel value.
References
Source of the article : Wikipedia