• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
RE: NSBitmapImageRep with floating point values
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: NSBitmapImageRep with floating point values


  • Subject: RE: NSBitmapImageRep with floating point values
  • From: Paul Morel <email@hidden>
  • Date: Sat, 5 Feb 2011 16:33:53 +0100
  • Importance: Normal

Hi,
thank you very much for the idea! I'll try that!
Paul

Date: Fri, 4 Feb 2011 21:07:10 -0800
Subject: Re: NSBitmapImageRep with floating point values
From: email@hidden
To: email@hidden
CC: email@hidden; email@hidden

On Thu, Feb 3, 2011 at 2:37 PM, David Duncan <email@hidden> wrote:

On Feb 3, 2011, at 1:32 PM, Paul Morel wrote:



> in my application I would need to save an image where pixel intensities are floating point values. Apparently TIFF can support that.But I don't know I can do that in Objective-C. I saw that there is a bitmap format "NSFloatingPointSamplesBitmapFormat" that can be used. Does anybody knows how to use it? I tried to use a (float **) instead of (unsigned char **) but it doesn't work of course, because it is supposed to receive (unsigned char **)!




Did you try just allocating an appropriately sized buffer and typecasting to (unsigned char **)? The type cast doesn't change the data, just the compiler's interpretation of it (and since this is a pointer that won't affect the data itself in anyway).


Yes, unsigned char here really is just intended to signify "raw data" - a byte stream.  The byte stream may be interpreted as floating point data channels.

-Ken
--

David Duncan



_______________________________________________



Cocoa-dev mailing list (email@hidden)



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:




This email sent to email@hidden


 		 	   		  _______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

References: 
 >NSBitmapImageRep with floating point values (From: Paul Morel <email@hidden>)
 >Re: NSBitmapImageRep with floating point values (From: David Duncan <email@hidden>)
 >Re: NSBitmapImageRep with floating point values (From: Ken Ferry <email@hidden>)

  • Prev by Date: [iOS] NSUserDefaults best practices
  • Next by Date: Re: Identify key colour in video/photo
  • Previous by thread: Re: NSBitmapImageRep with floating point values
  • Next by thread: NSTextView line wrap toggle (was NSTextView exception with line wrap and horizontal scroller - RESOLVED)
  • Index(es):
    • Date
    • Thread