On 12/03/2009, at 11:08 PM, Kevin Walzer wrote:

Hello,

I'm getting these gcc errors:

macicon.m:29: error: incompatible type for argument 1 of ‘NSMakeSize’
macicon.m:29: error: incompatible type for argument 2 of ‘NSMakeSize’

[snip]

-(int) makeIcon: (NSString *) filePath imagewidth: (float *) width imageheight: (float*)height outputfile:(NSString *)imagePath {

[snip]

 //set the icon size
 [resizeicon setSize:NSMakeSize(width, height)];        
 [resizeicon  setPixelsWide:(int*) width];
 [resizeicon setPixelsHigh:(int*)height];


Hello Kevin,
Not sure why you're using pointers to floats and ints, but...

Your method's signature says it expects a pointer to float. If that's what you have, then the args to NSMakeSize need to be dereferenced. I think something like NSMakeSize(*width, *height). Unfortunately, I'm not sure about syntax of that, but you could look up dereferencing pointers to find the answer.

HTH,
Ron_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to