PixImage usage - aardvark-platform/aardvark.docs GitHub Wiki
- 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 copy
let pix = PixImage<byte>()
let res = 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 everything
let pix = PixImage<byte>()
let res = PixImage<byte>(pix.GetChannel(1L))- More complex examples in this file: PixImageDemo.cs