saving image format problem of NSBMPFileType
saving image format problem of NSBMPFileType
- Subject: saving image format problem of NSBMPFileType
- From: 김경옥 <email@hidden>
- Date: Wed, 06 Oct 2004 09:06:18 +0900
- Importance: Normal
Title: Message
Hi,
I'm working on saving an image
to several image file formats.
For 'png, gif, jpeg, and tiff',
it works, but bmp below doesn't work.
if ([[[sheet filename]
pathExtension] isEqualToString:@"bmp"])
{
NSDictionary
*bmpProperties = [NSDictionary dictionaryWithObjectAndKeys:[NSNumber
numberWithFloat:1],
NSImageCompressionFactor, nil];
NSData
*bmpData = [[NSBitmapImageRep imageRepWithData:[image TIFFRepresentation]]
represntationUsingType:NSBMPFileType
properties:bmpProperties];
BOOL result
= [bmpData writeToFile:[sheet filename] atomically:YES];
}
The
bmpData becomes null even though bmpProperties and image are
fine.
Is there anything
wrong?
Thanks
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden