Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-26 Thread Dave
Opps! I sent this by mistake, I already found the solution this weekend, I just changed the BitmapInfo to kCGImageAlphaPremulitipledFirst and all is well! Thanks a lot for your help, it's almost all working now. All the Best Dave Hi Jean, Thanks, I added the code you suggested and it basic

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-26 Thread Dave
Hi Jean, Thanks, I added the code you suggested and it basically works! I have one small problem left in that the colors are shifted, I think the routine I am returning the buffer to expects ARGB or BGRA and I am returning the opposite! Typical! Is there an easy way to get the pixels in t

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-23 Thread Jean-Daniel Dupas
Le 23 janv. 09 à 19:53, Dave a écrit : Hi Jean, Thank you so much for your help. I've almost got the code in place now. But please see below. On 23 Jan 2009, at 17:33, Jean-Daniel Dupas wrote: Also at this point, I'd like to get a pointer to the Pixel buffer in the CGContext and r

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-23 Thread Dave
Hi Jean, Thank you so much for your help. I've almost got the code in place now. But please see below. On 23 Jan 2009, at 17:33, Jean-Daniel Dupas wrote: Also at this point, I'd like to get a pointer to the Pixel buffer in the CGContext and return this. The code I already have will

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-23 Thread Jean-Daniel Dupas
Le 23 janv. 09 à 17:34, Dave a écrit : Hi Jean, On 23 Jan 2009, at 13:56, Jean-Daniel Dupas wrote: An icns file can be opened using NSImage methods. Then choose the representation you need and convert it to JPEG as you would do with any image. If you want to go the "hard" way (that is not

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-23 Thread Dave
Hi Jean, On 23 Jan 2009, at 13:56, Jean-Daniel Dupas wrote: An icns file can be opened using NSImage methods. Then choose the representation you need and convert it to JPEG as you would do with any image. If you want to go the "hard" way (that is not that hard): Use ReadIconFromFSRef() to lo

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-23 Thread Jean-Daniel Dupas
Le 23 janv. 09 à 14:29, Dave a écrit : Hi, Is there some sample code anywhere that renders (e.g. applies the mask etc.) an Icon from a .icns file at a given resolution? I'd then like to be able to save the rendered image as a JPEG file. If anyone knows of some sample code to get me going

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-23 Thread Dave
Hi, Is there some sample code anywhere that renders (e.g. applies the mask etc.) an Icon from a .icns file at a given resolution? I'd then like to be able to save the rendered image as a JPEG file. If anyone knows of some sample code to get me going or can point me to the best starting pl

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-21 Thread jonat...@mugginsoft.com
On 21 Jan 2009, at 08:50, Jean-Daniel Dupas wrote: iTunes contains a full list of iPod icon (in iTunes.rsrc). Could it be responsible to set the iPod icon ? A convenient way to browse this resource is with ThemePark. Goto menu File - Open Special - iTunes.rsrc http://www.geekspiff.com/so

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-21 Thread Jean-Daniel Dupas
iTunes contains a full list of iPod icon (in iTunes.rsrc). Could it be responsible to set the iPod icon ? Le 20 janv. 09 à 19:40, Russell Hancox a écrit : Dave, Due to there being an icon stored on the root of each iPod, I don't *think* there is an icon stored on the system for each one.

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-21 Thread Russell Hancox
Dave, Due to there being an icon stored on the root of each iPod, I don't *think* there is an icon stored on the system for each one. Russell On 20 Jan 2009, at 02:38 pm, wrote: Hi All, I would like to something similar which is to display the Icons of iPods. I can get the .icns files

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-20 Thread Jean-Daniel Dupas
Did you try -[NSWorkspace iconForFile:] ? Le 20 janv. 09 à 19:49, Dave a écrit : Hi, Yes, that's true. Can I get the Icon with the volume associated with an iPod? I can form the volume file path no problem. All the Best Dave On 20 Jan 2009, at 18:40, Russell Hancox wrote: Dave, Due to

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-20 Thread Dave
Hi, Yes, that's true. Can I get the Icon with the volume associated with an iPod? I can form the volume file path no problem. All the Best Dave On 20 Jan 2009, at 18:40, Russell Hancox wrote: Dave, Due to there being an icon stored on the root of each iPod, I don't *think* there is an i

Re: Getting iPod icon, was Getting the network Machine Icon

2009-01-20 Thread Sandro Noel
dave The only one i found was the one for he ipod touch, enjoy. //- // returns the default iPod Touch icon. + (NSImage *) getDefaultiPodTouchIcon{ IconRef iconRef; OSErr err = GetIconRef (kOnSystemDisk

Getting iPod icon, was Getting the network Machine Icon

2009-01-20 Thread Dave
Hi All, I would like to something similar which is to display the Icons of iPods. I can get the .icns files for the iPhone and iPod Touch from: /System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/ But where to locate the icons for iPods? Thanks a lot All the Best Dave On 11 Ja

Re: Getting the network Machine Icon

2009-01-16 Thread Sandro Noel
sorry I typed it to quickly. [computer bonjour name].[_device-info._tcp].[domain] but I get error -72004 when i try it. :( witch is an invalid parameter. I've searched the internet for _device-info. and apparently i'm not the only one asking about this feature, but no one seems to be getting

Re: Getting the network Machine Icon

2009-01-15 Thread Sandro Noel
Guy's I think I found it. Using a packet analyzer on my laptop, and using my iphone with DataCase (AFP server for iphone) when the service is resolved, finder sends a special bonjour query. called device-info. Packet: 5, Packetlength: 252 bytes, Packet follows: 00030 00 05 00 00 00 00 16

Re: Getting the network Machine Icon

2009-01-13 Thread Sandro Noel
Well it's not that bad of a place to put it... there is not way to know beforehand if the servers are going to be present So it makes sense to ask the server what it is. when Bonjour declares it's presence. or when the SMB server broadcasts. The icons for every possible mac model are local t

Re: Getting the network Machine Icon

2009-01-13 Thread I. Savant
On Tue, Jan 13, 2009 at 11:32 AM, Sandro Noel wrote: > The AFP client sends the FPGetSrvrInfo command to obtain server information. > The FPGetSrvrInfo command returns server information including the following > server parameters: server name, machine type, AFP version strings, UAM > strings, vo

Re: Getting the network Machine Icon

2009-01-13 Thread Sandro Noel
Follow UP. Here is what i got from the Carbon-dev list I'd guess it just uses AFP to ask the server: From : The AFP client sends the FPGetS

Re: Getting the network Machine Icon

2009-01-12 Thread I. Savant
On Mon, Jan 12, 2009 at 1:52 PM, Sandro Noel wrote: > Thanks guy's i'll ask in the Carbon-dev list. Sorry - I didn't see the "remote" part of the requirement at first. After spending some time searching the docs, tech notes, and even some headers for this myself (because it's an intriguing que

Re: Getting the network Machine Icon

2009-01-12 Thread Sandro Noel
Thanks guy's i'll ask in the Carbon-dev list. Sandro Noel. On 11-Jan-09, at 2:31 PM, Sandro Noel wrote: Greetings I'm looking for a way to programatically get the machine icon from my servers, just like finder does in the finder. for every type of mac it has a different icon, and for window

Re: Getting the network Machine Icon

2009-01-12 Thread matt . gough
On 12 Jan 2009, at 18:19, Jean-Daniel Dupas wrote: NSImage. I think it's NSImageNameComputer. Fine to get the current machine icon, but not to get a remote machine icon, just like the Finder does when it display the list of machine on the local network. I don't know, but you could

Re: Getting the network Machine Icon

2009-01-12 Thread Jean-Daniel Dupas
Le 12 janv. 09 à 17:56, Sean McBride a écrit : On 1/11/09 2:31 PM, Sandro Noel said: I'm looking for a way to programatically get the machine icon from my servers, just like finder does in the finder. *SNIP*. Any suggestions on where to look?? NSImage. I think it's NSImageNameComputer.

Re: Getting the network Machine Icon

2009-01-12 Thread I. Savant
On Mon, Jan 12, 2009 at 11:56 AM, Sean McBride wrote: > NSImage. I think it's NSImageNameComputer. Yep: http://developer.apple.com/documentation/UserExperience/Conceptual/AppleHIGuidelines/XHIGIcons/chapter_15_section_10.html# -- I.S. ___ Coco

Re: Getting the network Machine Icon

2009-01-12 Thread Sean McBride
On 1/11/09 2:31 PM, Sandro Noel said: >I'm looking for a way to programatically get the machine icon from my >servers, just like finder does in the finder. > > *SNIP*. > >Any suggestions on where to look?? NSImage. I think it's NSImageNameComputer. -- ___

Getting the network Machine Icon

2009-01-11 Thread Sandro Noel
Greetings I'm looking for a way to programatically get the machine icon from my servers, just like finder does in the finder. for every type of mac it has a different icon, and for windows computers, it;s the nice crash screen icon. I would like my application to represent the network hosts