m lC As Long
   lC = GetDIBColorTable(cDIB.hdc, 0, 256, tRGB(0))
   Debug.Assert (lC = 256)
   If (lC &gt; 0) Then
      lC = SetDIBColorTable(m_hDC, 0, 256, tRGB(0))
      Debug.Assert (lC = 256)
   End If
End Sub
Private Sub RGBToHSL( _
      ByVal r As Long, ByVal g As Long, ByVal b As Long, _
      h As Single, s As Single, l As Single _
   )
Dim Max As Single
Dim Min As Single
Dim delta As Single
Dim rR As Single, rG As Single, rB As Single

   rR = r / 255: rG = g / 255: rB = b / 255

'{Given: rgb eac