    ' Fill with solid brush:
      hBrush = CreateSolidBrush(TranslateColor(oEndColor))
      FillRect lHDC, tR, hBrush
      DeleteObject hBrush
   End If
   
End Sub

Private Sub setTriVertexColor(tTV As TRIVERTEX, lColor As Long)
Dim lRed As Long
Dim lGreen As Long
Dim lBlue As Long
   lRed = (lColor And &amp;HFF&amp;) * &amp;H100&amp;
   lGreen = (lColor And &amp;HFF00&amp;)
   lBlue = (lColor And &amp;HFF0000) \ &amp;H100&amp;
   setTriVertexColorComponent tTV.Red, lRed
   setTriVertexColorComponent tT