Advertise here




Advertise here

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Google Sign In with OpenID
Please do not post the same thing multiple times. The board software automatically flags certain posts as needing moderator attention. This happens the most often for new users. I'm pretty sure this is made clear at the time you attempt to post. Posting the same thing over and over again just makes that many more posts the moderators have to weed through later. This makes us sad. Don't make us sad. If your post/thread doesn't appear, just wait a while. Don't post it again. If it hasn't shown up by the next day, then you can try again. I normally go through posts in the mornings, and try to check a few times throughout the day, but I'm not here 24/7. There will typically be a significant delay before posts are approved. Just be patient.

.plist Files

Hey guys, I have a .plist file with .png files in it. Is there a way or a program in which I can extract those .png files for the .plist file? Thanks!

Replies

  • Duncan CDuncan C Posts: 8,033Tutorial Authors, Registered Users
    That depends on how you encoded the png files. Property lists can only contain a very small list of object types (NSString, NSData, NSDate, NSNumber, NSArray, or NSDictionary objects.) Any other type of object needs to be converted to one of those types. There is a UIKit function a UIImagePNGRepresentation method that converts a UIImage to an NSData representation that can be saved to a property list. That's the most likely way to save PNGs to a property list, but not the only way.

    If the plist contains an array of NSData representations of PNGs, you'd use the NSArray method arrayWithContentsOfFile to read the contents of the plist into memory, then use the UIImage method imageWithData to convert the data objects in the array back to UIImages.

    This is hardly an advanced discussion topic however.
    Regards,

    Duncan C
    WareTo

    mug

    Animated GIF created with Face Dancer, available for free in the app store.
Sign In or Register to comment.