3

I have two colors that I need to linearly interpolate to create a duotone color based of another color's luminance value.

Dim clr1 = Color.Black
Dim clr2 = Color.FromArgb(224, 255, 165)
Dim lum = Color.FromArgb(226, 189, 136).GetBrightness
'lum = 0.71

I know the result of this should be R=171, G=192, B=125, but I can't figure out how to do this. I've searched through SO quite a bit and all over Google, but have not discovered a way to produce this result. Can anyone help?

Community
  • 1
  • 1
Todd Main
  • 28,951
  • 11
  • 82
  • 146

1 Answers1

1

Figured it out - my lum value should have been using relative luminance instead.

Todd Main
  • 28,951
  • 11
  • 82
  • 146