help-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSImage problem


From: Fred Kiefer
Subject: Re: NSImage problem
Date: Fri, 16 Mar 2012 17:44:20 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.2) Gecko/20120215 Thunderbird/10.0.2

On 15.03.2012 23:58, gusborsa wrote:

Hello, I´m trying to create a NSImage object from a png type image. My code:

NSImage *myImage = [[NSImage alloc] initWithContentsOfFile:
@"c:/MiProyect/Resources/imagen.png"];

but this method returns "nil", the description message from the myImage
object returns (NULL).

I Verified the path with the fileExistsAtPath (NSFileManager) method and
it's OK. I'm working on WinXP.

Most likely your version of gui was build without png support. Could you please print out the value of:

[NSImage imageUnfilteredFileTypes]

If this array doesn't include "png", then you need to install libpng and rebuild gui.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]