Пример #1
0
 public void CopyPixels(byte[] buffer, int bufferOffset, Color sourceColor, int count)
 {
     do
     {
         buffer[bufferOffset + ImageBuffer.OrderR] = m_gamma.inv(sourceColor.red);
         buffer[bufferOffset + ImageBuffer.OrderG] = m_gamma.inv(sourceColor.green);
         buffer[bufferOffset + ImageBuffer.OrderB] = m_gamma.inv(sourceColor.blue);
         buffer[bufferOffset + ImageBuffer.OrderA] = m_gamma.inv(sourceColor.alpha);
         bufferOffset += 4;
     }while (--count != 0);
 }
Пример #2
0
 public void CopyPixels(byte[] buffer, int bufferOffset, ColorRGBA sourceColor, int count)
 {
     do
     {
         buffer[bufferOffset + CO.R] = m_gamma.inv(sourceColor.red);
         buffer[bufferOffset + CO.G] = m_gamma.inv(sourceColor.green);
         buffer[bufferOffset + CO.B] = m_gamma.inv(sourceColor.blue);
         buffer[bufferOffset + CO.A] = m_gamma.inv(sourceColor.alpha);
         bufferOffset += 4;
     }while (--count != 0);
 }