|
|
|
|
|
- Correspondence between tags and constants
- Error management
ImageInfoValue (Function) In french: ImageInfoValeur Returns the value of an Exif tag for the image used. Remarks: - The Exif (EXchangeable Image File) information is included in the image file. This standard defines a set of markers for storing a wide range of image-related information: date, width, orientation, camera model, shutter speed, subject distance, exposure time, etc.
- To handle the Exif tags of an image, use the Exif property of Image variables. This property can be used on Android applications.
ListeMarqueur is string
MonMarqueur is int
i is int = 1
ListeMarqueur = ImageInfoList(IMG_MonChampImage)
WHILE ExtractString(ListeMarqueur, i, CR) <> EOT
MonMarqueur = ExtractString(ListeMarqueur, i, CR)
TableAddLine(TABLE_MaTable, MonMarqueur, ...
ImageInfoValue(IMG_MonChampImage, MonMarqueur))
i ++
END
CheminImg is string = "C:\Mes Images\MonImage.JPG"
Info("Date de réalisation : " + ImageInfoValue(CheminImg, imgDate) + CR + ...
"Luminosité : " + ImageInfoValue(CheminImg, imgBrightness) + CR + ...
"Longueur focale : " + ImageInfoValue(CheminImg, imgFocalLength) + CR + ...
"Ouverture : " + ImageInfoValue(CheminImg, imgAperture))
ImageInfoClose(CheminImg)
Syntax
<Result> = ImageInfoValue(<Image> , <Tag>)
<Result>: Buffer Value of the specified tag for the image used. <Image>: Character string Image to use. This image can correspond to:- an image file (JPEG or TIFF format): specify the name and full (or relative) path of the file. A UNC path can be used.
In this case, the file must be closed by ImageInfoClose. - an image (JPEG or TIFF format) displayed in an Image control: specify the name of the Image control.
- an image (JPEG or TIFF format) contained in a picture memo: specify the picture memo.
- an image (JPEG or TIFF format) contained in a binary string: specify this binary string.
<Tag>: Constant or integer Tag whose value you want to get. This tag can correspond to:- an integer given by ImageInfoList.
- a WLanguage constant. For more details, see "Correspondence between tags and constants".
Remarks Correspondence between tags and constants The table below presents the correspondence between tags and WLanguage constants. | | | Tag | WLanguage constant | Value |
---|
37510 | imgComment | Character string Comments about the image | 37122 | imgCompression | Real Compression of the image in bits/pixel | 33432 | imgCopyright | Character string Copyright of the image | 306 | imgDate | Date Date and time of the image in YYYY:MM:DD HH:MM:SS format | 270 | imgDescription | Character string Image description | 37382 | imgSubjectDistance | Real Distance from the subject in meters | 37380 | imgExposureBias | Real Exposure bias in APEX | 37385 | imgFlash | Integer Status of the flash during the shot:- 0: Flash not fired.
- 1: Flash off.
- 5: Flash triggered and return light not detected.
- 7: Flash triggered and return light detected.
| 928 | imgHeight | Integer Image height in pixels | 672 | imgWidth | Integer Image width in pixels | 305 | imgRecordingSoftware | Character string Name of the software that was used to record the image. | 37386 | imgFocalLength | Real Focal length in millimeters | 37379 | imgBrightness | Real Brightness of the image in APEX | 271 | imgDeviceMark | Character string Mark of the camera that took the photo | 272 | imgDeviceModel | Character string Model of camera that took the photo | 37383 | imgMeteringMode | Integer Metering mode:- 0: unknown.
- 1: average.
- 2: centered average.
- 3: point.
- 4: multipoint.
- 5: motif.
- 6: partial.
- 7 to 254: reserved.
- 255: other.
| 37500 | imgManufacturerNote | Character string Name of the camera manufacturer | 274 | imgOrientation | Integer Orientation of the image: This information indicates the location of the point (0,0) in the image. To display the image in the correct direction based on this information, use the following values:- 1: the point (0,0) is at the top left of the transformed image, so there's nothing to do.
- 2: the point (0,0) is at the top right of the transformed image, so we need to perform vertical symmetry.
- 3: the point (0,0) is at bottom right in the transformed image, so we need to perform horizontal and vertical symmetry.
- 4: the point (0,0) is at bottom left in the transformed image, so we need to perform horizontal symmetry.
- 5: the point (0,0) is on the left and at the top of the transformed image, so we need to perform a horizontal symmetry and a 90° rotation.
- 6: the point (0,0) is on the right and at the top of the transformed image, so a 90° rotation is required.
- 7: the point (0,0) is on the right and at the bottom of the transformed image, so we need to perform a vertical symmetry and a 90° rotation.
- 8: the point (0,0) is on the left and at the bottom of the transformed image, so we need to rotate it by -90°.
| 37378 | imgAperture | Real Aperture in APEX | 33437 | imgFAperture | Real Focal | 37381 | imgMaxAperture | Real Maximum aperture in APEX | 34850 | imgExposureProgram | Integer Exposure mode used during the shot:- 0: undefined.
- 1: manual.
- 2: normal.
- 3: aperture priority.
- 4: speed priority.
- 5: creative.
- 6: action.
- 7: close-up portrait without background.
- 8: landscape.
- 9 to 255: other.
| 282 | imgXResolution | Real Horizontal resolution of the image | 283 | imgYResolution | Real Vertical resolution of the image | 37384 | imgLightSource | Integer Light source for the image:- 0: unknown.
- 1: daylight.
- 2: fluorescent.
- 3: tungsten.
- 17: standard light A.
- 18: standard light B.
- 19: standard light C.
- 20: D55.
- 21: D65.
- 22: D75.
- 23 to 254: reserved.
- 255: other.
| 33434 | imgExposureTime | Real Exposure time | 296 | imgResolutionUnit | Integer Unit for the horizontal and vertical resolution of the image: - 2: inches.
- 3: centimetres.
| 36864 | imgEXIFVersion | Character string Version of Exif information | 65536 | imgThumbnail | Binary string Thumbnail corresponding to the image | 37377 | imgShutterSpeed | Real Shutter speed in APEX |
Other tags are also available. These unlisted tags are specific to some types of cameras or correspond to custom tags. ImageInfoValue returns no error code. To determine if this function generated an error, use the ErrorOccurred variable. If an error occurs, you can get more details on the error with ErrorInfo.
Related Examples:
|
Unit examples (WINDEV): The EXIF functions
[ + ] Using the ImageXXX functions. These functions are used to access the EXIF information of an image. The EXIF information is included in the JPEG or TIFF images. It can be for example the snapshot date, the orientation of the device when taking the photo, the make and model of the camera, a miniature of the image...
|
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|