for 5:6:5 just get average as you are used to (your n) and use only higher 5 (or
6) bits of it for each color


[EMAIL PROTECTED] wrote:
> Hello,
> From theory I am assuming that in order to convert an image to its greyscale 
> values we get the red green and blue pixel values and find the average and 
> set red, green and blue components to this average value.  When using rgb565 
> format images where pixel values can only go from 0-31 red, 0-63 green and 
> 0-31 blue i am having trouble converting these to greyscale which should be 
> (n,n,n) where n is between 0-255.  I know that 31, 63, 31 produces white, but 
> am unable to get any other combination that produces grey as i thought it had 
> to be (n,n,n) ie 31,31,31 to do so but this is not the case.  Do i need to 
> change the screen density to 4bpp??? I actually need to convert colour images 
> captured from the onboard pda camera to greyscale for processing.
> Any help would be greatly appreciated,
> Cheers.
> 

-- 
For information on using the PalmSource Developer Forums, or to unsubscribe, 
please see http://www.palmos.com/dev/support/forums/

Reply via email to