Notifications
Clear all
[Closed] C# net Color with gamma 2.2
Jun 27, 2016 4:55 am
Does anyone formula how to convert net color in c# to corrected gamma 2.2 ? I searched across the net but I can’t find it…
simple formula like this one maybe…but in C#…
fn correctColorGamma c =
(
255.0 * color ((c.r/255)^2.2) ((c.g/255)^2.2) ((c.b/255)^2.2)
)
it seem I cant use those formula in c# because “ ^ ” and color must be in int or byte [correct me if I wrong], but those formula result in float or double, I think.
Im new in c# and not math prof too. Thanks for helping.