The Graphics class in the GHIElectronics.TinyCLR.Drawing assembly contains this method:
public void DrawString(string s, Font font, Brush brush, float x, float y)
{
if (brush is SolidBrush solidBrush)
{
if (solidBrush.Color.A != byte.MaxValue)
{
throw new NotSupportedException("Alpha not supported.");
}
surface.DrawText(s, font, (uint)(solidBrush.Color.value & 0xFFFFFF), (int)x, (int)y);
return;
}
throw new NotSupportedException();
}
I am calling this method in two programs in identical (as far as i can tell) ways, namely with a white (255, 255, 255, 255) color. In one program the text is drawn on my screen with a nice white color. In the other program the text has an off white color. I suspect the text is being drawn with some transparency though I cant pinpoint how this is happening, or really what is happening. Like i said the method is being called with the same arguments in both cases. its all of the same hardware.
Has anyone had this problem before or one like it?
Thanks for any help that can be offered.