hi all!
i'm trying to extract one color channel (i.e. the red channel) out of a RGB bitmap:
for(x=0;x<CAM_W;x++)
{
for(y=0;y<CAM_H;y++)
{
BitmapUtil.SetPos(TPoint(x,y));
pixel = BitmapUtil.GetPixel();
color = TRgb(pixel);
value = color.Red();
color.SetRed(value);
color.SetGreen(value);
color.SetBlue(value);
BitmapUtil.SetPixel(color.Value());
}
}
but it seems that either the color getter or the set functions of TRgb don't work correctly.
any hints?
thx in advance
mugi