You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
aszabo314 edited this page Feb 14, 2018
·
4 revisions
Take one channel of a PixImage and use it as new greyscale PixImage:
//take color channel 1, create a new greyscale image as pixel-by-pixel copyletpix= PixImage<byte>()letres= PixImage<byte>(Col.Format.Gray, a.Size)
res.GetChannel(0L).Set(pix.GetChannel(1L))//view color channel 1 as greyscale PixImage without copying anything//WARNING: both PixImages view the same data. mutation will destroy everythingletpix= PixImage<byte>()letres= PixImage<byte>(pix.GetChannel(1L))