Sorry, but I don't speak, read or write Italian. Dutch by preference, English, German and somewhat French is also OK. I tried to read your Italian article , but I do not understand the clue.
Quite some time ago I posted sample code tot extract EXIF data from a JPEG file.
Recently I found myself two errers in that code:
1) Some manufacturers of camera devices store values in the EXIF data with the Least Significant Byte first, others with the Most Significant Byte first. This was not covered in my sample.
2) Values of less than 5 bytes will be stored in the OffSet field itself, in stead of the OffSet fields indicating an offset to the place where that data is stored. E.g the manufacturer name HTC will be stored in the offset field itself.
In my sample code this was not always covered.
I found these problems after buying another camera.
For those interested I have attached the improved sample code.
Thanks for posting this sample application. I am interested in accessing the GPS co-ordinates which can be included in the EXIF header (in order to geotag a photo) and wondered if you have already implemented this in a newer version of your code?
Meanwhile I finished the code to extract latitude, longitude and altitude from the EXIF data. However, I have problems in testing it as I have myself only two images with GPS data. Could you mail me some more images with GPS data, indicating as far as possible the location where these pictures were taken?
Sorry for the delayed response. The attached zip file contains some JPEG samples with GPS data in the EXIF header. I also included the PC command line utility jhead.exe which will display the EXIF header data for cross checking purposes.
Meanwhile I finished the work. Attached you will find the code of the test program, the module that does the extraction and a compiled demonstration program.
The test program includes a own made module to select a file. This module allows to select sub directories as much as you want, which is not possible on the device with the OpenDialog component.
Some explanation: the selection starts from the C:\ disk on the PC or from \ on the device. Directories are marked with "D", files with "F". Click on a "D" line to see lower level directories or files. Click on a "F" line to select that file. With the left button you go to a higher level, if available; with the right button the selection process is cancelled.
I found a program (Resco Photo Manager) on internet to add coordinates to a EXIF file; so I could test the extraction much better.
The files you have sent me are JFIF files; so I could not use them for testing. I learned from internet that some programs handling images change a file with EXIF data into a file with JFIF data.
Good luck. If there are any problems, please inform me,
The test program includes a own made module to select a file. This module allows to select sub directories as much as you want, which is not possible on the device with the OpenDialog