Answer the question
In order to leave comments, you need to log in
C# | How to set a custom color value in system.drawing in Color?
I need to set setpixel to the color I want. I have a range of colors that I need for a project. But the standard ones that already have colors do not suit me. How to set color with custom value like #ffffff?
Answer the question
In order to leave comments, you need to log in
In your case, you can simply:
Color myColor = System.Drawing.Color.FromArgb(0xFFFFFF); //Белый цвет
Color myColor2 = System.Drawing.Color.FromArgb(0xFF0000); //Красный цвет
//То, что вы ищите :)
myBitmap.SetPixel(Xcount, Ycount, Color.FromArgb(0xFFFFFF));
Was wrong
Color.Parse('Something is there')
See
docs https://docs.microsoft.com/ru-ru/dotnet/api/system...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question