Trasforme GRAY2RGB
plzzzz hel
plzz help me how to transforme image grayscale to RGB
function cvtColor(.,.,GRAY2RGB); don't work pfff plz help me how to do this in opencv C++ visuel studio 2010
plzzzz hel
plzz help me how to transforme image grayscale to RGB
function cvtColor(.,.,GRAY2RGB); don't work pfff plz help me how to do this in opencv C++ visuel studio 2010
I do think both suggestions contain wrong information. To make it a little more clear look at the link that @FLY provided right here. If you go down to the cvtColor function and to the grayscale to rgb conversion you will see the following statement.
Gray to RGB[A]: R <-- Y, G <-- Y, B <-- Y, A <-- \max(ChannelRange)
Here comes in play directly what @Allyson Martins suggested. When you got a grayscale image you only have intensity values from 0 - 255 of each pixel. You have basically no idea how the relation of green, blue and red is in that specific pixel.
So you either have to
You cant simply convert gray to rgb. You need to make a mask to do it. The computer needs to know what are the colors of the image in RGB scale to convert.
Asked: 2014-04-30 10:08:55 -0600
Seen: 3,298 times
Last updated: May 01 '14