public static void CopyColor(ProcessorState state)
{
for (int x = state.crop.Value.X; x <= state.crop.Value.Width + state.crop.Value.X; x++)
{
for (int y = state.crop.Value.Y; y <= state.crop.Value.Height + state.crop.Value.Y; y++)
{
int idx = Util.toID(x, y, width, height, kColorStride);
Array.Copy(state.rgb, idx, state.bitmap_bits, idx, kColorStride);
}
}
}