Very interesting, this is indeed the problem. Thanks for your answer,
I would have wasted another 3 hours at least getting here otherwise.

My mask identifies 11 distinct regions by using

RGB(250,250,250)
RGB(225,225,225)
RGB(200,200,200)
RGB(175,175,175)
RGB(150,150,150)
RGB(125,125,125)
RGB(100,100,100)
RGB(75,75,75)
RGB(50,50,50)
RGB(25,25,25)
RGB(0,0,0)

(I figured I would just divide Color.red(colour) by 25 to get the
item's index)

and they come out as

RGB(247,251,247)
RGB(222,227,222)
RGB(197,198,197)
RGB(173,174,173)
etc..

so the fact that the green stands out is a clear indication that the
RGB565 pre-conversion is at fault.

My not-so-elegant solution for now will be to average the 3 RGB values
and then round it off to the nearest multiple of 25.

Of course this begs for a better solution, but life goes on...
Perhaps when I have time I will write a function to load a raw matrix
from file to not give Android a chance to mangle my bits.

Thanks again Ralf,
/d42

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to