Re: Adding metadata to images
Re: Adding metadata to images
- Subject: Re: Adding metadata to images
- From: "Ken Ferry" <email@hidden>
- Date: Fri, 6 Jul 2007 23:05:30 -0700
I know there's no generic way to add metadata to files, but since
my app generates *images*, and since there does seem to be a
standard set of metadata for images, I feel like I ought to be able
to tag the images with a "generated by org.zakariya.normalmappr"
Mac OS X's in-depth support for image specific metadata is in
CGImageSource and CGImageDestination. The CGImageSource documentation
lists the properties supported for different image formats.
NSBitmapImageRep exposes some of that support. If you're reading and
writing JPEGs, you can access and write EXIF metadata. See
NSImageExifData in the NSBitmapImageRep documentation.
All of this stuff was new in 10.4.
-Ken
On 7/6/07, Shamyl Zakariya <email@hidden> wrote:
Is there another list I should ask this question on?
All I want to know is how to tag images I write out with metadata
that can be read by MDItem.
email@hidden
In the same episode, the scientist suggests that the
debigulation can only be reversed by a rebigulator.
-- wikipedia
On Jul 5, 2007, at 9:31 AM, Shamyl Zakariya wrote:
> I'm writing an app which batch processes bumpmaps to normalmaps
> when the user drops files ( or folders ) onto the app's batch window.
>
> Now, I want to filter existing normalmaps from the files dropped.
> Consider the situation where a user drops a folder full of bumpmaps
> on the app, and generates normalmaps from the bumpmaps. Then later
> the user decides to use different settings and drops the folder
> back in to the app. I need to filter out the normalmaps that were
> generated before.
>
> I've already written some simple image analysis code which seems to
> do a pretty good job filtering out normalmaps, but it occurs to me
> that if my app were to somehow tag the images it saves as being
> normalmaps I could easily use MDItem to extract that info and
> discard the normalmap without having to perform a ( relatively )
> expensive image analysis.
>
> I know there's no generic way to add metadata to files, but since
> my app generates *images*, and since there does seem to be a
> standard set of metadata for images, I feel like I ought to be able
> to tag the images with a "generated by org.zakariya.normalmappr" or
> some other kind of tag. I could then filter out any file with that
> tag without having to run image analysis.
>
> So, is there any way to add a tag to an image file?
>
> For context, my app writes the file by using NSBitmapImageRep's
> representationUsingType: properties: method which gives me NSData.
> I'm willing to use a different image writing approach if I can
> embed generator metadata.
>
>
> email@hidden
> "negative, i am a meat popsicle."
> -- Major Korben Dallas
>
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden