• 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: How to get image real number of bits per pixel
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to get image real number of bits per pixel


  • Subject: Re: How to get image real number of bits per pixel
  • From: Marco Binder <email@hidden>
  • Date: Tue, 25 Feb 2003 17:57:52 +0100

Directly instantiate an NSBitmapImageRep with the image-data and call the method. As to my experience, Cocoa will always use 8-bit RGBA to display images in an NSImageView.

marco


Am Dienstag, 25.02.03 um 17:21 Uhr schrieb Sebastien TOPIN:

Hi Folks,

I am trying to get the real number of bits per pixel for a displayed image.
A NSImageView object enables me to drag n' drop a bmp image from the Finder
and display it in my app.
Then I got an NSBitmapImageRep from the NSImageView and did that:

int iBitsPerPix = [bittmapImageRep bitsPerPixel];

The result is always 32 even for grayscale 8 bits per pixel images or 24 bits
per pixel color images.

How can I get the image real number of bits per pixel of those images?

Thanks in advance,
Seb
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


--
|\ /| E-Mail: email@hidden WWW: www.marco-binder.de
| \/ | Telefon: 07531 / 94 19 94 Fax: 07531 / 94 19 92
| |ARCO Snail-Mail: Banater Str. 3 - 78467 Konstanz
BINDER _____________________________________________________
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: How to get image real number of bits per pixel
      • From: "Sebastien TOPIN" <email@hidden>
References: 
 >How to get image real number of bits per pixel (From: "Sebastien TOPIN" <email@hidden>)

  • Prev by Date: Getting a window's child elements
  • Next by Date: NSDocument close notification
  • Previous by thread: How to get image real number of bits per pixel
  • Next by thread: Re: How to get image real number of bits per pixel
  • Index(es):
    • Date
    • Thread