• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Getting image info without loading entire image
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Getting image info without loading entire image


  • Subject: Re: Getting image info without loading entire image
  • From: Ken Tozier <email@hidden>
  • Date: Fri, 19 Jan 2007 14:20:33 -0500


On Jan 19, 2007, at 1:56 PM, Kaelin Colclasure wrote:


Hi Ken,

I missed the earlier messages in this thread, but... is there a reason why you're trying to load and run the importer instead of simply asking Spotlight for the attributes directly?


The initial question dealt with quickly fetching the width and height of images and Gregory suggested loading the Image.md importer.



MDItemRef item = MDItemCreate(kCFAllocatorDefault, inPath);
if (item != NULL) {
CFArrayRef attributeNames = MDItemCopyAttributeNames(item);
CFDictionaryRef attributes = MDItemCopyAttributes(item, attributeNames);
// ...
}



I just tried that and it sort of works, but unfortunately it doesn't expose the image width and height, just the generic file properties (name, size, mode date etc)


I notice in Spotlight that image width, height etc info is available. Any idea how to get at this more specific image info?


_______________________________________________

Cocoa-dev mailing list (email@hidden)

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


  • Follow-Ups:
    • Re: Getting image info without loading entire image
      • From: Kaelin Colclasure <email@hidden>
References: 
 >Re: Getting image info without loading entire image (From: Ken Tozier <email@hidden>)
 >Re: Getting image info without loading entire image (From: Kaelin Colclasure <email@hidden>)

  • Prev by Date: Re: Getting image info without loading entire image
  • Next by Date: Re: Getting image info without loading entire image
  • Previous by thread: Re: Getting image info without loading entire image
  • Next by thread: Re: Getting image info without loading entire image
  • Index(es):
    • Date
    • Thread