Color转ArcEngine的IRgbColor与IColor

Color转ArcEngine的IRgbColor与IColor

//Color转ArcEngine的IRgbColor

public static IRgbColor ColorToIRgbColor(Color pColor)

{

IRgbColor pRgbColor = new RgbColorClass();

pRgbColor.RGB = pColor.B * 65536 + pColor.G * 256 + pColor.R;

return pRgbColor;

}

//Color转ArcEngine的IColor

public static IColor ColorToIColor(Color color)

{

IColor pColor = new RgbColorClass();

pColor.RGB = color.B * 65536 + color.G * 256 + color.R;

return pColor;

}

转载自:https://blog.csdn.net/iteye_9770/article/details/81787819

You may also like...