Block Category: Signal Consumer
Input Image Requirements: None
Inputs:
• Enable: When the enable connector is high, the image is saved. When the enable connector is 0, the image is not saved.
• Image: Indicates the image to be saved.
Image
Path: Overrides the Save As parameter in the Save Image dialog and
uses the input connector value to specify the image path for the saved image. If
a directory is not specified, the image is saved to the current directory. The
Image Path connector is displayed when you activate Use input
connector value to specify the image path in the Save Image dialog.
The image path connector accepts only constant blocks. The
following formats are accepted in the const block:
“drive:\\directory\\<…>\\filename.type”
“drive:/directory/<…>/filename.type”
The
following syntax rules apply:
o The double quotation marks are required notation.
o If a directory is not specified, the image is saved to the current directory.
Description: The Save Image block saves an image to a file.
Use input connector value to specify the image path: Saves the image to the image path specified on the Image Path input connector When Use input connector value to specify the image path is activated, Save As is grayed out.
Save As: Saves a copy of the image to the specified location. Click … to select a location. You must always specify an image name and type. The file type does not have to match the original image, but it must be BMP, JPEG, JPG, or PNG. If you do not specify a location, the image is saved to the current directory. When Use input connector value to specify the image path is activated, Save As is grayed out.
Example
In this example, the Save Image block uses the Image Path input connector value to save the cat image to C:\\Tech Support\\Diagrams\\cat.bmp.