CadEditor.EditVideo.setPal C# (CSharp) Метод

setPal() приватный Метод

private setPal ( ) : void
Результат void
        private void setPal()
        {
            var palImage = new Bitmap(128,128);
            using (Graphics g = Graphics.FromImage(palImage))
            {
                for (int i = 0; i < 16; i++)
                {
                    g.FillRectangle(new SolidBrush(ConfigScript.videoNes.NesColors[curPal[i]]), i % 4 * 32, (i / 4) * 32, 32, 32);
                    if (showNo)
                        g.DrawString(String.Format("{0:X2}", curPal[i]), new Font("Arial", 6), Brushes.White, new Rectangle(i % 4 * 32, (i / 4) * 32, 32, 32));
                }
            }
            pbPal.Image = palImage;
        }