public override void WriteLine(byte[] rgba8, bool normalized) { for (int x = 0, readPos = 0; x < width; x++, readPos = x * 4) { builder.SetPixel( new Pixel(rgba8[readPos], rgba8[readPos + 1], rgba8[readPos + 2], rgba8[readPos + 3], false), x, y); } y++; }
public override void Write(TextureUtil.PixelColor color) { builder.SetPixel(new Pixel(SingleToByte(color.R), SingleToByte(color.G), SingleToByte(color.B), SingleToByte(color.A), false), x, y); if (++x >= width) { x = 0; y++; } }