For example the Exif standard has a “User Comment” tag that has a limit of 256 characters I believe.
If I want to add lets say a story into metadata, what would be my best bet for several megabytes worth of text.
Basically I’m trying to store certain things inside of an image and have it not lost when transferred between iPhones. I wrote this image directly into the image before by converting it into NSData and then appending the huge string and then changing the NSData to UIImage. This worked but when I emailed, texted, or placed it inside the photolibrary, all information I added was lost.
Apparently metadata stays with the image and I have it working using user comment but there is a character limit.
How would I go about using an existing tag or making my own so I can have almost no limit on the text size? I don’t care how big the file gets.
Have you looked into the IPTC extended data sets? They seem to allow what you want to do.
Or if the image is going directly between systems, you could simply append it to the end of the image data – for example, given a JPG lie I can do something like:
write in some text, and it does not interfere with applications reading JPG.
Of course, if you need the transmitted information to last through several editings of the image, then EXIF (or IPTC) is the only way to store data.