I need to create NSImage from a url and then set it as an image in my application. I tried the code that I found on the Internet, but it did not work. If anyone knows how to do this, any help would be great.
NSImage
thanks
Would you like to watch
initWithContentsOfURL: Initializes and returns an NSImage instance with the contents of the specified URL. - (id)initWithContentsOfURL:(NSURL *)aURL Parameters aUrl The URL identifying the image. Return Value An initialized NSImage instance, or nil if the method cannot create an image representation from the contents of the specified URL.
From http://developer.apple.com/mac/library/documentation/cocoa/Reference/ApplicationKit/Classes/NSImage_Class/Reference/Reference.html#//apple_ref/occ/instm/NSImage/initWithContentsOfURL :
Source: https://habr.com/ru/post/1307244/More articles:Django: Named URLs / same pattern, different named URLs - pythonFast file search algorithm for IP addresses - algorithmPrinting an entire array in C # - arraysWhether this Java regular expression will return one result or several - javaAndroid - How to use SQLiteDatabase.open? - androidHow to access an external object in an event handler? - pythonJavascript closing questions - javascriptPython animation time - pythonHow to detect taps in the gesture area on the Palm Pre? - webosPerl File Operator Help - perlAll Articles