Good day everyone,
I am stuck trying to convert a uint color value into its equivalent argb hexadecimal format. Basically, I am trying to convert a color from Flex(AS3) into its appropriate kml color, which is in the argb hexadecimal format from what I gather. Below is my function as it stands now. Although it does convert into a valid kml color, it is not the right color or even close. Does anyone see anything wrong here?
private static function getKmlColor(color:uint,alpha:Number):String
{
var argb:uint = 0;
var alphaUint:uint = 255 * alpha;
argb += (alphaUint<<24);
argb += (color);
return argb.toString(16);
}