Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

WriteImageAndVisionInfo function

The VB Reference manual states for the WriteImageAndVisionInfo function: "Writes an image, along with extra vision information associated with the image, to a PNG file. This extra vision information includes overlay, pattern matching template, and calibration information, and custom data."

 

What is this custom data? How do I implement the function to write custom data?

 

On a related note, the WriteCustomStringData function "associates a string with a keyname in an image." Can this string be embedded into the image file? If so, how?

 

Thanks!

0 Kudos
Message 1 of 4
(3,588 Views)

Steverino -

 

The WriteImageAndVisionInfo function writes the custom data contained in the image to a file.  To write/read the custom data in an image, check out the following functions:

 

CWIMAQVision.ReadCustomData

CWIMAQVision.ReadCustomStringData

CWIMAQVision.WriteCustomData

CWIMAQVision.WriteCustomStringData

 

Does that answer your question?

 

Greg Stoll

Vision R&D

National Instruments

Greg Stoll
LabVIEW R&D
0 Kudos
Message 2 of 4
(3,580 Views)

>> CWIMAQVision.ReadCustomData

>> CWIMAQVision.ReadCustomStringData

>> CWIMAQVision.WriteCustomData

>> CWIMAQVision.WriteCustomStringData

 

I do not believe that data embedded into the image using these functions actually save the data with this image when the image is written to disk. Is that correct?

 

Thanks!

 

 

0 Kudos
Message 3 of 4
(3,565 Views)

Steverino -

 

If you write custom data to the image, and then save the image with WriteImageAndVisionInfo, the data is saved with the image.  If you then open it with ReadImageAndVisionInfo you should be able to read the custom data back.

 

Greg Stoll

Vision R&D

National Instruments

Greg Stoll
LabVIEW R&D
0 Kudos
Message 4 of 4
(3,559 Views)