implement Color.ToUInt32

This commit is contained in:
Michael Becker 2022-03-17 14:27:24 -04:00
parent 6d1aae1600
commit 55af41f5cb
No known key found for this signature in database
GPG Key ID: 98C333A81F18C22C

View File

@ -203,7 +203,13 @@ namespace MBS.Framework.Drawing
public int ToInt32()
{
return BitConverter.ToInt32(new byte[] { (byte)mvarA, (byte)mvarB, (byte)mvarG, (byte)mvarR }, 0);
int index = BitConverter.ToInt32(new byte[] { GetAlphaByte(), GetBlueByte(), GetGreenByte(), GetRedByte() }, 0);
return index;
}
public uint ToUInt32()
{
uint index = BitConverter.ToUInt32(new byte[] { GetAlphaByte(), GetBlueByte(), GetGreenByte(), GetRedByte() }, 0);
return index;
}
public override string ToString()