Use this example to extract a part of an image defined by a rectangle.
This example is installed with the Vision Development Module and can be accessed from the LabVIEW Example Finder. This example uses IMAQ Extract.vi to extract a rectangular region from a source image and copy it into a separate IMAQ image buffer. IMAQ Extract.vi uses the Optional Rectangle input defined by the left, top, right, and bottom coordinates of the rectangle you want to extract. You can also scale down the extracted region using the X Step and Y step inputs. For example, using an X Step of 2 while reduce the size of the extracted region by a factor of 2 in the x dimension.
LabVIEW Vision Development Module
Front Panel:
J. Calvert
Applications Engineering
National Instruments
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.